Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>I found what I needed in <a href="https://stackoverflow.com/questions/2893776/how-to-get-title-of-uitabbaritem-in-the-more-section">this question</a>.</p> <p>Basically you set up a <code>UITabBarControllerDelegate</code> <em>and</em> a <code>UINavigationControllerDelegate</code> for the navigation controller that is displayed inside the More tab. After that you detect if the user touched one of the visible tabs, or the "More" tab.</p> <p>EDIT</p> <p>Also, to directly manipulate the table that is visible within the "More" navigation controller, you can set up a "man-in-the-middle" table view delegate, that intercepts the calls to the original delegate. See code from inside <code>didSelectViewController</code> below:</p> <pre><code>if (viewController == tabBarController.moreNavigationController &amp;&amp; tabBarController.moreNavigationController.delegate == nil) { // here we replace the "More" tab table delegate with our own implementation // this allows us to replace viewControllers seamlessly UITableView *view = (UITableView *)self.tabBarController.moreNavigationController.topViewController.view; self.originalDelegate = view.delegate; view.delegate = self; } </code></pre> <p>After that, you are free to do whatever you like inside the delegate methods, as long as you call the same methods in the other delegate (I actually checked to which methods the original delegate responds, and the only delegate method that is implemented is the <code>didSelectRow:forIndexPath:</code>). See an example below:</p> <pre><code>- (void)tableView:(UITableView *)tableView didSelectRowAtIndexPath:(NSIndexPath *)indexPath { // this is the delegate for the "More" tab table // it intercepts any touches and replaces the selected view controller if needed // then, it calls the original delegate to preserve the behavior of the "More" tab // do whatever here // and call the original delegate afterwards [self.originalDelegate tableView: tableView didSelectRowAtIndexPath: indexPath]; } </code></pre>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload