iOS7 上的 UISearchDisplayController [英] UISearchDisplayController on iOS7

查看:37
本文介绍了iOS7 上的 UISearchDisplayController的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 iOS7 上遇到了一个非常恼人的问题.我有一个具有不同子视图的 VC,一个是按下按钮后全屏显示的 tableview.此 tableview 有一个搜索栏,其标题中有一个范围栏,链接到搜索显示控制器.
在 iOS 6 上一切正常,当我按下搜索栏时,范围栏会显示出来,并且行在底部正确滑动,如您在图像中看到的(忘记大 X).

在 iOS7 上我遇到了问题.
一切似乎都很好(它处于状态下,但我知道如何解决这个问题).

但是当我开始搜索时,布局更改会在顶部留下一些空白,这在 iOS6 上不会发生.

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).

On iOS7 I have a problem.
Everything seems OK(and it's under the status but I know how to fix that).

But when I start a search the layout change leaving some blank space at the top, this doesn't happen on iOS6.


我该如何解决?这个问题从何而来?
安德里亚


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

推荐答案

看起来您的搜索结果被状态栏高度压低了.尝试修复您的标题位置(因此它不在状态栏下方)并查看是否有效.如果没有,您需要共享一些代码来展示您的布局是如何构建的.

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.

这篇关于iOS7 上的 UISearchDisplayController的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆