Reputation:
I have a portrait view showing a library of images, clicking on an image should open it in landscape view for editing. Now I know I could manually rotate the new view 90 degrees to make it “look” like it is in landscape but isn’t there a proper solution? e.g. somehow I could force the device to go into landscape mode?
Upvotes: 0
Views: 782
Reputation:
tuns out I'll have to manually rotate my views or at least my findings suggest so. So here's what I am doing now:
Upvotes: 1
Reputation: 4167
To force the device to go to landscape mode, you can add
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)interfaceOrientation
{
return (interfaceOrientation == UIInterfaceOrientationLandscapeRight);
}
Adding this to the view you want to display in landscape should make the view come in landscape mode...
Upvotes: 0
Reputation: 10283
Push a modal view controller which is configured to only support landscape mode.
Upvotes: 0