I have a Universal Xamarin Forms App with a single page wrapped in a NavigationPage:
Current.MainPage = new NavigationPage(new RootPage()
{
BackgroundColor = (Color)Application.Current.Resources["BackgroundColour"]
})
{
BackgroundColor = (Color)Application.Current.Resources["BackgroundColour"],
BarBackgroundColor = (Color)Application.Current.Resources["BackgroundColour"],
Padding = NavigationPaddingForPlatfrom()
};
I've also overridden GetSupportedInterfaceOrientations in AppDelegate and set a break point - however the break point is never hit. When I rotate in the simulator or device, the break point isn't hit. I've also set the Device Orientation in info.plist to Portrait only, however the App still rotates.
Am I missing some configuration point that's needed to control orientation?
I'm using Xamarin Forms 2.4.0.38779.
The end goal is to force a MasterDetail Page into landscape only.