window.portwidth Property

This property returns the visible screen width (in pixels) on the device for portrait

intel.xdk.display.window.portwidth

Description:

This property is only set by a call to intel.xdk.display.lockViewportWindow. Otherwise the returned value is 0.

Example:


//detect the current visible screen width of the device for portrait
var portWidth = intel.xdk.display.window.portwidth;
             
Nähere Informationen zur Compiler-Optimierung finden Sie in unserem Optimierungshinweis.