Don't like ads? PRO users don't see any ads ;-)
Guest

Untitled

By: a guest on May 15th, 2012  |  syntax: None  |  size: 1.14 KB  |  hits: 18  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. Push notification in view based app?
  2. tab_obj1 = [[First alloc] initWithNibName:@"First" bundle:nil];
  3.  
  4.     UINavigationController *tabItem1 = [[[UINavigationController alloc] initWithRootViewController: tab_obj1] autorelease];
  5.     tabItem1.title=@"First";
  6.     tabItem1.tabBarItem.image=[UIImage imageNamed:@"FirstIcon.png"];
  7.     tab_obj2 = [[Second alloc] initWithNibName:@"Second" bundle:nil];
  8.  
  9.     UINavigationController *tabItem2 = [[[UINavigationController alloc] initWithRootViewController: tab_obj2] autorelease];
  10.  
  11.     tabItem2.title=@"Second";
  12.     tabItem2.tabBarItem.image=[UIImage imageNamed:@"SecondSelc.png"];
  13.  
  14.     tab_obj3 = [[Third alloc] initWithNibName:@"Third" bundle:nil];
  15.  
  16.     UINavigationController *tabItem3 = [[[UINavigationController alloc] initWithRootViewController: tab_obj3] autorelease];
  17.  
  18.     tabItem3.title=@"Third";
  19.     tabItem3.tabBarItem.image=[UIImage imageNamed:@"ThirdIcon.png"];
  20.     tab_obj4 = [[Fourth alloc] initWithNibName:@"Fourth" bundle:nil];
  21.        
  22. - (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo   {
  23.     // Notification code here
  24. }
  25.        
  26. tabBarController.selectedIndex = 3;