/// <summary>
        /// Launches the About view controller.
        /// </summary>
        /// <param name="sender">Sender.</param>
        /// <param name="eventArgs">Event arguments.</param>
        private void NavBarButtonInfo_TouchUpInside(object sender, EventArgs eventArgs)
        {
            // Get about storyboard
            UIStoryboard aboutStoryboard = UIStoryboard.FromName("About", null);

            // Grab about view Controller reference
            AboutViewController aboutViewController = aboutStoryboard.InstantiateInitialViewController() as AboutViewController;

            // Push about view controller onto stack
            this.NavigationController.PushViewController(aboutViewController, true);
        }
Exemple #2
0
        void ShowInfo(object sender, EventArgs e)
        {
            AppDelegate appDel = UIApplication.SharedApplication.Delegate;

            if (UIDevice.CurrentDevice.UserInterfaceIdiom == UIUserInterfaceIdiom.Phone)
            {
                AboutViewController aboutViewController = new AboutViewController("AboutViewController_iPhone", null);

                aboutViewController.ModalTransitionStyle   = UIModalTransitionStyle.FlipHorizontal;
                aboutViewController.ModalPresentationStyle = UIModalPresentationStyle.FullScreen;
                appDel.NavController.PresentViewController(aboutViewController, true, null);
            }
            else
            {
                if (!appDel.NavController.ViewControllers.Last().GetType() == typeof(AboutViewController))
                {
                    AboutViewController aboutViewController = new AboutViewController("AboutViewController_iPad", null, appDel.NavController);
                    appDel.NavController.PushViewController(aboutViewController, false);
                    aboutViewController.CleanDetailNavStack();
                }
            }
        }