From b61eaae31024e0af53009dcd7143d3c1580ab68c Mon Sep 17 00:00:00 2001 From: Shazron Abdullah Date: Mon, 7 Oct 2013 16:51:36 -0700 Subject: [PATCH] Fixed statusbar background view not auto-resizing on landscape. --- src/ios/CDVStatusBar.m | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/ios/CDVStatusBar.m b/src/ios/CDVStatusBar.m index 51efc3d..e49bcd8 100644 --- a/src/ios/CDVStatusBar.m +++ b/src/ios/CDVStatusBar.m @@ -48,6 +48,8 @@ _statusBarBackgroundView = [[UIView alloc] initWithFrame:frame]; _statusBarBackgroundView.backgroundColor = [UIColor blackColor]; + _statusBarBackgroundView.autoresizingMask = (UIViewAutoresizingFlexibleWidth | UIViewAutoresizingFlexibleBottomMargin); + [self styleLightContent:nil]; // match default backgroundColor of #000000 NSString* setting; @@ -72,11 +74,7 @@ if (statusBarOverlaysWebView) { - CGRect statusBarFrame = [UIApplication sharedApplication].statusBarFrame; CGRect bounds = self.viewController.view.bounds; - bounds.origin.y = 0; - bounds.size.height += statusBarFrame.size.height; - self.webView.frame = bounds; [_statusBarBackgroundView removeFromSuperview];