private void Core_ScreenRequested(object sender, ScreenEventArgs e) { // Shows the right screen depending on the event. switch (e.Screen) { case ScreenType.Main: NavigationManager.NavigateToGameHome(Model.Core.Cartridge.Filename, GameHomeViewModel.SectionValue_Overview); break; case ScreenType.Locations: case ScreenType.Items: NavigationManager.NavigateToGameHome(Model.Core.Cartridge.Filename, GameHomeViewModel.SectionValue_World); break; case ScreenType.Inventory: NavigationManager.NavigateToGameHome(Model.Core.Cartridge.Filename, GameHomeViewModel.SectionValue_Inventory); break; case ScreenType.Tasks: NavigationManager.NavigateToGameHome(Model.Core.Cartridge.Filename, GameHomeViewModel.SectionValue_Tasks); break; case ScreenType.Details: NavigationManager.NavigateToView(e.Object); break; default: throw new InvalidOperationException(String.Format("Unknown WherigoScreenKind cannot be processed: {0}", e.Screen.ToString())); } }
private void Core_InputRequested(object sender, ObjectEventArgs <Input> e) { // Alerts the input manager of this request. InputManager.HandleInputRequested(e.Object); // Navigates to the input view. NavigationManager.NavigateToView(e.Object); }