You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by jc...@apache.org on 2016/12/15 23:44:31 UTC
cordova-plugin-statusbar git commit: CB-12141 (ios) fix white app
screen after camera overlay shown on iPad
Repository: cordova-plugin-statusbar
Updated Branches:
refs/heads/master 834b8cb5f -> a120ba1a1
CB-12141 (ios) fix white app screen after camera overlay shown on iPad
This closes #73
Project: http://git-wip-us.apache.org/repos/asf/cordova-plugin-statusbar/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-plugin-statusbar/commit/a120ba1a
Tree: http://git-wip-us.apache.org/repos/asf/cordova-plugin-statusbar/tree/a120ba1a
Diff: http://git-wip-us.apache.org/repos/asf/cordova-plugin-statusbar/diff/a120ba1a
Branch: refs/heads/master
Commit: a120ba1a1ffb27d46f2ac7962648e6f8a7a5b24c
Parents: 834b8cb
Author: Julio C�sar <jc...@gmail.com>
Authored: Fri Dec 9 00:18:23 2016 +0100
Committer: Julio C�sar <jc...@gmail.com>
Committed: Fri Dec 16 00:44:09 2016 +0100
----------------------------------------------------------------------
src/ios/CDVStatusBar.m | 23 +++++------------------
1 file changed, 5 insertions(+), 18 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cordova-plugin-statusbar/blob/a120ba1a/src/ios/CDVStatusBar.m
----------------------------------------------------------------------
diff --git a/src/ios/CDVStatusBar.m b/src/ios/CDVStatusBar.m
index 37c6dcd..ee1d6cb 100644
--- a/src/ios/CDVStatusBar.m
+++ b/src/ios/CDVStatusBar.m
@@ -448,26 +448,13 @@ static const void *kStatusBarStyle = &kStatusBarStyle;
if (isIOS7) {
CGRect bounds = [self.viewController.view.window bounds];
+ if (CGRectEqualToRect(bounds, CGRectZero)) {
+ bounds = [[UIScreen mainScreen] bounds];
+ }
bounds = [self invertFrameIfNeeded:bounds];
- if (UIInterfaceOrientationIsPortrait([[UIApplication sharedApplication] statusBarOrientation])) {
- self.viewController.view.frame = bounds;
- } else if (self.viewController.presentedViewController != nil) {
- // https://issues.apache.org/jira/browse/CB-11018
- BOOL isIOS8 = (IsAtLeastiOSVersion(@"8.0"));
- BOOL isIOS9 = (IsAtLeastiOSVersion(@"9.0"));
- if (isIOS8 && !isIOS9) {
- // iOS 8
- bounds = CGRectMake(0, 0, bounds.size.width, bounds.size.height);
- } else {
- // iOS7, iOS9+
- if ([self.viewController.presentedViewController.presentationController isKindOfClass:[UIPopoverPresentationController class]] || UI_USER_INTERFACE_IDIOM() != UIUserInterfaceIdiomPad) {
- bounds = CGRectMake(0, 0, bounds.size.width, bounds.size.height);
- } else {
- bounds = CGRectMake(0, 0, bounds.size.height, bounds.size.width);
- }
- }
- }
+ self.viewController.view.frame = bounds;
+
self.webView.frame = bounds;
CGRect statusBarFrame = [UIApplication sharedApplication].statusBarFrame;
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org