Closed FredzL closed 10 years ago
You need to set up your app supported orientation in your project main settings, shouldAutorotateToInterfaceOrientation
is no longer used.
You can check the sample included in this repository, the controller successfully rotates.
Ah sorry I didn't mention that it was for iOS 5.1, does the sample work in this case as well ?
You're right, this won't work in iOS5, I forgot that the library still supports that.
I'll reintroduce the shouldAutorotateToInterfaceOrientation
tomorrow with the fix for the other issue that you opened.
Thanks.
There was also a problem with the bounds when going in landscape mode, an empty bar of 20 pixels appeared at the top and was still there when back in portrait mode (maybe related to issue #39). I had to call [[self view] setFrame:[[UIScreen mainScreen] bounds]]; in viewWillAppear and viewDidLayoutSubviews in AMSlideOutNavigationController.m.
Not sure if it's the cleanest way to do it though...
While we are at it, I had to replace indexPathForItem by indexPathForRow twice in the method switchToControllerTagged in AMSlideOutNavigationController.m to make it work in iOS 5.1. Sorry for not providing pull requests, I've not yet set up Git on this machine...
Commit 38a981d enables the rotation in iOS5, also fixes the menu scrolling lock from being enabled/disabled incorrectly upon rotation.
As for the orientation's problems in iOS5: I tested it on a iOS 5 device and found no issues. Can you list here the steps to reproduce the bug? Your fix (setting the view's frame as the screen bounds) seems to 'eat' 20 pixels from the menu's TableView on iOS5 & 6, while it has no effects in iOS7.
Sorry but I don't work on this project anymore (finished), if I come back to it I will report back. Without the modifications there was a 20 pixel gap at the top of the screen when going into landscape mode that was still present when going back to portrait. Maybe one of your other commits corrected the problem.
I added this method in AMSlideOutNavigationController.m to make it work :