title: UINavigationBar not updating bar button item until after table view update
body: <p>I have a UITableViewController embedded in a navigation controller. My rightBarButtonItem is a refresh button. When pressed, the button triggers an update from a server. The update is synchronous (when I have time, I'll change it to an asynchronous request). What I want to do sounds simple in theory. Once the button is pressed:</p>
  
  <ul>
  <li>Change the bar button item to a UIActivityIndicatorView</li>
  <li>Refresh the data</li>
  <li>Reload the tableView</li>
  <li>Change the bar button item back to a refresh button.</li>
  </ul>
  
  <p>What's happening, however, is that I will set the rightBarButton to a view with an activity indicator view, but it's not getting updated until <em>after</em> the table view reloads, which is obviously pointless. My server update routine looks like this:</p>
  
  <ul>
  <li>View Controller calls a separate model object's "refresh" method.</li>
  <li>model object synchronously gets the new data from the server</li>
  <li>View controller calls [self.tableView reloadData];</li>
  </ul>
  
  <p>Since it's synchronous, I thought it would simply progress one step at a time, but that's not working. How can I make it so that the activityIndicatorView shows and disappears when it's supposed to?</p>