Example #1
0
 public void SetupView(string name, int index, ClickCallBack callBack = null)
 {
     this.itemName       = name;
     this.itemIndex      = index;
     this._clickCallBack = callBack;
     base.transform.Find("Text").GetComponent <Text>().text = this.itemName;
 }
Example #2
0
 public void SetClickCallback(ClickCallBack callback)
 {
     this._clickCallBack = callback;
 }
Example #3
0
 //移除监听事件
 public void RemoveListener(ClickCallBack fun)
 {
     OnClickCallBack -= fun;
 }
Example #4
0
 public void init(ClickCallBack clickCallBack)
 {
     this.clickCallBack = clickCallBack;
 }
Example #5
0
 //增加监听事件
 public void AddListener(ClickCallBack fun)
 {
     OnClickCallBack += fun;
 }