Beispiel #1
0
 protected override void InitBinding()
 {
     this.Paramater = base.GetComponent <ButtonParamater>();
     this.Button    = base.GetComponent <Button>();
     this.OnClickBinding.Filters     = BindingBase.BindingFilter.Commands;
     this.EnabledBinding.Action      = new Action <object>(this.UpdateState);
     this.EnabledBinding.Filters     = BindingBase.BindingFilter.Properties;
     this.EnabledBinding.FilterTypes = new Type[]
     {
         typeof(bool)
     };
     this.Button.get_onClick().AddListener(new UnityAction(this.Call));
 }
Beispiel #2
0
 protected override void InitBinding()
 {
     this.Paramater = base.GetComponent <ButtonParamater>();
     this.Button    = base.GetComponent <Button>();
     this.IsPressedBinding.Filters     = BindingBase.BindingFilter.Properties;
     this.IsPressedBinding.FilterTypes = new Type[]
     {
         typeof(bool)
     };
     this.EnabledBinding.Action      = new Action <object>(this.UpdateState);
     this.EnabledBinding.Filters     = BindingBase.BindingFilter.Properties;
     this.EnabledBinding.FilterTypes = new Type[]
     {
         typeof(bool)
     };
 }
        protected override void InitBinding()
        {
            this.Paramater = base.GetComponent <ButtonParamater>();
            this.Button    = base.GetComponent <Button>();
            this.OnClickBinding.Filters     = BindingBase.BindingFilter.Commands;
            this.OnDownBinding.Filters      = BindingBase.BindingFilter.Commands;
            this.OnUpBinding.Filters        = BindingBase.BindingFilter.Commands;
            this.EnabledBinding.Action      = new Action <object>(this.UpdateState);
            this.EnabledBinding.Filters     = BindingBase.BindingFilter.Properties;
            this.EnabledBinding.FilterTypes = new Type[]
            {
                typeof(bool)
            };
            EventTriggerListener expr_88 = EventTriggerListener.Get(base.get_gameObject());

            expr_88.onDown = (EventTriggerListener.VoidDelegateGameObject)Delegate.Combine(expr_88.onDown, new EventTriggerListener.VoidDelegateGameObject(this.OnButtonDown));
            EventTriggerListener expr_B4 = EventTriggerListener.Get(base.get_gameObject());

            expr_B4.onUp = (EventTriggerListener.VoidDelegateGameObject)Delegate.Combine(expr_B4.onUp, new EventTriggerListener.VoidDelegateGameObject(this.OnButtonUp));
        }
Beispiel #4
0
 private void OnDestroy()
 {
     this.Button       = null;
     this.Paramater    = null;
     this.TargetImages = null;
 }