Uploaded image for project: 'Apache Cordova'
  1. Apache Cordova
  2. CB-12478

iOS WebView's height becomes greater than screen height after dismissing the presented ViewController

    XMLWordPrintableJSON

    Details

      Description

      The combination of PRs for CB-10158 and CB-11191 has created this scenario.

      Versions involved:

      1. cordova-plugin-statusbar - 2.2.1
      2. 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

      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.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              michael-socast michael-socast
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: