@openfin/core 25.68.26 → 25.68.29
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.
- package/OpenFin.d.ts +1378 -373
- package/README.md +6 -2
- package/package.json +2 -3
- package/src/api/application/Instance.d.ts +2 -2
- package/src/api/application/Instance.js +1 -1
- package/src/api/base.d.ts +1 -1
- package/src/api/events/channel.d.ts +2 -1
- package/src/api/events/eventAggregator.d.ts +1 -1
- package/src/api/external-application/Instance.d.ts +1 -1
- package/src/api/fin.d.ts +1 -1
- package/src/api/frame/Instance.d.ts +1 -1
- package/src/api/global-hotkey/index.d.ts +1 -1
- package/src/api/interappbus/channel/channel.d.ts +3 -3
- package/src/api/interappbus/channel/index.d.ts +2 -1
- package/src/api/interappbus/index.d.ts +2 -1
- package/src/api/me.d.ts +1 -1
- package/src/api/platform/Instance.d.ts +1 -1
- package/src/api/platform/Instance.js +1 -2
- package/src/api/platform/common-utils.d.ts +1 -1
- package/src/api/platform/layout/Factory.d.ts +1 -1
- package/src/api/platform/layout/Factory.js +1 -0
- package/src/api/platform/layout/Instance.d.ts +2 -1
- package/src/api/platform/layout/index.d.ts +0 -1
- package/src/api/platform/layout/index.js +0 -1
- package/src/api/system/index.d.ts +17 -13
- package/src/api/system/index.js +3 -3
- package/src/api/view/Instance.d.ts +1 -1
- package/src/api/webcontents/main.d.ts +1 -1
- package/src/api/window/Instance.d.ts +3 -3
- package/src/environment/environment.d.ts +5 -8
- package/src/environment/node-env.d.ts +5 -4
- package/src/environment/openfin-env.d.ts +5 -4
- package/src/environment/openfin-env.js +2 -0
- package/src/mock.d.ts +0 -1
- package/src/mock.js +1 -2
- package/src/transport/transport-errors.d.ts +3 -2
- package/src/transport/transport-errors.js +1 -3
- package/src/transport/transport.d.ts +10 -24
- package/src/transport/transport.js +0 -14
- package/src/transport/wire.d.ts +6 -71
- package/src/transport/wire.js +1 -8
- package/src/util/errors.d.ts +1 -5
- package/src/util/errors.js +0 -3
- package/src/util/normalize-config.d.ts +3 -1
- package/src/api/events/application.d.ts +0 -69
- package/src/api/events/application.js +0 -2
- package/src/api/events/base.d.ts +0 -17
- package/src/api/events/base.js +0 -2
- package/src/api/events/externalApplication.d.ts +0 -5
- package/src/api/events/externalApplication.js +0 -2
- package/src/api/events/frame.d.ts +0 -9
- package/src/api/events/frame.js +0 -2
- package/src/api/events/globalHotkey.d.ts +0 -10
- package/src/api/events/globalHotkey.js +0 -2
- package/src/api/events/platform.d.ts +0 -18
- package/src/api/events/platform.js +0 -2
- package/src/api/events/system.d.ts +0 -22
- package/src/api/events/system.js +0 -2
- package/src/api/events/view.d.ts +0 -56
- package/src/api/events/view.js +0 -2
- package/src/api/events/webcontents.d.ts +0 -48
- package/src/api/events/webcontents.js +0 -2
- package/src/api/events/window.d.ts +0 -169
- package/src/api/events/window.js +0 -2
- package/src/api/platform/layout/shapes.d.ts +0 -11
- package/src/api/platform/layout/shapes.js +0 -2
- package/src/api/system/application.d.ts +0 -6
- package/src/api/system/application.js +0 -2
- package/src/api/system/entity.d.ts +0 -11
- package/src/api/system/entity.js +0 -2
- package/src/api/system/installedApps.d.ts +0 -6
- package/src/api/system/installedApps.js +0 -2
- package/src/api/system/log.d.ts +0 -11
- package/src/api/system/log.js +0 -2
- package/src/api/system/process.d.ts +0 -15
- package/src/api/system/process.js +0 -2
- package/src/api/system/proxy.d.ts +0 -15
- package/src/api/system/proxy.js +0 -2
- package/src/api/system/queryPermissionTypes.d.ts +0 -1
- package/src/api/system/queryPermissionTypes.js +0 -2
- package/src/api/system/registry-info.d.ts +0 -7
- package/src/api/system/registry-info.js +0 -2
- package/src/api/system/window.d.ts +0 -16
- package/src/api/system/window.js +0 -2
- package/src/shapes/ERROR_BOX_TYPES.d.ts +0 -6
- package/src/shapes/ERROR_BOX_TYPES.js +0 -10
- package/src/shapes/EntityType.d.ts +0 -1
- package/src/shapes/EntityType.js +0 -2
- package/src/shapes/LayoutPresetType.d.ts +0 -1
- package/src/shapes/LayoutPresetType.js +0 -2
- package/src/shapes/Platform.d.ts +0 -112
- package/src/shapes/Platform.js +0 -16
- package/src/shapes/WebOptions.d.ts +0 -12
- package/src/shapes/WebOptions.js +0 -2
- package/src/shapes/WindowOptions.d.ts +0 -42
- package/src/shapes/WindowOptions.js +0 -2
- package/src/shapes/protocol.d.ts +0 -178
- package/src/shapes/protocol.js +0 -2
package/OpenFin.d.ts
CHANGED
|
@@ -1,5 +1,8 @@
|
|
|
1
|
+
// / <reference lib="dom"/>
|
|
2
|
+
|
|
1
3
|
declare namespace OpenFin {
|
|
2
4
|
// "wrappable entities"
|
|
5
|
+
import EventEmitter = NodeJS.EventEmitter;
|
|
3
6
|
export type Application = import('./src/api/application/index').Application;
|
|
4
7
|
export type ExternalApplication = import('./src/api/external-application/index').ExternalApplication;
|
|
5
8
|
export type Frame = import('./src/api/frame/index')._Frame;
|
|
@@ -14,63 +17,64 @@ declare namespace OpenFin {
|
|
|
14
17
|
export type InteropBroker = import('./src/api/interop/index').InteropBroker;
|
|
15
18
|
export type SnapshotSource = import('./src/api/snapshot-source/index').SnapshotSource;
|
|
16
19
|
|
|
17
|
-
export
|
|
20
|
+
export type ApplicationIdentity = {
|
|
18
21
|
// used for applications
|
|
19
22
|
uuid: string;
|
|
20
|
-
}
|
|
23
|
+
};
|
|
21
24
|
|
|
22
|
-
export
|
|
25
|
+
export type Identity = {
|
|
23
26
|
// used for views/windows/frames
|
|
24
27
|
uuid: string;
|
|
25
28
|
name: string;
|
|
26
|
-
}
|
|
29
|
+
};
|
|
27
30
|
|
|
28
|
-
export
|
|
31
|
+
export type ClientIdentity = {
|
|
29
32
|
uuid: string;
|
|
30
33
|
name: string;
|
|
31
34
|
endpointId: string;
|
|
32
35
|
isLocalEndpointId: boolean; // If true, this connection is from a legacy client.
|
|
33
|
-
}
|
|
36
|
+
};
|
|
34
37
|
|
|
35
|
-
export
|
|
38
|
+
export type ClientIdentityMultiRuntime = ClientIdentity & {
|
|
36
39
|
runtimeUuid: string;
|
|
37
|
-
}
|
|
40
|
+
};
|
|
38
41
|
|
|
39
|
-
export
|
|
42
|
+
export type EntityInfo = {
|
|
40
43
|
uuid: string;
|
|
41
44
|
name: string;
|
|
42
45
|
entityType: EntityType;
|
|
43
|
-
}
|
|
44
|
-
export type EntityType = import('./src/shapes/EntityType').EntityType;
|
|
46
|
+
};
|
|
45
47
|
|
|
46
|
-
export
|
|
48
|
+
export type EntityType = 'window' | 'iframe' | 'external connection' | 'view' | 'unknown';
|
|
49
|
+
|
|
50
|
+
export type Bounds = {
|
|
47
51
|
top: number;
|
|
48
52
|
left: number;
|
|
49
53
|
height: number;
|
|
50
54
|
width: number;
|
|
51
|
-
}
|
|
55
|
+
};
|
|
52
56
|
|
|
53
57
|
/**
|
|
54
58
|
* Returned from getBounds call. bottom and right are never used for setting.
|
|
55
59
|
*/
|
|
56
|
-
export
|
|
60
|
+
export type WindowBounds = Bounds & {
|
|
57
61
|
bottom: number;
|
|
58
62
|
right: number;
|
|
59
|
-
}
|
|
63
|
+
};
|
|
60
64
|
|
|
61
|
-
export
|
|
65
|
+
export type Rectangle = {
|
|
62
66
|
x: number;
|
|
63
67
|
y: number;
|
|
64
68
|
width: number;
|
|
65
69
|
height: number;
|
|
66
|
-
}
|
|
70
|
+
};
|
|
67
71
|
|
|
68
|
-
export
|
|
72
|
+
export type ApplicationCreationOptions = Partial<ApplicationOption> & {
|
|
69
73
|
name: string;
|
|
70
74
|
uuid: string;
|
|
71
|
-
}
|
|
75
|
+
};
|
|
72
76
|
|
|
73
|
-
export
|
|
77
|
+
export type ApplicationOption = LegacyWinOptionsInAppOptions & {
|
|
74
78
|
disableIabSecureLogging: boolean;
|
|
75
79
|
loadErrorMessage: string;
|
|
76
80
|
mainWindowOptions: WindowCreationOptions;
|
|
@@ -92,18 +96,18 @@ declare namespace OpenFin {
|
|
|
92
96
|
apiDiagnostics: boolean;
|
|
93
97
|
defaultDomainSettings: DefaultDomainSettings;
|
|
94
98
|
enableJumpList: boolean;
|
|
95
|
-
}
|
|
99
|
+
};
|
|
96
100
|
|
|
97
|
-
|
|
101
|
+
type InteropBrokerOptions = {
|
|
98
102
|
contextGroups?: ContextGroupInfo;
|
|
99
|
-
}
|
|
103
|
+
};
|
|
100
104
|
|
|
101
|
-
export
|
|
105
|
+
export type ContextGroupInfo = {
|
|
102
106
|
id: string;
|
|
103
107
|
displayMetadata?: DisplayMetadata;
|
|
104
|
-
}
|
|
108
|
+
};
|
|
105
109
|
|
|
106
|
-
export
|
|
110
|
+
export type DisplayMetadata = {
|
|
107
111
|
/**
|
|
108
112
|
* A user-readable name for this context group, e.g: `"Red"`
|
|
109
113
|
*/
|
|
@@ -116,7 +120,7 @@ declare namespace OpenFin {
|
|
|
116
120
|
* A URL of an image that can be used to display this context group
|
|
117
121
|
*/
|
|
118
122
|
readonly glyph?: string;
|
|
119
|
-
}
|
|
123
|
+
};
|
|
120
124
|
|
|
121
125
|
export type LegacyWinOptionsInAppOptions = Pick<
|
|
122
126
|
WindowCreationOptions,
|
|
@@ -158,7 +162,7 @@ declare namespace OpenFin {
|
|
|
158
162
|
| 'waitForPageLoad'
|
|
159
163
|
>;
|
|
160
164
|
|
|
161
|
-
export
|
|
165
|
+
export type Snapshot = {
|
|
162
166
|
windows: WindowCreationOptions[];
|
|
163
167
|
snapshotDetails?: {
|
|
164
168
|
monitorInfo: MonitorInfo;
|
|
@@ -168,23 +172,23 @@ declare namespace OpenFin {
|
|
|
168
172
|
interopSnapshotDetails?: {
|
|
169
173
|
contextGroupStates: ContextGroupStates;
|
|
170
174
|
};
|
|
171
|
-
}
|
|
175
|
+
};
|
|
172
176
|
|
|
173
|
-
export
|
|
177
|
+
export type ContextGroupStates = {
|
|
174
178
|
[key: string]: {
|
|
175
179
|
[key: string]: Context;
|
|
176
180
|
};
|
|
177
|
-
}
|
|
181
|
+
};
|
|
178
182
|
|
|
179
|
-
export
|
|
183
|
+
export type Context = {
|
|
180
184
|
id?: {
|
|
181
185
|
[key: string]: string;
|
|
182
186
|
};
|
|
183
187
|
name?: string;
|
|
184
188
|
type: string;
|
|
185
|
-
}
|
|
189
|
+
};
|
|
186
190
|
|
|
187
|
-
export
|
|
191
|
+
export type MonitorInfo = {
|
|
188
192
|
deviceScaleFactor: number;
|
|
189
193
|
dpi: Point;
|
|
190
194
|
nonPrimaryMonitors: MonitorDetails[];
|
|
@@ -192,26 +196,26 @@ declare namespace OpenFin {
|
|
|
192
196
|
reason: string;
|
|
193
197
|
taskbar: TaskBar;
|
|
194
198
|
virtualScreen: DipRect;
|
|
195
|
-
}
|
|
199
|
+
};
|
|
196
200
|
|
|
197
|
-
export
|
|
201
|
+
export type Point = {
|
|
198
202
|
x: number;
|
|
199
203
|
y: number;
|
|
200
|
-
}
|
|
204
|
+
};
|
|
201
205
|
|
|
202
|
-
export
|
|
206
|
+
export type PointTopLeft = {
|
|
203
207
|
top: number;
|
|
204
208
|
left: number;
|
|
205
|
-
}
|
|
209
|
+
};
|
|
206
210
|
|
|
207
|
-
export
|
|
211
|
+
export type RectangleByEdgePositions = {
|
|
208
212
|
top: number;
|
|
209
213
|
left: number;
|
|
210
214
|
bottom: number;
|
|
211
215
|
right: number;
|
|
212
|
-
}
|
|
216
|
+
};
|
|
213
217
|
|
|
214
|
-
export
|
|
218
|
+
export type MonitorDetails = {
|
|
215
219
|
available: DipScaleRects;
|
|
216
220
|
availableRect: RectangleByEdgePositions;
|
|
217
221
|
deviceId: string | number; // Number on mac
|
|
@@ -221,32 +225,36 @@ declare namespace OpenFin {
|
|
|
221
225
|
name: string | number; // Number on mac
|
|
222
226
|
dpi: Point;
|
|
223
227
|
monitor: DipScaleRects;
|
|
224
|
-
}
|
|
228
|
+
};
|
|
225
229
|
|
|
226
|
-
export
|
|
230
|
+
export type DipRect = RectangleByEdgePositions & {
|
|
227
231
|
dipRect: RectangleByEdgePositions;
|
|
228
232
|
scaledRect: RectangleByEdgePositions;
|
|
229
|
-
}
|
|
233
|
+
};
|
|
230
234
|
|
|
231
|
-
export
|
|
235
|
+
export type DipScaleRects = {
|
|
232
236
|
dipRect: RectangleByEdgePositions;
|
|
233
237
|
scaledRect: RectangleByEdgePositions;
|
|
234
|
-
}
|
|
238
|
+
};
|
|
235
239
|
|
|
236
|
-
export
|
|
240
|
+
export type TaskBar = DipScaleRects & {
|
|
237
241
|
edge: string;
|
|
238
242
|
rect: RectangleByEdgePositions;
|
|
239
|
-
}
|
|
243
|
+
};
|
|
240
244
|
|
|
241
|
-
export
|
|
245
|
+
export type WindowCreationOptions = Partial<WindowOptions> & {
|
|
242
246
|
name: string;
|
|
243
|
-
}
|
|
247
|
+
};
|
|
248
|
+
|
|
249
|
+
export type UpdateableWindowOptions = Partial<MutableWindowOptions>;
|
|
244
250
|
|
|
245
|
-
export
|
|
251
|
+
export type DefaultWindowOptions = WindowOptions & {
|
|
246
252
|
permissions: Partial<Permissions>;
|
|
247
|
-
}
|
|
253
|
+
};
|
|
254
|
+
|
|
255
|
+
export type WindowOptions = MutableWindowOptions & ConstWindowOptions;
|
|
248
256
|
|
|
249
|
-
export
|
|
257
|
+
export type ConstWindowOptions = {
|
|
250
258
|
accelerator: Partial<Accelerator>;
|
|
251
259
|
api: Api;
|
|
252
260
|
applicationIcon: string;
|
|
@@ -284,9 +292,9 @@ declare namespace OpenFin {
|
|
|
284
292
|
y: number;
|
|
285
293
|
experimental?: any;
|
|
286
294
|
fdc3InteropApi?: string;
|
|
287
|
-
}
|
|
295
|
+
};
|
|
288
296
|
|
|
289
|
-
export
|
|
297
|
+
export type MutableWindowOptions = {
|
|
290
298
|
alphaMask: RGB;
|
|
291
299
|
alwaysOnTop: boolean;
|
|
292
300
|
aspectRatio: number;
|
|
@@ -311,73 +319,21 @@ declare namespace OpenFin {
|
|
|
311
319
|
showTaskbarIcon: boolean;
|
|
312
320
|
interop: InteropConfig;
|
|
313
321
|
workspacePlatform: WorkspacePlatformOptions;
|
|
314
|
-
}
|
|
322
|
+
};
|
|
315
323
|
|
|
316
|
-
export
|
|
317
|
-
pages: Page[];
|
|
324
|
+
export type WorkspacePlatformOptions = {
|
|
318
325
|
/** Leaving this as any for now until we figure out what the shape should look like in Workspace */
|
|
319
326
|
[key: string]: any;
|
|
320
|
-
}
|
|
321
|
-
|
|
322
|
-
type LayoutSettingsExtended = LayoutOptions['settings'] & {
|
|
323
|
-
reorderEnabled?: boolean;
|
|
324
|
-
};
|
|
325
|
-
|
|
326
|
-
type LayoutComponentStateExtended = LayoutComponent['componentState'] & { name: string; uuid: string };
|
|
327
|
-
|
|
328
|
-
type LayoutComponentExtended = Omit<OpenFin.LayoutComponent, 'componentState'> & {
|
|
329
|
-
componentState: LayoutComponentStateExtended;
|
|
330
|
-
};
|
|
331
|
-
|
|
332
|
-
type LayoutStack = { type: 'stack'; content: LayoutContent };
|
|
333
|
-
|
|
334
|
-
type LayoutContentItemExtended = OpenFin.LayoutRow | OpenFin.LayoutColumn | LayoutComponentExtended | LayoutStack;
|
|
335
|
-
|
|
336
|
-
type LayoutContentExtended = LayoutContentItemExtended[];
|
|
337
|
-
|
|
338
|
-
type LayoutExtended = {
|
|
339
|
-
settings: LayoutSettingsExtended;
|
|
340
|
-
content: LayoutContentExtended;
|
|
341
327
|
};
|
|
342
328
|
|
|
343
|
-
|
|
344
|
-
/** The id of the machine that created the page. */
|
|
345
|
-
machineId: string;
|
|
346
|
-
|
|
347
|
-
/** The name of the machine that created the page. */
|
|
348
|
-
machineName?: string;
|
|
349
|
-
}
|
|
350
|
-
|
|
351
|
-
type PageLayout = LayoutExtended & { layoutDetails: PageLayoutDetails };
|
|
352
|
-
|
|
353
|
-
interface Page {
|
|
354
|
-
/** A UI friendly title for the page. */
|
|
355
|
-
title: string;
|
|
356
|
-
|
|
357
|
-
/** The unique ID of the page. */
|
|
358
|
-
pageId: string;
|
|
359
|
-
|
|
360
|
-
/** An optional UI friendly description of the page. */
|
|
361
|
-
description?: string;
|
|
362
|
-
|
|
363
|
-
/** A optional UI friendly tooltip for the page. */
|
|
364
|
-
tooltip?: string;
|
|
365
|
-
|
|
366
|
-
/** True if the page is read only. In this state, the page is locked and cannot be unlocked. */
|
|
367
|
-
isReadOnly?: boolean;
|
|
368
|
-
|
|
369
|
-
/** The layout of the page. */
|
|
370
|
-
layout: PageLayout;
|
|
371
|
-
}
|
|
372
|
-
|
|
373
|
-
export interface WebRequestHeader {
|
|
329
|
+
export type WebRequestHeader = {
|
|
374
330
|
[key: string]: string;
|
|
375
|
-
}
|
|
331
|
+
};
|
|
376
332
|
|
|
377
|
-
export
|
|
333
|
+
export type CustomRequestHeaders = {
|
|
378
334
|
urlPatterns: string[];
|
|
379
335
|
headers: WebRequestHeader[]; // key=value is added to headers
|
|
380
|
-
}
|
|
336
|
+
};
|
|
381
337
|
|
|
382
338
|
export type WindowOptionDiff = {
|
|
383
339
|
[key in keyof WindowOptions]: {
|
|
@@ -386,7 +342,7 @@ declare namespace OpenFin {
|
|
|
386
342
|
};
|
|
387
343
|
};
|
|
388
344
|
|
|
389
|
-
export
|
|
345
|
+
export type ResizeRegion = {
|
|
390
346
|
size?: number;
|
|
391
347
|
bottomRightCorner?: number;
|
|
392
348
|
sides?: {
|
|
@@ -395,76 +351,76 @@ declare namespace OpenFin {
|
|
|
395
351
|
left?: boolean;
|
|
396
352
|
right?: boolean;
|
|
397
353
|
};
|
|
398
|
-
}
|
|
354
|
+
};
|
|
399
355
|
|
|
400
|
-
export
|
|
356
|
+
export type Accelerator = {
|
|
401
357
|
devtools: boolean;
|
|
402
358
|
reload: boolean;
|
|
403
359
|
reloadIgnoringCache: boolean;
|
|
404
360
|
zoom: boolean;
|
|
405
|
-
}
|
|
361
|
+
};
|
|
406
362
|
|
|
407
|
-
export
|
|
363
|
+
export type Api = {
|
|
408
364
|
iframe?: {
|
|
409
365
|
crossOriginInjection?: boolean;
|
|
410
366
|
sameOriginInjection?: boolean;
|
|
411
367
|
enableDeprecatedSharedName?: boolean;
|
|
412
368
|
};
|
|
413
|
-
}
|
|
369
|
+
};
|
|
414
370
|
|
|
415
|
-
export
|
|
371
|
+
export type ContentNavigation = {
|
|
416
372
|
whitelist?: string[];
|
|
417
373
|
blacklist?: string[];
|
|
418
|
-
}
|
|
374
|
+
};
|
|
419
375
|
|
|
420
|
-
export
|
|
376
|
+
export type ContentRedirect = {
|
|
421
377
|
whitelist: string[];
|
|
422
378
|
blacklist: string[];
|
|
423
|
-
}
|
|
379
|
+
};
|
|
424
380
|
|
|
425
|
-
export
|
|
381
|
+
export type CornerRounding = {
|
|
426
382
|
height: number;
|
|
427
383
|
width: number;
|
|
428
|
-
}
|
|
384
|
+
};
|
|
429
385
|
|
|
430
|
-
export
|
|
386
|
+
export type DownloadPreloadOption = {
|
|
431
387
|
url: string;
|
|
432
|
-
}
|
|
388
|
+
};
|
|
433
389
|
|
|
434
|
-
export
|
|
390
|
+
export type DownloadPreloadInfo = {
|
|
435
391
|
success: boolean;
|
|
436
392
|
url?: string;
|
|
437
393
|
error: string;
|
|
438
|
-
}
|
|
394
|
+
};
|
|
439
395
|
|
|
440
|
-
export
|
|
396
|
+
export type RGB = {
|
|
441
397
|
red: number;
|
|
442
398
|
blue: number;
|
|
443
399
|
green: number;
|
|
444
|
-
}
|
|
400
|
+
};
|
|
445
401
|
|
|
446
|
-
export
|
|
402
|
+
export type ContextMenuSettings = {
|
|
447
403
|
enable: boolean;
|
|
448
404
|
devtools?: boolean;
|
|
449
405
|
reload?: boolean;
|
|
450
|
-
}
|
|
406
|
+
};
|
|
451
407
|
|
|
452
|
-
export
|
|
408
|
+
export type Hotkey = {
|
|
453
409
|
keys: string;
|
|
454
410
|
preventDefault?: boolean;
|
|
455
|
-
}
|
|
411
|
+
};
|
|
456
412
|
|
|
457
|
-
export
|
|
413
|
+
export type ShortcutOverride = Hotkey & {
|
|
458
414
|
command: string;
|
|
459
|
-
}
|
|
415
|
+
};
|
|
460
416
|
|
|
461
|
-
export
|
|
417
|
+
export type PreloadScript = {
|
|
462
418
|
mandatory?: boolean;
|
|
463
419
|
state?: 'load-started' | 'load-failed' | 'load-succeeded' | 'failed' | 'succeeded';
|
|
464
420
|
url: string;
|
|
465
|
-
}
|
|
421
|
+
};
|
|
466
422
|
|
|
467
|
-
export
|
|
423
|
+
export type AutoResizeOptions = {
|
|
468
424
|
/**
|
|
469
425
|
* If true, the view's width will grow and shrink together with the window. false
|
|
470
426
|
* by default.
|
|
@@ -485,28 +441,28 @@ declare namespace OpenFin {
|
|
|
485
441
|
* the window. false by default.
|
|
486
442
|
*/
|
|
487
443
|
vertical?: boolean;
|
|
488
|
-
}
|
|
444
|
+
};
|
|
489
445
|
|
|
490
|
-
export
|
|
446
|
+
export type InteropConfig = {
|
|
491
447
|
currentContextGroup?: string | null;
|
|
492
448
|
providerId?: string;
|
|
493
|
-
}
|
|
449
|
+
};
|
|
494
450
|
|
|
495
|
-
export
|
|
451
|
+
export type ViewInfo = {
|
|
496
452
|
canNavigateBack: boolean;
|
|
497
453
|
canNavigateForward: boolean;
|
|
498
454
|
processAffinity: string;
|
|
499
455
|
title: string;
|
|
500
456
|
url: string;
|
|
501
457
|
favicons: string[];
|
|
502
|
-
}
|
|
503
|
-
export
|
|
458
|
+
};
|
|
459
|
+
export type ViewCreationOptions = Partial<ViewOptions> & {
|
|
504
460
|
name: string;
|
|
505
461
|
url: string;
|
|
506
462
|
target: Identity;
|
|
507
|
-
}
|
|
463
|
+
};
|
|
508
464
|
|
|
509
|
-
export
|
|
465
|
+
export type UpdatableViewOptions = {
|
|
510
466
|
autoResize: AutoResizeOptions;
|
|
511
467
|
contextMenuSettings: ContextMenuSettings;
|
|
512
468
|
backgroundColor: string;
|
|
@@ -519,13 +475,13 @@ declare namespace OpenFin {
|
|
|
519
475
|
preventDragOut: boolean;
|
|
520
476
|
// Doesn't get defaulted
|
|
521
477
|
interop?: InteropConfig;
|
|
522
|
-
}
|
|
478
|
+
};
|
|
523
479
|
|
|
524
|
-
export
|
|
480
|
+
export type DefaultViewOptions = ViewOptions & {
|
|
525
481
|
permissions: Partial<Permissions>;
|
|
526
|
-
}
|
|
482
|
+
};
|
|
527
483
|
|
|
528
|
-
export
|
|
484
|
+
export type ViewOptions = UpdatableViewOptions & {
|
|
529
485
|
name: string;
|
|
530
486
|
url: string;
|
|
531
487
|
target: Identity;
|
|
@@ -539,9 +495,9 @@ declare namespace OpenFin {
|
|
|
539
495
|
zoomLevel: number;
|
|
540
496
|
experimental: any;
|
|
541
497
|
fdc3InteropApi?: string;
|
|
542
|
-
}
|
|
498
|
+
};
|
|
543
499
|
|
|
544
|
-
export
|
|
500
|
+
export type Certificate = {
|
|
545
501
|
data: string;
|
|
546
502
|
fingerprint: string;
|
|
547
503
|
issuer: CertificatePrincipal;
|
|
@@ -552,85 +508,82 @@ declare namespace OpenFin {
|
|
|
552
508
|
subjectName: string;
|
|
553
509
|
validExpiry: number;
|
|
554
510
|
validStart: number;
|
|
555
|
-
}
|
|
511
|
+
};
|
|
556
512
|
|
|
557
|
-
|
|
513
|
+
type CertificatePrincipal = {
|
|
558
514
|
commonName: string;
|
|
559
515
|
country: string;
|
|
560
516
|
locality: string;
|
|
561
517
|
organizations: string[];
|
|
562
518
|
organizationUnits: string[];
|
|
563
519
|
state: string;
|
|
564
|
-
}
|
|
565
|
-
|
|
566
|
-
export type HostContextChangedReasons = import('./src/shapes/Platform').HostContextChangedReasons;
|
|
567
|
-
export type WindowCreationReason = import('./src/shapes/Platform').WindowCreationReason;
|
|
520
|
+
};
|
|
568
521
|
|
|
569
522
|
export type HostContextChangedPayload = {
|
|
570
523
|
context: any;
|
|
571
524
|
reason: HostContextChangedReasons;
|
|
572
525
|
};
|
|
573
526
|
|
|
574
|
-
export
|
|
527
|
+
export type ApplySnapshotOptions = {
|
|
575
528
|
closeExistingWindows?: boolean;
|
|
576
529
|
closeSnapshotWindows?: boolean;
|
|
577
530
|
skipOutOfBoundsCheck?: boolean;
|
|
578
|
-
}
|
|
531
|
+
};
|
|
579
532
|
|
|
580
|
-
export
|
|
533
|
+
export type ApplySnapshotPayload = {
|
|
581
534
|
snapshot: Snapshot;
|
|
582
535
|
options?: ApplySnapshotOptions;
|
|
583
|
-
}
|
|
584
|
-
export
|
|
536
|
+
};
|
|
537
|
+
export type CreateViewPayload = {
|
|
585
538
|
opts: Partial<ViewOptions>;
|
|
586
539
|
target: Identity;
|
|
587
540
|
targetView?: Identity;
|
|
588
|
-
}
|
|
541
|
+
};
|
|
589
542
|
|
|
590
|
-
export
|
|
543
|
+
export type ReplaceViewPayload = {
|
|
591
544
|
opts: {
|
|
592
545
|
viewToReplace: Identity;
|
|
593
546
|
newView: Partial<ViewOptions>;
|
|
594
547
|
};
|
|
595
548
|
target: Identity;
|
|
596
|
-
}
|
|
549
|
+
};
|
|
597
550
|
|
|
598
|
-
export
|
|
551
|
+
export type CloseViewPayload = {
|
|
599
552
|
view: Identity;
|
|
600
|
-
}
|
|
553
|
+
};
|
|
601
554
|
|
|
602
|
-
export
|
|
555
|
+
export type FetchManifestPayload = {
|
|
603
556
|
manifestUrl: string;
|
|
604
|
-
}
|
|
557
|
+
};
|
|
605
558
|
|
|
606
|
-
export
|
|
559
|
+
export type ReplaceLayoutOpts = {
|
|
607
560
|
layout: LayoutOptions;
|
|
608
|
-
}
|
|
609
|
-
export
|
|
561
|
+
};
|
|
562
|
+
export type ReplaceLayoutPayload = {
|
|
610
563
|
opts: ReplaceLayoutOpts;
|
|
611
564
|
target: Identity;
|
|
612
|
-
}
|
|
565
|
+
};
|
|
613
566
|
|
|
614
|
-
export
|
|
567
|
+
export type SetWindowContextPayload = {
|
|
615
568
|
context: any;
|
|
616
569
|
entityType: EntityType;
|
|
617
570
|
target: Identity;
|
|
618
|
-
}
|
|
571
|
+
};
|
|
619
572
|
|
|
620
|
-
export
|
|
573
|
+
export type LaunchIntoPlatformPayload = {
|
|
621
574
|
manifest: any;
|
|
622
|
-
}
|
|
575
|
+
};
|
|
623
576
|
|
|
624
|
-
export
|
|
577
|
+
export type GetWindowContextPayload = {
|
|
625
578
|
entityType: EntityType;
|
|
626
579
|
target: Identity;
|
|
627
|
-
}
|
|
580
|
+
};
|
|
628
581
|
|
|
629
|
-
export
|
|
582
|
+
export type ApplicationPermissions = {
|
|
630
583
|
setFileDownloadLocation: boolean;
|
|
631
|
-
}
|
|
584
|
+
};
|
|
632
585
|
|
|
633
|
-
export
|
|
586
|
+
export type SystemPermissions = {
|
|
634
587
|
getAllExternalWindows: boolean;
|
|
635
588
|
launchExternalProcess: boolean;
|
|
636
589
|
readRegistryValue:
|
|
@@ -644,7 +597,7 @@ declare namespace OpenFin {
|
|
|
644
597
|
enabled: boolean;
|
|
645
598
|
protocols: string[];
|
|
646
599
|
};
|
|
647
|
-
}
|
|
600
|
+
};
|
|
648
601
|
|
|
649
602
|
export type WebPermission =
|
|
650
603
|
| 'audio'
|
|
@@ -658,38 +611,38 @@ declare namespace OpenFin {
|
|
|
658
611
|
| 'clipboard-read'
|
|
659
612
|
| 'clipboard-sanitized-write';
|
|
660
613
|
|
|
661
|
-
export
|
|
614
|
+
export type Permissions = {
|
|
662
615
|
Application?: Partial<ApplicationPermissions>;
|
|
663
616
|
System?: Partial<SystemPermissions>;
|
|
664
617
|
webAPIs?: WebPermission[];
|
|
665
|
-
}
|
|
618
|
+
};
|
|
666
619
|
|
|
667
|
-
export
|
|
620
|
+
export type PlatformWindowCreationOptions = Partial<WindowCreationOptions> & {
|
|
668
621
|
updateStateIfExists?: boolean;
|
|
669
622
|
reason?: WindowCreationReason;
|
|
670
|
-
}
|
|
623
|
+
};
|
|
671
624
|
|
|
672
|
-
export
|
|
625
|
+
export type PlatformWindowOptions = WindowCreationOptions & {
|
|
673
626
|
stylesheetUrl: string;
|
|
674
|
-
}
|
|
627
|
+
};
|
|
675
628
|
|
|
676
|
-
export
|
|
629
|
+
export type PlatformViewCreationOptions = Partial<ViewOptions> & {
|
|
677
630
|
url: string;
|
|
678
631
|
target: Identity;
|
|
679
|
-
}
|
|
632
|
+
};
|
|
680
633
|
|
|
681
634
|
export type ProcessAffinityStrategy = 'same' | 'different';
|
|
682
635
|
|
|
683
|
-
export
|
|
636
|
+
export type PlatformOptions = ApplicationCreationOptions & {
|
|
684
637
|
defaultWindowOptions?: Partial<PlatformWindowOptions>;
|
|
685
638
|
defaultViewOptions?: Partial<PlatformViewCreationOptions>;
|
|
686
639
|
disableDefaultCommands?: boolean;
|
|
687
640
|
viewProcessAffinityStrategy?: ProcessAffinityStrategy;
|
|
688
641
|
providerUrl?: string;
|
|
689
642
|
permissions?: Partial<Permissions>;
|
|
690
|
-
}
|
|
643
|
+
};
|
|
691
644
|
|
|
692
|
-
export
|
|
645
|
+
export type Manifest = {
|
|
693
646
|
appAssets?: {
|
|
694
647
|
alias: string;
|
|
695
648
|
args?: string;
|
|
@@ -743,9 +696,9 @@ declare namespace OpenFin {
|
|
|
743
696
|
forwardErrorReports?: boolean;
|
|
744
697
|
enableErrorReporting?: boolean;
|
|
745
698
|
};
|
|
746
|
-
}
|
|
699
|
+
};
|
|
747
700
|
|
|
748
|
-
export
|
|
701
|
+
export type LayoutOptions = {
|
|
749
702
|
settings: {
|
|
750
703
|
popoutWholeStack?: boolean;
|
|
751
704
|
constrainDragToContainer?: boolean;
|
|
@@ -755,19 +708,19 @@ declare namespace OpenFin {
|
|
|
755
708
|
constrainDragToHeaders?: boolean;
|
|
756
709
|
};
|
|
757
710
|
content: LayoutContent;
|
|
758
|
-
}
|
|
711
|
+
};
|
|
759
712
|
|
|
760
713
|
export type LayoutContent = (LayoutRow | LayoutColumn | LayoutComponent)[];
|
|
761
714
|
|
|
762
|
-
export
|
|
715
|
+
export type LayoutRow = {
|
|
763
716
|
type: 'row';
|
|
764
717
|
content: LayoutContent;
|
|
765
|
-
}
|
|
766
|
-
export
|
|
718
|
+
};
|
|
719
|
+
export type LayoutColumn = {
|
|
767
720
|
type: 'column';
|
|
768
721
|
content: LayoutContent;
|
|
769
|
-
}
|
|
770
|
-
export
|
|
722
|
+
};
|
|
723
|
+
export type LayoutComponent = {
|
|
771
724
|
type: 'component';
|
|
772
725
|
componentName: 'view';
|
|
773
726
|
componentState: {
|
|
@@ -775,7 +728,7 @@ declare namespace OpenFin {
|
|
|
775
728
|
url: string;
|
|
776
729
|
title?: string;
|
|
777
730
|
};
|
|
778
|
-
}
|
|
731
|
+
};
|
|
779
732
|
|
|
780
733
|
export type OverrideCallback<T extends any = PlatformProvider, U extends T = T> = (
|
|
781
734
|
arg: Constructor<T>,
|
|
@@ -784,13 +737,144 @@ declare namespace OpenFin {
|
|
|
784
737
|
|
|
785
738
|
export type Constructor<T = {}> = new (...args: any[]) => T;
|
|
786
739
|
|
|
787
|
-
type
|
|
788
|
-
|
|
740
|
+
export type HostContextChangedReasons = 'updated' | 'reparented';
|
|
741
|
+
|
|
742
|
+
export type WindowCreationReason =
|
|
743
|
+
| 'tearout'
|
|
744
|
+
| 'create-view-without-target'
|
|
745
|
+
| 'api-call'
|
|
746
|
+
| 'app-creation'
|
|
747
|
+
| 'restore';
|
|
748
|
+
|
|
749
|
+
// TODO: Real PlatformProvider type def
|
|
750
|
+
export type PlatformProvider = {
|
|
751
|
+
/**
|
|
752
|
+
* Handles requests to create a window in the current platform.
|
|
753
|
+
* @param { WindowOption } payload Window options for the window to be created.
|
|
754
|
+
* @param { Identity } [identity] If {@link Platform#createWindow Platform.createWindow} was called, the identity of the caller will be here.
|
|
755
|
+
* If `createWindow` was called as part of applying a snapshot or creating a view without a target window, `identity` will be undefined.
|
|
756
|
+
*/
|
|
757
|
+
createWindow(
|
|
758
|
+
options: OpenFin.PlatformWindowCreationOptions,
|
|
759
|
+
identity?: OpenFin.Identity
|
|
760
|
+
): Promise<OpenFin.Window>;
|
|
761
|
+
|
|
762
|
+
/**
|
|
763
|
+
* Gets the current state of windows and their views and returns a snapshot object containing that info.
|
|
764
|
+
* @param { undefined } payload Undefined unless you've defined a custom `getSnapshot` protocol.
|
|
765
|
+
* @param { Identity } identity Identity of the entity that called {@link Platform#getSnapshot Platform.getSnapshot}.
|
|
766
|
+
* @return { Promise<Snapshot> } Snapshot of current platform state.
|
|
767
|
+
*/
|
|
768
|
+
getSnapshot(payload: undefined, identity: OpenFin.Identity): Promise<OpenFin.Snapshot>;
|
|
769
|
+
|
|
770
|
+
/**
|
|
771
|
+
* Called when a snapshot is being applied and some windows in that snapshot would be fully or partially off-screen.
|
|
772
|
+
* Returns an array of windows with modified positions, such that any off-screen windows are positioned in the top left
|
|
773
|
+
* corner of the main monitor.
|
|
774
|
+
* @param { Snapshot } snapshot The snapshot to be applied.
|
|
775
|
+
* @param { WindowOptions[] } outOfBoundsWindows An array of WindowOptions for any windows that would be off-screen.
|
|
776
|
+
* @return { Promise<WindowOptions[]> } An array of WindowOptions with their position modified to fit on screen.
|
|
777
|
+
*/
|
|
778
|
+
positionOutOfBoundsWindows(
|
|
779
|
+
snapshot: OpenFin.Snapshot,
|
|
780
|
+
outOfBoundsWindows: OpenFin.WindowCreationOptions[]
|
|
781
|
+
): Promise<OpenFin.WindowCreationOptions[]>;
|
|
782
|
+
|
|
783
|
+
/**
|
|
784
|
+
* Handles requests to apply a snapshot to the current Platform.
|
|
785
|
+
* @param { ApplySnapshotPayload } payload Payload containing the snapshot to be applied, as well as any options.
|
|
786
|
+
* @param { Identity } [identity] Identity of the entity that called {@link Platform#applySnapshot Platform.applySnapshot}.
|
|
787
|
+
* Undefined if called internally (e.g. when opening the initial snapshot).
|
|
788
|
+
* @return { Promise<void> }
|
|
789
|
+
*/
|
|
790
|
+
applySnapshot(payload: OpenFin.ApplySnapshotPayload, identity?: OpenFin.Identity): Promise<void>;
|
|
791
|
+
|
|
792
|
+
/**
|
|
793
|
+
* Closes the current Platform and all child windows and views.
|
|
794
|
+
* @param { undefined } payload Undefined unless you have implemented a custom quite protocol.
|
|
795
|
+
* @param { Identity } identity Identity of the entity that called {@link Platform#quit Platform.quit}.
|
|
796
|
+
* @return { Promise<void> }
|
|
797
|
+
*/
|
|
798
|
+
quit(payload: undefined, identity: OpenFin.Identity): Promise<void>;
|
|
799
|
+
|
|
800
|
+
/**
|
|
801
|
+
* Closes a view
|
|
802
|
+
* @param { CloseViewPayload } payload Specifies the `target` view to be closed.
|
|
803
|
+
* @param { Identity } identity Identity of the entity that called {@link Platform#closeView Platform.closeView}.
|
|
804
|
+
*/
|
|
805
|
+
closeView(payload: OpenFin.CloseViewPayload, identity?: OpenFin.Identity): Promise<any>;
|
|
806
|
+
|
|
807
|
+
/**
|
|
808
|
+
* Creates a new view and attaches it to a specified target window.
|
|
809
|
+
* @param { CreateViewPayload } payload Creation options for the new view.
|
|
810
|
+
* @param { Identity } identity Identity of the entity that called {@link Platform#createView Platform.createView}.
|
|
811
|
+
* @return { Promise<void> }
|
|
812
|
+
*/
|
|
813
|
+
createView(payload: OpenFin.CreateViewPayload, identity: OpenFin.Identity): Promise<OpenFin.View>;
|
|
814
|
+
|
|
815
|
+
/** Handles requests to fetch manifests in the current platform.
|
|
816
|
+
* @param { FetchManifestPayload } payload Payload containing the manifestUrl to be fetched.
|
|
817
|
+
* @param { Identity } callerIdentity If {@link Platform#fetchManifest Platform.fetchManifest}
|
|
818
|
+
* was called, the identity of the caller will be here.
|
|
819
|
+
* If `fetchManifest` was called internally, `callerIdentity` will be the provider's identity.
|
|
820
|
+
*/
|
|
821
|
+
fetchManifest(payload: OpenFin.FetchManifestPayload, callerIdentity: OpenFin.Identity): Promise<any>;
|
|
822
|
+
|
|
823
|
+
/**
|
|
824
|
+
* Replaces a Platform window's layout with a new layout. Any views that were in the old layout but not the new layout will be destroyed.
|
|
825
|
+
* @param { ReplaceLayoutPayload } payload Contains the `target` window and an `opts` object with a `layout` property to apply.
|
|
826
|
+
* @param { Identity } [identity] Identity of the entity that called {@link Platform#replaceLayout Platform.replaceLayout}.
|
|
827
|
+
* Undefined if `replaceLayout` is called internally (e.g. while applying a snapshot).
|
|
828
|
+
* @return { Promise<void> }
|
|
829
|
+
*/
|
|
830
|
+
replaceLayout(payload: OpenFin.ReplaceLayoutPayload, identity?: OpenFin.Identity): Promise<void>;
|
|
831
|
+
|
|
832
|
+
replaceView(payload: OpenFin.ReplaceViewPayload, identity?: OpenFin.Identity): Promise<void>;
|
|
833
|
+
|
|
834
|
+
launchIntoPlatform(payload: OpenFin.LaunchIntoPlatformPayload): Promise<void>;
|
|
835
|
+
|
|
836
|
+
/**
|
|
837
|
+
* Handles requests to set a window's context. `target` may be a window or a view.
|
|
838
|
+
* If it is a window, that window's `customContext` will be updated.
|
|
839
|
+
* If it is a view, the `customContext` of that view's current host window will be updated.
|
|
840
|
+
* @param { SetWindowContextPayload } payload Object containing the requested `context` update,
|
|
841
|
+
* the `target`'s identity, and the target's `entityType`.
|
|
842
|
+
* @param { Identity } [identity] Identity of the entity that called {@link Platform#setWindowContext Platform.setWindowContext}.
|
|
843
|
+
* Undefined if `setWindowContext` is called internally (e.g. while applying a snapshot).
|
|
844
|
+
* @return { Promise<any> } The new context.
|
|
845
|
+
*/
|
|
846
|
+
setWindowContext(payload: OpenFin.SetWindowContextPayload, identity?: OpenFin.Identity): Promise<any>;
|
|
847
|
+
|
|
848
|
+
/**
|
|
849
|
+
* Handles requests to get a window's context. `target` may be a window or a view.
|
|
850
|
+
* If it is a window, that window's `customContext` will be returned.
|
|
851
|
+
* If it is a view, the `customContext` of that view's current host window will be returned.
|
|
852
|
+
* @param { GetWindowContextPayload } payload Object containing the requested `context` update,
|
|
853
|
+
* the `target`'s identity, and the target's `entityType`.
|
|
854
|
+
* @param { Identity } [identity] Identity of the entity that called {@link Platform#getWindowContext Platform.getWindowContext}.
|
|
855
|
+
* Undefined when `getWindowContext` is called internally
|
|
856
|
+
* (e.g. when getting a window's context for the purpose of raising a "host-context-changed" event on a reparented view).
|
|
857
|
+
* @return { Promise<any> } The new context.
|
|
858
|
+
*/
|
|
859
|
+
getWindowContext(payload: OpenFin.GetWindowContextPayload, identity?: OpenFin.Identity): Promise<any>;
|
|
860
|
+
|
|
861
|
+
/**
|
|
862
|
+
* Called when a window's `customContext` is updated. Responsible for raising the `host-context-updated` event on that window's child views.
|
|
863
|
+
* @param { WindowOptionsChangedEvent<'window', 'options-changed'> } payload The event payload for the window whose context has changed.
|
|
864
|
+
* The new context will be contained as `payload.diff.customContext.newVal`.
|
|
865
|
+
* @return { Promise<HostContextChangedPayload> } The event that it raised.
|
|
866
|
+
*/
|
|
867
|
+
onWindowContextUpdated(
|
|
868
|
+
payload: WindowOptionsChangedEvent<'window', 'options-changed'>
|
|
869
|
+
): Promise<OpenFin.HostContextChangedPayload | undefined>;
|
|
870
|
+
};
|
|
871
|
+
|
|
872
|
+
export type InitPlatformOptions = {
|
|
789
873
|
overrideCallback?: OverrideCallback<PlatformProvider>;
|
|
790
874
|
interopOverride?: OverrideCallback<InteropBroker>;
|
|
791
|
-
}
|
|
875
|
+
};
|
|
792
876
|
|
|
793
|
-
export
|
|
877
|
+
export type ProcessDetails = {
|
|
794
878
|
cpuUsage: number;
|
|
795
879
|
nonPagedPoolUsage: number;
|
|
796
880
|
pageFaultCount: number;
|
|
@@ -803,80 +887,80 @@ declare namespace OpenFin {
|
|
|
803
887
|
workingSetSize: number;
|
|
804
888
|
privateSetSize: number;
|
|
805
889
|
pid: number;
|
|
806
|
-
}
|
|
890
|
+
};
|
|
807
891
|
|
|
808
|
-
export
|
|
892
|
+
export type FrameProcessDetails = ProcessDetails & {
|
|
809
893
|
url: string;
|
|
810
894
|
entityType: string;
|
|
811
|
-
}
|
|
895
|
+
};
|
|
812
896
|
|
|
813
|
-
export
|
|
897
|
+
export type EntityProcessDetails = FrameProcessDetails & {
|
|
814
898
|
name: string;
|
|
815
899
|
uuid: string;
|
|
816
900
|
iframes: FrameProcessDetails[];
|
|
817
|
-
}
|
|
901
|
+
};
|
|
818
902
|
|
|
819
|
-
export
|
|
903
|
+
export type AppProcessInfo = {
|
|
820
904
|
uuid: string;
|
|
821
905
|
entities: EntityProcessDetails[];
|
|
822
|
-
}
|
|
906
|
+
};
|
|
823
907
|
|
|
824
|
-
export
|
|
908
|
+
export type NonAppProcessDetails = ProcessDetails & {
|
|
825
909
|
name: string;
|
|
826
|
-
}
|
|
910
|
+
};
|
|
827
911
|
|
|
828
|
-
export
|
|
912
|
+
export type SystemProcessInfo = {
|
|
829
913
|
apps: AppProcessInfo[];
|
|
830
914
|
browserProcess: NonAppProcessDetails;
|
|
831
915
|
nonApps: NonAppProcessDetails[];
|
|
832
|
-
}
|
|
916
|
+
};
|
|
833
917
|
|
|
834
|
-
export
|
|
918
|
+
export type ClearCacheOption = {
|
|
835
919
|
appcache?: boolean;
|
|
836
920
|
cache?: boolean;
|
|
837
921
|
cookies?: boolean;
|
|
838
922
|
localStorage?: boolean;
|
|
839
|
-
}
|
|
923
|
+
};
|
|
840
924
|
|
|
841
|
-
export
|
|
925
|
+
export type CookieInfo = {
|
|
842
926
|
name: string;
|
|
843
927
|
// expirationDate: Date;
|
|
844
928
|
domain: string;
|
|
845
929
|
path: string;
|
|
846
|
-
}
|
|
930
|
+
};
|
|
847
931
|
|
|
848
|
-
export
|
|
932
|
+
export type CookieOption = {
|
|
849
933
|
name: string;
|
|
850
|
-
}
|
|
934
|
+
};
|
|
851
935
|
|
|
852
|
-
export
|
|
936
|
+
export type CrashReporterOptions = {
|
|
853
937
|
diagnosticsMode: boolean;
|
|
854
|
-
}
|
|
938
|
+
};
|
|
855
939
|
|
|
856
|
-
export
|
|
940
|
+
export type CrashReporterState = CrashReporterOptions & {
|
|
857
941
|
isRunning: boolean;
|
|
858
942
|
diagnosticMode: boolean;
|
|
859
|
-
}
|
|
943
|
+
};
|
|
860
944
|
|
|
861
|
-
export
|
|
945
|
+
export type Time = {
|
|
862
946
|
user: number;
|
|
863
947
|
nice: number;
|
|
864
948
|
sys: number;
|
|
865
949
|
idle: number;
|
|
866
950
|
irq: number;
|
|
867
|
-
}
|
|
951
|
+
};
|
|
868
952
|
|
|
869
|
-
export
|
|
953
|
+
export type CpuInfo = {
|
|
870
954
|
model: string;
|
|
871
955
|
speed: number;
|
|
872
956
|
times: Time;
|
|
873
|
-
}
|
|
957
|
+
};
|
|
874
958
|
|
|
875
|
-
export
|
|
959
|
+
export type GpuInfo = {
|
|
876
960
|
name: string;
|
|
877
|
-
}
|
|
961
|
+
};
|
|
878
962
|
|
|
879
|
-
export
|
|
963
|
+
export type HostSpecs = {
|
|
880
964
|
aeroGlassEnabled?: boolean;
|
|
881
965
|
arch: string;
|
|
882
966
|
cpus: CpuInfo[];
|
|
@@ -884,29 +968,29 @@ declare namespace OpenFin {
|
|
|
884
968
|
memory: number;
|
|
885
969
|
name: string;
|
|
886
970
|
screenSaver?: boolean;
|
|
887
|
-
}
|
|
971
|
+
};
|
|
888
972
|
|
|
889
|
-
export
|
|
973
|
+
export type PrinterInfo = {
|
|
890
974
|
name: string;
|
|
891
975
|
description: string;
|
|
892
976
|
status: number;
|
|
893
977
|
isDefault: boolean;
|
|
894
|
-
}
|
|
978
|
+
};
|
|
895
979
|
|
|
896
|
-
export
|
|
980
|
+
export type Dpi = {
|
|
897
981
|
horizontal?: number;
|
|
898
982
|
vertical?: number;
|
|
899
|
-
}
|
|
983
|
+
};
|
|
900
984
|
|
|
901
|
-
export
|
|
985
|
+
export type Margins = {
|
|
902
986
|
marginType?: 'default' | 'none' | 'printableArea' | 'custom';
|
|
903
987
|
top?: number;
|
|
904
988
|
bottom?: number;
|
|
905
989
|
left?: number;
|
|
906
990
|
right?: number;
|
|
907
|
-
}
|
|
991
|
+
};
|
|
908
992
|
|
|
909
|
-
export
|
|
993
|
+
export type PrintOptions = {
|
|
910
994
|
silent?: boolean;
|
|
911
995
|
printBackground?: boolean;
|
|
912
996
|
deviceName?: string;
|
|
@@ -920,103 +1004,103 @@ declare namespace OpenFin {
|
|
|
920
1004
|
pageRanges?: Record<string, number>;
|
|
921
1005
|
duplexMode?: 'simplex' | 'shortEdge' | 'longEdge';
|
|
922
1006
|
dpi?: Dpi;
|
|
923
|
-
}
|
|
924
|
-
export
|
|
1007
|
+
};
|
|
1008
|
+
export type WriteRequestType = {
|
|
925
1009
|
data: string;
|
|
926
1010
|
type?: string;
|
|
927
|
-
}
|
|
1011
|
+
};
|
|
928
1012
|
|
|
929
|
-
export
|
|
1013
|
+
export type WriteAnyRequestType = {
|
|
930
1014
|
data: {
|
|
931
1015
|
text?: string;
|
|
932
1016
|
html?: string;
|
|
933
1017
|
rtf?: string;
|
|
934
1018
|
};
|
|
935
1019
|
type?: string;
|
|
936
|
-
}
|
|
1020
|
+
};
|
|
937
1021
|
|
|
938
|
-
export
|
|
1022
|
+
export type SubscriptionOptions = {
|
|
939
1023
|
timestamp?: number;
|
|
940
|
-
}
|
|
1024
|
+
};
|
|
941
1025
|
|
|
942
|
-
export
|
|
1026
|
+
export type SharedWorkerInfo = {
|
|
943
1027
|
id: string;
|
|
944
1028
|
url: string;
|
|
945
|
-
}
|
|
1029
|
+
};
|
|
946
1030
|
|
|
947
|
-
export
|
|
1031
|
+
export type ServiceIdentifier = {
|
|
948
1032
|
name: string;
|
|
949
|
-
}
|
|
1033
|
+
};
|
|
950
1034
|
|
|
951
|
-
export
|
|
1035
|
+
export type ServiceConfiguration = {
|
|
952
1036
|
config: object;
|
|
953
1037
|
name: string;
|
|
954
|
-
}
|
|
1038
|
+
};
|
|
955
1039
|
|
|
956
|
-
export
|
|
1040
|
+
export type RVMInfo = {
|
|
957
1041
|
'action': string;
|
|
958
1042
|
'appLogDirectory': string;
|
|
959
1043
|
'path': string;
|
|
960
1044
|
'start-time': string;
|
|
961
1045
|
'version': string;
|
|
962
1046
|
'working-dir': string;
|
|
963
|
-
}
|
|
1047
|
+
};
|
|
964
1048
|
|
|
965
|
-
export
|
|
1049
|
+
export type RvmLaunchOptions = {
|
|
966
1050
|
noUi?: boolean;
|
|
967
1051
|
userAppConfigArgs?: object;
|
|
968
|
-
}
|
|
1052
|
+
};
|
|
969
1053
|
|
|
970
|
-
export
|
|
1054
|
+
export type ShortCutConfig = {
|
|
971
1055
|
desktop?: boolean;
|
|
972
1056
|
startMenu?: boolean;
|
|
973
1057
|
systemStartup?: boolean;
|
|
974
|
-
}
|
|
1058
|
+
};
|
|
975
1059
|
|
|
976
|
-
export
|
|
1060
|
+
export type TerminateExternalRequestType = {
|
|
977
1061
|
uuid: string;
|
|
978
1062
|
timeout: number;
|
|
979
1063
|
killTree: boolean;
|
|
980
|
-
}
|
|
1064
|
+
};
|
|
981
1065
|
|
|
982
|
-
export
|
|
1066
|
+
export type TrayInfo = {
|
|
983
1067
|
bounds: OpenFin.Rectangle;
|
|
984
1068
|
monitorInfo: OpenFin.MonitorInfo;
|
|
985
1069
|
x: number;
|
|
986
1070
|
y: number;
|
|
987
|
-
}
|
|
1071
|
+
};
|
|
988
1072
|
|
|
989
|
-
export
|
|
1073
|
+
export type Transition = {
|
|
990
1074
|
opacity?: Opacity;
|
|
991
1075
|
position?: Position;
|
|
992
1076
|
size?: Size;
|
|
993
|
-
}
|
|
1077
|
+
};
|
|
994
1078
|
|
|
995
|
-
export
|
|
1079
|
+
export type Size = TransitionBase & {
|
|
996
1080
|
width: number;
|
|
997
1081
|
height: number;
|
|
998
|
-
}
|
|
1082
|
+
};
|
|
999
1083
|
|
|
1000
|
-
export
|
|
1084
|
+
export type Opacity = TransitionBase & {
|
|
1001
1085
|
opacity: number;
|
|
1002
|
-
}
|
|
1086
|
+
};
|
|
1003
1087
|
|
|
1004
|
-
export
|
|
1088
|
+
export type TransitionBase = {
|
|
1005
1089
|
duration: number;
|
|
1006
1090
|
relative?: boolean;
|
|
1007
|
-
}
|
|
1091
|
+
};
|
|
1008
1092
|
|
|
1009
|
-
export
|
|
1093
|
+
export type Position = TransitionBase & {
|
|
1010
1094
|
left: number;
|
|
1011
1095
|
top: number;
|
|
1012
|
-
}
|
|
1096
|
+
};
|
|
1013
1097
|
|
|
1014
1098
|
export type AnchorType = 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
|
1015
1099
|
|
|
1016
|
-
export
|
|
1100
|
+
export type TransitionOptions = {
|
|
1017
1101
|
interrupt: boolean;
|
|
1018
1102
|
tween?: tween;
|
|
1019
|
-
}
|
|
1103
|
+
};
|
|
1020
1104
|
|
|
1021
1105
|
type tween =
|
|
1022
1106
|
| 'linear'
|
|
@@ -1037,31 +1121,31 @@ declare namespace OpenFin {
|
|
|
1037
1121
|
| 'ease-out-elastic'
|
|
1038
1122
|
| 'ease-in-out-elastic';
|
|
1039
1123
|
|
|
1040
|
-
export
|
|
1124
|
+
export type FindInPageOptions = {
|
|
1041
1125
|
forward?: boolean;
|
|
1042
1126
|
findNext?: boolean;
|
|
1043
1127
|
matchCase?: boolean;
|
|
1044
1128
|
wordStart?: boolean;
|
|
1045
1129
|
medialCapitalAsWordStart?: boolean;
|
|
1046
|
-
}
|
|
1130
|
+
};
|
|
1047
1131
|
|
|
1048
|
-
export
|
|
1132
|
+
export type FrameInfo = {
|
|
1049
1133
|
name: string;
|
|
1050
1134
|
uuid: string;
|
|
1051
1135
|
entityType: EntityType;
|
|
1052
1136
|
parent: Identity;
|
|
1053
|
-
}
|
|
1137
|
+
};
|
|
1054
1138
|
|
|
1055
|
-
export
|
|
1139
|
+
export type ExternalApplicationInfo = {
|
|
1056
1140
|
parent: Identity;
|
|
1057
|
-
}
|
|
1141
|
+
};
|
|
1058
1142
|
|
|
1059
|
-
export
|
|
1143
|
+
export type ExternalConnection = {
|
|
1060
1144
|
token: string;
|
|
1061
1145
|
uuid: string;
|
|
1062
|
-
}
|
|
1146
|
+
};
|
|
1063
1147
|
|
|
1064
|
-
export
|
|
1148
|
+
export type ExternalProcessRequestType = {
|
|
1065
1149
|
path?: string;
|
|
1066
1150
|
alias?: string;
|
|
1067
1151
|
arguments?: string;
|
|
@@ -1071,114 +1155,111 @@ declare namespace OpenFin {
|
|
|
1071
1155
|
uuid?: string;
|
|
1072
1156
|
initialWindowState?: string;
|
|
1073
1157
|
cwd?: string;
|
|
1074
|
-
}
|
|
1158
|
+
};
|
|
1075
1159
|
|
|
1076
|
-
export
|
|
1160
|
+
export type CertificationInfo = {
|
|
1077
1161
|
serial?: string;
|
|
1078
1162
|
subject?: string;
|
|
1079
1163
|
publickey?: string;
|
|
1080
1164
|
thumbprint?: string;
|
|
1081
1165
|
trusted?: boolean;
|
|
1082
|
-
}
|
|
1166
|
+
};
|
|
1083
1167
|
|
|
1084
|
-
export
|
|
1168
|
+
export type ExitCode = {
|
|
1085
1169
|
topic: string;
|
|
1086
1170
|
uuid: string;
|
|
1087
1171
|
exitCode: number;
|
|
1088
|
-
}
|
|
1172
|
+
};
|
|
1089
1173
|
|
|
1090
|
-
export
|
|
1174
|
+
export type LaunchExternalProcessListener = {
|
|
1091
1175
|
(code: ExitCode): void;
|
|
1092
|
-
}
|
|
1176
|
+
};
|
|
1093
1177
|
|
|
1094
|
-
export
|
|
1178
|
+
export type ExternalProcessInfo = {
|
|
1095
1179
|
pid: number;
|
|
1096
1180
|
listener?: LaunchExternalProcessListener;
|
|
1097
|
-
}
|
|
1181
|
+
};
|
|
1098
1182
|
|
|
1099
|
-
export
|
|
1183
|
+
export type AppAssetInfo = {
|
|
1100
1184
|
src: string;
|
|
1101
1185
|
alias: string;
|
|
1102
1186
|
version: string;
|
|
1103
1187
|
target?: string;
|
|
1104
1188
|
args?: string;
|
|
1105
1189
|
mandatory?: boolean;
|
|
1106
|
-
}
|
|
1190
|
+
};
|
|
1107
1191
|
|
|
1108
|
-
export
|
|
1192
|
+
export type RuntimeDownloadOptions = {
|
|
1109
1193
|
version: string;
|
|
1110
|
-
}
|
|
1194
|
+
};
|
|
1111
1195
|
|
|
1112
|
-
export
|
|
1196
|
+
export type AppAssetRequest = {
|
|
1113
1197
|
alias: string;
|
|
1114
|
-
}
|
|
1198
|
+
};
|
|
1115
1199
|
|
|
1116
|
-
export
|
|
1200
|
+
export type RuntimeDownloadProgress = {
|
|
1117
1201
|
downloadedBytes: number;
|
|
1118
1202
|
totalBytes: number;
|
|
1119
|
-
}
|
|
1203
|
+
};
|
|
1120
1204
|
|
|
1121
|
-
export
|
|
1205
|
+
export type CertifiedAppInfo = {
|
|
1122
1206
|
isRunning: boolean;
|
|
1123
1207
|
isOptedIntoCertfiedApp?: boolean;
|
|
1124
1208
|
isCertified?: boolean;
|
|
1125
1209
|
isSSLCertified?: boolean;
|
|
1126
1210
|
isPresentInAppDirectory?: boolean;
|
|
1127
|
-
}
|
|
1128
|
-
export
|
|
1211
|
+
};
|
|
1212
|
+
export type JumpListCategory = {
|
|
1129
1213
|
name?: string;
|
|
1130
1214
|
items: Array<JumpListTask | JumpListSeparator>;
|
|
1131
|
-
}
|
|
1215
|
+
};
|
|
1132
1216
|
|
|
1133
1217
|
export type JumpListItem = JumpListTask | JumpListSeparator;
|
|
1134
1218
|
|
|
1135
|
-
export
|
|
1219
|
+
export type JumpListTask = {
|
|
1136
1220
|
type: 'task';
|
|
1137
1221
|
title: string;
|
|
1138
1222
|
description: string;
|
|
1139
1223
|
deepLink: string;
|
|
1140
1224
|
iconPath?: string;
|
|
1141
1225
|
iconIndex?: number;
|
|
1142
|
-
}
|
|
1226
|
+
};
|
|
1143
1227
|
|
|
1144
|
-
export
|
|
1228
|
+
export type JumpListSeparator = {
|
|
1145
1229
|
type: 'separator';
|
|
1146
|
-
}
|
|
1147
|
-
|
|
1230
|
+
};
|
|
1231
|
+
|
|
1232
|
+
export type ApplicationInfo = {
|
|
1148
1233
|
initialOptions: OpenFin.ApplicationCreationOptions;
|
|
1149
1234
|
launchMode: string;
|
|
1150
1235
|
manifest: OpenFin.Manifest & { [key: string]: any };
|
|
1151
1236
|
manifestUrl: string;
|
|
1152
1237
|
parentUuid?: string;
|
|
1153
1238
|
runtime: { version: string };
|
|
1154
|
-
}
|
|
1155
|
-
|
|
1156
|
-
export interface LogInfo {
|
|
1157
|
-
logId: string;
|
|
1158
|
-
}
|
|
1239
|
+
};
|
|
1159
1240
|
|
|
1160
|
-
export
|
|
1241
|
+
export type ManifestInfo = {
|
|
1161
1242
|
uuid: string;
|
|
1162
1243
|
manifestUrl: string;
|
|
1163
|
-
}
|
|
1244
|
+
};
|
|
1164
1245
|
|
|
1165
|
-
export
|
|
1246
|
+
export type ClickedMenuResult = {
|
|
1166
1247
|
result: 'clicked';
|
|
1167
1248
|
data: any;
|
|
1168
|
-
}
|
|
1249
|
+
};
|
|
1169
1250
|
|
|
1170
|
-
export
|
|
1251
|
+
export type ClosedMenuResult = {
|
|
1171
1252
|
result: 'closed';
|
|
1172
|
-
}
|
|
1253
|
+
};
|
|
1173
1254
|
|
|
1174
1255
|
export type MenuResult = ClickedMenuResult | ClosedMenuResult;
|
|
1175
1256
|
|
|
1176
|
-
export
|
|
1257
|
+
export type ShowPopupMenuOptions = {
|
|
1177
1258
|
template: MenuItemTemplate[];
|
|
1178
1259
|
x?: number;
|
|
1179
1260
|
y?: number;
|
|
1180
|
-
}
|
|
1181
|
-
export
|
|
1261
|
+
};
|
|
1262
|
+
export type MenuItemTemplate = {
|
|
1182
1263
|
/**
|
|
1183
1264
|
* Can be `normal`, `separator`, `submenu`, or `checkbox`.
|
|
1184
1265
|
* Defaults to 'normal' unless a 'submenu' key exists
|
|
@@ -1214,13 +1295,13 @@ declare namespace OpenFin {
|
|
|
1214
1295
|
* Image Data URI with image dimensions inferred from the encoded string
|
|
1215
1296
|
*/
|
|
1216
1297
|
icon?: string;
|
|
1217
|
-
}
|
|
1298
|
+
};
|
|
1218
1299
|
|
|
1219
|
-
export
|
|
1300
|
+
export type NativeWindowIntegrationProviderAuthorization = {
|
|
1220
1301
|
authorizedUuid: string;
|
|
1221
|
-
}
|
|
1302
|
+
};
|
|
1222
1303
|
|
|
1223
|
-
export
|
|
1304
|
+
export type RuntimeInfo = {
|
|
1224
1305
|
architecture: string;
|
|
1225
1306
|
manifestUrl: string;
|
|
1226
1307
|
port: number;
|
|
@@ -1230,75 +1311,74 @@ declare namespace OpenFin {
|
|
|
1230
1311
|
chromeVersion: string;
|
|
1231
1312
|
electronVersion: string;
|
|
1232
1313
|
devtoolsPort?: number;
|
|
1233
|
-
}
|
|
1314
|
+
};
|
|
1234
1315
|
|
|
1235
|
-
export
|
|
1316
|
+
export type DefaultDomainSettings = {
|
|
1236
1317
|
rules: DefaultDomainSettingsRule[];
|
|
1237
|
-
}
|
|
1318
|
+
};
|
|
1238
1319
|
|
|
1239
|
-
export
|
|
1320
|
+
export type DefaultDomainSettingsRule = {
|
|
1240
1321
|
// match pattern is a domain based string type
|
|
1241
1322
|
match: string[];
|
|
1242
1323
|
options: {
|
|
1243
1324
|
downloadSettings: FileDownloadSettings;
|
|
1244
1325
|
};
|
|
1245
|
-
}
|
|
1326
|
+
};
|
|
1246
1327
|
|
|
1247
1328
|
export type FileDownloadBehaviorNames = 'prompt' | 'no-prompt' | 'block';
|
|
1248
1329
|
|
|
1249
|
-
export
|
|
1330
|
+
export type FileDownloadSettings = {
|
|
1250
1331
|
rules: DownloadRule[];
|
|
1251
|
-
}
|
|
1332
|
+
};
|
|
1252
1333
|
|
|
1253
|
-
export
|
|
1334
|
+
export type DownloadRule = {
|
|
1254
1335
|
behavior: FileDownloadBehaviorNames;
|
|
1255
1336
|
// match pattern is a string type
|
|
1256
1337
|
match: string[];
|
|
1257
|
-
}
|
|
1258
|
-
export
|
|
1338
|
+
};
|
|
1339
|
+
export type ContextSubscription = {
|
|
1259
1340
|
handler: ContextHandler;
|
|
1260
1341
|
contextType?: string;
|
|
1261
|
-
}
|
|
1342
|
+
};
|
|
1262
1343
|
|
|
1263
1344
|
export type ContextHandler = (context: OpenFin.Context) => void;
|
|
1264
1345
|
|
|
1265
|
-
export
|
|
1346
|
+
export type Intent<MetadataType = IntentMetadata> = {
|
|
1266
1347
|
name: string;
|
|
1267
1348
|
context: Context;
|
|
1268
1349
|
metadata?: MetadataType;
|
|
1269
|
-
}
|
|
1350
|
+
};
|
|
1270
1351
|
|
|
1271
|
-
export
|
|
1352
|
+
export type IntentMetadata<TargetType = any> = {
|
|
1272
1353
|
target?: TargetType;
|
|
1273
|
-
}
|
|
1354
|
+
};
|
|
1274
1355
|
|
|
1275
1356
|
export type IntentHandler = (intent: OpenFin.Intent) => void;
|
|
1276
1357
|
type MatchPattern = string;
|
|
1277
1358
|
|
|
1278
1359
|
export type ContentCreationBehaviorNames = 'window' | 'view' | 'block' | 'browser';
|
|
1279
|
-
export
|
|
1360
|
+
export type ContentCreationRule<T = ContentCreationBehaviorNames> = {
|
|
1280
1361
|
behavior: T;
|
|
1281
1362
|
match: MatchPattern[];
|
|
1282
1363
|
options?: T extends 'window' ? Partial<WindowOptions> : T extends 'view' ? Partial<OpenFin.ViewOptions> : never;
|
|
1283
|
-
}
|
|
1364
|
+
};
|
|
1284
1365
|
|
|
1285
|
-
export
|
|
1366
|
+
export type ContentCreationOptions = {
|
|
1286
1367
|
rules: ContentCreationRule[];
|
|
1287
|
-
}
|
|
1288
|
-
export
|
|
1368
|
+
};
|
|
1369
|
+
export type SnapshotProvider<T> = {
|
|
1289
1370
|
getSnapshot: () => Promise<T>;
|
|
1290
1371
|
applySnapshot: (snapshot: T) => Promise<void>;
|
|
1291
|
-
}
|
|
1372
|
+
};
|
|
1292
1373
|
|
|
1293
|
-
export type
|
|
1294
|
-
export interface QueryPermissionResult {
|
|
1374
|
+
export type QueryPermissionResult = {
|
|
1295
1375
|
permission: string;
|
|
1296
1376
|
state: PermissionState;
|
|
1297
1377
|
granted: boolean;
|
|
1298
1378
|
rawValue?: unknown;
|
|
1299
|
-
}
|
|
1379
|
+
};
|
|
1300
1380
|
|
|
1301
|
-
export
|
|
1381
|
+
export type SessionContextGroup = {
|
|
1302
1382
|
id: string;
|
|
1303
1383
|
setContext: (context: OpenFin.Context) => Promise<void>;
|
|
1304
1384
|
getCurrentContext: (type?: string) => Promise<OpenFin.Context>;
|
|
@@ -1306,35 +1386,960 @@ declare namespace OpenFin {
|
|
|
1306
1386
|
handler: OpenFin.ContextHandler,
|
|
1307
1387
|
contextType?: string
|
|
1308
1388
|
) => Promise<{ unsubscribe: () => void }>;
|
|
1309
|
-
}
|
|
1389
|
+
};
|
|
1310
1390
|
|
|
1311
1391
|
export type MessagingProtocols = import('./src/api/interappbus/channel/protocols/index').MessagingProtocols;
|
|
1312
1392
|
|
|
1313
|
-
export
|
|
1393
|
+
export type ChannelCreateOptions = {
|
|
1314
1394
|
protocols?: MessagingProtocols[];
|
|
1315
|
-
}
|
|
1395
|
+
};
|
|
1316
1396
|
|
|
1317
|
-
export
|
|
1397
|
+
export type ChannelConnectOptions = ChannelCreateOptions & {
|
|
1318
1398
|
wait?: boolean;
|
|
1319
1399
|
payload?: any;
|
|
1320
|
-
}
|
|
1400
|
+
};
|
|
1321
1401
|
|
|
1322
|
-
export
|
|
1402
|
+
export type ContextForIntent<MetadataType = any> = Context & {
|
|
1323
1403
|
metadata?: MetadataType;
|
|
1324
|
-
}
|
|
1404
|
+
};
|
|
1325
1405
|
|
|
1326
|
-
export
|
|
1406
|
+
export type InfoForIntentOptions = {
|
|
1327
1407
|
name: string;
|
|
1328
1408
|
context?: OpenFin.Context;
|
|
1329
|
-
}
|
|
1409
|
+
};
|
|
1330
1410
|
|
|
1331
|
-
export
|
|
1411
|
+
export type ProviderIdentity = Identity & {
|
|
1332
1412
|
channelId: string;
|
|
1333
1413
|
channelName: string;
|
|
1334
|
-
}
|
|
1414
|
+
};
|
|
1335
1415
|
|
|
1336
|
-
export
|
|
1416
|
+
export type RegisterUsageData = {
|
|
1337
1417
|
data: unknown;
|
|
1338
1418
|
type: string;
|
|
1339
|
-
}
|
|
1419
|
+
};
|
|
1420
|
+
|
|
1421
|
+
export type ProxyInfo = {
|
|
1422
|
+
config: ProxyConfig;
|
|
1423
|
+
system: ProxySystemInfo;
|
|
1424
|
+
};
|
|
1425
|
+
|
|
1426
|
+
export type ProxyConfig = {
|
|
1427
|
+
proxyAddress: string;
|
|
1428
|
+
proxyPort: number;
|
|
1429
|
+
type: string;
|
|
1430
|
+
};
|
|
1431
|
+
|
|
1432
|
+
export type ProxySystemInfo = {
|
|
1433
|
+
autoConfigUrl: string;
|
|
1434
|
+
bypass: string;
|
|
1435
|
+
enabled: boolean;
|
|
1436
|
+
proxy: string;
|
|
1437
|
+
};
|
|
1438
|
+
|
|
1439
|
+
export type BaseEvent<Topic, Type> = {
|
|
1440
|
+
topic: Topic;
|
|
1441
|
+
type: Type;
|
|
1442
|
+
};
|
|
1443
|
+
|
|
1444
|
+
export type ApplicationEvent<Topic, Type> = BaseEvent<Topic, Type> & {
|
|
1445
|
+
uuid: string;
|
|
1446
|
+
};
|
|
1447
|
+
|
|
1448
|
+
export type WindowEvent<Topic, Type> = ApplicationEvent<Topic, Type> & {
|
|
1449
|
+
name: string;
|
|
1450
|
+
};
|
|
1451
|
+
|
|
1452
|
+
export type BaseEventMap = {
|
|
1453
|
+
[name: string]: any;
|
|
1454
|
+
newListener: string;
|
|
1455
|
+
listenerRemoved: string;
|
|
1456
|
+
};
|
|
1457
|
+
|
|
1458
|
+
export type WindowResourceLoadFailedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1459
|
+
errorCode: number;
|
|
1460
|
+
errorDescription: string;
|
|
1461
|
+
validatedURL: string;
|
|
1462
|
+
isMainFrame: boolean;
|
|
1463
|
+
};
|
|
1464
|
+
|
|
1465
|
+
export type WindowResourceResponseReceivedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1466
|
+
status: boolean;
|
|
1467
|
+
newUrl: string;
|
|
1468
|
+
originalUrl: string;
|
|
1469
|
+
httpResponseCode: number;
|
|
1470
|
+
requestMethod: string;
|
|
1471
|
+
referrer: string;
|
|
1472
|
+
headers: any;
|
|
1473
|
+
resourceType: 'mainFrame' | 'subFrame' | 'styleSheet' | 'script' | 'image' | 'object' | 'xhr' | 'other';
|
|
1474
|
+
};
|
|
1475
|
+
|
|
1476
|
+
export type PageTitleUpdatedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1477
|
+
title: string;
|
|
1478
|
+
};
|
|
1479
|
+
|
|
1480
|
+
export type CertificateErrorEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1481
|
+
error: string;
|
|
1482
|
+
url: string;
|
|
1483
|
+
certificate: OpenFin.Certificate;
|
|
1484
|
+
};
|
|
1485
|
+
|
|
1486
|
+
export type CertificateSelectionShownEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1487
|
+
url: string;
|
|
1488
|
+
certificates: OpenFin.Certificate[];
|
|
1489
|
+
};
|
|
1490
|
+
|
|
1491
|
+
export type FaviconUpdatedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1492
|
+
favicons: string[];
|
|
1493
|
+
};
|
|
1494
|
+
|
|
1495
|
+
export type CrashedEvent = {
|
|
1496
|
+
reason:
|
|
1497
|
+
| 'normal-termination'
|
|
1498
|
+
| 'abnormal-termination'
|
|
1499
|
+
| 'killed'
|
|
1500
|
+
| 'crashed'
|
|
1501
|
+
| 'still-running'
|
|
1502
|
+
| 'launch-failed'
|
|
1503
|
+
| 'out-of-memory'
|
|
1504
|
+
| 'integrity-failure';
|
|
1505
|
+
exitCode: number;
|
|
1506
|
+
details: {
|
|
1507
|
+
reason: string;
|
|
1508
|
+
exitCode: number;
|
|
1509
|
+
};
|
|
1510
|
+
};
|
|
1511
|
+
|
|
1512
|
+
export type WindowNavigationRejectedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1513
|
+
sourceName?: string; // DEPRECATED
|
|
1514
|
+
url: string;
|
|
1515
|
+
};
|
|
1516
|
+
|
|
1517
|
+
export type FrameEvent<Type> = WindowEvent<'frame', Type> & {
|
|
1518
|
+
entityType: 'iframe';
|
|
1519
|
+
frameName: string;
|
|
1520
|
+
};
|
|
1521
|
+
|
|
1522
|
+
export type FrameEvents = BaseEventMap & {
|
|
1523
|
+
connected: FrameEvent<'connected'>;
|
|
1524
|
+
disconnected: FrameEvent<'disconnected'>;
|
|
1525
|
+
};
|
|
1526
|
+
|
|
1527
|
+
// This file exports base event types to level specific events
|
|
1528
|
+
// Those files map event names to event shapes and use a mapped type to specify topic and type
|
|
1529
|
+
export type RuntimeEvent<Topic = string, Type = string> = Topic extends 'window' | 'view'
|
|
1530
|
+
? WindowEvent<Topic, Type>
|
|
1531
|
+
: Topic extends 'frame'
|
|
1532
|
+
? FrameEvent<Type>
|
|
1533
|
+
: Topic extends 'application'
|
|
1534
|
+
? ApplicationEvent<Topic, Type>
|
|
1535
|
+
: BaseEvent<Topic, Type>;
|
|
1536
|
+
|
|
1537
|
+
export type WebContentsEventMapping<Topic = string, Type = string> = BaseEventMap & {
|
|
1538
|
+
'blurred': WindowEvent<Topic, Type>;
|
|
1539
|
+
'certificate-error': CertificateErrorEvent<Topic, Type>;
|
|
1540
|
+
'certificate-selection-shown': CertificateSelectionShownEvent<Topic, Type>;
|
|
1541
|
+
'crashed': CrashedEvent & WindowEvent<Topic, Type>;
|
|
1542
|
+
'did-change-theme-color': WindowEvent<Topic, Type>;
|
|
1543
|
+
'focused': WindowEvent<Topic, Type>;
|
|
1544
|
+
'found-in-page': WindowEvent<Topic, Type>;
|
|
1545
|
+
'navigation-rejected': WindowNavigationRejectedEvent<Topic, Type>;
|
|
1546
|
+
'page-favicon-updated': FaviconUpdatedEvent<Topic, Type>;
|
|
1547
|
+
'page-title-updated': PageTitleUpdatedEvent<Topic, Type>;
|
|
1548
|
+
'resource-load-failed': WindowResourceLoadFailedEvent<Topic, Type>;
|
|
1549
|
+
'resource-response-received': WindowResourceResponseReceivedEvent<Topic, Type>;
|
|
1550
|
+
};
|
|
1551
|
+
|
|
1552
|
+
export type RunRequestedEvent<Topic, Type> = ApplicationEvent<Topic, Type> & {
|
|
1553
|
+
userAppConfigArgs: any;
|
|
1554
|
+
manifest: OpenFin.ManifestInfo;
|
|
1555
|
+
};
|
|
1556
|
+
|
|
1557
|
+
export type TrayIconClicked<Topic, Type> = ApplicationEvent<Topic, Type> & {
|
|
1558
|
+
button: 0 | 1 | 2;
|
|
1559
|
+
bounds: OpenFin.Rectangle;
|
|
1560
|
+
x: number;
|
|
1561
|
+
y: number;
|
|
1562
|
+
monitorInfo: any;
|
|
1563
|
+
};
|
|
1564
|
+
|
|
1565
|
+
export type WindowAlertRequestedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1566
|
+
message: string;
|
|
1567
|
+
url: string;
|
|
1568
|
+
};
|
|
1569
|
+
|
|
1570
|
+
export type WindowAuthRequestedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1571
|
+
authInfo: {
|
|
1572
|
+
host: string;
|
|
1573
|
+
isProxy: boolean;
|
|
1574
|
+
port: number;
|
|
1575
|
+
realm: string;
|
|
1576
|
+
scheme: string;
|
|
1577
|
+
};
|
|
1578
|
+
};
|
|
1579
|
+
|
|
1580
|
+
export type WindowEndLoadEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1581
|
+
documentName: string;
|
|
1582
|
+
isMain: boolean;
|
|
1583
|
+
};
|
|
1584
|
+
|
|
1585
|
+
export type WindowReloadedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1586
|
+
url: string;
|
|
1587
|
+
};
|
|
1588
|
+
|
|
1589
|
+
export type WindowOptionsChangedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1590
|
+
options: OpenFin.WindowOptions;
|
|
1591
|
+
diff: OpenFin.WindowOptionDiff;
|
|
1592
|
+
};
|
|
1593
|
+
|
|
1594
|
+
export type WindowExternalProcessExitedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1595
|
+
processUuid: string;
|
|
1596
|
+
exitCode: number;
|
|
1597
|
+
};
|
|
1598
|
+
|
|
1599
|
+
export type WindowExternalProcessStartedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1600
|
+
processUuid: string;
|
|
1601
|
+
};
|
|
1602
|
+
|
|
1603
|
+
export type WindowHiddenEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1604
|
+
reason: 'closing' | 'hide' | 'hide-on-close';
|
|
1605
|
+
};
|
|
1606
|
+
|
|
1607
|
+
export type PreloadScriptInfoRunning = {
|
|
1608
|
+
state:
|
|
1609
|
+
| 'load-started' // started loading preload script
|
|
1610
|
+
| 'load-failed' // preload script failed to load
|
|
1611
|
+
| 'load-succeeded' // preload script is loaded and ready to be eval'ed
|
|
1612
|
+
| 'failed' // preload script failed to eval
|
|
1613
|
+
| 'succeeded'; // preload script eval'ed successfully
|
|
1614
|
+
};
|
|
1615
|
+
|
|
1616
|
+
export type PreloadScriptInfo = {
|
|
1617
|
+
state:
|
|
1618
|
+
| 'load-failed' // preload script failed to load
|
|
1619
|
+
| 'failed' // preload script failed to eval
|
|
1620
|
+
| 'succeeded'; // preload script eval'ed successfully
|
|
1621
|
+
};
|
|
1622
|
+
export type WindowPreloadScriptsStateChangeEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1623
|
+
preloadScripts: (PreloadScriptInfoRunning & any)[];
|
|
1624
|
+
};
|
|
1625
|
+
export type WindowPreloadScriptsStateChangedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1626
|
+
preloadScripts: (PreloadScriptInfoRunning & any)[];
|
|
1627
|
+
};
|
|
1628
|
+
|
|
1629
|
+
export type WindowBeginBoundsChangingEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1630
|
+
height: number;
|
|
1631
|
+
left: number;
|
|
1632
|
+
top: number;
|
|
1633
|
+
width: number;
|
|
1634
|
+
windowState: 'minimized' | 'normal' | 'maximized';
|
|
1635
|
+
};
|
|
1636
|
+
|
|
1637
|
+
export type WindowEndBoundsChangingEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1638
|
+
height: number;
|
|
1639
|
+
left: number;
|
|
1640
|
+
top: number;
|
|
1641
|
+
width: number;
|
|
1642
|
+
windowState: 'minimized' | 'normal' | 'maximized';
|
|
1643
|
+
};
|
|
1644
|
+
|
|
1645
|
+
export type WindowBoundsChange<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1646
|
+
changeType: 0 | 1 | 2;
|
|
1647
|
+
deferred: boolean;
|
|
1648
|
+
height: number;
|
|
1649
|
+
left: number;
|
|
1650
|
+
top: number;
|
|
1651
|
+
width: number;
|
|
1652
|
+
};
|
|
1653
|
+
|
|
1654
|
+
export type WillMoveOrResize<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1655
|
+
height: number;
|
|
1656
|
+
left: number;
|
|
1657
|
+
top: number;
|
|
1658
|
+
width: number;
|
|
1659
|
+
monitorScaleFactor: number;
|
|
1660
|
+
};
|
|
1661
|
+
|
|
1662
|
+
export type WindowPerformanceReport<Topic, Type> = Performance & WindowEvent<Topic, Type>;
|
|
1663
|
+
|
|
1664
|
+
export type ViewDetached<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1665
|
+
previousTarget: OpenFin.Identity;
|
|
1666
|
+
target: OpenFin.Identity;
|
|
1667
|
+
viewIdentity: OpenFin.Identity;
|
|
1668
|
+
};
|
|
1669
|
+
|
|
1670
|
+
export type WindowEventMapping<Topic = string, Type = string> = WebContentsEventMapping & {
|
|
1671
|
+
'auth-requested': WindowAuthRequestedEvent<Topic, Type>;
|
|
1672
|
+
'begin-user-bounds-changing': WindowBeginBoundsChangingEvent<Topic, Type>;
|
|
1673
|
+
'bounds-changed': WindowBoundsChange<Topic, Type>;
|
|
1674
|
+
'bounds-changing': WindowBoundsChange<Topic, Type>;
|
|
1675
|
+
'close-requested': WindowEvent<Topic, Type>;
|
|
1676
|
+
'closed': WindowEvent<Topic, Type>;
|
|
1677
|
+
'closing': WindowEvent<Topic, Type>;
|
|
1678
|
+
'disabled-movement-bounds-changed': WindowBoundsChange<Topic, Type>;
|
|
1679
|
+
'disabled-movement-bounds-changing': WindowBoundsChange<Topic, Type>;
|
|
1680
|
+
'embedded': WindowEvent<Topic, Type>;
|
|
1681
|
+
'end-user-bounds-changing': WindowEndBoundsChangingEvent<Topic, Type>;
|
|
1682
|
+
'external-process-exited': WindowExternalProcessExitedEvent<Topic, Type>;
|
|
1683
|
+
'external-process-started': WindowExternalProcessStartedEvent<Topic, Type>;
|
|
1684
|
+
'hidden': WindowHiddenEvent<Topic, Type>;
|
|
1685
|
+
'hotkey': InputEvent & WindowEvent<Topic, Type>;
|
|
1686
|
+
'initialized': WindowEvent<Topic, Type>;
|
|
1687
|
+
'layout-initialized': WindowEvent<Topic, Type>;
|
|
1688
|
+
'layout-ready': WindowEvent<Topic, Type>;
|
|
1689
|
+
'maximized': WindowEvent<Topic, Type>;
|
|
1690
|
+
'minimized': WindowEvent<Topic, Type>;
|
|
1691
|
+
'options-changed': WindowOptionsChangedEvent<Topic, Type>;
|
|
1692
|
+
'performance-report': WindowPerformanceReport<Topic, Type>;
|
|
1693
|
+
'preload-scripts-state-changed': WindowPreloadScriptsStateChangeEvent<Topic, Type>;
|
|
1694
|
+
'preload-scripts-state-changing': WindowPreloadScriptsStateChangeEvent<Topic, Type>;
|
|
1695
|
+
'reloaded': WindowReloadedEvent<Topic, Type>;
|
|
1696
|
+
'restored': WindowEvent<Topic, Type>;
|
|
1697
|
+
'show-requested': WindowEvent<Topic, Type>;
|
|
1698
|
+
'shown': WindowEvent<Topic, Type>;
|
|
1699
|
+
'user-movement-disabled': WindowEvent<Topic, Type>;
|
|
1700
|
+
'user-movement-enabled': WindowEvent<Topic, Type>;
|
|
1701
|
+
'view-attached': WindowEvent<Topic, Type>;
|
|
1702
|
+
'view-detached': ViewDetached<Topic, Type>;
|
|
1703
|
+
'will-move': WillMoveOrResize<Topic, Type>;
|
|
1704
|
+
'will-resize': WillMoveOrResize<Topic, Type>;
|
|
1705
|
+
};
|
|
1706
|
+
|
|
1707
|
+
export type PropagatedWindowEventMapping<Topic = string, Type = string> = BaseEventMap & {
|
|
1708
|
+
'window-begin-user-bounds-changing': WindowBeginBoundsChangingEvent<Topic, Type>;
|
|
1709
|
+
'window-blurred': WindowEvent<Topic, Type>;
|
|
1710
|
+
'window-bounds-changed': WindowBoundsChange<Topic, Type>;
|
|
1711
|
+
'window-bounds-changing': WindowBoundsChange<Topic, Type>;
|
|
1712
|
+
'window-certificate-selection-shown': CertificateSelectionShownEvent<Topic, Type>;
|
|
1713
|
+
'window-closed': WindowEvent<Topic, Type>;
|
|
1714
|
+
'window-closing': WindowEvent<Topic, Type>;
|
|
1715
|
+
'window-crashed': CrashedEvent & WindowEvent<Topic, Type>;
|
|
1716
|
+
'window-disabled-movement-bounds-changed': WindowBoundsChange<Topic, Type>;
|
|
1717
|
+
'window-disabled-movement-bounds-changing': WindowBoundsChange<Topic, Type>;
|
|
1718
|
+
'window-embedded': WindowEvent<Topic, Type>;
|
|
1719
|
+
'window-end-user-bounds-changing': WindowBeginBoundsChangingEvent<Topic, Type>;
|
|
1720
|
+
'window-external-process-exited': WindowExternalProcessExitedEvent<Topic, Type>;
|
|
1721
|
+
'window-external-process-started': WindowExternalProcessStartedEvent<Topic, Type>;
|
|
1722
|
+
'window-focused': WindowEvent<Topic, Type>;
|
|
1723
|
+
'window-hidden': WindowHiddenEvent<Topic, Type>;
|
|
1724
|
+
'window-hotkey': InputEvent & WindowEvent<Topic, Type>;
|
|
1725
|
+
'window-initialized': WindowEvent<Topic, Type>;
|
|
1726
|
+
'window-layout-initialized': WindowEvent<Topic, Type>;
|
|
1727
|
+
'window-layout-ready': WindowEvent<Topic, Type>;
|
|
1728
|
+
'window-maximized': WindowEvent<Topic, Type>;
|
|
1729
|
+
'window-minimized': WindowEvent<Topic, Type>;
|
|
1730
|
+
'window-navigation-rejected': WindowNavigationRejectedEvent<Topic, Type>;
|
|
1731
|
+
'window-options-changed': WindowOptionsChangedEvent<Topic, Type>;
|
|
1732
|
+
'window-performance-report': WindowPerformanceReport<Topic, Type>;
|
|
1733
|
+
'window-preload-scripts-state-changed': WindowPreloadScriptsStateChangeEvent<Topic, Type>;
|
|
1734
|
+
'window-preload-scripts-state-changing': WindowPreloadScriptsStateChangedEvent<Topic, Type>;
|
|
1735
|
+
'window-resource-load-failed': WindowResourceLoadFailedEvent<Topic, Type>;
|
|
1736
|
+
'window-resource-response-received': WindowResourceResponseReceivedEvent<Topic, Type>;
|
|
1737
|
+
'window-reloaded': WindowReloadedEvent<Topic, Type>;
|
|
1738
|
+
'window-restored': WindowEvent<Topic, Type>;
|
|
1739
|
+
'window-shown': WindowEvent<Topic, Type>;
|
|
1740
|
+
'window-user-movement-disabled': WindowEvent<Topic, Type>;
|
|
1741
|
+
'window-user-movement-enabled': WindowEvent<Topic, Type>;
|
|
1742
|
+
'window-will-move': WillMoveOrResize<Topic, Type>;
|
|
1743
|
+
'window-will-resize': WillMoveOrResize<Topic, Type>;
|
|
1744
|
+
};
|
|
1745
|
+
|
|
1746
|
+
export type ViewEventMapping<Topic = string, Type = string> = WebContentsEventMapping & {
|
|
1747
|
+
'attached': WindowEvent<Topic, Type>;
|
|
1748
|
+
'created': WindowEvent<Topic, Type>;
|
|
1749
|
+
'destroyed': WindowEvent<Topic, Type>;
|
|
1750
|
+
'hidden': WindowEvent<Topic, Type>;
|
|
1751
|
+
'hotkey': InputEvent & WindowEvent<Topic, Type>;
|
|
1752
|
+
'shown': WindowEvent<Topic, Type>;
|
|
1753
|
+
'target-changed': TargetChangedEvent<Topic, Type>;
|
|
1754
|
+
};
|
|
1755
|
+
|
|
1756
|
+
type PropagatedViewIdentity = {
|
|
1757
|
+
viewIdentity: OpenFin.Identity;
|
|
1758
|
+
};
|
|
1759
|
+
|
|
1760
|
+
export type PropagatedViewEventMapping<Topic = string, Type = string> = BaseEventMap & {
|
|
1761
|
+
'view-blurred': WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1762
|
+
'view-certificate-selection-shown': CertificateSelectionShownEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1763
|
+
'view-crashed': CrashedEvent & WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1764
|
+
'view-created': CrashedEvent & WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1765
|
+
'view-destroyed': WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1766
|
+
'view-did-change-theme-color': WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1767
|
+
'view-focused': WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1768
|
+
'view-hidden': WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1769
|
+
'view-hotkey': InputEvent & WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1770
|
+
'view-navigation-rejected': WindowNavigationRejectedEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1771
|
+
'view-page-favicon-updated': WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1772
|
+
'view-page-title-updated': WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1773
|
+
'view-resource-load-failed': WindowResourceLoadFailedEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1774
|
+
'view-resource-response-received': WindowResourceResponseReceivedEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1775
|
+
'view-shown': WindowEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1776
|
+
'view-target-changed': TargetChangedEvent<Topic, Type> & PropagatedViewIdentity;
|
|
1777
|
+
};
|
|
1778
|
+
|
|
1779
|
+
export type ViewEvents = {
|
|
1780
|
+
[Type in keyof ViewEventMapping]: ViewEventMapping<'view', Type>[Type];
|
|
1781
|
+
};
|
|
1782
|
+
|
|
1783
|
+
export type PropagatedViewEvents<Topic> = {
|
|
1784
|
+
[Type in keyof PropagatedViewEventMapping]: PropagatedViewEventMapping<Topic, Type>[Type];
|
|
1785
|
+
};
|
|
1786
|
+
|
|
1787
|
+
export type InputEvent = {
|
|
1788
|
+
inputType: 'keyUp' | 'keyDown';
|
|
1789
|
+
ctrlKey: boolean;
|
|
1790
|
+
shiftKey: boolean;
|
|
1791
|
+
altKey: boolean;
|
|
1792
|
+
metaKey: boolean;
|
|
1793
|
+
key: string;
|
|
1794
|
+
code: string;
|
|
1795
|
+
repeat: boolean;
|
|
1796
|
+
command?: string;
|
|
1797
|
+
};
|
|
1798
|
+
|
|
1799
|
+
export type TargetChangedEvent<Topic, Type> = WindowEvent<Topic, Type> & {
|
|
1800
|
+
previousTarget: OpenFin.Identity;
|
|
1801
|
+
target: OpenFin.Identity;
|
|
1802
|
+
};
|
|
1803
|
+
|
|
1804
|
+
// This is the type we should be using. It takes the more generic mapping and applies the proper Topic and Type to each event
|
|
1805
|
+
export type WindowEvents = PropagatedViewEventMapping<'window'> &
|
|
1806
|
+
{
|
|
1807
|
+
[Type in keyof WindowEventMapping]: WindowEventMapping<'window', Type>[Type];
|
|
1808
|
+
};
|
|
1809
|
+
|
|
1810
|
+
export type PropagatedWindowEvents<Topic> = {
|
|
1811
|
+
[Type in keyof PropagatedWindowEventMapping]: PropagatedWindowEventMapping<Topic, Type>[Type];
|
|
1812
|
+
};
|
|
1813
|
+
|
|
1814
|
+
export type ApplicationEventMapping<Topic = string, Type = string> = BaseEventMap & {
|
|
1815
|
+
'closed': ApplicationEvent<Topic, Type>;
|
|
1816
|
+
'connected': ApplicationEvent<Topic, Type>;
|
|
1817
|
+
'crashed': CrashedEvent & ApplicationEvent<Topic, Type>;
|
|
1818
|
+
'initialized': ApplicationEvent<Topic, Type>;
|
|
1819
|
+
'manifest-changed': ApplicationEvent<Topic, Type>;
|
|
1820
|
+
'not-responding': ApplicationEvent<Topic, Type>;
|
|
1821
|
+
'responding': ApplicationEvent<Topic, Type>;
|
|
1822
|
+
'run-requested': RunRequestedEvent<Topic, Type>;
|
|
1823
|
+
'started': ApplicationEvent<Topic, Type>;
|
|
1824
|
+
'tray-icon-clicked': TrayIconClicked<Topic, Type>;
|
|
1825
|
+
'window-alert-requested': WindowAlertRequestedEvent<Topic, Type>;
|
|
1826
|
+
'window-auth-requested': WindowAuthRequestedEvent<Topic, Type>;
|
|
1827
|
+
'window-created': WindowEvent<Topic, Type>;
|
|
1828
|
+
'window-end-load': WindowEndLoadEvent<Topic, Type>;
|
|
1829
|
+
'window-not-responding': WindowEvent<Topic, Type>;
|
|
1830
|
+
'window-performance-report': WindowPerformanceReport<Topic, Type>;
|
|
1831
|
+
'window-responding': WindowEvent<Topic, Type>;
|
|
1832
|
+
'window-show-requested': WindowEvent<Topic, Type>;
|
|
1833
|
+
'window-start-load': WindowEvent<Topic, Type>;
|
|
1834
|
+
};
|
|
1835
|
+
|
|
1836
|
+
export type PropagatedApplicationEventMapping<Topic = string, Type = string> = {
|
|
1837
|
+
'application-closed': ApplicationEvent<Topic, Type>;
|
|
1838
|
+
'application-connected': ApplicationEvent<Topic, Type>;
|
|
1839
|
+
'application-crashed': CrashedEvent & ApplicationEvent<Topic, Type>;
|
|
1840
|
+
'application-initialized': ApplicationEvent<Topic, Type>;
|
|
1841
|
+
'application-manifest-changed': ApplicationEvent<Topic, Type>;
|
|
1842
|
+
'application-not-responding': ApplicationEvent<Topic, Type>;
|
|
1843
|
+
'application-responding': ApplicationEvent<Topic, Type>;
|
|
1844
|
+
'application-started': ApplicationEvent<Topic, Type>;
|
|
1845
|
+
'application-tray-icon-clicked': TrayIconClicked<Topic, Type>;
|
|
1846
|
+
'window-created': WindowEvent<Topic, Type>;
|
|
1847
|
+
'window-did-change-theme-color': WindowEvent<Topic, Type>;
|
|
1848
|
+
'window-end-load': WindowEndLoadEvent<Topic, Type>;
|
|
1849
|
+
'window-not-responding': WindowEvent<Topic, Type>;
|
|
1850
|
+
'window-page-favicon-updated': WindowEvent<Topic, Type>;
|
|
1851
|
+
'window-page-title-updated': WindowEvent<Topic, Type>;
|
|
1852
|
+
'window-performance-report': WindowPerformanceReport<Topic, Type>;
|
|
1853
|
+
'window-responding': WindowEvent<Topic, Type>;
|
|
1854
|
+
'window-start-load': WindowEvent<Topic, Type>;
|
|
1855
|
+
};
|
|
1856
|
+
|
|
1857
|
+
export type ApplicationEvents = PropagatedWindowEvents<'application'> &
|
|
1858
|
+
PropagatedViewEvents<'application'> &
|
|
1859
|
+
{
|
|
1860
|
+
[Type in keyof ApplicationEventMapping]: ApplicationEventMapping<'application', Type>[Type];
|
|
1861
|
+
};
|
|
1862
|
+
export type PropagatedApplicationEvents<Topic> = {
|
|
1863
|
+
[Type in keyof PropagatedApplicationEventMapping]: PropagatedApplicationEventMapping<Topic, Type>[Type];
|
|
1864
|
+
};
|
|
1865
|
+
|
|
1866
|
+
export type PlatformEventMapping<Topic = string, Type = string> = ApplicationEventMapping & {
|
|
1867
|
+
'platform-api-ready': ApplicationEvent<Topic, Type>;
|
|
1868
|
+
'platform-snapshot-applied': ApplicationEvent<Topic, Type>;
|
|
1869
|
+
};
|
|
1870
|
+
|
|
1871
|
+
export type PropagatedPlatformEventMapping<Topic = string, Type = string> = PropagatedApplicationEventMapping & {
|
|
1872
|
+
'platform-api-ready': ApplicationEvent<Topic, Type>;
|
|
1873
|
+
'platform-snapshot-applied': ApplicationEvent<Topic, Type>;
|
|
1874
|
+
};
|
|
1875
|
+
|
|
1876
|
+
export type PlatformEvents = PropagatedWindowEvents<'application'> &
|
|
1877
|
+
PropagatedViewEvents<'application'> &
|
|
1878
|
+
{
|
|
1879
|
+
[Type in keyof PlatformEventMapping]: PlatformEventMapping<'application', Type>[Type];
|
|
1880
|
+
};
|
|
1881
|
+
export type PropagatedPlatformEvents<Topic> = {
|
|
1882
|
+
[Type in keyof PropagatedPlatformEventMapping]: PropagatedPlatformEventMapping<Topic, Type>[Type];
|
|
1883
|
+
};
|
|
1884
|
+
|
|
1885
|
+
export type IdleEvent<Topic, Type> = BaseEvent<Topic, Type> & {
|
|
1886
|
+
elapsedTime: number;
|
|
1887
|
+
isIdle: boolean;
|
|
1888
|
+
};
|
|
1889
|
+
|
|
1890
|
+
export type MonitorEvent<Topic, Type> = OpenFin.MonitorInfo & BaseEvent<Topic, Type>;
|
|
1891
|
+
|
|
1892
|
+
export type SessionChangedEvent<Topic, Type> = BaseEvent<Topic, Type> & {
|
|
1893
|
+
reason: 'lock' | 'unlock' | 'remote-connect' | 'remote-disconnect' | 'unknown';
|
|
1894
|
+
};
|
|
1895
|
+
|
|
1896
|
+
export type SystemEventMapping<Topic = string, Type = string> = BaseEventMap & {
|
|
1897
|
+
'application-created': ApplicationEvent<Topic, Type>;
|
|
1898
|
+
'desktop-icon-clicked': ApplicationEvent<Topic, Type>;
|
|
1899
|
+
'idle-state-changed': IdleEvent<Topic, Type>;
|
|
1900
|
+
'monitor-info-changed': MonitorEvent<Topic, Type>;
|
|
1901
|
+
'session-changed': SessionChangedEvent<Topic, Type>;
|
|
1902
|
+
};
|
|
1903
|
+
export type SystemEvents = PropagatedWindowEvents<'system'> &
|
|
1904
|
+
PropagatedApplicationEvents<'system'> &
|
|
1905
|
+
PropagatedViewEvents<'system'> &
|
|
1906
|
+
{
|
|
1907
|
+
[Type in keyof SystemEventMapping]: SystemEventMapping<'system', Type>[Type];
|
|
1908
|
+
};
|
|
1909
|
+
|
|
1910
|
+
export type GlobalHotkeyEvent<Type> = RuntimeEvent<'global-hotkey', Type> & {
|
|
1911
|
+
identity: Identity;
|
|
1912
|
+
hotkey: string;
|
|
1913
|
+
};
|
|
1914
|
+
|
|
1915
|
+
export type GlobalHotkeyEvents = BaseEventMap & {
|
|
1916
|
+
registered: GlobalHotkeyEvent<'registered'>;
|
|
1917
|
+
unregistered: GlobalHotkeyEvent<'unregistered'>;
|
|
1918
|
+
};
|
|
1919
|
+
|
|
1920
|
+
export type ExternalApplicationEvents = BaseEventMap & {
|
|
1921
|
+
connected: RuntimeEvent<'externalapplication', 'connected'>;
|
|
1922
|
+
disconnected: RuntimeEvent<'externalapplication', 'disconnected'>;
|
|
1923
|
+
};
|
|
1924
|
+
|
|
1925
|
+
export type ChannelAction = (payload: unknown, id: ProviderIdentity | OpenFin.ClientIdentity) => unknown;
|
|
1926
|
+
|
|
1927
|
+
export type ChannelMiddleware = (
|
|
1928
|
+
topic: string,
|
|
1929
|
+
payload: unknown,
|
|
1930
|
+
senderIdentity: ProviderIdentity | OpenFin.ClientIdentity
|
|
1931
|
+
) => unknown;
|
|
1932
|
+
|
|
1933
|
+
export type ErrorMiddleware = (
|
|
1934
|
+
topic: string,
|
|
1935
|
+
error: Error,
|
|
1936
|
+
id: ProviderIdentity | OpenFin.ClientIdentity
|
|
1937
|
+
) => unknown;
|
|
1938
|
+
|
|
1939
|
+
export type SystemApplicationInfo = {
|
|
1940
|
+
isPlatform: boolean;
|
|
1941
|
+
isRunning: boolean;
|
|
1942
|
+
uuid: string;
|
|
1943
|
+
parentUuid?: string;
|
|
1944
|
+
};
|
|
1945
|
+
|
|
1946
|
+
export type InstalledApps = {
|
|
1947
|
+
[key: string]: InstallationInfo;
|
|
1948
|
+
};
|
|
1949
|
+
|
|
1950
|
+
export type InstallationInfo = {
|
|
1951
|
+
cachedManifest: any;
|
|
1952
|
+
};
|
|
1953
|
+
|
|
1954
|
+
export type GetLogRequestType = {
|
|
1955
|
+
name: string;
|
|
1956
|
+
endFile?: string;
|
|
1957
|
+
sizeLimit?: number;
|
|
1958
|
+
};
|
|
1959
|
+
|
|
1960
|
+
export type LogInfo = {
|
|
1961
|
+
name: string;
|
|
1962
|
+
size: number;
|
|
1963
|
+
date: string;
|
|
1964
|
+
};
|
|
1965
|
+
|
|
1966
|
+
// 2.4 supports string enum types, currently we use 2.2
|
|
1967
|
+
export type LogLevel = 'verbose' | 'info' | 'warning' | 'error' | 'fatal';
|
|
1968
|
+
|
|
1969
|
+
export type ProcessInfo = {
|
|
1970
|
+
cpuUsage?: number;
|
|
1971
|
+
name?: string;
|
|
1972
|
+
nonPagedPoolUsage?: number;
|
|
1973
|
+
pageFaultCount?: number;
|
|
1974
|
+
pagedPoolUsage?: number;
|
|
1975
|
+
pagefileUsage?: number;
|
|
1976
|
+
peakNonPagedPoolUsage?: number;
|
|
1977
|
+
peakPagedPoolUsage?: number;
|
|
1978
|
+
peakPagefileUsage?: number;
|
|
1979
|
+
peakWorkingSetSize?: number;
|
|
1980
|
+
processId?: number;
|
|
1981
|
+
uuid?: string;
|
|
1982
|
+
workingSetSize?: number;
|
|
1983
|
+
};
|
|
1984
|
+
|
|
1985
|
+
export type PermissionState = 'granted' | 'denied' | 'unavailable';
|
|
1986
|
+
|
|
1987
|
+
export type RegistryInfo = {
|
|
1988
|
+
data: any;
|
|
1989
|
+
rootKey: string;
|
|
1990
|
+
subkey: string;
|
|
1991
|
+
type: string;
|
|
1992
|
+
value: string;
|
|
1993
|
+
};
|
|
1994
|
+
|
|
1995
|
+
export type Entity = {
|
|
1996
|
+
type: string;
|
|
1997
|
+
uuid: string;
|
|
1998
|
+
};
|
|
1999
|
+
|
|
2000
|
+
export type WindowInfo = {
|
|
2001
|
+
childWindows: Array<WindowDetail>;
|
|
2002
|
+
mainWindow: WindowDetail;
|
|
2003
|
+
uuid: string;
|
|
2004
|
+
};
|
|
2005
|
+
|
|
2006
|
+
export type WindowDetail = {
|
|
2007
|
+
bottom: number;
|
|
2008
|
+
height: number;
|
|
2009
|
+
isShowing: boolean;
|
|
2010
|
+
left: number;
|
|
2011
|
+
name: string;
|
|
2012
|
+
right: number;
|
|
2013
|
+
state: string;
|
|
2014
|
+
top: number;
|
|
2015
|
+
width: number;
|
|
2016
|
+
};
|
|
2017
|
+
|
|
2018
|
+
export type WebOptions = {
|
|
2019
|
+
preloadScripts?: OpenFin.PreloadScript[];
|
|
2020
|
+
uuid: string;
|
|
2021
|
+
name: string;
|
|
2022
|
+
contentCreation?: OpenFin.ContentCreationOptions;
|
|
2023
|
+
contentRedirect?: Partial<OpenFin.ContentRedirect>;
|
|
2024
|
+
customContext?: any;
|
|
2025
|
+
experimental?: any;
|
|
2026
|
+
processAffinity?: string;
|
|
2027
|
+
backgroundThrottling?: boolean;
|
|
2028
|
+
interop?: OpenFin.InteropConfig;
|
|
2029
|
+
};
|
|
2030
|
+
|
|
2031
|
+
// Error types
|
|
2032
|
+
export type ERROR_BOX_TYPES =
|
|
2033
|
+
| 'OF_error_box:app_initialization'
|
|
2034
|
+
| 'OF_error_box:main_process'
|
|
2035
|
+
| 'OF_error_box:renderer_crash';
|
|
2036
|
+
|
|
2037
|
+
export type LayoutPresetType = 'columns' | 'grid' | 'rows' | 'tabs';
|
|
2038
|
+
|
|
2039
|
+
export type InitLayoutOptions = {
|
|
2040
|
+
containerId?: string;
|
|
2041
|
+
};
|
|
2042
|
+
|
|
2043
|
+
export type PresetLayoutOptions = {
|
|
2044
|
+
presetType: LayoutPresetType;
|
|
2045
|
+
};
|
|
2046
|
+
|
|
2047
|
+
export type DragPayload = {
|
|
2048
|
+
'view-config': OpenFin.ViewCreationOptions;
|
|
2049
|
+
'view-identity': [string, string, string]; // [componentState, uuid, name]
|
|
2050
|
+
};
|
|
2051
|
+
|
|
2052
|
+
export type Message<T> = {
|
|
2053
|
+
action: string;
|
|
2054
|
+
payload: T;
|
|
2055
|
+
correlationId?: number;
|
|
2056
|
+
};
|
|
2057
|
+
|
|
2058
|
+
export type EventMessage = Message<RuntimeEvent> & {
|
|
2059
|
+
action: 'process-desktop-event';
|
|
2060
|
+
payload: RuntimeEvent;
|
|
2061
|
+
};
|
|
2062
|
+
|
|
2063
|
+
export type Payload = {
|
|
2064
|
+
success: boolean;
|
|
2065
|
+
data: any;
|
|
2066
|
+
};
|
|
2067
|
+
|
|
2068
|
+
export type AuthorizationPayload = {
|
|
2069
|
+
token: string;
|
|
2070
|
+
file: string;
|
|
2071
|
+
};
|
|
2072
|
+
|
|
2073
|
+
/*
|
|
2074
|
+
To Add an api call:
|
|
2075
|
+
1. The action (string passed to wire.sendAction and key in the actionMap on the core side) should be the key in the protocolmap
|
|
2076
|
+
2. The request for that key is the type of the second object passed to wire.sendAction, it will be picked up as message.payload in the handler
|
|
2077
|
+
3. The response for that key is what the core api handler either returns or passes to "ack". It will be the 'data' property of the return value of wire.sendAction
|
|
2078
|
+
*/
|
|
2079
|
+
export type ProtocolMap = ProtocolMapBase & {
|
|
2080
|
+
'request-external-authorization': {
|
|
2081
|
+
request: any;
|
|
2082
|
+
response: void;
|
|
2083
|
+
specialResponse: AuthorizationPayload;
|
|
2084
|
+
};
|
|
2085
|
+
'application-get-views': {
|
|
2086
|
+
request: OpenFin.ApplicationIdentity;
|
|
2087
|
+
response: OpenFin.Identity[];
|
|
2088
|
+
};
|
|
2089
|
+
'set-jump-list': {
|
|
2090
|
+
request: { config: OpenFin.JumpListCategory[] | null } & OpenFin.ApplicationIdentity;
|
|
2091
|
+
response: void;
|
|
2092
|
+
};
|
|
2093
|
+
'get-view-window': {
|
|
2094
|
+
request: OpenFin.Identity;
|
|
2095
|
+
response: OpenFin.Identity;
|
|
2096
|
+
};
|
|
2097
|
+
'window-get-views': {
|
|
2098
|
+
request: OpenFin.Identity;
|
|
2099
|
+
response: OpenFin.Identity[];
|
|
2100
|
+
};
|
|
2101
|
+
'hide-view': {
|
|
2102
|
+
request: OpenFin.Identity;
|
|
2103
|
+
response: void;
|
|
2104
|
+
};
|
|
2105
|
+
'launch-manifest': {
|
|
2106
|
+
request: { manifestUrl: string; opts?: OpenFin.RvmLaunchOptions };
|
|
2107
|
+
response: { manifest: OpenFin.Manifest };
|
|
2108
|
+
};
|
|
2109
|
+
'get-system-app-configuration': {
|
|
2110
|
+
request: { name: string };
|
|
2111
|
+
response: any;
|
|
2112
|
+
};
|
|
2113
|
+
'show-popup-menu': {
|
|
2114
|
+
request: OpenFin.Identity & { options: OpenFin.ShowPopupMenuOptions };
|
|
2115
|
+
response: OpenFin.MenuResult;
|
|
2116
|
+
};
|
|
2117
|
+
'enable-native-window-integration-provider': {
|
|
2118
|
+
request: { permissions: any };
|
|
2119
|
+
response: OpenFin.NativeWindowIntegrationProviderAuthorization;
|
|
2120
|
+
};
|
|
2121
|
+
'get-permissions': {
|
|
2122
|
+
request: void;
|
|
2123
|
+
response: any;
|
|
2124
|
+
};
|
|
2125
|
+
'set-file-download-location': {
|
|
2126
|
+
request: OpenFin.ApplicationIdentity & { downloadLocation: string };
|
|
2127
|
+
response: void;
|
|
2128
|
+
};
|
|
2129
|
+
'close-popup-menu': {
|
|
2130
|
+
request: OpenFin.Identity;
|
|
2131
|
+
response: void;
|
|
2132
|
+
};
|
|
2133
|
+
'fdc3-add-context-listener': {
|
|
2134
|
+
request: void;
|
|
2135
|
+
response: void;
|
|
2136
|
+
};
|
|
2137
|
+
'fdc3-broadcast': {
|
|
2138
|
+
request: void;
|
|
2139
|
+
response: void;
|
|
2140
|
+
};
|
|
2141
|
+
'fdc3-get-system-channels': {
|
|
2142
|
+
request: void;
|
|
2143
|
+
response: void;
|
|
2144
|
+
};
|
|
2145
|
+
'fdc3-join-channel': {
|
|
2146
|
+
request: void;
|
|
2147
|
+
response: void;
|
|
2148
|
+
};
|
|
2149
|
+
'fdc3-leave-current-channel': {
|
|
2150
|
+
request: void;
|
|
2151
|
+
response: void;
|
|
2152
|
+
};
|
|
2153
|
+
'interop-connect-sync': {
|
|
2154
|
+
request: void;
|
|
2155
|
+
response: void;
|
|
2156
|
+
};
|
|
2157
|
+
'interop-client-set-context': {
|
|
2158
|
+
request: void;
|
|
2159
|
+
response: void;
|
|
2160
|
+
};
|
|
2161
|
+
'interop-client-add-context-handler': {
|
|
2162
|
+
request: void;
|
|
2163
|
+
response: void;
|
|
2164
|
+
};
|
|
2165
|
+
'interop-client-get-context-groups': {
|
|
2166
|
+
request: void;
|
|
2167
|
+
response: void;
|
|
2168
|
+
};
|
|
2169
|
+
'interop-client-join-context-group': {
|
|
2170
|
+
request: void;
|
|
2171
|
+
response: void;
|
|
2172
|
+
};
|
|
2173
|
+
'interop-client-remove-from-context-group': {
|
|
2174
|
+
request: void;
|
|
2175
|
+
response: void;
|
|
2176
|
+
};
|
|
2177
|
+
'interop-client-get-all-clients-in-context-group': {
|
|
2178
|
+
request: void;
|
|
2179
|
+
response: void;
|
|
2180
|
+
};
|
|
2181
|
+
'interop-client-get-info-for-context-group': {
|
|
2182
|
+
request: void;
|
|
2183
|
+
response: void;
|
|
2184
|
+
};
|
|
2185
|
+
'interop-broker-add-client-to-context-group': {
|
|
2186
|
+
request: void;
|
|
2187
|
+
response: void;
|
|
2188
|
+
};
|
|
2189
|
+
'interop-broker-get-all-clients-in-context-group': {
|
|
2190
|
+
request: void;
|
|
2191
|
+
response: void;
|
|
2192
|
+
};
|
|
2193
|
+
'interop-broker-get-context-groups': {
|
|
2194
|
+
request: void;
|
|
2195
|
+
response: void;
|
|
2196
|
+
};
|
|
2197
|
+
'interop-broker-get-info-for-context-group': {
|
|
2198
|
+
request: void;
|
|
2199
|
+
response: void;
|
|
2200
|
+
};
|
|
2201
|
+
'interop-broker-is-action-authorized': {
|
|
2202
|
+
request: void;
|
|
2203
|
+
response: void;
|
|
2204
|
+
};
|
|
2205
|
+
'interop-broker-is-connection-authorized': {
|
|
2206
|
+
request: void;
|
|
2207
|
+
response: void;
|
|
2208
|
+
};
|
|
2209
|
+
'interop-broker-join-context-group': {
|
|
2210
|
+
request: void;
|
|
2211
|
+
response: void;
|
|
2212
|
+
};
|
|
2213
|
+
'interop-broker-remove-client-from-context-group': {
|
|
2214
|
+
request: void;
|
|
2215
|
+
response: void;
|
|
2216
|
+
};
|
|
2217
|
+
'interop-broker-remove-from-context-group': {
|
|
2218
|
+
request: void;
|
|
2219
|
+
response: void;
|
|
2220
|
+
};
|
|
2221
|
+
'interop-broker-set-context': {
|
|
2222
|
+
request: void;
|
|
2223
|
+
response: void;
|
|
2224
|
+
};
|
|
2225
|
+
'query-permission-for-current-context': {
|
|
2226
|
+
request: { apiName: string; identity: OpenFin.Identity };
|
|
2227
|
+
response: OpenFin.QueryPermissionResult;
|
|
2228
|
+
};
|
|
2229
|
+
};
|
|
2230
|
+
|
|
2231
|
+
type ProtocolMapBase = {
|
|
2232
|
+
[action: string]: {
|
|
2233
|
+
request: any;
|
|
2234
|
+
response: any;
|
|
2235
|
+
specialResponse?: any; // Used for anything not on payload.data (only request-external-authorization for now)
|
|
2236
|
+
};
|
|
2237
|
+
};
|
|
2238
|
+
|
|
2239
|
+
export type MessageHandler = (data: any) => boolean;
|
|
2240
|
+
|
|
2241
|
+
export type ViewState = OpenFin.ViewCreationOptions & {
|
|
2242
|
+
url: string;
|
|
2243
|
+
};
|
|
2244
|
+
|
|
2245
|
+
export type OsConfig = {
|
|
2246
|
+
manifestLocation: string;
|
|
2247
|
+
namedPipeName: string;
|
|
2248
|
+
urlPath: string;
|
|
2249
|
+
executablePath: string;
|
|
2250
|
+
};
|
|
2251
|
+
|
|
2252
|
+
export type Wire = EventEmitter & {
|
|
2253
|
+
connect(address: string): Promise<any>;
|
|
2254
|
+
connectSync(): any;
|
|
2255
|
+
send(data: any): Promise<any>;
|
|
2256
|
+
shutdown(): Promise<void>;
|
|
2257
|
+
};
|
|
2258
|
+
export type WireConstructor = {
|
|
2259
|
+
new (onmessage: (data: any) => void): Wire;
|
|
2260
|
+
};
|
|
2261
|
+
|
|
2262
|
+
export type RuntimeConfig = {
|
|
2263
|
+
version: string;
|
|
2264
|
+
fallbackVersion?: string;
|
|
2265
|
+
securityRealm?: string;
|
|
2266
|
+
verboseLogging?: boolean;
|
|
2267
|
+
arguments?: string;
|
|
2268
|
+
rvmDir?: string;
|
|
2269
|
+
};
|
|
2270
|
+
|
|
2271
|
+
export type ServiceConfig = {
|
|
2272
|
+
name: string;
|
|
2273
|
+
manifestUrl: string;
|
|
2274
|
+
};
|
|
2275
|
+
|
|
2276
|
+
export type BaseConfig = {
|
|
2277
|
+
uuid?: string;
|
|
2278
|
+
address?: string;
|
|
2279
|
+
name?: string;
|
|
2280
|
+
nonPersistent?: boolean;
|
|
2281
|
+
runtimeClient?: boolean;
|
|
2282
|
+
licenseKey?: string;
|
|
2283
|
+
client?: any;
|
|
2284
|
+
manifestUrl?: string;
|
|
2285
|
+
startupApp?: any;
|
|
2286
|
+
lrsUrl?: string;
|
|
2287
|
+
assetsUrl?: string;
|
|
2288
|
+
devToolsPort?: number;
|
|
2289
|
+
installerUI?: boolean;
|
|
2290
|
+
runtime?: RuntimeConfig;
|
|
2291
|
+
services?: ServiceConfig[];
|
|
2292
|
+
appAssets?: [
|
|
2293
|
+
{
|
|
2294
|
+
src: string;
|
|
2295
|
+
alias: string;
|
|
2296
|
+
target: string;
|
|
2297
|
+
version: string;
|
|
2298
|
+
args: string;
|
|
2299
|
+
}
|
|
2300
|
+
];
|
|
2301
|
+
customItems?: [any];
|
|
2302
|
+
timeout?: number; // in seconds
|
|
2303
|
+
};
|
|
2304
|
+
|
|
2305
|
+
export type ConfigWithUuid = BaseConfig & {
|
|
2306
|
+
uuid: string;
|
|
2307
|
+
};
|
|
2308
|
+
|
|
2309
|
+
export type ExistingConnectConfig = ConfigWithUuid & {
|
|
2310
|
+
address: string;
|
|
2311
|
+
};
|
|
2312
|
+
|
|
2313
|
+
export type ConfigWithRuntime = BaseConfig & {
|
|
2314
|
+
runtime: RuntimeConfig;
|
|
2315
|
+
};
|
|
2316
|
+
|
|
2317
|
+
export type ExternalConfig = BaseConfig & {
|
|
2318
|
+
manifestUrl: string;
|
|
2319
|
+
};
|
|
2320
|
+
|
|
2321
|
+
export type NewConnectConfig = ConfigWithUuid & ConfigWithRuntime;
|
|
2322
|
+
|
|
2323
|
+
export type PortDiscoveryConfig = (ExternalConfig & ConfigWithRuntime) | NewConnectConfig;
|
|
2324
|
+
|
|
2325
|
+
export type ConnectConfig = ExistingConnectConfig | NewConnectConfig | ExternalConfig;
|
|
2326
|
+
|
|
2327
|
+
export type InternalConnectConfig = ExistingConnectConfig | NewConnectConfig;
|
|
2328
|
+
|
|
2329
|
+
export type ReadyState = // https://github.com/websockets/ws/blob/master/doc/ws.md#ready-state-constants
|
|
2330
|
+
| 'CONNECTING' // The connection is not yet open.
|
|
2331
|
+
| 'OPEN' // The connection is open and ready to communicate.
|
|
2332
|
+
| 'CLOSING' // The connection is in the process of closing.
|
|
2333
|
+
| 'CLOSED'; // The connection is closed.
|
|
2334
|
+
|
|
2335
|
+
export type ChildContentOptions = {
|
|
2336
|
+
options: any;
|
|
2337
|
+
entityType: EntityType;
|
|
2338
|
+
};
|
|
2339
|
+
|
|
2340
|
+
export type ErrorPlainObject = {
|
|
2341
|
+
stack: string;
|
|
2342
|
+
message: string;
|
|
2343
|
+
toString(): string;
|
|
2344
|
+
};
|
|
1340
2345
|
}
|