Advertise Mobile SDKs Books Events Forum News Social Networking Support Us
Follow @iphonedevsdk on Twitter

Interface 2, Advanced iOS
Mockup & Code Gen
($9.99)

Make your own iPhone apps
and run them live!
(free)

Pic Frame Dynamo: Photo Editing
($0.99)

Abiliator
($1.99)

Want your application or service advertised on iPhone Dev SDK?

Go Back   iPhone Dev SDK Forum > iPhone SDK Development Forums > iPhone SDK Development

Reply
 
LinkBack Thread Tools Display Modes
Old 09-03-2010, 12:01 PM   #1 (permalink)
Registered Member
 
Join Date: Mar 2010
Posts: 68
Parental is on a distinguished road
Default Two SplitViewController in TabBarController

In interface builder i can't put my splitviewcontrollers in the main tabbarcontroller
Why?
Parental is offline   Reply With Quote
Old 09-03-2010, 01:43 PM   #2 (permalink)
Registered Member
 
Join Date: Jan 2009
Location: Long Beach, CA
Posts: 612
bytor99999 is on a distinguished road
Send a message via AIM to bytor99999 Send a message via Yahoo to bytor99999
Default

Quote:
Originally Posted by Parental View Post
In interface builder i can't put my splitviewcontrollers in the main tabbarcontroller
Why?
I am making assumptions here, just my opinion and based on no facts.

But maybe because it doesn't make sense to have a splitviewcontroller inside a tabbarcontroller, and I would assume breaks the Apple UI guidelines.

But I also assume that via code you might be able to get it to work.

Mark
__________________
Perfect World Programming LLC
http://www.perfectworldprogramming.com

Please check out my apps.

TubeOrganizer
http://www.spritzlerapps.com/tube-organizer.html

Paper Clips
http://spritzlerapps.weebly.com/paper-clips.html
bytor99999 is offline   Reply With Quote
Old 09-03-2010, 07:27 PM   #3 (permalink)
Registered Member
 
Join Date: Nov 2009
Posts: 920
spiderguy84 is on a distinguished road
Default

I'm not aware of any interface guidelines that prohibit putting a splitview inside a tabbarcontroller. I'm also about to start working on something where I'll need to do the same thing. If u are able to get ib working with it, please let us know
__________________
My latest app...i Miss Mommy
spiderguy84 is offline   Reply With Quote
Old 09-04-2010, 03:40 PM   #4 (permalink)
Registered Member
 
Join Date: Mar 2010
Posts: 68
Parental is on a distinguished road
Default

Quote:
Originally Posted by bytor99999 View Post
I am making assumptions here, just my opinion and based on no facts.

But maybe because it doesn't make sense to have a splitviewcontroller inside a tabbarcontroller, and I would assume breaks the Apple UI guidelines.

But I also assume that via code you might be able to get it to work.

Mark
I want to do something like iPad Youtube app. I think that apple use their custom class and not splitviewcontroller.
Parental is offline   Reply With Quote
Old 09-04-2010, 06:10 PM   #5 (permalink)
Registered Member
 
Join Date: Jan 2009
Location: Long Beach, CA
Posts: 612
bytor99999 is on a distinguished road
Send a message via AIM to bytor99999 Send a message via Yahoo to bytor99999
Default

Quote:
Originally Posted by Parental View Post
I want to do something like iPad Youtube app. I think that apple use their custom class and not splitviewcontroller.
Ah, yes in that app I remember the TabBarController on the bottom and there is at least one splitview controller in one of the screens.

Personally, I think it would be easier to do it in code.

You can create a Nib with the TabBarController at the bottom and put a viewController for one of the tabButton selections. In the ViewController code setup, I would code the creation of the splitviewController

It really is as simple as creating an array with two viewControllers, the first for the left side the second for the detail, put them in the array and assign it to the splitviewcontroller.

Here is the code I used to create a splitviewcontroller

Code:
-(void)setupAppContainerView {
        
    
    MyVideoDrawerViewController *drawerController = [[MyVideoDrawerViewController alloc]
                                                    initWithNibName:@"MyVideosDrawerView"
                                                     bundle:nil];  
    
    //Figure out a way to decouple this Delegation, Notification, Observer
    appContainerViewController.myVideoDrawerViewController = drawerController;
    drawerController.appContainerViewController = appContainerViewController;
    
    NSMutableArray *drawers = [appContainerViewController loadFirstData];
    drawerController.drawers = drawers;
    //[drawers release];
    
    UINavigationController *rootNav = [[UINavigationController alloc] 
                                        initWithRootViewController:drawerController];
    [drawerController release];
     
    
    appContainerViewController.navigationController = rootNav;
    
    DetailViewTableViewController *detailViewController = [[DetailViewTableViewController alloc] 
                                                   initWithNibName:@"DetailViewTableView" 
                                                   bundle:nil];
    
    appContainerViewController.detailViewController = detailViewController;    
    detailViewController.appContainerViewController = appContainerViewController;
    
    
    appContainerViewController.viewControllers = [NSArray arrayWithObjects:rootNav, detailViewController, nil];
    [rootNav release];
    [detailViewController release];
}
This also includes a complete navigation controller for the left side, which with IB is difficult to setup.

Hope that helps.

Mark
__________________
Perfect World Programming LLC
http://www.perfectworldprogramming.com

Please check out my apps.

TubeOrganizer
http://www.spritzlerapps.com/tube-organizer.html

Paper Clips
http://spritzlerapps.weebly.com/paper-clips.html
bytor99999 is offline   Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On



» Advertisements
» Online Users: 344
12 members and 332 guests
bignoggins, carlandrews, flamingliquid, hzwegjxg, ilmman, iram91419, linkmx, nadav@webtview.com, Objective Zero, Paul Slocum, stanny, v1n2e7t
Most users ever online was 1,387, 04-10-2012 at 04:21 AM.
» Stats
Members: 175,656
Threads: 94,116
Posts: 402,889
Top Poster: BrianSlick (7,990)
Welcome to our newest member, iram91419
Powered by vBadvanced CMPS v3.1.0

All times are GMT -5. The time now is 11:44 PM.
Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.3.0