Showing both Master and Detail View in portrait mode in MGSplitViewController #46

rajatmohanty opened this Issue Oct 27, 2011 · 0 comments


None yet
1 participant

I am currently integrating MGSplitViewController in one of my application and its working properly.

But i want to modify the way it is displaying currently in portrait mode.So i want in portrait mode whenever application open it should display both master as well as detail view controller.So on pressing the navigation bar button it will again hide and show the left root view controller.

So i have changed the code to

  • (BOOL)shouldShowMasterForInterfaceOrientation:(UIInterfaceOrientation)theOrientation
    // Returns YES if master view should be shown directly embedded in the splitview, instead of hidden in a popover.
    //return ((UIInterfaceOrientationIsLandscape(theOrientation)) ? _showsMasterInLandscape : _showsMasterInPortrait);

    return YES;
    Now both portrait and landscape mode is showing both root and detail view controller as i wants but the problem is navigation bar button is not working to hide & show left root view controller.

Any body have done this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment