Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- presenting modal view from app delegate unbalanced calls to begin/end appearance
- - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
- self.window.rootViewController = self.tabBarController;
- [self.window makeKeyAndVisible];
- Security *security = [[Security alloc] initWithNibName:@"Security" bundle:nil];
- [self.tabBarController.selectedViewController presentModalViewController:security animated:YES];
- [security release];
- return YES;
- Unbalanced calls to begin/end appearance transitions for <UITabBarController: 0x171320>.
- -(BOOL)tabBarController:(UITabBarController *)tabBarController shouldSelectViewController:(UIViewController *)viewController {
- if (viewController == [tabBarController.viewControllers objectAtIndex:2]) {
- //The Log Out tab locks the app by presenting a modalviewcontroller that can't be dismissed unless there is a password.
- Security *security = [[Security alloc] initWithNibName:@"Security" bundle:nil];
- [self.tabBarController presentModalViewController:security animated:YES];
- [security release];
- return NO;
- } else {
- return YES;
- }
- }
- [self presentModalViewController:security animated:YES];
- [self.navigationController presentModalViewController:security animated:YES];
Advertisement
Add Comment
Please, Sign In to add comment