UISearchDisplayController on iOS7

2019-09-03 02:33发布

I'm having a very annoing problem on iOS7. I have a VC with different subviews, one is a tableview that is display fullscreen after pressing a button. This tableview has a search bar with a scope bar in its header that is linked to a search display controller.
On iOS 6 everything runs fine, when I press on the search bar the scope bar is displayed and the rows correctly slide at the bottom as you can see in the images (forget about the big X).
Search bar iOS6 Search bar with scope iOS6
On iOS7 I have a problem.
Everything seems OK(and it's under the status but I know how to fix that).
Search bar iOS7
But when I start a search the layout change leaving some blank space at the top, this doesn't happen on iOS6.
Search bar iOS7 searching


How can I solve that? where this problem comes from?
Andrea

1条回答
疯言疯语
2楼-- · 2019-09-03 03:08

It looks like your search results are pushed down by the status bar height. Try fixing your header position (so it's not under the status bar) and see if that works. If not, you'll need to share some code to show how your layouts are constructed.

查看更多
登录 后发表回答