Application

From GiderosMobile
Revision as of 09:36, 24 August 2018 by Hgy29 (talk | contribs)

Supported platforms: Platform android.pngPlatform ios.pngPlatform mac.pngPlatform pc.png
Available since: Gideros 2011.6
Inherits from: Object

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

Events

Constants

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