@nativescript/core 9.1.0-next.2 → 9.1.0-next.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (83) hide show
  1. package/accessibility/accessibility-common.d.ts +8 -0
  2. package/accessibility/accessibility-common.js +28 -0
  3. package/accessibility/accessibility-common.js.map +1 -1
  4. package/application/application-common.d.ts +187 -3
  5. package/application/application-common.js +397 -54
  6. package/application/application-common.js.map +1 -1
  7. package/application/application-interfaces.d.ts +59 -1
  8. package/application/application.android.d.ts +21 -0
  9. package/application/application.android.js +189 -7
  10. package/application/application.android.js.map +1 -1
  11. package/application/application.d.ts +121 -66
  12. package/application/application.ios.d.ts +88 -26
  13. package/application/application.ios.js +474 -351
  14. package/application/application.ios.js.map +1 -1
  15. package/application/helpers-common.d.ts +5 -0
  16. package/application/helpers-common.js +23 -1
  17. package/application/helpers-common.js.map +1 -1
  18. package/application/scene-delegate-bridge.d.ts +55 -0
  19. package/application/scene-delegate-bridge.js +122 -0
  20. package/application/scene-delegate-bridge.js.map +1 -0
  21. package/config/config.interface.d.ts +38 -2
  22. package/css/system-classes.d.ts +9 -0
  23. package/css/system-classes.js +23 -0
  24. package/css/system-classes.js.map +1 -1
  25. package/data/observable/index.d.ts +5 -0
  26. package/data/observable/index.js +9 -0
  27. package/data/observable/index.js.map +1 -1
  28. package/global-types.d.ts +39 -33
  29. package/globals/global-utils.d.ts +6 -1
  30. package/globals/global-utils.js +10 -5
  31. package/globals/global-utils.js.map +1 -1
  32. package/index.d.ts +1 -0
  33. package/index.js +1 -0
  34. package/index.js.map +1 -1
  35. package/native-window/index.d.ts +426 -0
  36. package/native-window/index.js +4 -0
  37. package/native-window/index.js.map +1 -0
  38. package/native-window/native-window-common.d.ts +153 -0
  39. package/native-window/native-window-common.js +340 -0
  40. package/native-window/native-window-common.js.map +1 -0
  41. package/native-window/native-window-interfaces.d.ts +186 -0
  42. package/native-window/native-window-interfaces.js +90 -0
  43. package/native-window/native-window-interfaces.js.map +1 -0
  44. package/native-window/native-window.android.d.ts +59 -0
  45. package/native-window/native-window.android.js +175 -0
  46. package/native-window/native-window.android.js.map +1 -0
  47. package/native-window/native-window.ios.d.ts +57 -0
  48. package/native-window/native-window.ios.js +208 -0
  49. package/native-window/native-window.ios.js.map +1 -0
  50. package/native-window/window-base.d.ts +103 -0
  51. package/native-window/window-base.js +78 -0
  52. package/native-window/window-base.js.map +1 -0
  53. package/package.json +1 -1
  54. package/ui/core/view/index.android.js +3 -1
  55. package/ui/core/view/index.android.js.map +1 -1
  56. package/ui/core/view/index.d.ts +25 -0
  57. package/ui/core/view/view-common.d.ts +19 -0
  58. package/ui/core/view/view-common.js +34 -0
  59. package/ui/core/view/view-common.js.map +1 -1
  60. package/ui/core/view-base/index.js +6 -0
  61. package/ui/core/view-base/index.js.map +1 -1
  62. package/ui/frame/frame-common.d.ts +14 -2
  63. package/ui/frame/frame-common.js +17 -5
  64. package/ui/frame/frame-common.js.map +1 -1
  65. package/ui/frame/frame-constants.d.ts +9 -0
  66. package/ui/frame/frame-constants.js +10 -0
  67. package/ui/frame/frame-constants.js.map +1 -0
  68. package/ui/frame/frame-helper-for-android.d.ts +2 -2
  69. package/ui/frame/frame-helper-for-android.js +2 -2
  70. package/ui/frame/frame-helper-for-android.js.map +1 -1
  71. package/ui/frame/frame-interfaces.d.ts +1 -1
  72. package/ui/frame/frame-stack.d.ts +17 -1
  73. package/ui/frame/frame-stack.js +32 -5
  74. package/ui/frame/frame-stack.js.map +1 -1
  75. package/ui/frame/index.android.d.ts +1 -1
  76. package/ui/frame/index.android.js +111 -38
  77. package/ui/frame/index.android.js.map +1 -1
  78. package/ui/frame/index.d.ts +15 -5
  79. package/ui/segmented-bar/segmented-bar-common.js +6 -1
  80. package/ui/segmented-bar/segmented-bar-common.js.map +1 -1
  81. package/ui/tab-view/tab-view-common.js +4 -0
  82. package/ui/tab-view/tab-view-common.js.map +1 -1
  83. package/utils/native-helper.d.ts +2 -2
@@ -57,6 +57,14 @@ export declare function setCurrentFontScaleCategory(value: string): void;
57
57
  export declare function getCurrentFontScaleCategory(): string;
58
58
  export declare function setCurrentA11YServiceClass(value: string): void;
59
59
  export declare function getCurrentA11YServiceClass(): string;
60
+ /**
61
+ * Applies the current accessibility state — the a11y service class, the font scale
62
+ * classes and the inherited font scale — to a root view.
63
+ *
64
+ * Runs for every window's root view; the `readyInit*` helpers next to it only wire up
65
+ * the process-wide listeners that keep this state current, and do so once.
66
+ */
67
+ export declare function applyAccessibilityCssToRoot(rootView: View): void;
60
68
  export declare enum AccessibilityTrait {
61
69
  /**
62
70
  * The element allows direct touch interaction for VoiceOver users.
@@ -192,6 +192,34 @@ export function setCurrentA11YServiceClass(value) {
192
192
  export function getCurrentA11YServiceClass() {
193
193
  return currentA11YServiceClass;
194
194
  }
195
+ /**
196
+ * Applies the current accessibility state — the a11y service class, the font scale
197
+ * classes and the inherited font scale — to a root view.
198
+ *
199
+ * Runs for every window's root view; the `readyInit*` helpers next to it only wire up
200
+ * the process-wide listeners that keep this state current, and do so once.
201
+ */
202
+ export function applyAccessibilityCssToRoot(rootView) {
203
+ if (!rootView) {
204
+ return;
205
+ }
206
+ const a11yServiceClass = getCurrentA11YServiceClass();
207
+ if (a11yServiceClass) {
208
+ rootView.cssClasses.add(a11yServiceClass);
209
+ }
210
+ const fontScaleClass = getCurrentFontScaleClass();
211
+ if (fontScaleClass) {
212
+ rootView.cssClasses.add(fontScaleClass);
213
+ }
214
+ const fontScaleCategoryClass = getCurrentFontScaleCategory();
215
+ if (fontScaleCategoryClass) {
216
+ rootView.cssClasses.add(fontScaleCategoryClass);
217
+ }
218
+ const fontScale = getFontScale();
219
+ if (fontScale) {
220
+ rootView.style.fontScaleInternal = fontScale;
221
+ }
222
+ }
195
223
  export var AccessibilityTrait;
196
224
  (function (AccessibilityTrait) {
197
225
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"accessibility-common.js","sourceRoot":"","sources":["../../../../packages/core/accessibility/accessibility-common.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accessibility-common.js","sourceRoot":"","sources":["../../../../packages/core/accessibility/accessibility-common.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAIhD,MAAM,4BAA4B,GAAG,yBAAyB,CAAC;AAE/D,MAAM,CAAC,MAAM,sBAAsB,GAAG,mBAAmB,CAAC;AAC1D,MAAM,CAAC,MAAM,uBAAuB,GAAG,oBAAoB,CAAC;AAC5D,MAAM,CAAC,MAAM,8BAA8B,GAAG,2BAA2B,CAAC;AAC1E,MAAM,CAAC,MAAM,+BAA+B,GAAG,4BAA4B,CAAC;AAE5E;;;;;;;;;GASG;AACH,MAAM,UAAU,6BAA6B,CAAC,IAAU,EAAE,aAAsB,EAAE,SAAkB;IACnG,IAAI,CAAC,aAAa,IAAI,CAAC,SAAS,EAAE,CAAC;QAClC,OAAO;IACR,CAAC;IAED,IAAI,CAAC,MAAM,CAAC;QACX,SAAS,EAAE,8BAA8B;QACzC,MAAM,EAAE,IAAI;QACZ,KAAK,EAAE,CAAC,CAAC,aAAa;KACJ,CAAC,CAAC;IAErB,IAAI,aAAa,EAAE,CAAC;QACnB,IAAI,IAAI,CAAC,IAAI,EAAE,CAAC;YACf,IAAI,CAAC,IAAI,CAAC,4BAA4B,CAAC,GAAG,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;QAC7D,CAAC;QAED,IAAI,CAAC,MAAM,CAAC;YACX,SAAS,EAAE,uBAAuB;YAClC,MAAM,EAAE,IAAI;SACC,CAAC,CAAC;IACjB,CAAC;SAAM,IAAI,SAAS,EAAE,CAAC;QACtB,IAAI,CAAC,MAAM,CAAC;YACX,SAAS,EAAE,sBAAsB;YACjC,MAAM,EAAE,IAAI;SACC,CAAC,CAAC;IACjB,CAAC;AACF,CAAC;AAED,MAAM,UAAU,wBAAwB,CAAC,IAAU;IAClD,IAAI,CAAC;QACJ,MAAM,kBAAkB,GAAG,IAAI,CAAC,4BAA4B,CAAkB,CAAC;QAC/E,IAAI,CAA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A;IAEvC;;OAEG;IACH,4DAA+B,CAAA;IAE/B;;OAEG;IACH,0DAA6B,CAAA;IAE7B;;OAEG;IACH,oEAAuC,CAAA;IAEvC;;OAEG;IACH,0EAA6C,CAAA;IAE7C;;OAEG;IACH,sFAAyD,CAAA;IAEzD;;OAEG;IACH,kEAAqC,CAAA;IAErC;;OAEG;IACH,gEAAmC,CAAA;IACnC;;OAEG;IACH,gGAAmE,CAAA;IACnE;;OAEG;IACH,4FAA+D,CAAA;IAE/D;;OAEG;IACH,8EAAiD,CAAA;IAEjD;;OAEG;IACH,4DAA+B,CAAA;IAE/B;;OAEG;IACH,wFAA2D,CAAA;IAE3D;;OAEG;IACH,0DAA6B,CAAA;IAE7B;;OAEG;IACH,sFAAyD,CAAA;IAEzD;;OAEG;IACH,kGAAqE,CAAA;IAErE;;OAEG;IACH,wHAA2F,CAAA;IAE3F;;OAEG;IACH,gFAAmD,CAAA;IAEnD;;OAEG;IACH,4EAA+C,CAAA;IAE/C;;OAEG;IACH,gFAAmD,CAAA;IAEnD;;OAEG;IACH,4EAA+C,CAAA;IAE/C;;OAEG;IACH,6CAAgB,CAAA;AACjB,CAAC,EA3HW,yBAAyB,KAAzB,yBAAyB,QA2HpC"}
@@ -2,14 +2,25 @@ import { CoreTypes } from '../core-types';
2
2
  import type { View } from '../ui/core/view';
3
3
  import type { NavigationEntry } from '../ui/frame/frame-interfaces';
4
4
  import type { AndroidApplication as AndroidApplicationType, iOSApplication as iOSApplicationType } from '.';
5
- import type { ApplicationEventData, CssChangedEventData, DiscardedErrorEventData, FontScaleChangedEventData, LaunchEventData, OrientationChangedEventData, SystemAppearanceChangedEventData, LayoutDirectionChangedEventData, UnhandledErrorEventData } from './application-interfaces';
5
+ import type { ApplicationEventData, CssChangedEventData, DiscardedErrorEventData, FontScaleChangedEventData, LaunchEventData, OrientationChangedEventData, SystemAppearanceChangedEventData, LayoutDirectionChangedEventData, UnhandledErrorEventData, SceneOpenURLContextsEventData, SceneContinueUserActivityEventData, ScenePerformActionForShortcutItemEventData } from './application-interfaces';
6
+ import type { NativeWindow, PrimaryWindowChangedEventData, WindowBase, WindowCloseEventData, WindowContentRequest, WindowContentResolver, WindowOpenEventData, WindowOpenOptions, WindowRole } from '../native-window';
7
+ /**
8
+ * @deprecated Use `NativeWindowEvents` from `@nativescript/core/native-window` instead.
9
+ */
6
10
  export declare const SceneEvents: {
11
+ /** @deprecated Use `NativeWindowEvents.sceneWillConnect` instead. */
7
12
  sceneWillConnect: string;
13
+ /** @deprecated Use `NativeWindowEvents.sceneDidActivate` instead. */
8
14
  sceneDidActivate: string;
15
+ /** @deprecated Use `NativeWindowEvents.sceneWillResignActive` instead. */
9
16
  sceneWillResignActive: string;
17
+ /** @deprecated Use `NativeWindowEvents.sceneWillEnterForeground` instead. */
10
18
  sceneWillEnterForeground: string;
19
+ /** @deprecated Use `NativeWindowEvents.sceneDidEnterBackground` instead. */
11
20
  sceneDidEnterBackground: string;
21
+ /** @deprecated Use `NativeWindowEvents.sceneDidDisconnect` instead. */
12
22
  sceneDidDisconnect: string;
23
+ /** @deprecated Use the Application 'windowOpen' event and NativeWindow.setContent() instead. */
13
24
  sceneContentSetup: string;
14
25
  };
15
26
  export type SceneEventName = (typeof SceneEvents)[keyof typeof SceneEvents];
@@ -30,6 +41,10 @@ interface ApplicationEvents {
30
41
  * This event is raised on application launchEvent.
31
42
  */
32
43
  on(event: 'launch', callback: (args: LaunchEventData) => void, thisArg?: any): void;
44
+ /**
45
+ * This event is raised once the JS context is initialized.
46
+ */
47
+ on(event: 'ready', callback: (args: ApplicationEventData) => void, thisArg?: any): void;
33
48
  /**
34
49
  * This event is raised after the application has performed most of its startup actions.
35
50
  * Its intent is to be suitable for measuring app startup times.
@@ -46,6 +61,9 @@ interface ApplicationEvents {
46
61
  on(event: 'resume', callback: (args: ApplicationEventData) => void, thisArg?: any): void;
47
62
  /**
48
63
  * This event is raised when the Application is about to exit.
64
+ *
65
+ * On Android it is raised when the last window closes; the process may stay alive.
66
+ * On iOS it is raised when the process itself terminates.
49
67
  */
50
68
  on(event: 'exit', callback: (args: ApplicationEventData) => void, thisArg?: any): void;
51
69
  /**
@@ -76,14 +94,41 @@ interface ApplicationEvents {
76
94
  */
77
95
  on(event: 'layoutDirectionChanged', callback: (args: LayoutDirectionChangedEventData) => void, thisArg?: any): void;
78
96
  on(event: 'fontScaleChanged', callback: (args: FontScaleChangedEventData) => void, thisArg?: any): void;
97
+ on(event: 'windowOpen', callback: (args: WindowOpenEventData) => void, thisArg?: any): void;
98
+ on(event: 'windowClose', callback: (args: WindowCloseEventData) => void, thisArg?: any): void;
99
+ on(event: 'primaryWindowChanged', callback: (args: PrimaryWindowChangedEventData) => void, thisArg?: any): void;
100
+ on(event: 'sceneOpenURLContexts', callback: (args: SceneOpenURLContextsEventData) => void, thisArg?: any): void;
101
+ on(event: 'sceneContinueUserActivity', callback: (args: SceneContinueUserActivityEventData) => void, thisArg?: any): void;
102
+ on(event: 'scenePerformActionForShortcutItem', callback: (args: ScenePerformActionForShortcutItemEventData) => void, thisArg?: any): void;
79
103
  }
80
104
  export declare class ApplicationCommon {
105
+ /**
106
+ * @deprecated Use the 'ready' event for application initialization and Application.setWindowContentResolver() to provide window UI. 'launch' continues to fire before the first window's content is created, and its 'root' property is still honored, for backwards compatibility. It will not fire for additional windows or for background launches.
107
+ */
81
108
  readonly launchEvent = "launch";
109
+ /**
110
+ * Raised once per JS context, as soon as the context is initialized. It is never deferred,
111
+ * so it also fires on a background launch where no window is created.
112
+ *
113
+ * Guaranteed ordering: `ready` -> `windowOpen` -> raw connect/create events -> content
114
+ * resolution (the legacy `launch` bridge runs here, for the first window only) ->
115
+ * `contentLoaded` -> `activate`/`displayed`.
116
+ */
117
+ readonly readyEvent = "ready";
118
+ /**
119
+ * Reflects whole-app state: with multiple windows it is raised once the app itself is
120
+ * no longer in the foreground, not when an individual window backgrounds. Listen on a
121
+ * NativeWindow for per-window state.
122
+ */
82
123
  readonly suspendEvent = "suspend";
83
124
  readonly displayedEvent = "displayed";
84
125
  readonly backgroundEvent = "background";
85
126
  readonly foregroundEvent = "foreground";
86
127
  readonly resumeEvent = "resume";
128
+ /**
129
+ * On Android, raised when the last window closes; the process may stay alive.
130
+ * On iOS, raised when the process itself terminates.
131
+ */
87
132
  readonly exitEvent = "exit";
88
133
  readonly lowMemoryEvent = "lowMemory";
89
134
  readonly uncaughtErrorEvent = "uncaughtError";
@@ -96,6 +141,9 @@ export declare class ApplicationCommon {
96
141
  readonly loadAppCssEvent = "loadAppCss";
97
142
  readonly cssChangedEvent = "cssChanged";
98
143
  readonly initRootViewEvent = "initRootView";
144
+ readonly windowOpenEvent: "windowOpen";
145
+ readonly windowCloseEvent: "windowClose";
146
+ readonly primaryWindowChangedEvent: "primaryWindowChanged";
99
147
  /**
100
148
  * @deprecated Use `Application.android.on()` instead.
101
149
  */
@@ -127,12 +175,17 @@ export declare class ApplicationCommon {
127
175
  private _inBackground;
128
176
  private _suspended;
129
177
  private _cssFile;
178
+ private _readyNotified;
179
+ private _appCssLoaded;
180
+ private _launchBridgeConsumed;
181
+ private _windowContentResolver;
130
182
  protected mainEntry: NavigationEntry;
131
183
  started: boolean;
132
184
  /**
133
185
  * Boolean to enable/disable systemAppearanceChanged
134
186
  */
135
- autoSystemAppearanceChanged: boolean;
187
+ get autoSystemAppearanceChanged(): boolean;
188
+ set autoSystemAppearanceChanged(value: boolean);
136
189
  /**
137
190
  * @internal - should not be constructed by the user.
138
191
  */
@@ -152,6 +205,16 @@ export declare class ApplicationCommon {
152
205
  applyCssClass(rootView: View, cssClasses: string[], newCssClass: string, skipCssUpdate?: boolean): void;
153
206
  private addCssClass;
154
207
  private removeCssClass;
208
+ /**
209
+ * Same as {@link applyCssClass}, minus the system class list: window-scoped classes
210
+ * must not leak into it, because it seeds every window's root view.
211
+ */
212
+ private applyWindowScopedCssClass;
213
+ /**
214
+ * The modal registry is process-wide, so only the modals presented over this root
215
+ * view may follow its window-scoped classes.
216
+ */
217
+ private getOwnedModalViews;
155
218
  private increaseStyleScopeApplicationCssSelectorVersion;
156
219
  private setRootViewCSSClasses;
157
220
  /**
@@ -176,11 +239,123 @@ export declare class ApplicationCommon {
176
239
  * @returns The main entry of the application
177
240
  */
178
241
  getMainEntry(): any;
242
+ /**
243
+ * Sets the callback that supplies the UI for windows that need content.
244
+ * Pass `null` to remove a previously set resolver.
245
+ */
246
+ setWindowContentResolver(resolver: WindowContentResolver | null): void;
247
+ /**
248
+ * @returns The callback currently supplying window content, if any.
249
+ */
250
+ getWindowContentResolver(): WindowContentResolver | null;
251
+ protected _windows: NativeWindow[];
252
+ /**
253
+ * Get the primary NativeWindow.
254
+ */
255
+ get primaryWindow(): NativeWindow | undefined;
256
+ /**
257
+ * Get the NativeWindow the user is currently interacting with - the one that activated most
258
+ * recently and is still attached. Falls back to the primary window while no window holds
259
+ * activation, which is the case before the first window activates and on a platform that
260
+ * never raises `activate`.
261
+ */
262
+ get activeWindow(): NativeWindow | undefined;
263
+ /**
264
+ * Get the active windows, filtered by role.
265
+ *
266
+ * Defaults to the view-carrying app windows (`application` and `embedded`).
267
+ * Pass `'all'` to include every registered surface, including ones that carry no view tree.
268
+ */
269
+ getWindows(role: 'all'): WindowBase[];
270
+ getWindows(role?: WindowRole | WindowRole[]): NativeWindow[];
271
+ getWindows(role?: WindowRole | WindowRole[] | 'all'): WindowBase[];
272
+ /**
273
+ * Get a registered NativeWindow by its id.
274
+ */
275
+ getWindowById(id: string): NativeWindow | undefined;
276
+ /**
277
+ * Opens a new window.
278
+ *
279
+ * @param options Options for the new window, including data to hand to it.
280
+ */
281
+ openWindow(options?: WindowOpenOptions): void;
282
+ /**
283
+ * @internal - Get all registered NativeWindows, whatever their role.
284
+ */
285
+ _getWindows(): NativeWindow[];
286
+ /**
287
+ * @internal - Register a NativeWindow created by the platform lifecycle.
288
+ */
289
+ _registerWindow(nativeWindow: NativeWindow): void;
290
+ /**
291
+ * @internal - Unregister a NativeWindow when its native surface is gone for good.
292
+ */
293
+ _unregisterWindow(nativeWindow: NativeWindow): void;
294
+ /**
295
+ * Hook for platform-specific bookkeeping right after a window joins the registry,
296
+ * before `windowOpen` is raised.
297
+ */
298
+ protected _onWindowRegistered(nativeWindow: NativeWindow): void;
299
+ /**
300
+ * Hook for platform-specific bookkeeping right after a window takes over the primary
301
+ * role, before `primaryWindowChanged` is raised.
302
+ */
303
+ protected _onPrimaryWindowPromoted(nativeWindow: NativeWindow): void;
304
+ private _traitsWindow;
305
+ /**
306
+ * Points the application-level orientation, appearance and layout direction at the
307
+ * primary window, which owns those values now that each window has its own.
308
+ */
309
+ private trackPrimaryWindowTraits;
310
+ /**
311
+ * Adopts the window's values. The very first window seeds them quietly — there is no
312
+ * previous application state for it to differ from — while a later promotion raises
313
+ * the change events, because app code observed the outgoing window's values.
314
+ */
315
+ private syncTraitsFromWindow;
316
+ private onWindowActivated;
317
+ private onWindowOrientationChanged;
318
+ private onWindowSystemAppearanceChanged;
319
+ private onWindowLayoutDirectionChanged;
320
+ /**
321
+ * @internal - raises `ready` at most once per JS context.
322
+ */
323
+ notifyReady(): void;
324
+ /**
325
+ * @internal - produces the content for a window that has none.
326
+ *
327
+ * Resolution order: the window content resolver, then the legacy `launch` event
328
+ * (offered to the first window that asks for content and to no other), then the
329
+ * application main entry. A resolver or a `launch` handler returning `null` takes
330
+ * ownership of the content, so nothing else is tried. A missing main entry leaves
331
+ * the window empty instead of throwing, because content can still arrive later
332
+ * through `run()`/`resetRootView()`.
333
+ *
334
+ * @param options.install `false` returns the resolved view instead of applying it,
335
+ * for platform pipelines that install the root view on the native surface themselves.
336
+ * @param options.launchData platform payload merged into the legacy `launch` event args.
337
+ * @returns The resolved view, or `null` when no content was produced.
338
+ */
339
+ _resolveWindowContent(window: NativeWindow, request: WindowContentRequest, options?: {
340
+ install?: boolean;
341
+ launchData?: any;
342
+ }): View | null;
343
+ private resolveWindowContent;
344
+ private buildContentView;
345
+ /**
346
+ * Loads the app CSS once per JS context. On the legacy `launch` path this has to run
347
+ * after the handlers, which are allowed to call `setCssFileName()`.
348
+ */
349
+ private _ensureAppCssLoaded;
179
350
  protected notifyLaunch(additionalLanchEventData?: any): View | null;
180
351
  createRootView(view?: View, fireLaunchEvent?: boolean, additionalLanchEventData?: any): View;
181
352
  getRootView(): View;
182
353
  resetRootView(entry?: NavigationEntry | string): void;
183
- initRootView(rootView: View): void;
354
+ /**
355
+ * @param window the window the root view belongs to. Supplies the window-scoped CSS
356
+ * classes; without it they come from the primary window.
357
+ */
358
+ initRootView(rootView: View, window?: NativeWindow): void;
184
359
  /**
185
360
  * Get application level static resources.
186
361
  */
@@ -208,12 +383,18 @@ export declare class ApplicationCommon {
208
383
  run(entry?: string | NavigationEntry): void;
209
384
  protected getOrientation(): 'portrait' | 'landscape' | 'unknown';
210
385
  protected setOrientation(value: 'portrait' | 'landscape' | 'unknown'): void;
386
+ /**
387
+ * @deprecated Use Application.primaryWindow?.orientation() - or the NativeWindow of the relevant view - instead. Continues to reflect the primary window.
388
+ */
211
389
  orientation(): 'portrait' | 'landscape' | 'unknown';
212
390
  orientationChanged(rootView: View, newOrientation: 'portrait' | 'landscape' | 'unknown'): void;
213
391
  getNativeApplication(): any;
214
392
  hasLaunched(): boolean;
215
393
  protected getSystemAppearance(): 'dark' | 'light' | null;
216
394
  protected setSystemAppearance(value: 'dark' | 'light'): void;
395
+ /**
396
+ * @deprecated Use Application.primaryWindow?.systemAppearance() - or the NativeWindow of the relevant view - instead. Continues to reflect the primary window.
397
+ */
217
398
  systemAppearance(): 'dark' | 'light' | null;
218
399
  /**
219
400
  * enable/disable systemAppearanceChanged
@@ -227,6 +408,9 @@ export declare class ApplicationCommon {
227
408
  systemAppearanceChanged(rootView: View, newSystemAppearance: 'dark' | 'light'): void;
228
409
  protected getLayoutDirection(): CoreTypes.LayoutDirectionType | null;
229
410
  protected setLayoutDirection(value: CoreTypes.LayoutDirectionType): void;
411
+ /**
412
+ * @deprecated Use Application.primaryWindow?.layoutDirection() - or the NativeWindow of the relevant view - instead. Continues to reflect the primary window.
413
+ */
230
414
  layoutDirection(): CoreTypes.LayoutDirectionType | null;
231
415
  /**
232
416
  * Updates root view classes including those of modals