title: warning: 'UIViewController' may not respond to 'xxx'
body: <p>I'm still relatively new to iPhone development but I know this warning is usually the result of not declaring a method in my classes header file. This is slightly different - at least I think it is. </p>
  
  <p>I've created a custom tab bar in my applications root view controller which loads in the other view controllers dynamically inside the delegate method - essentially like this:</p>
  
  <pre><code>- (void)tabBar:(UITabBar *)tabBar didSelectItem:(UITabBarItem *)item {
  
      UIViewController *viewController = [viewControllers objectAtIndex:item.tag];
      [self.selectedViewController.view removeFromSuperview];
      [self.view insertSubview:viewController.view atIndex:0];
      self.selectedViewController = viewController;
  
  }
  </code></pre>
  
  <p>That code works fine and loads in the required views. When the view changes a check is run to see if the setting view is about to be unloaded and if so it calls the save settings method like this:</p>
  
  <pre><code>- (void)tabBar:(UITabBar *)tabBar didSelectItem:(UITabBarItem *)item {
  
      if (self.currentController == 1) {
          [self.selectedViewController saveSettings];
      }
  
      UIViewController *viewController = [viewControllers objectAtIndex:item.tag];
      [self.selectedViewController.view removeFromSuperview];
      [self.view insertSubview:viewController.view atIndex:0];
      self.selectedViewController = viewController;
  
  }
  </code></pre>
  
  <p>Again the code functions fine and the instance method of SettingsViewController is called, but because the declaration of the method is in the header of the SettingsViewController and not the RootViewController hence the warning.</p>
  
  <p>If I declare it in the RootViewController as well I get the 'no matching method declaration' warning.  I presume redeclaring my function would fix the warning - but surely isn't the 'proper' way to fix this.</p>