public override void Execute(INotice notice) { switch (notice.GetType()) { case Command_Show: GameObject go = null; GameObject root = GameObject.Find("UIRoot"); go = root.transform.Find("OtherWindow").gameObject; this.mediator = RegisterMediator <OtherMediator>(go); this.SendToMediator(notice); break; case Command_Close: RemoveMediator(); break; case Command_OK: ChangeScene("OtherScene", (token) => { SelfNotice(Command_Show); }); break; } base.Execute(notice); }
protected override void OnDispose() { SaveViewObj(); that = null; base.OnDispose(); }
protected override void OnInitialize() { that = this; this.button = this.transform.Find("Image/Button").GetComponent <Button>(); base.OnInitialize(); }