Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
iOS
Description
The combination of PRs for CB-10158 and CB-11191 has created this scenario.
Versions involved:
- cordova-plugin-statusbar - 2.2.1
- cordova-plugin-camera - 2.3.1 and below
When the camera plugin view controller is dismissed in line 548
the cordovaViewWillAppear method is called. This happens because cordovaViewWillAppear was registered to listen for "CDVViewWillAppearNotification" events
The method cordovaViewWillAppear calls resizeWebView. When resizeWebView reaches line 475
the local vars frame and statusBarFrame are set with zeroes. The app then proceeds with lines 476 and 480
- https://github.com/apache/cordova-plugin-statusbar/blob/rel/2.2.1/src/ios/CDVStatusBar.m#L476
- https://github.com/apache/cordova-plugin-statusbar/blob/rel/2.2.1/src/ios/CDVStatusBar.m#L480
and this results in frame.origin.y being assigned the value of 20.
Then in line 485, the frame.size.height gets the value of -20
The negative height of the frame causes the the WebView to increase its height beyond the screen by 20 units.