- Joined
- Nov 19, 2019
- Messages
- 80
This module gets you access to some info about the system on Android.
canOpenUrl:Bool(url:String)
More functions may be added later. It is all only implemented in Android. Maybe GLFW and HTML will get some functions later.
The first of many modules I plan on making.
Demo: The included demo.cxs prints all the function results into the log.
Install: extract the zip file inside the modules_ext folder inside your Cerberus X installation folder. Rename the resulting folder to systemcheck.
License: zlib/libpng (see included license.txt)
canOpenUrl:Bool(url:String)
Returns if the specified URL can be opened by any installed apps. Sometimes no web browser is installed and it's just good to check before opening anything.
checkSystemFeature:Bool(feature:String)Returns if the device has the specified feature. EX: "android.hardware.screen.portrait"
shouldUseTelevisionUI:Bool()Returns if the device is in the TV mode. On TV top boxes it should always return true.
nightModeTheme:Bool()Returns if the device is in night mode, so apps can use a dark theme and whatever.
userLanguage:String()Returns the users chosen language's name (3 characters long) as a string.
osVersion:Int()Returns the API level of the system. EX: Android 10 = 29
developerModeEnabled:Bool()Returns if the device has developer mode activated.
hasPermission:Bool(permission:String)Returns if the specied permission has been granted by the system.
More functions may be added later. It is all only implemented in Android. Maybe GLFW and HTML will get some functions later.
The first of many modules I plan on making.
Demo: The included demo.cxs prints all the function results into the log.
Install: extract the zip file inside the modules_ext folder inside your Cerberus X installation folder. Rename the resulting folder to systemcheck.
License: zlib/libpng (see included license.txt)