March 2012
Intermediate to advanced
590 pages
22h 48m
English
If your application only makes sense in landscape mode, you can force it to run that way. First, in your view controller implement shouldAutorotateToInterfaceOrientation: to only return YES for landscape orientations.
- (BOOL)shouldAutorotateToInterfaceOrientation:(UIInterfaceOrientation)x
{
return UIInterfaceOrientationIsLandscape(x);
}
An application’s Info.plist contains a key-value pair that specifies the valid initial orientations of the application. Select the project from the project navigator, then the HeavyRotation target from the editor area, and finally the Summary pane.
Figure 8.12 Choosing ...
Read now
Unlock full access