aryaxt / iOS-Slide-Menu

iOS Slide Menu with ability to add both left and right menu, and built in gesture recognizer. Similar to Path and Facebook
Other
1.53k stars 359 forks source link

Complete view is reverse in iOS7 #138 #171

Closed evgeniyd closed 9 years ago

evgeniyd commented 9 years ago

This is an approach I've been taken to fix the opposite slide issue in my project. Fallback to Portrait in case the orientation is invalid.

aryaxt commented 9 years ago

Hey @evgeniyd Thanks for the PR. I'm extremely busy right now will go over it this weekend.

I'm sure there are more places in the code that UIDeviceOrientation is used (ex: in Animator classes) Also wondering what the behavior would be if device goes form landscape to face up and then trying to interact with the menu. I'll test it, but I think we should save the last valid orientation and use that instead of assuming UIDeviceOrientationPortrait

I think this is how it should be fixed to cover all cases

Or a different option is to use UIViewController methods to detect rotation

willRotateToInterfaceOrientation:duration for iOS7- viewWillTransitionToSize: withTransitionCoordinator for iOS8+