iPhone: Utility Application - Open Flipside on startup

Posted by Joel on Stack Overflow See other posts from Stack Overflow or by Joel
Published on 2010-03-29T20:18:26Z Indexed on 2010/03/29 20:23 UTC
Read the original article Hit count: 481

Filed under:
|
|

I have an application that I started with the Utility Application template. I'm using the Flipside for the Settings screen. I'm having the settings serialized to a file when the app is closed and deserialized when the app is opened. If there is no file to deserialize at startup, I want the flipside to be shown so the user can enter required information.

This is what I have:

- (void)viewDidLoad
{
    flipController = [[FlipsideViewController alloc] initWithNibName:@"FlipsideView" bundle:nil];
    flipController.delegate = self;
    flipController.modalTransitionStyle = UIModalTransitionStyleFlipHorizontal;

    if(![self deserialize])
    {
        [self showInfo];
    }
}

- (IBAction)showInfo
{       
    [self presentModalViewController:flipController animated:YES]; 
}

showInfo is the method that is called with the little 'i' button is pressed on the MainView. The button works, however my call in viewDidLoad doesn't.

I have run through my code with the debugger. [self deserialize] is returning NO and [self showInfo] is being called, and I checked if flipController is nil in that context, and it's not.

I've searched around and couldn't find anyone who's tried to do the same thing. I'm stumped to as why this isn't working. Anyone see what I'm doing wrong?

Thanks

© Stack Overflow or respective owner

Related posts about iphone-sdk-3.0

Related posts about iphone