Classes
ApplicationCommon
ApplicationCommon
Summary โ
Properties
- autoSystemAppearanceChanged
- backgroundEvent
- cssChangedEvent
- discardedErrorEvent
- displayedEvent
- exitEvent
- fontScaleChangedEvent
- foregroundEvent
- hasListeners
- hasListeners
- launchEvent
- livesyncEvent
- loadAppCssEvent
- lowMemoryEvent
- mainEntry
- notify
- notify
- off
- off
- on
- on
- once
- once
- orientationChangedEvent
- resumeEvent
- started
- suspendEvent
- systemAppearanceChangedEvent
- uncaughtErrorEvent
Methods
- addCss
- applyCssClass
- createRootView
- getCssFileName
- getMainEntry
- getNativeApplication
- getOrientation
- getResources
- getRootView
- getSystemAppearance
- hasLaunched
- initRootView
- loadAppCss
- notifyLaunch
- orientation
- orientationChanged
- resetRootView
- run
- setAutoSystemAppearanceChanged
- setCssFileName
- setInBackground
- setMaxRefreshRate
- setOrientation
- setResources
- setSuspended
- setSystemAppearance
- systemAppearance
- systemAppearanceChanged
Properties โ
autoSystemAppearanceChanged โ
Boolean to enable/disable systemAppearanceChanged
backgroundEvent โ
Readonly
cssChangedEvent โ
Readonly
discardedErrorEvent โ
Readonly
displayedEvent โ
Readonly
exitEvent โ
Readonly
fontScaleChangedEvent โ
Readonly
foregroundEvent โ
Readonly
hasListeners โ
launchEvent โ
Readonly
livesyncEvent โ
Readonly
loadAppCssEvent โ
Readonly
lowMemoryEvent โ
Readonly
mainEntry โ
Protected
notify โ
off โ
on โ
on: { (eventNames: string, callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "cssChanged", callback: (args: CssChangedEventData) => void, thisArg?: any) => void; (event: "livesync", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "cssChanged", callback: (args: CssChangedEventData) => void, thisArg?: any) => void; (event: "launch", callback: (args: LaunchEventData) => void, thisArg?: any) => void; (event: "displayed", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "suspend", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "resume", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "exit", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "lowMemory", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "uncaughtError", callback: (args: UnhandledErrorEventData) => void, thisArg?: any) => void; (event: "discardedError", callback: (args: DiscardedErrorEventData) => void, thisArg?: any) => void; (event: "orientationChanged", callback: (args: OrientationChangedEventData) => void, thisArg?: any) => void; (event: "systemAppearanceChanged", callback: (args: SystemAppearanceChangedEventData) => void, thisArg?: any) => void; }
once โ
once: { (eventNames: string, callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "cssChanged", callback: (args: CssChangedEventData) => void, thisArg?: any) => void; (event: "livesync", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "cssChanged", callback: (args: CssChangedEventData) => void, thisArg?: any) => void; (event: "launch", callback: (args: LaunchEventData) => void, thisArg?: any) => void; (event: "displayed", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "suspend", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "resume", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "exit", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "lowMemory", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "uncaughtError", callback: (args: UnhandledErrorEventData) => void, thisArg?: any) => void; (event: "discardedError", callback: (args: DiscardedErrorEventData) => void, thisArg?: any) => void; (event: "orientationChanged", callback: (args: OrientationChangedEventData) => void, thisArg?: any) => void; (event: "systemAppearanceChanged", callback: (args: SystemAppearanceChangedEventData) => void, thisArg?: any) => void; }
orientationChangedEvent โ
Readonly
resumeEvent โ
Readonly
started โ
suspendEvent โ
Readonly
systemAppearanceChangedEvent โ
Readonly
uncaughtErrorEvent โ
Readonly
hasListeners โ
Static
notify โ
Static
off โ
Static
on โ
Static
on: { (eventNames: string, callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "cssChanged", callback: (args: CssChangedEventData) => void, thisArg?: any) => void; (event: "livesync", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "cssChanged", callback: (args: CssChangedEventData) => void, thisArg?: any) => void; (event: "launch", callback: (args: LaunchEventData) => void, thisArg?: any) => void; (event: "displayed", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "suspend", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "resume", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "exit", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "lowMemory", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "uncaughtError", callback: (args: UnhandledErrorEventData) => void, thisArg?: any) => void; (event: "discardedError", callback: (args: DiscardedErrorEventData) => void, thisArg?: any) => void; (event: "orientationChanged", callback: (args: OrientationChangedEventData) => void, thisArg?: any) => void; (event: "systemAppearanceChanged", callback: (args: SystemAppearanceChangedEventData) => void, thisArg?: any) => void; }
once โ
Static
once: { (eventNames: string, callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "cssChanged", callback: (args: CssChangedEventData) => void, thisArg?: any) => void; (event: "livesync", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "cssChanged", callback: (args: CssChangedEventData) => void, thisArg?: any) => void; (event: "launch", callback: (args: LaunchEventData) => void, thisArg?: any) => void; (event: "displayed", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "suspend", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "resume", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "exit", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "lowMemory", callback: (args: ApplicationEventData) => void, thisArg?: any) => void; (event: "uncaughtError", callback: (args: UnhandledErrorEventData) => void, thisArg?: any) => void; (event: "discardedError", callback: (args: DiscardedErrorEventData) => void, thisArg?: any) => void; (event: "orientationChanged", callback: (args: OrientationChangedEventData) => void, thisArg?: any) => void; (event: "systemAppearanceChanged", callback: (args: SystemAppearanceChangedEventData) => void, thisArg?: any) => void; }
Accessors โ
AndroidApplication โ
get AndroidApplication(): AndroidApplication
Returns AndroidApplication
android โ
get android(): AndroidApplication
Returns AndroidApplication
iOSApplication โ
get iOSApplication(): iOSApplication
Returns iOSApplication
inBackground โ
Returns boolean
ios โ
get ios(): iOSApplication
Returns iOSApplication
suspended โ
Returns boolean
Methods โ
addCss โ
applyCssClass โ
applyCssClass(rootView: View, cssClasses: string[], newCssClass: string): void
Applies the the
`newCssClass`
to the `rootView`
and removes all other css classes from `cssClasses`
previously applied to the `rootView`
. Returns void
createRootView โ
getCssFileName โ
Gets css file name for the application.
Returns string
getMainEntry โ
Returns NavigationEntry
getNativeApplication โ
Returns any
getOrientation โ
Protected
Returns "portrait" | "landscape" | "unknown"
getResources โ
Get application level static resources.
Returns any
getSystemAppearance โ
Protected
Returns "dark" | "light"
hasLaunched โ
Returns boolean
loadAppCss โ
Loads immediately the app.css.
By default the app.css file is loaded shortly after "loaded".
For the Android snapshot the CSS can be parsed during the snapshot generation,
as the CSS does not depend on runtime APIs, and loadAppCss will be called explicitly.
Returns void
orientation โ
Returns "portrait" | "landscape" | "unknown"
orientationChanged โ
orientationChanged(rootView: View, newOrientation: "portrait" | "landscape" | "unknown"): void
resetRootView โ
run โ
setAutoSystemAppearanceChanged โ
enable/disable systemAppearanceChanged
Returns void
setCssFileName โ
Sets css file name for the application.
Returns void
setInBackground โ
setMaxRefreshRate โ
iOS Only
Dynamically change the preferred frame rate
For devices (iOS 15+) which support min/max/preferred frame rate you can specify ranges
For devices (iOS < 15), you can specify the max frame rate
see: https://developer.apple.com/documentation/quartzcore/optimizing_promotion_refresh_rates_for_iphone_13_pro_and_ipad_pro
To use, ensure your Info.plist has:
```xml
CADisableMinimumFrameDurationOnPhone
```
Returns void
setOrientation โ
Protected
setResources โ
Set application level static resources.
Returns void
setSuspended โ
setSystemAppearance โ
Protected
systemAppearance โ
Returns "dark" | "light"
- Previous
- Animation
- Next
- Background