I am doing an imaging app for iPad and it requires use of the entire screen. The approach I have used on iPhone does not appear to work on iPad. In Interface Builder I have set the UIToolbar to translucent.This code echos the dimensions of the main view before and after requesting fullscreen.
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[self.window addSubview:self.viewController.view];
NSLog(@"Hello Popover AD - application did Finish Launching With Options - viewSize: %f %f BEFORE",
self.viewController.view.bounds.size.width, self.viewController.view.bounds.size.height);
[self.viewController setWantsFullScreenLayout:YES];
[self.viewController.view layoutIfNeeded];
NSLog(@"Hello Popover AD - application did Finish Launching With Options - viewSize: %f %f AFTER",
self.viewController.view.bounds.size.width, self.viewController.view.bounds.size.height);
[self.window makeKeyAndVisible];
return YES;
}
This is what NSlog has to say:
Hello Popover AD - application did Finish Launching With Options - viewSize: 768 1004 BEFORE
Hello Popover AD - application did Finish Launching With Options - viewSize: 768 1004 AFTER
Can someone please tell me what I am doing incorrectly here? Note, on iPhone I set fullscreen within the init method of the relevant ViewController. Can view resizing only be done in a ViewController?
My ultimate goal is a fullscreen view nicely tucked underneath a translucent status bar and tool bar. I will retract the status/tool bars when user interaction begins in the main view.
Thanks,
Doug