Exemple #1
0
        private void UpdateContent()
        {
            KeyboardHelper.HideKeyboard(this);

            // Remove previous content
            base.RemoveAllViews();

            if (ViewModel?.Content != null)
            {
                // Create and set new content
                var view = ViewModelToViewConverter.Convert(this, ViewModel.Content);
                base.AddView(view);
            }

            else if (ViewModel != null)
            {
                var splashView = ViewModelToViewConverter.GetSplash(this, ViewModel);
                if (splashView != null)
                {
                    base.AddView(splashView);
                }
            }

            ContentChanged?.Invoke(this, new EventArgs());
        }
Exemple #2
0
        private void UpdateContent()
        {
            // Remove previous content
            base.RemoveAllViews();

            if (ViewModel != null)
            {
                // Create and set new content
                var view = ViewModelToViewConverter.Convert(this, ViewModel);
                base.AddView(view);
            }
        }