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

Real device Width and Height

    XMLWordPrintableJSON

    Details

    • Type: Wish
    • Status: Closed
    • Priority: Major
    • Resolution: Won't Do
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: cordova-plugin-device
    • Labels:
      None

      Description

      At current there is no way in Cordova to get the device width/height in pixels. The only way to do this is to run in full screen then hope window.innerHeight/width is reliable.. This is not useful if you need to take into account the offset created by the notification bar(on Android for example).

      Ideally this information would be provided by the "device plugin" as:
      ``device.width`` & ``device.height``

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              johnyma22 John McLear
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: