Пример #1
0
 private void Update_Vm(global::NasaSpaceApp.UI.LoginPageViewModel obj, int phase)
 {
     this.bindingsTracking.UpdateChildListeners_Vm(obj);
     if (obj != null)
     {
         if ((phase & (NOT_PHASED | DATA_CHANGED | (1 << 0))) != 0)
         {
             this.Update_Vm_LoginCommand(obj.LoginCommand, phase);
             this.Update_Vm_SignUpCommand(obj.SignUpCommand, phase);
             this.Update_Vm_SignUpVisibility(obj.SignUpVisibility, phase);
             this.Update_Vm_UserName(obj.UserName, phase);
             this.Update_Vm_ErrorVisibility(obj.ErrorVisibility, phase);
         }
     }
 }
Пример #2
0
 public void UpdateChildListeners_Vm(global::NasaSpaceApp.UI.LoginPageViewModel obj)
 {
     if (obj != cache_Vm)
     {
         if (cache_Vm != null)
         {
             ((global::System.ComponentModel.INotifyPropertyChanged)cache_Vm).PropertyChanged -= PropertyChanged_Vm;
             cache_Vm = null;
         }
         if (obj != null)
         {
             cache_Vm = obj;
             ((global::System.ComponentModel.INotifyPropertyChanged)obj).PropertyChanged += PropertyChanged_Vm;
         }
     }
 }
Пример #3
0
                public void PropertyChanged_Vm(object sender, global::System.ComponentModel.PropertyChangedEventArgs e)
                {
                    LoginPageView_obj1_Bindings bindings;

                    if (WeakRefToBindingObj.TryGetTarget(out bindings))
                    {
                        string propName = e.PropertyName;
                        global::NasaSpaceApp.UI.LoginPageViewModel obj = sender as global::NasaSpaceApp.UI.LoginPageViewModel;
                        if (global::System.String.IsNullOrEmpty(propName))
                        {
                            if (obj != null)
                            {
                                bindings.Update_Vm_LoginCommand(obj.LoginCommand, DATA_CHANGED);
                                bindings.Update_Vm_SignUpCommand(obj.SignUpCommand, DATA_CHANGED);
                                bindings.Update_Vm_SignUpVisibility(obj.SignUpVisibility, DATA_CHANGED);
                                bindings.Update_Vm_UserName(obj.UserName, DATA_CHANGED);
                                bindings.Update_Vm_ErrorVisibility(obj.ErrorVisibility, DATA_CHANGED);
                            }
                        }
                        else
                        {
                            switch (propName)
                            {
                            case "LoginCommand":
                            {
                                if (obj != null)
                                {
                                    bindings.Update_Vm_LoginCommand(obj.LoginCommand, DATA_CHANGED);
                                }
                                break;
                            }

                            case "SignUpCommand":
                            {
                                if (obj != null)
                                {
                                    bindings.Update_Vm_SignUpCommand(obj.SignUpCommand, DATA_CHANGED);
                                }
                                break;
                            }

                            case "SignUpVisibility":
                            {
                                if (obj != null)
                                {
                                    bindings.Update_Vm_SignUpVisibility(obj.SignUpVisibility, DATA_CHANGED);
                                }
                                break;
                            }

                            case "UserName":
                            {
                                if (obj != null)
                                {
                                    bindings.Update_Vm_UserName(obj.UserName, DATA_CHANGED);
                                }
                                break;
                            }

                            case "ErrorVisibility":
                            {
                                if (obj != null)
                                {
                                    bindings.Update_Vm_ErrorVisibility(obj.ErrorVisibility, DATA_CHANGED);
                                }
                                break;
                            }

                            default:
                                break;
                            }
                        }
                    }
                    else
                    {
                        ReleaseAllListeners();
                    }
                }