title: UIBarButtonItem changing title not working
body: <p>How can I change the title of a <code>UIBarButtonItem</code>? I have the following code which is called when an <strong>edit</strong> button is pressed on my <code>UINavigationBar</code>.</p>
  <pre><code>-(void)editButtonSelected:(id)sender {
      NSLog(@&quot;edit button selected!&quot;);
      if(editing) {
          NSLog(@&quot;notediting&quot;);
          [super setEditing:NO animated:NO];
          [tableView setEditing:NO animated:NO];
          [tableView reloadData];
          [rightButtonItem setTitle:@&quot;Edit&quot;];
          [rightButtonItem setStyle:UIBarButtonItemStylePlain];
          editing = false;
      }
      else {
          NSLog(@&quot;editing&quot;);
          [super setEditing:YES animated:YES];
          [tableView setEditing:YES animated:YES];
          [tableView reloadData];
          [rightButtonItem setTitle:@&quot;Done&quot;];
          [rightButtonItem setStyle:UIBarButtonItemStyleDone];
          editing = true;
      }
  }
  </code></pre>
  <p>The <strong>edit</strong> button is changing color (so the line which sets the style is working), however the line which sets the title of the button is not working.</p>