private void OnDestroy() { _shipListPanel = null; _maskList = null; _mainObj = null; AllShips = null; ship = null; KeyController = null; ListScroll = null; }
private void OnDestroy() { this._shipListPanel = null; this._maskList = null; this._mainObj = null; this.AllShips = null; this.ship = null; TaskOrganizeList.KeyController = null; TaskOrganizeList.ListScroll = null; }
public void FirstInit() { if (!IsCreated) { IsCreate = false; IsShip = false; AllShips = OrganizeTaskManager.Instance.GetLogicManager().GetShipList(); KeyController = new KeyControl(); KeyController.useDoubleIndex(0, 3); _mainObj = OrganizeTaskManager.GetMainObject().transform.FindChild("OrganizeScrollListParent").gameObject; _shipListPanel = _mainObj.transform.FindChild("List/ListFrame/ShipListScroll").gameObject; _maskList = ((Component)_mainObj.transform.FindChild("Panel/ListBackMask")).GetComponent <UITexture>(); UIButtonMessage component = _maskList.GetComponent <UIButtonMessage>(); component.target = base.gameObject; component.functionName = "BackListEL"; component.trigger = UIButtonMessage.Trigger.OnClick; ListScroll = ((Component)_mainObj.transform.FindChild("List")).GetComponent <OrganizeScrollListParent>(); ListScroll.Initialize(OrganizeTaskManager.Instance.GetLogicManager(), Camera); ListScroll.HeadFocus(); ListScroll.SetOnSelect(ListSelectEL); ListScroll.SetOnCancel(ListCancelEL); IsCreated = true; } }
public void FirstInit() { if (!this.IsCreated) { this.IsCreate = false; this.IsShip = false; this.AllShips = OrganizeTaskManager.Instance.GetLogicManager().GetShipList(); TaskOrganizeList.KeyController = new KeyControl(0, 0, 0.4f, 0.1f); TaskOrganizeList.KeyController.useDoubleIndex(0, 3); this._mainObj = OrganizeTaskManager.GetMainObject().get_transform().FindChild("OrganizeScrollListParent").get_gameObject(); this._shipListPanel = this._mainObj.get_transform().FindChild("List/ListFrame/ShipListScroll").get_gameObject(); this._maskList = this._mainObj.get_transform().FindChild("Panel/ListBackMask").GetComponent <UITexture>(); UIButtonMessage component = this._maskList.GetComponent <UIButtonMessage>(); component.target = base.get_gameObject(); component.functionName = "BackListEL"; component.trigger = UIButtonMessage.Trigger.OnClick; TaskOrganizeList.ListScroll = this._mainObj.get_transform().FindChild("List").GetComponent <OrganizeScrollListParent>(); TaskOrganizeList.ListScroll.Initialize(OrganizeTaskManager.Instance.GetLogicManager(), this.Camera); TaskOrganizeList.ListScroll.HeadFocus(); TaskOrganizeList.ListScroll.SetOnSelect(new OrganizeScrollListParent.OnSelectCallBack(this.ListSelectEL)); TaskOrganizeList.ListScroll.SetOnCancel(new Action(this.ListCancelEL)); this.IsCreated = true; } }