コード例 #1
0
 public MenuPresenterViewModel([NotNull] MenuConfig config, [NotNull]ISoundService soundService)
 {
     _config = config;
     _soundService = soundService;
     Buttons = new ObservableCollection<MenuButtonViewModel>();
     buttonsEnteringDelayTimer.Tick += ButtonsEnteringDelayTimer_Tick;
     buttonsLeavingDelayTimer.Tick += ButtonsLeavingDelayTimer_Tick;
     LoadResources();
 }
コード例 #2
0
        private void OnNavigateToMenu(Uri uri)
        {
            if (uri == null)
            {
                OnNavigateScene();
            }
            else
            {
                var navigation = new MenuNavigationModel();
                App.LoadComponent(navigation, uri);

                _mainMenuService.NavigateContent(navigation.ViewType);
                MenuConfig = navigation.MenuConfig;
            }
        }