iOS 7 SDK-UI导航栏有时会变暗,有时不会变暗.但为什么? [英] iOS 7 SDK - UI Navigation Bar is sometimes darker and sometimes not. But why?

查看:63
本文介绍了iOS 7 SDK-UI导航栏有时会变暗,有时不会变暗.但为什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在努力将我的应用程序移植到iOS 7,除了一件事情外,它的运行非常好.我使用了新的半透明背景,但并未将其关闭.

I am working on porting my app to iOS 7 and it works very good except one thing. I use the new Translucent background and did not turn it off.

我刚刚注意到,我的导航栏比ABUnknownPersonViewController委托导航栏要暗一些.我附上了截图.有人可以给我解释一下吗?

I just noticed that my navigation bar is a little bit darker as the ABUnknownPersonViewController delegate navigationbar. I attached a screenshot. Can someone explain me this?

我希望具有与ABUnknownPersonViewController中的导航栏颜色完全相同的默认颜色.

I would like to have the exact same navigation bar color as in the ABUnknownPersonViewController as default.

我希望有人可以向我解释一下.

I hope someone can explain me this.

问候

推荐答案

我只是自己弄清楚了.导航栏的颜色发生了变化,因为我使用了以下代码行:

I just figured it out myself. The navigation bar color changes because i use the following line of code:

        if ([view respondsToSelector:@selector(edgesForExtendedLayout)])
           [view setEdgesForExtendedLayout: UIRectEdgeNone];

这篇关于iOS 7 SDK-UI导航栏有时会变暗,有时不会变暗.但为什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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