示例#1
0
 protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
 {
     base.InitializeViewModel(model);
     // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
     // var vm = model as TestViewModel;
     // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
 }
示例#2
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            CoreGameRootViewModel coreGame = model as CoreGameRootViewModel;

            coreGame.LBRoom     = Network.Client.CurrentRoom;
            coreGame.PlayerName = Network.Client.PlayerName;
        }
示例#3
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as SubScreenViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var subscreenview = ((SubScreenViewModel)model);

            subscreenview.IsActive = this._IsActive;
        }
示例#4
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as DebugInfoPanelViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var debuginfopanelview = ((DebugInfoPanelViewModel)model);

            debuginfopanelview.Text = this._Text;
        }
示例#5
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as MainMenuRootViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var mainmenurootview = ((MainMenuRootViewModel)model);

            mainmenurootview.CurrentScreenType = this._CurrentScreenType;
        }
示例#6
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as LobbyPanelViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var lobbypanelview = ((LobbyPanelViewModel)model);

            lobbypanelview.RoomId = this._RoomId;
        }
示例#7
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as OutOfGameRootViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var outofgamerootview = ((OutOfGameRootViewModel)model);

            outofgamerootview.CanvasRoot = this._CanvasRoot == null ? null :  ViewService.FetchViewModel(this._CanvasRoot) as CanvasRootViewModel;
        }
示例#8
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as TodoItemViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var todoitemview = ((TodoItemViewModel)model);

            todoitemview.Content  = this._Content;
            todoitemview.Finished = this._Finished;
        }
示例#9
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as RoomPanelViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var roompanelview = ((RoomPanelViewModel)model);

            roompanelview.RoomPropertiesJson = this._RoomPropertiesJson;
            roompanelview.EventParamsJson    = this._EventParamsJson;
        }
示例#10
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as UserViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var mainmenuuserview = ((UserViewModel)model);

            mainmenuuserview.AuthorizationState = this._AuthorizationState;
            mainmenuuserview.Username           = this._Username;
        }
示例#11
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as UIPlayerInfoViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var uiplayerinfoview = ((UIPlayerInfoViewModel)model);

            uiplayerinfoview.Title    = this._Title;
            uiplayerinfoview.Username = this._Username;
        }
示例#12
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as GameHUDViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var gamehudview = ((GameHUDViewModel)model);

            gamehudview.TimeLimit = this._TimeLimit;
            gamehudview.Score     = this._Score;
        }
示例#13
0
    protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
    {
        base.InitializeViewModel(model);
        // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
        // var vm = model as EntityViewModel;
        // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
        var entityview = ((EntityViewModel)model);

        entityview.Name     = this._Name;
        entityview.Position = this._Position;
        entityview.Health   = this._Health;
    }
示例#14
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as LoginScreenViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var loginscreenview = ((LoginScreenViewModel)model);

            loginscreenview.Username     = this._Username;
            loginscreenview.Password     = this._Password;
            loginscreenview.ErrorMessage = this._ErrorMessage;
        }
示例#15
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as TodoListViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var todolistview = ((TodoListViewModel)model);

            todolistview.TodoContent = this._TodoContent;
            todolistview.PageType    = this._PageType;
            todolistview.TodoEditor  = this._TodoEditor == null ? null :  ViewService.FetchViewModel(this._TodoEditor) as TodoEditorViewModel;
            todolistview.EventMask   = this._EventMask == null ? null :  ViewService.FetchViewModel(this._EventMask) as EventMaskViewModel;
        }
示例#16
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as TodoEditorViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var todoeditorview = ((TodoEditorViewModel)model);

            todoeditorview.TodoContent   = this._TodoContent;
            todoeditorview.State         = this._State;
            todoeditorview.TodoItem      = this._TodoItem == null ? null :  ViewService.FetchViewModel(this._TodoItem) as TodoItemViewModel;
            todoeditorview.OriginContent = this._OriginContent;
        }
示例#17
0
    protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
    {
        base.InitializeViewModel(model);
        // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
        // var vm = model as TestViewModel;
        // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
        var testview = ((TestViewModel)model);

        testview.Name          = this._Name;
        testview.IsAmazing     = this._IsAmazing;
        testview.Complex       = this._Complex;
        testview.Reference     = this._Reference;
        testview.SomeUnityType = this._SomeUnityType;
    }
示例#18
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as CubeViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var cubeview = ((CubeViewModel)model);

            cubeview.Id      = this._Id;
            cubeview.Type    = this._Type;
            cubeview.Point   = this._Point;
            cubeview.AddTime = this._AddTime;
            cubeview.Expire  = this._Expire;
        }
示例#19
0
        protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
        {
            base.InitializeViewModel(model);
            // NOTE: this method is only invoked if the 'Initialize ViewModel' is checked in the inspector.
            // var vm = model as PlayerItemViewModel;
            // This method is invoked when applying the data from the inspector to the viewmodel.  Add any view-specific customizations here.
            var playeritemview = ((PlayerItemViewModel)model);

            playeritemview.ActerId = this._ActerId;
            playeritemview.Name    = this._Name;
            playeritemview.Ready   = this._Ready;
            playeritemview.Player  = this._Player;
            playeritemview.IsLocal = this._IsLocal;
        }
示例#20
0
    private static void DoViewModelGUI(ViewModel t)
    {
        if (t == null)
        {
            return;
        }

        var properties = t.GetViewModelProperties();

        foreach (var property in properties)
        {
            var type = property.Property.ValueType;
            DoViewModelProperty(type, property);
        }
    }
示例#21
0
 public override void DisposingViewModel(uFrame.MVVM.ViewModel viewModel)
 {
     base.DisposingViewModel(viewModel);
     UserViewModelManager.Remove(viewModel);
 }
示例#22
0
 public override void Initialize(uFrame.MVVM.ViewModel viewModel)
 {
     base.Initialize(viewModel);
     // This is called when a viewmodel is created
     this.InitializeUser(((UserViewModel)(viewModel)));
 }
示例#23
0
    private static void DoViewModelGUI(ViewModel t)
    {
        if (t == null) return;

        var properties = t.GetViewModelProperties();
        foreach (var property in properties)
        {
            var type = property.Property.ValueType;
            DoViewModelProperty(type, property);
        }
    }
示例#24
0
 protected override void InitializeViewModel(uFrame.MVVM.ViewModel model)
 {
     base.InitializeViewModel(model);
 }
示例#25
0
 public override uFrame.MVVM.ViewBase PanelCollectionCreateView(uFrame.MVVM.ViewModel viewModel)
 {
     return(InstantiateView(viewModel));
 }
示例#26
0
 public virtual uFrame.MVVM.ViewBase ScreensCreateView(uFrame.MVVM.ViewModel viewModel)
 {
     return(InstantiateView(viewModel));
 }
示例#27
0
 public override void DisposingViewModel(uFrame.MVVM.ViewModel viewModel)
 {
     base.DisposingViewModel(viewModel);
     LevelSelectScreenViewModelManager.Remove(viewModel);
 }
示例#28
0
 public override void Initialize(uFrame.MVVM.ViewModel viewModel)
 {
     base.Initialize(viewModel);
     // This is called when a viewmodel is created
     this.InitializeMainMenuRoot(((MainMenuRootViewModel)(viewModel)));
 }
示例#29
0
        public override uFrame.MVVM.ViewBase HandCardsCreateView(uFrame.MVVM.ViewModel viewModel)
        {
            GameObject prefab = Resources.Load <GameObject> ("_Card_Blue_");

            return(InstantiateView(prefab, viewModel));
        }
示例#30
0
 public override uFrame.MVVM.ViewBase ScreensCreateView(uFrame.MVVM.ViewModel viewModel)
 {
     return(InstantiateView(viewModel));
 }
示例#31
0
 public virtual uFrame.MVVM.ViewBase PlayerItemsCreateView(uFrame.MVVM.ViewModel viewModel)
 {
     return(InstantiateView(viewModel));
 }