Advertisement
Guest User

Untitled

a guest
Jul 22nd, 2017
59
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1.  
  2. - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {    
  3.     navigationController = [[AGIMainNewsViewController controller] retain];
  4.     mainController = [((AGIMainNewsViewController*)[navigationController topViewController]) retain];
  5.    
  6.     // Add the view controller's view to the window and display.
  7.     [self.window addSubview:navigationController.view];
  8.     [self.window makeKeyAndVisible];
  9. }
  10.  
  11. my it's [AGIMainNewsViewController controller]
  12.  
  13. + (UINavigationController *) controller {
  14.     UINavigationController *a = [[[UINavigationController alloc] initWithRootViewController:
  15.                                   [[[AGIMainNewsViewController alloc] init] autorelease]] autorelease];
  16.     a.navigationBar.tintColor = [UIColor colorWithRed:0.071 green:0.114 blue:0.247 alpha:1.000];
  17.     a.navigationBar.hidden = YES;
  18.     return a;
  19. }
  20.  
  21. while in my main top view controller AGIMainNewsViewController i've
  22.  
  23.  
  24.     [[self navigationController]setNavigationBarHidden:NO animated:NO];
  25.  
  26. but it does not work
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement