protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e) { // Start with calling the base implementation base.OnNavigatedTo(e); this.SupportedOrientations = GamePage.get().SupportedOrientations; // Replace the context only if it's not null. A null context should mean we were backed to the page if (e.NavigationMode != System.Windows.Navigation.NavigationMode.Back) { this.pageContext = NavigationContext.GetData <SingleSearchPageContext>(); LanguageResources.Instance.UpdateControl(this); } // Make sure the message grids are collapsed InProgressGrid.Visibility = System.Windows.Visibility.Collapsed; MessageGrid.Visibility = System.Windows.Visibility.Collapsed; }
protected override void OnNavigatedTo(System.Windows.Navigation.NavigationEventArgs e) { // Start with calling the base implementation base.OnNavigatedTo(e); this.SupportedOrientations = GamePage.get().SupportedOrientations; // Replace the context only if it's not null. A null context should mean we were backed to the page if (e.NavigationMode != System.Windows.Navigation.NavigationMode.Back) { this.pageContext = NavigationContext.GetData<SingleSearchPageContext>(); LanguageResources.Instance.UpdateControl(this); } // Make sure the message grids are collapsed InProgressGrid.Visibility = System.Windows.Visibility.Collapsed; MessageGrid.Visibility = System.Windows.Visibility.Collapsed; }
public static void NOPH_SearchDialog_showDialog(int in_callback) { System.Windows.Deployment.Current.Dispatcher.BeginInvoke(() => { var mainScreen = ((App)Application.Current).RootFrame.Content as WazeApplicationPage; if (mainScreen != null) { var searchPageContext = new SingleSearchPageContext { OnActionSelected = (selectedAction, searchString) => { CRunTime.stringToCharPtr(searchString, textAddr); int c_editbox_callback = CibylCallTable.getAddressByName("rim_on_editbox_closed"); UIWorker.addUIEvent(c_editbox_callback, in_callback, 0, (int)selectedAction, 0, true); } }; mainScreen.NavigationService.Navigate<SingleSearchPage>(searchPageContext); } }); }