I am developing an App using Sencha Touch 2. I am trying to find out the device/screen width and height, but I can't seem to figure it out. I have tried using:
which returns 100%. However, I would need to know the width/height in pixels. I need to embed a video, and I need to maintain aspect ratio for different device resolutions.
which seems to work fine, but I would like to know the proper way to do it in Sencha Touch 2.
var width = (window.innerWidth > 0) ? window.innerWidth : screen.width;
Any Help would be appreciated.