コード例 #1
0
        ///// <summary>
        ///// This will be invoked by view when this instance of viewmodel in ViewModel property is overwritten.
        ///// </summary>
        ///// <param name="view">Overwrite target view.</param>
        ///// <param name="newValue">The value replacing </param>
        ///// <returns>Task awaiter</returns>
        //protected override Task OnUnbindedFromView(MVVMSidekick.Views.IView view, IViewModel newValue)
        //{
        //    return base.OnUnbindedFromView(view, newValue);
        //}

        /// <summary>
        /// This will be invoked by view when the view fires Load event and this viewmodel instance is already in view's ViewModel property
        /// </summary>
        /// <param name="view">View that firing Load event</param>
        /// <returns>Task awaiter</returns>
        protected async override Task OnBindedViewLoad(MVVMSidekick.Views.IView view)
        {
            await base.OnBindedViewLoad(view);

            MapLandMarkVisible = AppSettings.Intance.GetAppSetting(AppSettings.LandmarksVisibleSettingKey);
            //var visible = AppSettings.Intance.GetAppSetting(AppSettings.LandmarksVisibleSettingKey);
            //MVVMSidekick.EventRouting.EventRouter.Instance.RaiseEvent(this, visible, typeof(bool), "ChangeMapLandMarks", true);
        }
コード例 #2
0
 /// <summary>
 /// This will be invoked by view when the view fires Load event and this viewmodel instance is already in view's ViewModel property
 /// </summary>
 /// <param name="view">View that firing Load event</param>
 /// <returns>Task awaiter</returns>
 protected override Task OnBindedViewLoad(MVVMSidekick.Views.IView view)
 {
     if (!isLoadSuscribe)
     {
         SuscribeCommand();
         isLoadSuscribe = true;
     }
     return(base.OnBindedViewLoad(view));
 }
コード例 #3
0
 /// <summary>
 /// This will be invoked by view when this viewmodel instance is set to view's ViewModel property.
 /// </summary>
 /// <param name="view">Set target</param>
 /// <param name="oldValue">Value before set.</param>
 /// <returns>Task awaiter</returns>
 protected override Task OnBindedToView(MVVMSidekick.Views.IView view, IViewModel oldValue)
 {
     return(base.OnBindedToView(view, oldValue));
 }
コード例 #4
0
        ///// <summary>
        ///// This will be invoked by view when this viewmodel instance is set to view's ViewModel property.
        ///// </summary>
        ///// <param name="view">Set target</param>
        ///// <param name="oldValue">Value before set.</param>
        ///// <returns>Task awaiter</returns>
        //protected override Task OnBindedToView(MVVMSidekick.Views.IView view, IViewModel oldValue)
        //{
        //    return base.OnBindedToView(view, oldValue);
        //}

        ///// <summary>
        ///// This will be invoked by view when this instance of viewmodel in ViewModel property is overwritten.
        ///// </summary>
        ///// <param name="view">Overwrite target view.</param>
        ///// <param name="newValue">The value replacing </param>
        ///// <returns>Task awaiter</returns>
        protected override Task OnUnbindedFromView(MVVMSidekick.Views.IView view, IViewModel newValue)
        {
            return(base.OnUnbindedFromView(view, newValue));
        }
コード例 #5
0
        ///// <summary>
        ///// This will be invoked by view when this instance of viewmodel in ViewModel property is overwritten.
        ///// </summary>
        ///// <param name="view">Overwrite target view.</param>
        ///// <param name="newValue">The value replacing </param>
        ///// <returns>Task awaiter</returns>
        //protected override Task OnUnbindedFromView(MVVMSidekick.Views.IView view, IViewModel newValue)
        //{
        //    return base.OnUnbindedFromView(view, newValue);
        //}

        /// <summary>
        /// This will be invoked by view when the view fires Load event and this viewmodel instance is already in view's ViewModel property
        /// </summary>
        /// <param name="view">View that firing Load event</param>
        /// <returns>Task awaiter</returns>
        protected override Task OnBindedViewLoad(MVVMSidekick.Views.IView view)
        {
            return(base.OnBindedViewLoad(view));
        }