Created
March 19, 2011 22:27
-
-
Save alexleutgoeb/877866 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation { | |
if (self.tabBarController.selectedViewController == self.navigationController) | |
return NO; | |
else | |
return (interfaceOrientation != UIInterfaceOrientationPortraitUpsideDown); | |
} |
Hab das auch mal probiert, jedoch musste ich dann view + status bar manuell drehen, und das war richtig böse. Das ist dann der Fall den Peter meinte: don't fight the framework. ;)
Evtl kannst du "einfach" das Interface nochmal überdenken?
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Danke für das Code-Segment, so weit hab ichs derzeit auch. Ich war bei meinem Tweet leider nicht exakt genug, eigentlich will ich nicht die Rotation in diesem Tab verhindern, sondern ich will dass dieser Tab immer im Portrait-Modus erscheint. Das Problem mit dieser Lösung ist also wenn die App im Landscape ist, und der User auf den Tab wechselt. Dann sollte sich die App in den Portrait-Modus drehen….