Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8248857
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 7, 20262026-06-07T23:20:24+00:00 2026-06-07T23:20:24+00:00

I am new to SplitViewController and I am running into the following issue. Here

  • 0

I am new to SplitViewController and I am running into the following issue. Here is the setup:

In IB, I only have a VC linked to the SVC as the detail VC (This compares to the standard Master Detail project template which has a Nav Controller as the starting point for the detail Hierarchy). I am doing this to try to maximize image space in the detail VC.

I then add a UIToolbar (called imageTable) to the detail VC which I connect with an IBoutlet to the detail VC class.

I am using the detail VC as the SVC delegate.

I then adopt the follow SVC delegate 3 methods in the detail VC:

#pragma mark - SplitViewController Delegates
-(BOOL) splitViewController:(UISplitViewController *)svc
   shouldHideViewController:(UIViewController *)vc
             inOrientation:(UIInterfaceOrientation)orientation
{
  return UIInterfaceOrientationIsPortrait(orientation); 
}



-(void) splitViewController:(UISplitViewController *)svc
     willHideViewController:(UIViewController *)aViewController
         withBarButtonItem:(UIBarButtonItem *)barButtonItem
      forPopoverController:(UIPopoverController *)pc
{    
  barButtonItem.title=@"ImageList";
  NSMutableArray *toolbarItems=[self.imageTable.items mutableCopy];
  [toolbarItems insertObject:barButtonItem atIndex:0];
  self.imageTable.items=toolbarItems;
}



-(void) splitViewController:(UISplitViewController *)svc
     willShowViewController:(UIViewController *)aViewController
  invalidatingBarButtonItem:(UIBarButtonItem *)barButtonItem
{
  NSMutableArray *toolbarItems=[self.imageTable.items mutableCopy];
  [toolbarItems removeObjectAtIndex:0];
  self.imageTable.items=toolbarItems;
}

Because I am not using Nav Controller as the starting point in the VC, I am running into the following:

  • UIToolBar automatically disappears when I turn back to landscape. Is it inherent in the SVC class that since the UIBarbuttonItem representing the VC to reappear is no longer needed in landscape, so is the UIToolbar I created (emphasizing ‘I’)…

  • Is there any way to add or enable a title to the UIToolbar or is the only way using a label.

Thanks

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-07T23:20:25+00:00Added an answer on June 7, 2026 at 11:20 pm

    I have been pushing a bit forward in CS193P class and I gather the simple answer is:

    If you are ever in need of a UIToolbar (to add Buttons or a title), just embed the Table View Controller or any view Controller you are working on, in a Navigation controller – this way you get a free UIToolbar (with easy access to title, etc..)

    Do that even if you have no need to push/pop or segue.

    KMB

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

New to android here, (and programming in general) I'm following this example trying to
New to PHP and MySQL, have heard amazing things about this website from Leo
New programmer here, I am trying to understand and break down this code below
NEW EDIT: I have narrowed my problem to this - i have a view
I have a splitViewController that has a master and detail view controllers. The code
New to Objective-C and iOS development, would love a hand here! I have written
New to linux and trying to escape doing this the hard way. I have
New Android programmer here. I have a Service which performs socket management and async
New to DDD here and have a architecture question which should be a typical
New to mvc, I have a controller like this public ActionResult Index(DateTime Date, DateTime

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.