I have a UINavigationController
in my app. The UINavigationBar
is set to opaque and all the scroll views do not overlap underneath the bar.
In one view I have a UITableView
. The frame of the UITableView
is (0 0; 320 504)
on my iPhone 5. i.e. the height is 568 - 64 (the height of the nav bar and status bar).
The contentInset
of the UITableView
is (0, 0, 0, 0)
. When the table view first loads the contentOffset
is (0, 0)
.
This is fine. Works brilliantly.
I added a UIRefreshControl
to the table view. This works a couple of times but then after a few times of doing pull to refresh then the content at the top gets "stuck" under the nav bar.
When this happens I inspect the contentInset
and it is now (-60, 0, 0, 0)
.
Is there any way to stop the UIRefreshControl from changing the contentInset
?