Difference between revisions of "Application"

From GiderosMobile
Line 9: Line 9:
 
| style="width: 50%;"|
 
| style="width: 50%;"|
 
=== Methods ===
 
=== Methods ===
[[Application:canOpenUrl]] - Tests if it is possible to open provided url<br/>
+
[[Application:canOpenUrl]] {{<translate>Tests if it is possible to open provided url</translate>}}<br/>
[[Application:configureFrustum]] - Configure the projection for 3D perspective.<br/>
+
[[Application:configureFrustum]] {{<translate>Configure the projection for 3D perspective.</translate>}}<br/>
[[Application:exit]] - Application - terminates the application<br/>
+
[[Application:exit]] {{<translate>Application - terminates the application</translate>}}<br/>
[[Application:getApiVersion]] - Application - returns the API version<br/>
+
[[Application:getApiVersion]] {{<translate>Application - returns the API version</translate>}}<br/>
[[Application:getAppId]] - Application - returns the app id or bundle id<br/>
+
[[Application:getAppId]] {{<translate>Application - returns the app id or bundle id</translate>}}<br/>
[[Application:getBackgroundColor]] - Application - returns the background color in hexadecimal format<br/>
+
[[Application:getBackgroundColor]] {{<translate>Application - returns the background color in hexadecimal format</translate>}}<br/>
[[Application:getContentHeight]] - Application - returns content height<br/>
+
[[Application:getContentHeight]] {{<translate>Application - returns content height</translate>}}<br/>
[[Application:getContentWidth]] - Application - returns content width<br/>
+
[[Application:getContentWidth]] {{<translate>Application - returns content width</translate>}}<br/>
[[Application:getDeviceHeight]] - Application - returns the physical height of the device in pixels<br/>
+
[[Application:getDeviceHeight]] {{<translate>Application - returns the physical height of the device in pixels</translate>}}<br/>
[[Application:getDeviceInfo]] - Application - returns information about device<br/>
+
[[Application:getDeviceInfo]] {{<translate>Application - returns information about device</translate>}}<br/>
[[Application:getDeviceOrientation]] - Get the device orientation<br/>
+
[[Application:getDeviceOrientation]] {{<translate>Get the device orientation</translate>}}<br/>
[[Application:getDeviceSafeArea]] - Application - returns the safe display area bounds<br/>
+
[[Application:getDeviceSafeArea]] {{<translate>Application - returns the safe display area bounds</translate>}}<br/>
[[Application:getDeviceWidth]] - Application - returns the physical width of the device in pixels<br/>
+
[[Application:getDeviceWidth]] {{<translate>Application - returns the physical width of the device in pixels</translate>}}<br/>
[[Application:getFps]] - Application - returns the frame rate of the application<br/>
+
[[Application:getFps]] {{<translate>Application - returns the frame rate of the application</translate>}}<br/>
[[Application:getLanguage]] - Application - returns the user language<br/>
+
[[Application:getLanguage]] {{<translate>Application - returns the user language</translate>}}<br/>
[[Application:getLocale]] - Application - returns the device locale<br/>
+
[[Application:getLocale]] {{<translate>Application - returns the device locale</translate>}}<br/>
[[Application:getLogicalBounds]] - Application - returns the physical screen bounds in logical space<br/>
+
[[Application:getLogicalBounds]] {{<translate>Application - returns the physical screen bounds in logical space</translate>}}<br/>
[[Application:getLogicalHeight]] - Application - returns the logical height of the application<br/>
+
[[Application:getLogicalHeight]] {{<translate>Application - returns the logical height of the application</translate>}}<br/>
[[Application:getLogicalScaleX]] - Application - returns the scaling of automatic screen scaling on the x-axis<br/>
+
[[Application:getLogicalScaleX]] {{<translate>Application - returns the scaling of automatic screen scaling on the x-axis</translate>}}<br/>
[[Application:getLogicalScaleY]] - Application - returns the scaling of automatic screen scaling on the y-axis<br/>
+
[[Application:getLogicalScaleY]] {{<translate>Application - returns the scaling of automatic screen scaling on the y-axis</translate>}}<br/>
[[Application:getLogicalTranslateX]] - Application - returns the translation of automatic screen scaling on the x-axis<br/>
+
[[Application:getLogicalTranslateX]] {{<translate>Application - returns the translation of automatic screen scaling on the x-axis</translate>}}<br/>
[[Application:getLogicalTranslateY]] - Application - returns the translation of automatic screen scaling on the y-axis<br/>
+
[[Application:getLogicalTranslateY]] {{<translate>Application - returns the translation of automatic screen scaling on the y-axis</translate>}}<br/>
[[Application:getLogicalWidth]] - Application - returns the logical width of the application<br/>
+
[[Application:getLogicalWidth]] {{<translate>Application - returns the logical width of the application</translate>}}<br/>
[[Application:getOrientation]] - Application - returns the orientation of the application<br/>
+
[[Application:getOrientation]] {{<translate>Application - returns the orientation of the application</translate>}}<br/>
[[Application:getScaleMode]] - Application - returns the automatic scale mode of the application<br/>
+
[[Application:getScaleMode]] {{<translate>Application - returns the automatic scale mode of the application</translate>}}<br/>
[[Application:getScreenDensity]] - Application - returns the screen density in pixels per inch<br/>
+
[[Application:getScreenDensity]] {{<translate>Application - returns the screen density in pixels per inch</translate>}}<br/>
[[Application:getTextureMemoryUsage]] - Application - returns the texture memory usage in Kbytes<br/>
+
[[Application:getTextureMemoryUsage]] {{<translate>Application - returns the texture memory usage in Kbytes</translate>}}<br/>
[[Application:isPlayerMode]] - Check if app runs on player<br/>
+
[[Application:isPlayerMode]] {{<translate>Check if app runs on player</translate>}}<br/>
[[Application:openUrl]] - Application - opens the given URL in the appropriate application<br/>
+
[[Application:openUrl]] {{<translate>Application - opens the given URL in the appropriate application</translate>}}<br/>
[[Application:setBackgroundColor]] - Application - sets the background color in hexadecimal format<br/>
+
[[Application:setBackgroundColor]] {{<translate>Application - sets the background color in hexadecimal format</translate>}}<br/>
[[Application:setFps]] - Application - sets the frame rate of the application<br/>
+
[[Application:setFps]] {{<translate>Application - sets the frame rate of the application</translate>}}<br/>
[[Application:setFullScreen]] - Full screen or window mode<br/>
+
[[Application:setFullScreen]] {{<translate>Full screen or window mode</translate>}}<br/>
[[Application:setKeepAwake]] - Application - enables/disables screen dimming and device sleeping<br/>
+
[[Application:setKeepAwake]] {{<translate>Application - enables/disables screen dimming and device sleeping</translate>}}<br/>
[[Application:setKeyboardVisibility]] - <br/>
+
[[Application:setKeyboardVisibility]] {{<translate></translate>}}<br/>
[[Application:setLogicalDimensions]] - Application - sets the logical dimensions of the application<br/>
+
[[Application:setLogicalDimensions]] {{<translate>Application - sets the logical dimensions of the application</translate>}}<br/>
[[Application:setOrientation]] - Application - sets the orientation of the application<br/>
+
[[Application:setOrientation]] {{<translate>Application - sets the orientation of the application</translate>}}<br/>
[[Application:setScaleMode]] - Application - sets the automatic scale mode of the application<br/>
+
[[Application:setScaleMode]] {{<translate>Application - sets the automatic scale mode of the application</translate>}}<br/>
[[Application:setWindowSize]] - Sets desktop window to a specific size<br/>
+
[[Application:setWindowSize]] {{<translate>Sets desktop window to a specific size</translate>}}<br/>
[[Application:vibrate]] - Application - vibrates the device<br/>
+
[[Application:vibrate]] {{<translate>Application - vibrates the device</translate>}}<br/>
 
| style="width: 50%;"|
 
| style="width: 50%;"|
 
=== Events ===
 
=== Events ===

Revision as of 14:19, 23 August 2018

Supported platforms: android, ios, mac, pc
Available since: Gideros 2011.6

Description


Application class contains the common functions that's available to the current application. There is a global variable application of type Application to access these functions.

Methods

Application:canOpenUrl Template:Tests if it is possible to open provided url
Application:configureFrustum Template:Configure the projection for 3D perspective.
Application:exit Template:Application - terminates the application
Application:getApiVersion Template:Application - returns the API version
Application:getAppId Template:Application - returns the app id or bundle id
Application:getBackgroundColor Template:Application - returns the background color in hexadecimal format
Application:getContentHeight Template:Application - returns content height
Application:getContentWidth Template:Application - returns content width
Application:getDeviceHeight Template:Application - returns the physical height of the device in pixels
Application:getDeviceInfo Template:Application - returns information about device
Application:getDeviceOrientation Template:Get the device orientation
Application:getDeviceSafeArea Template:Application - returns the safe display area bounds
Application:getDeviceWidth Template:Application - returns the physical width of the device in pixels
Application:getFps Template:Application - returns the frame rate of the application
Application:getLanguage Template:Application - returns the user language
Application:getLocale Template:Application - returns the device locale
Application:getLogicalBounds Template:Application - returns the physical screen bounds in logical space
Application:getLogicalHeight Template:Application - returns the logical height of the application
Application:getLogicalScaleX Template:Application - returns the scaling of automatic screen scaling on the x-axis
Application:getLogicalScaleY Template:Application - returns the scaling of automatic screen scaling on the y-axis
Application:getLogicalTranslateX Template:Application - returns the translation of automatic screen scaling on the x-axis
Application:getLogicalTranslateY Template:Application - returns the translation of automatic screen scaling on the y-axis
Application:getLogicalWidth Template:Application - returns the logical width of the application
Application:getOrientation Template:Application - returns the orientation of the application
Application:getScaleMode Template:Application - returns the automatic scale mode of the application
Application:getScreenDensity Template:Application - returns the screen density in pixels per inch
Application:getTextureMemoryUsage Template:Application - returns the texture memory usage in Kbytes
Application:isPlayerMode Template:Check if app runs on player
Application:openUrl Template:Application - opens the given URL in the appropriate application
Application:setBackgroundColor Template:Application - sets the background color in hexadecimal format
Application:setFps Template:Application - sets the frame rate of the application
Application:setFullScreen Template:Full screen or window mode
Application:setKeepAwake Template:Application - enables/disables screen dimming and device sleeping
Application:setKeyboardVisibility {{}}
Application:setLogicalDimensions Template:Application - sets the logical dimensions of the application
Application:setOrientation Template:Application - sets the orientation of the application
Application:setScaleMode Template:Application - sets the automatic scale mode of the application
Application:setWindowSize Template:Sets desktop window to a specific size
Application:vibrate Template:Application - vibrates the device

Events

Constants

Application.LANDSCAPE_LEFT
Application.LANDSCAPE_RIGHT
Application.PORTRAIT
Application.PORTRAIT_UPSIDE_DOWN