software-mariodiana
12/14/2016 - 2:10 PM

Create the main UIView in view controller's m-file by overriding -loadView. (Done when forgoing Xib files.)

Create the main UIView in view controller's m-file by overriding -loadView. (Done when forgoing Xib files.)

- (void)loadView
{
    // Create the main view programmatically.
    UIWindow *mainWindow = [[[UIApplication sharedApplication] delegate] window];
    UIView *view = [[UIView alloc] initWithFrame:[mainWindow bounds]];
    [view setBackgroundColor:[UIColor whiteColor]];
    self.view = view;
}