2013-10-04 62 views
-1

iOS7上的状态栏有不一致的行为。有时节目如:为显示在第一张图调整iOS7状态栏

enter image description here

我的行为:enter image description here

虽然有时视图显示为。

+1

问题是? – Sulthan

+2

你需要设置你的控制Y位置20px..every time,每一页都是这样。 –

+0

@Sulthan,问题是保持视图始终如第一张图所示。 – Zubair

回答

1

在您的viewDidLoad

if ([self respondsToSelector:@selector(setEdgesForExtendedLayout:)]) 
{ 
    self.edgesForExtendedLayout = UIRectEdgeNone; 
} 
+0

已经添加了这段代码,但现在工作 – Zubair

-1

添加该代码这将工作,如果你不使用导航控制器

didFinishLaunchingWithOptions添加该代码方法

if ([[[UIDevice currentDevice] systemVersion] floatValue] >= 7) 
{ 

    [application setStatusBarStyle:UIStatusBarStyleLightContent]; 

    self.window.clipsToBounds =YES; 

    self.window.frame =  CGRectMake(0,20,self.window.frame.size.width,self.window.frame.size.height-20); 
} 

中进行更改您的plist添加基于视图控制器的状态栏外观 enter image description here