0

私のアプリには、すべてのアクティビティが行われている UIWebview があります。アプリは ios6 で完璧に動作しますが、iOS 7 では UIwebview コンテンツがステータス バーと衝突します。

これを正しく表示するように UIWindow のビューを設定する方法はありますか。

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

            if (self.window.rootViewController.view.frame.origin.y <=0) {
                screenBounds = CGRectMake(0, 20, self.window.bounds.size.width, self.window.bounds.size.height-20);
            }
        }
self.window.rootViewController = self.viewController;

Thanks,
4

1 に答える 1

0

試す:

if ([self respondsToSelector:@selector(edgesForExtendedLayout)])
        self.edgesForExtendedLayout = UIRectEdgeNone;

ビューコントローラーのviewDidLoadメソッドで。

于 2013-10-18T10:47:12.697 に答える