@lvce-editor/extension-management-worker 4.88.5 → 4.89.0
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.
|
@@ -757,7 +757,7 @@ const waitForWebSocketToBeOpen = webSocket => {
|
|
|
757
757
|
open: Open
|
|
758
758
|
});
|
|
759
759
|
};
|
|
760
|
-
const create$
|
|
760
|
+
const create$d = async ({
|
|
761
761
|
webSocket
|
|
762
762
|
}) => {
|
|
763
763
|
const firstWebSocketEvent = await waitForWebSocketToBeOpen(webSocket);
|
|
@@ -794,7 +794,7 @@ const wrap = webSocket => {
|
|
|
794
794
|
};
|
|
795
795
|
const IpcParentWithWebSocket$1 = {
|
|
796
796
|
__proto__: null,
|
|
797
|
-
create: create$
|
|
797
|
+
create: create$d,
|
|
798
798
|
wrap
|
|
799
799
|
};
|
|
800
800
|
|
|
@@ -1105,7 +1105,7 @@ const getErrorResponse = (id, error, preparePrettyError, logError) => {
|
|
|
1105
1105
|
const errorProperty = getErrorProperty(error, prettyError);
|
|
1106
1106
|
return create$1$1(id, errorProperty);
|
|
1107
1107
|
};
|
|
1108
|
-
const create$
|
|
1108
|
+
const create$c = (message, result) => {
|
|
1109
1109
|
return {
|
|
1110
1110
|
id: message.id,
|
|
1111
1111
|
jsonrpc: Two$1,
|
|
@@ -1114,7 +1114,7 @@ const create$b = (message, result) => {
|
|
|
1114
1114
|
};
|
|
1115
1115
|
const getSuccessResponse = (message, result) => {
|
|
1116
1116
|
const resultProperty = result ?? null;
|
|
1117
|
-
return create$
|
|
1117
|
+
return create$c(message, resultProperty);
|
|
1118
1118
|
};
|
|
1119
1119
|
const getErrorResponseSimple = (id, error) => {
|
|
1120
1120
|
return {
|
|
@@ -1213,7 +1213,7 @@ const handleJsonRpcMessage = async (...args) => {
|
|
|
1213
1213
|
|
|
1214
1214
|
const Two = '2.0';
|
|
1215
1215
|
|
|
1216
|
-
const create$
|
|
1216
|
+
const create$b = (method, params) => {
|
|
1217
1217
|
return {
|
|
1218
1218
|
jsonrpc: Two,
|
|
1219
1219
|
method,
|
|
@@ -1221,7 +1221,7 @@ const create$a = (method, params) => {
|
|
|
1221
1221
|
};
|
|
1222
1222
|
};
|
|
1223
1223
|
|
|
1224
|
-
const create$
|
|
1224
|
+
const create$a = (id, method, params) => {
|
|
1225
1225
|
const message = {
|
|
1226
1226
|
id,
|
|
1227
1227
|
jsonrpc: Two,
|
|
@@ -1232,12 +1232,12 @@ const create$9 = (id, method, params) => {
|
|
|
1232
1232
|
};
|
|
1233
1233
|
|
|
1234
1234
|
let id = 0;
|
|
1235
|
-
const create$
|
|
1235
|
+
const create$9 = () => {
|
|
1236
1236
|
return ++id;
|
|
1237
1237
|
};
|
|
1238
1238
|
|
|
1239
1239
|
const registerPromise = map => {
|
|
1240
|
-
const id = create$
|
|
1240
|
+
const id = create$9();
|
|
1241
1241
|
const {
|
|
1242
1242
|
promise,
|
|
1243
1243
|
resolve
|
|
@@ -1254,7 +1254,7 @@ const invokeHelper = async (callbacks, ipc, method, params, useSendAndTransfer)
|
|
|
1254
1254
|
id,
|
|
1255
1255
|
promise
|
|
1256
1256
|
} = registerPromise(callbacks);
|
|
1257
|
-
const message = create$
|
|
1257
|
+
const message = create$a(id, method, params);
|
|
1258
1258
|
if (useSendAndTransfer && ipc.sendAndTransfer) {
|
|
1259
1259
|
ipc.sendAndTransfer(message);
|
|
1260
1260
|
} else {
|
|
@@ -1290,7 +1290,7 @@ const createRpc = ipc => {
|
|
|
1290
1290
|
* @deprecated
|
|
1291
1291
|
*/
|
|
1292
1292
|
send(method, ...params) {
|
|
1293
|
-
const message = create$
|
|
1293
|
+
const message = create$b(method, params);
|
|
1294
1294
|
ipc.send(message);
|
|
1295
1295
|
}
|
|
1296
1296
|
};
|
|
@@ -1361,7 +1361,7 @@ const createSharedLazyRpc = factory => {
|
|
|
1361
1361
|
};
|
|
1362
1362
|
};
|
|
1363
1363
|
|
|
1364
|
-
const create$
|
|
1364
|
+
const create$8 = async ({
|
|
1365
1365
|
commandMap,
|
|
1366
1366
|
isMessagePortOpen = true,
|
|
1367
1367
|
messagePort
|
|
@@ -1379,7 +1379,7 @@ const create$7 = async ({
|
|
|
1379
1379
|
return rpc;
|
|
1380
1380
|
};
|
|
1381
1381
|
|
|
1382
|
-
const create$
|
|
1382
|
+
const create$7 = async ({
|
|
1383
1383
|
commandMap,
|
|
1384
1384
|
isMessagePortOpen,
|
|
1385
1385
|
send
|
|
@@ -1389,20 +1389,20 @@ const create$6 = async ({
|
|
|
1389
1389
|
port2
|
|
1390
1390
|
} = new MessageChannel();
|
|
1391
1391
|
await send(port1);
|
|
1392
|
-
return create$
|
|
1392
|
+
return create$8({
|
|
1393
1393
|
commandMap,
|
|
1394
1394
|
isMessagePortOpen,
|
|
1395
1395
|
messagePort: port2
|
|
1396
1396
|
});
|
|
1397
1397
|
};
|
|
1398
1398
|
|
|
1399
|
-
const create$
|
|
1399
|
+
const create$6 = async ({
|
|
1400
1400
|
commandMap,
|
|
1401
1401
|
isMessagePortOpen,
|
|
1402
1402
|
send
|
|
1403
1403
|
}) => {
|
|
1404
1404
|
return createSharedLazyRpc(() => {
|
|
1405
|
-
return create$
|
|
1405
|
+
return create$7({
|
|
1406
1406
|
commandMap,
|
|
1407
1407
|
isMessagePortOpen,
|
|
1408
1408
|
send
|
|
@@ -1430,7 +1430,7 @@ const getProtocol = () => {
|
|
|
1430
1430
|
return location.protocol;
|
|
1431
1431
|
};
|
|
1432
1432
|
|
|
1433
|
-
const create$
|
|
1433
|
+
const create$5 = async ({
|
|
1434
1434
|
commandMap,
|
|
1435
1435
|
webSocket
|
|
1436
1436
|
}) => {
|
|
@@ -1462,7 +1462,7 @@ const connect$1 = async ({
|
|
|
1462
1462
|
}) => {
|
|
1463
1463
|
const webSocket = new WebSocket(wsUrl);
|
|
1464
1464
|
try {
|
|
1465
|
-
const rpc = await create$
|
|
1465
|
+
const rpc = await create$5({
|
|
1466
1466
|
commandMap,
|
|
1467
1467
|
webSocket
|
|
1468
1468
|
});
|
|
@@ -1475,7 +1475,7 @@ const connect$1 = async ({
|
|
|
1475
1475
|
throw error;
|
|
1476
1476
|
}
|
|
1477
1477
|
};
|
|
1478
|
-
const create$
|
|
1478
|
+
const create$4 = async ({
|
|
1479
1479
|
commandMap,
|
|
1480
1480
|
onClose,
|
|
1481
1481
|
type
|
|
@@ -1504,7 +1504,7 @@ const create$3 = async ({
|
|
|
1504
1504
|
return connection.rpc;
|
|
1505
1505
|
};
|
|
1506
1506
|
|
|
1507
|
-
const create$
|
|
1507
|
+
const create$3 = async ({
|
|
1508
1508
|
commandMap,
|
|
1509
1509
|
isMessagePortOpen,
|
|
1510
1510
|
messagePort
|
|
@@ -1521,7 +1521,7 @@ const create$2 = async ({
|
|
|
1521
1521
|
return rpc;
|
|
1522
1522
|
};
|
|
1523
1523
|
|
|
1524
|
-
const create$
|
|
1524
|
+
const create$2 = async ({
|
|
1525
1525
|
commandMap
|
|
1526
1526
|
}) => {
|
|
1527
1527
|
// TODO create a commandMap per rpc instance
|
|
@@ -1578,7 +1578,7 @@ const remove$2 = id => {
|
|
|
1578
1578
|
};
|
|
1579
1579
|
|
|
1580
1580
|
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
|
1581
|
-
const create = rpcId => {
|
|
1581
|
+
const create$1 = rpcId => {
|
|
1582
1582
|
return {
|
|
1583
1583
|
async dispose() {
|
|
1584
1584
|
const rpc = get$5(rpcId);
|
|
@@ -1617,13 +1617,13 @@ const create = rpcId => {
|
|
|
1617
1617
|
const {
|
|
1618
1618
|
invoke: invoke$9,
|
|
1619
1619
|
set: set$c
|
|
1620
|
-
} = create(6010);
|
|
1620
|
+
} = create$1(6010);
|
|
1621
1621
|
|
|
1622
1622
|
const {
|
|
1623
1623
|
invoke: invoke$8,
|
|
1624
1624
|
invokeAndTransfer: invokeAndTransfer$2,
|
|
1625
1625
|
set: set$b
|
|
1626
|
-
} = create(19_001);
|
|
1626
|
+
} = create$1(19_001);
|
|
1627
1627
|
const getCacheStorageItem = async (request, cacheName, bucketName, bucketOptions) => {
|
|
1628
1628
|
return invoke$8('Cache.getCacheStorageItem', request, cacheName, bucketName, bucketOptions);
|
|
1629
1629
|
};
|
|
@@ -1637,12 +1637,12 @@ const setCacheStorageItem = async (request, value, cacheName, headers, bucketNam
|
|
|
1637
1637
|
const {
|
|
1638
1638
|
invoke: invoke$7,
|
|
1639
1639
|
set: set$a
|
|
1640
|
-
} = create(ErrorWorker);
|
|
1640
|
+
} = create$1(ErrorWorker);
|
|
1641
1641
|
|
|
1642
1642
|
const {
|
|
1643
1643
|
invoke: invoke$6,
|
|
1644
1644
|
set: set$9
|
|
1645
|
-
} = create(FileSystemWorker);
|
|
1645
|
+
} = create$1(FileSystemWorker);
|
|
1646
1646
|
const readFile$1 = async uri => {
|
|
1647
1647
|
return invoke$6('FileSystem.readFile', uri);
|
|
1648
1648
|
};
|
|
@@ -1659,13 +1659,13 @@ const exists = async uri => {
|
|
|
1659
1659
|
const {
|
|
1660
1660
|
invoke: invoke$5,
|
|
1661
1661
|
set: set$8
|
|
1662
|
-
} = create(MainProcess);
|
|
1662
|
+
} = create$1(MainProcess);
|
|
1663
1663
|
|
|
1664
1664
|
const {
|
|
1665
1665
|
invoke: invoke$4,
|
|
1666
1666
|
invokeAndTransfer: invokeAndTransfer$1,
|
|
1667
1667
|
set: set$7
|
|
1668
|
-
} = create(RendererWorker);
|
|
1668
|
+
} = create$1(RendererWorker);
|
|
1669
1669
|
const sendMessagePortToAuthWorker = async (port, rpcId) => {
|
|
1670
1670
|
const command = 'HandleMessagePort.handleMessagePort';
|
|
1671
1671
|
await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToAuthWorker', port, command, rpcId);
|
|
@@ -1690,7 +1690,7 @@ const sendMessagePortToSharedProcess = async port => {
|
|
|
1690
1690
|
const {
|
|
1691
1691
|
invoke: invoke$3,
|
|
1692
1692
|
set: set$6
|
|
1693
|
-
} = create(SharedProcess);
|
|
1693
|
+
} = create$1(SharedProcess);
|
|
1694
1694
|
|
|
1695
1695
|
const extensions = Object.create(null);
|
|
1696
1696
|
const get$4 = extensionId => {
|
|
@@ -2488,7 +2488,7 @@ const fileSystemMethods = new Set(['readFile', 'readDirWithFileTypes', 'stat', '
|
|
|
2488
2488
|
const createFileSystemPort = async (application, port, extensionId) => {
|
|
2489
2489
|
const services = getServices(application);
|
|
2490
2490
|
const version = extensionId === undefined ? 0 : services.extensionVersions.get(extensionId) || 0;
|
|
2491
|
-
const rpc = await create$
|
|
2491
|
+
const rpc = await create$8({
|
|
2492
2492
|
commandMap: {},
|
|
2493
2493
|
messagePort: port
|
|
2494
2494
|
});
|
|
@@ -2512,7 +2512,7 @@ const createFileSystemPort = async (application, port, extensionId) => {
|
|
|
2512
2512
|
throw error;
|
|
2513
2513
|
}
|
|
2514
2514
|
};
|
|
2515
|
-
const dispose = async application => {
|
|
2515
|
+
const dispose$1 = async application => {
|
|
2516
2516
|
const services = applications$1.get(application.applicationGeneration);
|
|
2517
2517
|
if (!services) return;
|
|
2518
2518
|
applications$1.delete(application.applicationGeneration);
|
|
@@ -2842,6 +2842,69 @@ const createNodeRpcMessagePort = async (extensionId, rpcId, port) => {
|
|
|
2842
2842
|
await invokeAndTransfer$1('ExtensionNodeRpc.createMessagePort', port, extensionId, rpcId);
|
|
2843
2843
|
};
|
|
2844
2844
|
|
|
2845
|
+
/* eslint-disable @typescript-eslint/prefer-readonly-parameter-types */
|
|
2846
|
+
const registrations = new Map();
|
|
2847
|
+
const byId = new Map();
|
|
2848
|
+
const keyFor = (extensionId, clientId, application) => JSON.stringify([application?.applicationGeneration ?? null, extensionId, clientId]);
|
|
2849
|
+
const create = async (extensionId, clientId, options, application) => {
|
|
2850
|
+
if (application) assertCurrentApplication(application);
|
|
2851
|
+
if (!Number.isSafeInteger(clientId) || clientId < 1 || !Array.isArray(options?.roots) || options.roots.length === 0 || options.recursive !== undefined && typeof options.recursive !== 'boolean' || options.roots.some(uri => typeof uri !== 'string' || !uri.startsWith('file://')) || options.exclude !== undefined && (!Array.isArray(options.exclude) || options.exclude.some(name => typeof name !== 'string'))) {
|
|
2852
|
+
throw new Error('File watchers require disk roots and a valid registration id');
|
|
2853
|
+
}
|
|
2854
|
+
// Application hosts can expose virtual disk paths through browser callbacks;
|
|
2855
|
+
// a host-process watch would observe a different filesystem for those URIs.
|
|
2856
|
+
if (application) throw new Error('Disk watchers are unavailable for application filesystem providers');
|
|
2857
|
+
const key = keyFor(extensionId, clientId, application);
|
|
2858
|
+
if (registrations.has(key)) throw new Error('File watcher is already registered');
|
|
2859
|
+
const registration = {
|
|
2860
|
+
application,
|
|
2861
|
+
clientId,
|
|
2862
|
+
disposed: false,
|
|
2863
|
+
extensionId,
|
|
2864
|
+
id: crypto.randomUUID()
|
|
2865
|
+
};
|
|
2866
|
+
registrations.set(key, registration);
|
|
2867
|
+
byId.set(registration.id, registration);
|
|
2868
|
+
try {
|
|
2869
|
+
await invoke$2('FileWatcher.watchExtension', registration.id, {
|
|
2870
|
+
...(options.recursive === false && {
|
|
2871
|
+
depth: 0
|
|
2872
|
+
}),
|
|
2873
|
+
exclude: options.exclude || [],
|
|
2874
|
+
roots: options.roots
|
|
2875
|
+
});
|
|
2876
|
+
if (registrations.get(key) !== registration || registration.disposed) throw new Error('File watcher was disposed during registration');
|
|
2877
|
+
} catch (error) {
|
|
2878
|
+
await dispose(extensionId, clientId, application);
|
|
2879
|
+
throw error;
|
|
2880
|
+
}
|
|
2881
|
+
};
|
|
2882
|
+
const dispose = async (extensionId, clientId, application) => {
|
|
2883
|
+
const key = keyFor(extensionId, clientId, application);
|
|
2884
|
+
const registration = registrations.get(key);
|
|
2885
|
+
if (!registration) return;
|
|
2886
|
+
registration.disposed = true;
|
|
2887
|
+
await invoke$2('FileWatcher.disposeExtension', registration.id);
|
|
2888
|
+
registrations.delete(key);
|
|
2889
|
+
byId.delete(registration.id);
|
|
2890
|
+
};
|
|
2891
|
+
const disposeOwner = async (extensionId, applicationId) => {
|
|
2892
|
+
const owned = registrations.values().filter(registration => registration.extensionId === extensionId && registration.application?.applicationId === applicationId).toArray();
|
|
2893
|
+
await Promise.all(owned.map(registration => dispose(extensionId, registration.clientId, registration.application)));
|
|
2894
|
+
};
|
|
2895
|
+
const handleEvent = async (id, event) => {
|
|
2896
|
+
const registration = byId.get(id);
|
|
2897
|
+
if (!registration || registration.disposed) return;
|
|
2898
|
+
const {
|
|
2899
|
+
application,
|
|
2900
|
+
clientId,
|
|
2901
|
+
extensionId
|
|
2902
|
+
} = registration;
|
|
2903
|
+
if (application) assertCurrentApplication(application);
|
|
2904
|
+
const rpc = get$2(extensionId, application?.applicationId);
|
|
2905
|
+
await rpc?.invoke('ExtensionApi.handleFileWatcherEvent', clientId, event);
|
|
2906
|
+
};
|
|
2907
|
+
|
|
2845
2908
|
const extensionIds = new Set();
|
|
2846
2909
|
const applications = new Map();
|
|
2847
2910
|
const register = (extensionId, applicationId) => {
|
|
@@ -3096,6 +3159,8 @@ const createExtensionCommandMap = (extensionId, invokeCommand = invokeGlobalComm
|
|
|
3096
3159
|
// callback (notifications, secrets, file watchers, or privileged node ports).
|
|
3097
3160
|
return {
|
|
3098
3161
|
...inheritedCommands,
|
|
3162
|
+
'Extensions.createFileSystemWatcher': (clientId, options) => invokeCommand('Extensions.createFileSystemWatcher', clientId, options),
|
|
3163
|
+
'Extensions.disposeFileSystemWatcher': clientId => invokeCommand('Extensions.disposeFileSystemWatcher', clientId),
|
|
3099
3164
|
'Extensions.executeCommand': (id, ...args) => executeCommand$1(invokeCommand, id, ...args),
|
|
3100
3165
|
'Extensions.getCacheFileHandle': name => invokeCommand('Extensions.getCacheFileHandle', name),
|
|
3101
3166
|
'Extensions.registerFileChangeHandler': () => invokeCommand('Extensions.registerFileChangeHandler'),
|
|
@@ -3105,6 +3170,9 @@ const createExtensionCommandMap = (extensionId, invokeCommand = invokeGlobalComm
|
|
|
3105
3170
|
}
|
|
3106
3171
|
return {
|
|
3107
3172
|
...inheritedCommands,
|
|
3173
|
+
'Extensions.createFileSystemWatcher'(clientId, options) {
|
|
3174
|
+
return create(extensionId, clientId, options);
|
|
3175
|
+
},
|
|
3108
3176
|
'Extensions.createNodeRpcConnection'(rpcId) {
|
|
3109
3177
|
return createNodeRpcConnection(extensionId, rpcId);
|
|
3110
3178
|
},
|
|
@@ -3114,6 +3182,9 @@ const createExtensionCommandMap = (extensionId, invokeCommand = invokeGlobalComm
|
|
|
3114
3182
|
'Extensions.deleteSecret'(key) {
|
|
3115
3183
|
return deleteSecret(extensionId, key);
|
|
3116
3184
|
},
|
|
3185
|
+
'Extensions.disposeFileSystemWatcher'(clientId) {
|
|
3186
|
+
return dispose(extensionId, clientId);
|
|
3187
|
+
},
|
|
3117
3188
|
'Extensions.executeCommand'(id, ...args) {
|
|
3118
3189
|
return executeCommand$1(invokeCommand, id, ...args);
|
|
3119
3190
|
},
|
|
@@ -3181,6 +3252,12 @@ const createIsolatedExtensionHostWorker = async (extensionId, absolutePath, work
|
|
|
3181
3252
|
if (method === 'Extensions.getCacheFileHandle') {
|
|
3182
3253
|
return getCacheFileHandle(extensionId, args[0]);
|
|
3183
3254
|
}
|
|
3255
|
+
if (method === 'Extensions.createFileSystemWatcher') {
|
|
3256
|
+
return create(extensionId, args[0], args[1], application);
|
|
3257
|
+
}
|
|
3258
|
+
if (method === 'Extensions.disposeFileSystemWatcher') {
|
|
3259
|
+
return dispose(extensionId, args[0], application);
|
|
3260
|
+
}
|
|
3184
3261
|
if (method === 'Extensions.registerFileChangeHandler') {
|
|
3185
3262
|
return register(extensionId, application.applicationId);
|
|
3186
3263
|
}
|
|
@@ -3215,7 +3292,7 @@ const createIsolatedExtensionHostWorker = async (extensionId, absolutePath, work
|
|
|
3215
3292
|
return bindCommandMap(rpc, commandMap);
|
|
3216
3293
|
};
|
|
3217
3294
|
const createWorker = (extensionId, absolutePath, workerName, contentSecurityPolicy, application) => {
|
|
3218
|
-
return createIsolatedExtensionHostWorker(extensionId, absolutePath, workerName, contentSecurityPolicy, create$
|
|
3295
|
+
return createIsolatedExtensionHostWorker(extensionId, absolutePath, workerName, contentSecurityPolicy, create$7, invokeAndTransfer, application);
|
|
3219
3296
|
};
|
|
3220
3297
|
const createAndStoreRpc = async (extensionId, absolutePath, workerName, contentSecurityPolicy, create, application) => {
|
|
3221
3298
|
try {
|
|
@@ -3571,20 +3648,16 @@ const disposeIsolatedExtensionHostWorker = async (extensionId, invoke = invoke$2
|
|
|
3571
3648
|
unregister(extensionId);
|
|
3572
3649
|
const rpc = remove$1(extensionId);
|
|
3573
3650
|
if (!rpc) {
|
|
3651
|
+
await disposeOwner(extensionId);
|
|
3574
3652
|
return false;
|
|
3575
3653
|
}
|
|
3576
3654
|
resetExtensionActivation(extensionId);
|
|
3577
3655
|
resetExtensionRuntimeState(extensionId);
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3581
|
-
|
|
3582
|
-
|
|
3583
|
-
try {
|
|
3584
|
-
await rpc.dispose();
|
|
3585
|
-
} catch {
|
|
3586
|
-
// The extension is already disabled and removed from state.
|
|
3587
|
-
}
|
|
3656
|
+
// Close all owned resources even if one backend fails during teardown.
|
|
3657
|
+
const [watchers] = await Promise.allSettled([disposeOwner(extensionId), Promise.try(() => invoke('LaunchIsolatedExtensionHostWorker.disposeIsolatedExtensionHostWorker', extensionId)), Promise.try(() => rpc.dispose())]);
|
|
3658
|
+
// Older renderers may not support worker disposal; watcher cleanup failures
|
|
3659
|
+
// still need to remain visible so their registrations can be retried.
|
|
3660
|
+
if (watchers.status === 'rejected') throw watchers.reason;
|
|
3588
3661
|
return true;
|
|
3589
3662
|
};
|
|
3590
3663
|
|
|
@@ -3699,7 +3772,7 @@ const disposeExtensionApplication = async applicationId => {
|
|
|
3699
3772
|
clear$1(applicationId);
|
|
3700
3773
|
resetAllExtensionActivations(application);
|
|
3701
3774
|
reset(applicationId);
|
|
3702
|
-
const results = await Promise.allSettled([dispose(application), ...runtimes.map(async ({
|
|
3775
|
+
const results = await Promise.allSettled([dispose$1(application), ...runtimes.map(async ({
|
|
3703
3776
|
id,
|
|
3704
3777
|
rpc
|
|
3705
3778
|
}) => {
|
|
@@ -5620,7 +5693,7 @@ const createWebViewIpc = async webView => {
|
|
|
5620
5693
|
port1,
|
|
5621
5694
|
port2
|
|
5622
5695
|
} = getPortTuple();
|
|
5623
|
-
const rpcPromise = create$
|
|
5696
|
+
const rpcPromise = create$3({
|
|
5624
5697
|
commandMap: {},
|
|
5625
5698
|
isMessagePortOpen: false,
|
|
5626
5699
|
messagePort: port2
|
|
@@ -6011,7 +6084,7 @@ const StatusBarWorker = 200;
|
|
|
6011
6084
|
const NotificationCenterWorker = 201;
|
|
6012
6085
|
|
|
6013
6086
|
const handleMessagePort = async (port, rpcId) => {
|
|
6014
|
-
const rpc = await create$
|
|
6087
|
+
const rpc = await create$8({
|
|
6015
6088
|
commandMap: commandMapRef,
|
|
6016
6089
|
messagePort: port
|
|
6017
6090
|
});
|
|
@@ -6027,7 +6100,7 @@ const handleViewContextChange = async (uid, viewId, context) => {
|
|
|
6027
6100
|
};
|
|
6028
6101
|
|
|
6029
6102
|
const defaultDependencies$4 = {
|
|
6030
|
-
createRpc: create$
|
|
6103
|
+
createRpc: create$6,
|
|
6031
6104
|
invokeRendererAndTransfer: invokeAndTransfer$1,
|
|
6032
6105
|
setMainProcess: set$8
|
|
6033
6106
|
};
|
|
@@ -6048,12 +6121,12 @@ const initializeMainProcess = async (platform, dependencies = defaultDependencie
|
|
|
6048
6121
|
};
|
|
6049
6122
|
|
|
6050
6123
|
const defaultDependencies$3 = {
|
|
6051
|
-
createLegacyWebSocketRpc: create$
|
|
6052
|
-
createTransferMessagePortRpc: create$
|
|
6124
|
+
createLegacyWebSocketRpc: create$4,
|
|
6125
|
+
createTransferMessagePortRpc: create$7,
|
|
6053
6126
|
createWebSocket(url, protocols) {
|
|
6054
6127
|
return new WebSocket(url, [...protocols]);
|
|
6055
6128
|
},
|
|
6056
|
-
createWebSocketRpc: create$
|
|
6129
|
+
createWebSocketRpc: create$5,
|
|
6057
6130
|
invokeRenderer: invoke$4,
|
|
6058
6131
|
sendMessagePortToSharedProcess: sendMessagePortToSharedProcess,
|
|
6059
6132
|
setSharedProcess: set$6
|
|
@@ -6615,6 +6688,7 @@ const commandMap = {
|
|
|
6615
6688
|
'Extensions.getWorkspaceTransportUri': getWorkspaceTransportUri,
|
|
6616
6689
|
'Extensions.handleData': handleData,
|
|
6617
6690
|
'Extensions.handleFileChanges': handleFileChanges,
|
|
6691
|
+
'Extensions.handleFileWatcherEvent': handleEvent,
|
|
6618
6692
|
'Extensions.handleLinkedExtensionChange': handleLinkedExtensionChange,
|
|
6619
6693
|
'Extensions.handleMessagePort': handleMessagePort,
|
|
6620
6694
|
'Extensions.handleUncaughtExtensionError': handleUncaughtExtensionError,
|
|
@@ -6647,7 +6721,7 @@ const commandMap = {
|
|
|
6647
6721
|
};
|
|
6648
6722
|
|
|
6649
6723
|
const initializeAuthWorker = async () => {
|
|
6650
|
-
const rpc = await create$
|
|
6724
|
+
const rpc = await create$6({
|
|
6651
6725
|
commandMap: commandMapRef,
|
|
6652
6726
|
async send(port) {
|
|
6653
6727
|
await sendMessagePortToAuthWorker(port, 0);
|
|
@@ -6657,7 +6731,7 @@ const initializeAuthWorker = async () => {
|
|
|
6657
6731
|
};
|
|
6658
6732
|
|
|
6659
6733
|
const initializeCacheWorker = async () => {
|
|
6660
|
-
const rpc = await create$
|
|
6734
|
+
const rpc = await create$6({
|
|
6661
6735
|
commandMap: commandMapRef,
|
|
6662
6736
|
async send(port) {
|
|
6663
6737
|
await invokeAndTransfer$1('SendMessagePortToExtensionHostWorker.sendMessagePortToCacheWorker', port);
|
|
@@ -6667,7 +6741,7 @@ const initializeCacheWorker = async () => {
|
|
|
6667
6741
|
};
|
|
6668
6742
|
|
|
6669
6743
|
const initializeErrorWorker = async () => {
|
|
6670
|
-
const rpc = await create$
|
|
6744
|
+
const rpc = await create$6({
|
|
6671
6745
|
commandMap: commandMapRef,
|
|
6672
6746
|
async send(port) {
|
|
6673
6747
|
await sendMessagePortToErrorWorker(port, 0);
|
|
@@ -6677,7 +6751,7 @@ const initializeErrorWorker = async () => {
|
|
|
6677
6751
|
};
|
|
6678
6752
|
|
|
6679
6753
|
const initializeFileSystemWorker = async () => {
|
|
6680
|
-
const rpc = await create$
|
|
6754
|
+
const rpc = await create$6({
|
|
6681
6755
|
commandMap: commandMapRef,
|
|
6682
6756
|
async send(port) {
|
|
6683
6757
|
await sendMessagePortToFileSystemWorker$1(port, 0);
|
|
@@ -6687,7 +6761,7 @@ const initializeFileSystemWorker = async () => {
|
|
|
6687
6761
|
};
|
|
6688
6762
|
|
|
6689
6763
|
const initializeIframeWorker = async () => {
|
|
6690
|
-
const rpc = await create$
|
|
6764
|
+
const rpc = await create$6({
|
|
6691
6765
|
commandMap: {},
|
|
6692
6766
|
async send(port) {
|
|
6693
6767
|
await sendMessagePortToIconThemeWorker(port, 0);
|
|
@@ -6697,7 +6771,7 @@ const initializeIframeWorker = async () => {
|
|
|
6697
6771
|
};
|
|
6698
6772
|
|
|
6699
6773
|
const initializeRendererWorker = async () => {
|
|
6700
|
-
const rpc = await create$
|
|
6774
|
+
const rpc = await create$2({
|
|
6701
6775
|
commandMap: commandMap
|
|
6702
6776
|
});
|
|
6703
6777
|
set$7(rpc);
|