I have looked around for an answer, and I see related problems on this and other sites, but the solutions do not relate to me. I have an app that was working just fine before I upgraded to IOS 4.2. Now the app does not load the view which includes an image background, and a collection of buttons and labels. The app has a timer in it, and I can determine that the timer is running because from another post I can show that the following methods are executed during startup:
SELECTOR: application:handleOpenURL:
SELECTOR: application:openURL:sourceApplication:annotation:
SELECTOR: applicationDidReceiveMemoryWarning:
SELECTOR: applicationWillTerminate:
SELECTOR: applicationSignificantTimeChange:
SELECTOR: application:willChangeStatusBarOrientation:duration:
SELECTOR: application:didChangeStatusBarOrientation:
SELECTOR: application:willChangeStatusBarFrame:
SELECTOR: application:didChangeStatusBarFrame:
SELECTOR: application:deviceAccelerated:
SELECTOR: application:deviceChangedOrientation:
SELECTOR: applicationDidBecomeActive:
SELECTOR: applicationWillResignActive:
SELECTOR: applicationDidEnterBackground:
SELECTOR: applicationWillEnterForeground:
SELECTOR: applicationWillSuspend:
SELECTOR: application:didResumeWithOptions:
SELECTOR: application:didFinishLaunchingWithOptions:
SELECTOR: applicationDidFinishLaunching:
SELECTOR: createTimer
The view should have loaded. I am not getting any error messages. THe following is my applicationDidFinishLaunching: method.
- (void)applicationDidFinishLaunching:(UIApplication *)application {
// Override point for customization after app launch
// set instance variable for view controller
viewController.pressNumberNext = TRUE;
// reset total and last value
viewController.userTotal = 0;
// clear status text
viewController.status.text = @"";
// initalize the number of digits entered
viewController.numberOfDigits = 0;
// disable interaction with status area
[viewController.status setUserInteractionEnabled:NO];
// initialize items for the tokenizer
viewController.endOfInput = [PKToken EOFToken];
viewController.randomExpr = [[NSString alloc] initWithString:@""];
// debugging flags
viewController.debugSolution = false; // debug flag to show solution under status
// initialize the timer
viewController.timeCount = MAXTIME;
// timer should start running
viewController.pauseTimer = false;
// timer reset initialized
viewController.timerNeedsReset = false;
[window addSubview:viewController.view];
[window makeKeyAndVisible];
}
Any help would be greatly appreciated. Thank you.
Things to check:
How does the view get loaded? Via a nib, or via code in loadView?
In either case, check the frame of the view. Log it out in viewDidAppear:animated:.
Also check your view's alpha and hidden properties.
Are you doing anything wierd with the main window? Is the main-window
frame set to the bounds of the
screen? Is clipsToBounds set on the window?