Use a pull-to-refresh control instead of a button for syncing

Works for me, but definitely could use more testing.

I did some refactoring of the app delegate to make the change easier.