private void InitializeButton(IButtonInstance button) { if (!button.isInitialize) { button.Initialize(this); } }
public void RegistButton(IButtonInstance button) { if (this.ContainsButton(button.ID)) { this.RemoveButton(button.ID); if (isDebug) { Debug.Log(string.Format("{0}將已註冊之按鈕[{1}]覆蓋", debugName, button.ID)); } } this.buttonList.Add(button); button.Initialize(this); if (onButtonChange != null) { onButtonChange(this, new ButtonChangeArgs(button, ButtonChange.REGIST)); } }