Clancey / FlyoutNavigation

Other
95 stars 87 forks source link

FlyoutNavigation and sub-pages with NavigationController #53

Closed gridr-ch closed 10 years ago

gridr-ch commented 10 years ago

When I use the FlyoutNavigation, i have an empty space on top of my app (the NavigationBar of the NavigationController). To hide this, I can just set NavigationBar.NavigationBarHidden = true.

The issue now is, that if I have detail pages, where I want to use the NavigationBar (for swipe-back navigation etc.), I have to NavigationBarHidden = false again etc., which produces ugly effects for the user.

Is there a possibility to have the header of the main views (the ones listed in the menu) in the NavigationBar? Or is there an even better solution to this?

Regards & thanks for the help, Marcel

Clancey commented 10 years ago

The flyout should not be nested inside a navigation controller. Instead each deatil gets its own navigation controller like this:

flyout.ViewControllers = new []{ new UINavigationController(new MyVC1()), new UINavigationController(new MyVC2()), new UINavigationController(new MyVC3()), }

gridr-ch commented 10 years ago

Hi Clancey,

Thanks for your answer and sorry if my questions seem a bit silly (i am a beginner in Xamarin and iOS).

I am using MvvmCross as framework, so I am not really sure what is going on in there, but I am not actively creating a UINavigationController. Do you by chance know how to get this right?

Thanks, Marcel

Edit: As far as I know, my flyout is not nested inside a UINavigationController.

gridr-ch commented 10 years ago

I try to find a solution for this as well on stackoverflow: http://stackoverflow.com/questions/23474304/flyoutnavigationcontroller-mvvmcross-and-navigationcontroller