protected override void OnInitialize() { base.OnInitialize(); //初始化Binder Binder.Add <string>("Name", OnNamePropertyVlaueChanged); Binder.Add <int>("Level", OnLevelPropertyValueChanged); Binder.Add <string>("Face", OnFacePropertyValueChanged); Binder.Add <Badge>("Badge", OnBadgePropertyValueChanged); //监听事件 var beginDragEntry = new EventTrigger.Entry(); beginDragEntry.eventID = EventTriggerType.BeginDrag; beginDragEntry.callback.AddListener(eventData => { OnBeginDrag(); }); eventTrigger.triggers.Add(beginDragEntry); var dragEntry = new EventTrigger.Entry(); dragEntry.eventID = EventTriggerType.Drag; dragEntry.callback.AddListener(eventData => { OnDrag(); }); eventTrigger.triggers.Add(dragEntry); var endDragEntry = new EventTrigger.Entry(); endDragEntry.eventID = EventTriggerType.EndDrag; endDragEntry.callback.AddListener(eventData => { OnEndDrag(); }); eventTrigger.triggers.Add(endDragEntry); var pointClickEntry = new EventTrigger.Entry(); pointClickEntry.eventID = EventTriggerType.PointerClick; pointClickEntry.callback.AddListener(eventData => { OnClick(); }); eventTrigger.triggers.Add(pointClickEntry); }
protected override void OnInitialize() { base.OnInitialize(); Binder.Add <string>("TestName", OnTestNameValueChanged); Binder.Add <string>("TestInput", OnTestInputValueChanged); }
public override void Initialize() { base.Initialize(); info = dictBind.FindUI <Text>("info"); dictBind.AddButton("BackButton", OnBackButton); Binder.Add <string>("info", OnInfo); }
public override void Initialize() { base.Initialize(); Binder.Add <string>("Name", OnNamePropertyValueChanged); Binder.Add <string>("Job", OnJobPropertyValueChanged); Binder.Add <int>("ATK", OnATKPropertyValueChanged); Binder.Add <float>("SuccessRate", OnSuccessRatePropertyValueChanged); Binder.Add <State>("State", OnStatePropertyValueChanged); }
protected override void OnInit() { NBsn.C_Global.Instance.Log.InfoFormat("NBsn.NMVVM.LuaConsoleV.OnInit()"); Binder.Add <string>("TextOutput", VMOnTextOutputChanged); var vm = new LuaConsoleVM(); SetVM(vm); }
protected override void OnInit() { NBsn.C_Global.Instance.Log.InfoFormat("NBsn.NMVVM.LoginV.OnInit()"); Binder.Add <string>("NameDefault", VMOnNameDefaultChanged); var vm = new LoginVM(); SetVM(vm); }
public override void Initialize() { base.Initialize(); LoginState = dictBind.FindUI <Text>("LoginState"); InputAccount = dictBind.FindUI <InputField>("InputAccount"); InputPassed = dictBind.FindUI <InputField>("InputPassed"); dictBind.AddButton("LoginButton", OnLoginButton); dictBind.AddButton("BackButton", OnBackButton); Binder.Add <string>("LoginState", OnLoginState); }
protected override void OnInit() { NBsn.C_Global.Instance.Log.InfoFormat("NBsn.NMVVM.MsgV.OnInit()"); Binder.Add <string>("Name", VMOnNameChanged); Binder.Add <string>("Desc", VMOnDescChanged); var vm = new MsgVM(); SetVM(vm); }
protected override void OnInitialize() { base.OnInitialize(); Binder.Add <string>("AccountText", OnAccountInputValueChanged); Binder.Add <string>("PasswordText", OnPasswordInputValueChanged); //Binder.Add<string>(nameof(ViewModel.AccountText), OnAccountInputValueChanged); //Binder.Add<string>(nameof(ViewModel.PasswordText), OnAccountInputValueChanged); }
protected override void OnInit() { NBsn.C_Global.Instance.Log.InfoFormat("NBsn.NMVVM.UpdateV.OnInit()"); Binder.Add <string>("TextCenter", VMOnTextCenterChanged); Binder.Add <string>("TextName", VMOnTextNameChanged); Binder.Add <string>("TextDesc", VMOnTextDescChanged); Binder.Add <string>("TextLocalVer", VMOnTextLocalVerChanged); Binder.Add <string>("TextServerVer", VMOnTextServerVerChanged); Binder.Add <uint>("SliderValue", VMOnSliderValueChanged); var vm = new UpdateVM(); SetVM(vm); }
public override void Initialize() { base.Initialize(); LoginState = dictBind.FindUI <Text>("LoginState"); InputField = dictBind.FindUI <InputField>("InputField"); dictBind.AddButton("StartButton", OnStartButton); dictBind.AddButton("LoginButton", OnLoginButton); dictBind.AddButton("SendButton", OnSendButton); dictBind.AddButton("RegisterButton", OnRegisterButton); Binder.Add <string>("LoginState", OnLoginState); //Binder.Add<string>("Job", OnJobPropertyValueChanged); //Binder.Add<int>("ATK", OnATKPropertyValueChanged); //Binder.Add<float>("SuccessRate", OnSuccessRatePropertyValueChanged); //Binder.Add<State>("State", OnStatePropertyValueChanged); }
protected override void OnInitialize() { base.OnInitialize(); Binder.Add <string>("Color", OnColorPropertyValueChanged); }
protected override void OnInitialize() { base.OnInitialize(); Binder.Add <string>("Icon", OnIconPropertyValueChanged); Binder.Add <string>("ElementColor", OnElementColorPropertyValueChanged); }