Skip to content

README missing #1

@xinsight

Description

@xinsight

Basic usage is not obvious. e.g. NSRangeException if selectedIndex not set.

- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
    self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
    RSTabBarViewController *tabvc = [[RSTabBarViewController alloc] init];
    FirstViewController *vc1 = [[FirstViewController alloc] init];
    SecondViewController *vc2 = [[SecondViewController alloc] init];    
    tabvc.viewControllers = @[vc1, vc2];
    // !!!: required to avoid NSRangeException
    tabvc.selectedIndex = 0; 
    self.window.rootViewController = tabvc;    
    [self.window makeKeyAndVisible];
    return YES;
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions