We're working on the transition between IOS6 and IOS7 and have the next issues, for the moment without solution:
The structure of our view is the next one:
- UIView
- UIToolbar for ad-hoc buttons (filter button for the list)
- UISearchBar over the UIToolbar to integrate the search component with the list
- UITableView
Working perfectly on the previous versions of the IOS SDK.
But in IOS7 we have the next troubles:
- The UIToolbar and UISearch bar is not visible anymore
- We integrated the UIRefreshBar component and after refresh the UITableView always move under the UINavigationBar
Any suggestions?
Regarding
1.The UIToolbar
and UISearchBar
is not visible any more write the below code in viewDidLoad
and your problem will solved.
[self setEdgesForExtendedLayout:UIExtendedEdgeLeft |
UIExtendedEdgeBottom |
UIExtendedEdgeRight];
In viewDidLoad
this worked for me
[self setEdgesForExtendedLayout:UIRectEdgeNone];
If you like storyboard, select the viewController
and make sure Extended Edges
>> Under top bars
is not selected.
Update:
For people like me, who can't install Xcode 5 available only in Mountain Lion:
#if __IPHONE_OS_VERSION_MAX_ALLOWED >= 70000
[self setEdgesForExtendedLayout:UIRectEdgeNone];
#endif
Regarding
2. We integrated the UIRefreshBar component and after refresh the UITableView always move under the UINavigationBar
Make the NavigationBar not translucent, by default it is which allows views to scroll underneath it.