tabby-rdp 0.6.1 → 0.6.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +34 -0
- package/README.md +16 -11
- package/bin/SHA256SUMS +8 -8
- package/bin/darwin-arm64/tabby-rdp-proxy +0 -0
- package/bin/darwin-x64/tabby-rdp-proxy +0 -0
- package/bin/linux-arm/tabby-rdp-proxy +0 -0
- package/bin/linux-arm64/tabby-rdp-proxy +0 -0
- package/bin/linux-x64/tabby-rdp-proxy +0 -0
- package/bin/win32-arm64/tabby-rdp-proxy.exe +0 -0
- package/bin/win32-x64/tabby-rdp-proxy.exe +0 -0
- package/dist/audio.js +26 -5
- package/dist/clipboard.js +8 -2
- package/dist/desktop.service.js +60 -14
- package/dist/desktopForm.js +1 -1
- package/dist/fileTransfer.js +41 -8
- package/dist/freerdp.js +36 -14
- package/dist/freerdpClipboard.js +39 -9
- package/dist/freerdpFiles.js +183 -0
- package/dist/freerdpView.js +6 -0
- package/dist/freerdpWasm.js +183 -0
- package/dist/freerdpWasmSocket.js +28 -0
- package/dist/freerdpWasmWorker.js +174 -0
- package/dist/pduTrace.js +27 -5
- package/dist/rdpClient.js +2 -2
- package/dist/rdpProfile.js +2 -2
- package/dist/settingsPage.js +6 -6
- package/dist/ui.js +2 -2
- package/dist/zgfx.js +33 -18
- package/native/README.md +74 -33
- package/package.json +6 -18
- package/vendor/SHA256SUMS +16 -5
- package/vendor/iron-remote-desktop-rdp.js +301 -301
- package/vendor/iron-remote-desktop.js +770 -736
- package/vendor/ironrdp-factory.js +301 -301
- package/vendor/ironrdp_web_bg.wasm +0 -0
- package/wasm/freerdp/BUILD.json +63 -0
- package/wasm/freerdp/licenses/Emscripten-LICENSE +102 -0
- package/wasm/freerdp/licenses/FreeRDP-LICENSE +202 -0
- package/wasm/freerdp/licenses/FreeRDP-NOTICE +13 -0
- package/wasm/freerdp/licenses/LibreSSL-LICENSE +133 -0
- package/wasm/freerdp/licenses/Unicode-NOTICE +21 -0
- package/wasm/freerdp/licenses/zlib-LICENSE +22 -0
- package/wasm/freerdp/tabby-freerdp.js +2 -0
- package/wasm/freerdp/tabby-freerdp.wasm +0 -0
|
@@ -19,7 +19,7 @@ class d {
|
|
|
19
19
|
* @param {Uint8Array} binary
|
|
20
20
|
*/
|
|
21
21
|
addBinary(A, I) {
|
|
22
|
-
const g =
|
|
22
|
+
const g = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), B = R, E = bA(I, C.__wbindgen_malloc), D = R;
|
|
23
23
|
C.clipboarddata_addBinary(this.__wbg_ptr, g, B, E, D);
|
|
24
24
|
}
|
|
25
25
|
/**
|
|
@@ -27,7 +27,7 @@ class d {
|
|
|
27
27
|
* @param {string} text
|
|
28
28
|
*/
|
|
29
29
|
addText(A, I) {
|
|
30
|
-
const g =
|
|
30
|
+
const g = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), B = R, E = F(I, C.__wbindgen_malloc, C.__wbindgen_realloc), D = R;
|
|
31
31
|
C.clipboarddata_addText(this.__wbg_ptr, g, B, E, D);
|
|
32
32
|
}
|
|
33
33
|
constructor() {
|
|
@@ -45,7 +45,7 @@ class d {
|
|
|
45
45
|
*/
|
|
46
46
|
items() {
|
|
47
47
|
const A = C.clipboarddata_items(this.__wbg_ptr);
|
|
48
|
-
var I =
|
|
48
|
+
var I = lA(A[0], A[1]).slice();
|
|
49
49
|
return C.__wbindgen_free(A[0], A[1] * 4, 4), I;
|
|
50
50
|
}
|
|
51
51
|
}
|
|
@@ -70,7 +70,7 @@ class n {
|
|
|
70
70
|
let A, I;
|
|
71
71
|
try {
|
|
72
72
|
const g = C.clipboarditem_mimeType(this.__wbg_ptr);
|
|
73
|
-
return A = g[0], I = g[1],
|
|
73
|
+
return A = g[0], I = g[1], Y(g[0], g[1]);
|
|
74
74
|
} finally {
|
|
75
75
|
C.__wbindgen_free(A, I, 1);
|
|
76
76
|
}
|
|
@@ -130,9 +130,9 @@ class V {
|
|
|
130
130
|
}
|
|
131
131
|
}
|
|
132
132
|
Symbol.dispose && (V.prototype[Symbol.dispose] = V.prototype.free);
|
|
133
|
-
class
|
|
133
|
+
class h {
|
|
134
134
|
static __wrap(A) {
|
|
135
|
-
const I = Object.create(
|
|
135
|
+
const I = Object.create(h.prototype);
|
|
136
136
|
return I.__wbg_ptr = A, GA.register(I, I.__wbg_ptr, I), I;
|
|
137
137
|
}
|
|
138
138
|
__destroy_into_raw() {
|
|
@@ -149,7 +149,7 @@ class c {
|
|
|
149
149
|
*/
|
|
150
150
|
static keyPressed(A) {
|
|
151
151
|
const I = C.deviceevent_keyPressed(A);
|
|
152
|
-
return
|
|
152
|
+
return h.__wrap(I);
|
|
153
153
|
}
|
|
154
154
|
/**
|
|
155
155
|
* @param {number} scancode
|
|
@@ -157,7 +157,7 @@ class c {
|
|
|
157
157
|
*/
|
|
158
158
|
static keyReleased(A) {
|
|
159
159
|
const I = C.deviceevent_keyReleased(A);
|
|
160
|
-
return
|
|
160
|
+
return h.__wrap(I);
|
|
161
161
|
}
|
|
162
162
|
/**
|
|
163
163
|
* @param {number} button
|
|
@@ -165,7 +165,7 @@ class c {
|
|
|
165
165
|
*/
|
|
166
166
|
static mouseButtonPressed(A) {
|
|
167
167
|
const I = C.deviceevent_mouseButtonPressed(A);
|
|
168
|
-
return
|
|
168
|
+
return h.__wrap(I);
|
|
169
169
|
}
|
|
170
170
|
/**
|
|
171
171
|
* @param {number} button
|
|
@@ -173,7 +173,7 @@ class c {
|
|
|
173
173
|
*/
|
|
174
174
|
static mouseButtonReleased(A) {
|
|
175
175
|
const I = C.deviceevent_mouseButtonReleased(A);
|
|
176
|
-
return
|
|
176
|
+
return h.__wrap(I);
|
|
177
177
|
}
|
|
178
178
|
/**
|
|
179
179
|
* @param {number} x
|
|
@@ -182,7 +182,7 @@ class c {
|
|
|
182
182
|
*/
|
|
183
183
|
static mouseMove(A, I) {
|
|
184
184
|
const g = C.deviceevent_mouseMove(A, I);
|
|
185
|
-
return
|
|
185
|
+
return h.__wrap(g);
|
|
186
186
|
}
|
|
187
187
|
/**
|
|
188
188
|
* @param {string} unicode
|
|
@@ -190,9 +190,9 @@ class c {
|
|
|
190
190
|
*/
|
|
191
191
|
static unicodePressed(A) {
|
|
192
192
|
const I = A.codePointAt(0);
|
|
193
|
-
|
|
193
|
+
yA(I);
|
|
194
194
|
const g = C.deviceevent_unicodePressed(I);
|
|
195
|
-
return
|
|
195
|
+
return h.__wrap(g);
|
|
196
196
|
}
|
|
197
197
|
/**
|
|
198
198
|
* @param {string} unicode
|
|
@@ -200,9 +200,9 @@ class c {
|
|
|
200
200
|
*/
|
|
201
201
|
static unicodeReleased(A) {
|
|
202
202
|
const I = A.codePointAt(0);
|
|
203
|
-
|
|
203
|
+
yA(I);
|
|
204
204
|
const g = C.deviceevent_unicodeReleased(I);
|
|
205
|
-
return
|
|
205
|
+
return h.__wrap(g);
|
|
206
206
|
}
|
|
207
207
|
/**
|
|
208
208
|
* @param {boolean} vertical
|
|
@@ -212,10 +212,10 @@ class c {
|
|
|
212
212
|
*/
|
|
213
213
|
static wheelRotations(A, I, g) {
|
|
214
214
|
const B = C.deviceevent_wheelRotations(A, I, g);
|
|
215
|
-
return
|
|
215
|
+
return h.__wrap(B);
|
|
216
216
|
}
|
|
217
217
|
}
|
|
218
|
-
Symbol.dispose && (
|
|
218
|
+
Symbol.dispose && (h.prototype[Symbol.dispose] = h.prototype.free);
|
|
219
219
|
class k {
|
|
220
220
|
__destroy_into_raw() {
|
|
221
221
|
const A = this.__wbg_ptr;
|
|
@@ -230,7 +230,7 @@ class k {
|
|
|
230
230
|
* @param {any} value
|
|
231
231
|
*/
|
|
232
232
|
constructor(A, I) {
|
|
233
|
-
const g =
|
|
233
|
+
const g = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), B = R, E = C.extension_create(g, B, I);
|
|
234
234
|
return this.__wbg_ptr = E, oA.register(this, this.__wbg_ptr, this), this;
|
|
235
235
|
}
|
|
236
236
|
}
|
|
@@ -248,7 +248,7 @@ class _ {
|
|
|
248
248
|
* @param {DeviceEvent} event
|
|
249
249
|
*/
|
|
250
250
|
addEvent(A) {
|
|
251
|
-
t(A,
|
|
251
|
+
t(A, h);
|
|
252
252
|
var I = A.__destroy_into_raw();
|
|
253
253
|
C.inputtransaction_addEvent(this.__wbg_ptr, I);
|
|
254
254
|
}
|
|
@@ -258,9 +258,9 @@ class _ {
|
|
|
258
258
|
}
|
|
259
259
|
}
|
|
260
260
|
Symbol.dispose && (_.prototype[Symbol.dispose] = _.prototype.free);
|
|
261
|
-
class
|
|
261
|
+
class z {
|
|
262
262
|
static __wrap(A) {
|
|
263
|
-
const I = Object.create(
|
|
263
|
+
const I = Object.create(z.prototype);
|
|
264
264
|
return I.__wbg_ptr = A, kA.register(I, I.__wbg_ptr, I), I;
|
|
265
265
|
}
|
|
266
266
|
__destroy_into_raw() {
|
|
@@ -278,7 +278,7 @@ class r {
|
|
|
278
278
|
let A, I;
|
|
279
279
|
try {
|
|
280
280
|
const g = C.ironerror_backtrace(this.__wbg_ptr);
|
|
281
|
-
return A = g[0], I = g[1],
|
|
281
|
+
return A = g[0], I = g[1], Y(g[0], g[1]);
|
|
282
282
|
} finally {
|
|
283
283
|
C.__wbindgen_free(A, I, 1);
|
|
284
284
|
}
|
|
@@ -294,18 +294,18 @@ class r {
|
|
|
294
294
|
*/
|
|
295
295
|
rdcleanpathDetails() {
|
|
296
296
|
const A = C.ironerror_rdcleanpathDetails(this.__wbg_ptr);
|
|
297
|
-
return A === 0 ? void 0 :
|
|
297
|
+
return A === 0 ? void 0 : e.__wrap(A);
|
|
298
298
|
}
|
|
299
299
|
}
|
|
300
|
-
Symbol.dispose && (
|
|
301
|
-
class
|
|
300
|
+
Symbol.dispose && (z.prototype[Symbol.dispose] = z.prototype.free);
|
|
301
|
+
class e {
|
|
302
302
|
static __wrap(A) {
|
|
303
|
-
const I = Object.create(
|
|
304
|
-
return I.__wbg_ptr = A,
|
|
303
|
+
const I = Object.create(e.prototype);
|
|
304
|
+
return I.__wbg_ptr = A, RA.register(I, I.__wbg_ptr, I), I;
|
|
305
305
|
}
|
|
306
306
|
__destroy_into_raw() {
|
|
307
307
|
const A = this.__wbg_ptr;
|
|
308
|
-
return this.__wbg_ptr = 0,
|
|
308
|
+
return this.__wbg_ptr = 0, RA.unregister(this), A;
|
|
309
309
|
}
|
|
310
310
|
free() {
|
|
311
311
|
const A = this.__destroy_into_raw();
|
|
@@ -357,11 +357,11 @@ class z {
|
|
|
357
357
|
return A === 16777215 ? void 0 : A;
|
|
358
358
|
}
|
|
359
359
|
}
|
|
360
|
-
Symbol.dispose && (
|
|
360
|
+
Symbol.dispose && (e.prototype[Symbol.dispose] = e.prototype.free);
|
|
361
361
|
class iA {
|
|
362
362
|
__destroy_into_raw() {
|
|
363
363
|
const A = this.__wbg_ptr;
|
|
364
|
-
return this.__wbg_ptr = 0,
|
|
364
|
+
return this.__wbg_ptr = 0, FA.unregister(this), A;
|
|
365
365
|
}
|
|
366
366
|
free() {
|
|
367
367
|
const A = this.__destroy_into_raw();
|
|
@@ -369,14 +369,14 @@ class iA {
|
|
|
369
369
|
}
|
|
370
370
|
constructor() {
|
|
371
371
|
const A = C.rdpfile_create();
|
|
372
|
-
return this.__wbg_ptr = A,
|
|
372
|
+
return this.__wbg_ptr = A, FA.register(this, this.__wbg_ptr, this), this;
|
|
373
373
|
}
|
|
374
374
|
/**
|
|
375
375
|
* @param {string} key
|
|
376
376
|
* @returns {number | undefined}
|
|
377
377
|
*/
|
|
378
378
|
getInt(A) {
|
|
379
|
-
const I =
|
|
379
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R, B = C.rdpfile_getInt(this.__wbg_ptr, I, g);
|
|
380
380
|
return B === Number.MAX_SAFE_INTEGER ? void 0 : B;
|
|
381
381
|
}
|
|
382
382
|
/**
|
|
@@ -384,16 +384,16 @@ class iA {
|
|
|
384
384
|
* @returns {string | undefined}
|
|
385
385
|
*/
|
|
386
386
|
getStr(A) {
|
|
387
|
-
const I =
|
|
387
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R, B = C.rdpfile_getStr(this.__wbg_ptr, I, g);
|
|
388
388
|
let E;
|
|
389
|
-
return B[0] !== 0 && (E =
|
|
389
|
+
return B[0] !== 0 && (E = Y(B[0], B[1]).slice(), C.__wbindgen_free(B[0], B[1] * 1, 1)), E;
|
|
390
390
|
}
|
|
391
391
|
/**
|
|
392
392
|
* @param {string} key
|
|
393
393
|
* @param {number} value
|
|
394
394
|
*/
|
|
395
395
|
insertInt(A, I) {
|
|
396
|
-
const g =
|
|
396
|
+
const g = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), B = R;
|
|
397
397
|
C.rdpfile_insertInt(this.__wbg_ptr, g, B, I);
|
|
398
398
|
}
|
|
399
399
|
/**
|
|
@@ -401,14 +401,14 @@ class iA {
|
|
|
401
401
|
* @param {string} value
|
|
402
402
|
*/
|
|
403
403
|
insertStr(A, I) {
|
|
404
|
-
const g =
|
|
404
|
+
const g = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), B = R, E = F(I, C.__wbindgen_malloc, C.__wbindgen_realloc), D = R;
|
|
405
405
|
C.rdpfile_insertStr(this.__wbg_ptr, g, B, E, D);
|
|
406
406
|
}
|
|
407
407
|
/**
|
|
408
408
|
* @param {string} config
|
|
409
409
|
*/
|
|
410
410
|
parse(A) {
|
|
411
|
-
const I =
|
|
411
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R;
|
|
412
412
|
C.rdpfile_parse(this.__wbg_ptr, I, g);
|
|
413
413
|
}
|
|
414
414
|
/**
|
|
@@ -418,21 +418,21 @@ class iA {
|
|
|
418
418
|
let A, I;
|
|
419
419
|
try {
|
|
420
420
|
const g = C.rdpfile_write(this.__wbg_ptr);
|
|
421
|
-
return A = g[0], I = g[1],
|
|
421
|
+
return A = g[0], I = g[1], Y(g[0], g[1]);
|
|
422
422
|
} finally {
|
|
423
423
|
C.__wbindgen_free(A, I, 1);
|
|
424
424
|
}
|
|
425
425
|
}
|
|
426
426
|
}
|
|
427
427
|
Symbol.dispose && (iA.prototype[Symbol.dispose] = iA.prototype.free);
|
|
428
|
-
class
|
|
428
|
+
class r {
|
|
429
429
|
static __wrap(A) {
|
|
430
|
-
const I = Object.create(
|
|
431
|
-
return I.__wbg_ptr = A,
|
|
430
|
+
const I = Object.create(r.prototype);
|
|
431
|
+
return I.__wbg_ptr = A, YA.register(I, I.__wbg_ptr, I), I;
|
|
432
432
|
}
|
|
433
433
|
__destroy_into_raw() {
|
|
434
434
|
const A = this.__wbg_ptr;
|
|
435
|
-
return this.__wbg_ptr = 0,
|
|
435
|
+
return this.__wbg_ptr = 0, YA.unregister(this), A;
|
|
436
436
|
}
|
|
437
437
|
free() {
|
|
438
438
|
const A = this.__destroy_into_raw();
|
|
@@ -446,7 +446,7 @@ class P {
|
|
|
446
446
|
var I = A.__destroy_into_raw();
|
|
447
447
|
const g = C.session_applyInputs(this.__wbg_ptr, I);
|
|
448
448
|
if (g[1])
|
|
449
|
-
throw
|
|
449
|
+
throw Z(g[0]);
|
|
450
450
|
}
|
|
451
451
|
/**
|
|
452
452
|
* @returns {DesktopSize}
|
|
@@ -464,8 +464,8 @@ class P {
|
|
|
464
464
|
var I = A.__destroy_into_raw();
|
|
465
465
|
const g = C.session_invokeExtension(this.__wbg_ptr, I);
|
|
466
466
|
if (g[2])
|
|
467
|
-
throw
|
|
468
|
-
return
|
|
467
|
+
throw Z(g[1]);
|
|
468
|
+
return Z(g[0]);
|
|
469
469
|
}
|
|
470
470
|
/**
|
|
471
471
|
* @param {ClipboardData} content
|
|
@@ -477,7 +477,7 @@ class P {
|
|
|
477
477
|
releaseAllInputs() {
|
|
478
478
|
const A = C.session_releaseAllInputs(this.__wbg_ptr);
|
|
479
479
|
if (A[1])
|
|
480
|
-
throw
|
|
480
|
+
throw Z(A[0]);
|
|
481
481
|
}
|
|
482
482
|
/**
|
|
483
483
|
* @param {number} width
|
|
@@ -487,7 +487,7 @@ class P {
|
|
|
487
487
|
* @param {number | null} [physical_height]
|
|
488
488
|
*/
|
|
489
489
|
resize(A, I, g, B, E) {
|
|
490
|
-
C.session_resize(this.__wbg_ptr, A, I,
|
|
490
|
+
C.session_resize(this.__wbg_ptr, A, I, S(g) ? Number.MAX_SAFE_INTEGER : g >>> 0, S(B) ? Number.MAX_SAFE_INTEGER : B >>> 0, S(E) ? Number.MAX_SAFE_INTEGER : E >>> 0);
|
|
491
491
|
}
|
|
492
492
|
/**
|
|
493
493
|
* @returns {Promise<SessionTerminationInfo>}
|
|
@@ -498,7 +498,7 @@ class P {
|
|
|
498
498
|
shutdown() {
|
|
499
499
|
const A = C.session_shutdown(this.__wbg_ptr);
|
|
500
500
|
if (A[1])
|
|
501
|
-
throw
|
|
501
|
+
throw Z(A[0]);
|
|
502
502
|
}
|
|
503
503
|
/**
|
|
504
504
|
* @returns {boolean}
|
|
@@ -515,13 +515,13 @@ class P {
|
|
|
515
515
|
synchronizeLockKeys(A, I, g, B) {
|
|
516
516
|
const E = C.session_synchronizeLockKeys(this.__wbg_ptr, A, I, g, B);
|
|
517
517
|
if (E[1])
|
|
518
|
-
throw
|
|
518
|
+
throw Z(E[0]);
|
|
519
519
|
}
|
|
520
520
|
}
|
|
521
|
-
Symbol.dispose && (
|
|
522
|
-
class
|
|
521
|
+
Symbol.dispose && (r.prototype[Symbol.dispose] = r.prototype.free);
|
|
522
|
+
class J {
|
|
523
523
|
static __wrap(A) {
|
|
524
|
-
const I = Object.create(
|
|
524
|
+
const I = Object.create(J.prototype);
|
|
525
525
|
return I.__wbg_ptr = A, IA.register(I, I.__wbg_ptr, I), I;
|
|
526
526
|
}
|
|
527
527
|
__destroy_into_raw() {
|
|
@@ -537,8 +537,8 @@ class U {
|
|
|
537
537
|
* @returns {SessionBuilder}
|
|
538
538
|
*/
|
|
539
539
|
authToken(A) {
|
|
540
|
-
const I =
|
|
541
|
-
return
|
|
540
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R, B = C.sessionbuilder_authToken(this.__wbg_ptr, I, g);
|
|
541
|
+
return J.__wrap(B);
|
|
542
542
|
}
|
|
543
543
|
/**
|
|
544
544
|
* @param {Function} callback
|
|
@@ -546,7 +546,7 @@ class U {
|
|
|
546
546
|
*/
|
|
547
547
|
canvasResizedCallback(A) {
|
|
548
548
|
const I = C.sessionbuilder_canvasResizedCallback(this.__wbg_ptr, A);
|
|
549
|
-
return
|
|
549
|
+
return J.__wrap(I);
|
|
550
550
|
}
|
|
551
551
|
/**
|
|
552
552
|
* @returns {Promise<Session>}
|
|
@@ -566,15 +566,15 @@ class U {
|
|
|
566
566
|
t(A, V);
|
|
567
567
|
var I = A.__destroy_into_raw();
|
|
568
568
|
const g = C.sessionbuilder_desktopSize(this.__wbg_ptr, I);
|
|
569
|
-
return
|
|
569
|
+
return J.__wrap(g);
|
|
570
570
|
}
|
|
571
571
|
/**
|
|
572
572
|
* @param {string} destination
|
|
573
573
|
* @returns {SessionBuilder}
|
|
574
574
|
*/
|
|
575
575
|
destination(A) {
|
|
576
|
-
const I =
|
|
577
|
-
return
|
|
576
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R, B = C.sessionbuilder_destination(this.__wbg_ptr, I, g);
|
|
577
|
+
return J.__wrap(B);
|
|
578
578
|
}
|
|
579
579
|
/**
|
|
580
580
|
* @param {Extension} ext
|
|
@@ -584,7 +584,7 @@ class U {
|
|
|
584
584
|
t(A, k);
|
|
585
585
|
var I = A.__destroy_into_raw();
|
|
586
586
|
const g = C.sessionbuilder_extension(this.__wbg_ptr, I);
|
|
587
|
-
return
|
|
587
|
+
return J.__wrap(g);
|
|
588
588
|
}
|
|
589
589
|
/**
|
|
590
590
|
* @param {Function} callback
|
|
@@ -592,23 +592,23 @@ class U {
|
|
|
592
592
|
*/
|
|
593
593
|
forceClipboardUpdateCallback(A) {
|
|
594
594
|
const I = C.sessionbuilder_forceClipboardUpdateCallback(this.__wbg_ptr, A);
|
|
595
|
-
return
|
|
595
|
+
return J.__wrap(I);
|
|
596
596
|
}
|
|
597
597
|
/**
|
|
598
598
|
* @param {string} password
|
|
599
599
|
* @returns {SessionBuilder}
|
|
600
600
|
*/
|
|
601
601
|
password(A) {
|
|
602
|
-
const I =
|
|
603
|
-
return
|
|
602
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R, B = C.sessionbuilder_password(this.__wbg_ptr, I, g);
|
|
603
|
+
return J.__wrap(B);
|
|
604
604
|
}
|
|
605
605
|
/**
|
|
606
606
|
* @param {string} address
|
|
607
607
|
* @returns {SessionBuilder}
|
|
608
608
|
*/
|
|
609
609
|
proxyAddress(A) {
|
|
610
|
-
const I =
|
|
611
|
-
return
|
|
610
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R, B = C.sessionbuilder_proxyAddress(this.__wbg_ptr, I, g);
|
|
611
|
+
return J.__wrap(B);
|
|
612
612
|
}
|
|
613
613
|
/**
|
|
614
614
|
* @param {Function} callback
|
|
@@ -616,7 +616,7 @@ class U {
|
|
|
616
616
|
*/
|
|
617
617
|
remoteClipboardChangedCallback(A) {
|
|
618
618
|
const I = C.sessionbuilder_remoteClipboardChangedCallback(this.__wbg_ptr, A);
|
|
619
|
-
return
|
|
619
|
+
return J.__wrap(I);
|
|
620
620
|
}
|
|
621
621
|
/**
|
|
622
622
|
* @param {HTMLCanvasElement} canvas
|
|
@@ -624,15 +624,15 @@ class U {
|
|
|
624
624
|
*/
|
|
625
625
|
renderCanvas(A) {
|
|
626
626
|
const I = C.sessionbuilder_renderCanvas(this.__wbg_ptr, A);
|
|
627
|
-
return
|
|
627
|
+
return J.__wrap(I);
|
|
628
628
|
}
|
|
629
629
|
/**
|
|
630
630
|
* @param {string} server_domain
|
|
631
631
|
* @returns {SessionBuilder}
|
|
632
632
|
*/
|
|
633
633
|
serverDomain(A) {
|
|
634
|
-
const I =
|
|
635
|
-
return
|
|
634
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R, B = C.sessionbuilder_serverDomain(this.__wbg_ptr, I, g);
|
|
635
|
+
return J.__wrap(B);
|
|
636
636
|
}
|
|
637
637
|
/**
|
|
638
638
|
* @param {Function} callback
|
|
@@ -640,7 +640,7 @@ class U {
|
|
|
640
640
|
*/
|
|
641
641
|
setCursorStyleCallback(A) {
|
|
642
642
|
const I = C.sessionbuilder_setCursorStyleCallback(this.__wbg_ptr, A);
|
|
643
|
-
return
|
|
643
|
+
return J.__wrap(I);
|
|
644
644
|
}
|
|
645
645
|
/**
|
|
646
646
|
* @param {any} context
|
|
@@ -648,21 +648,21 @@ class U {
|
|
|
648
648
|
*/
|
|
649
649
|
setCursorStyleCallbackContext(A) {
|
|
650
650
|
const I = C.sessionbuilder_setCursorStyleCallbackContext(this.__wbg_ptr, A);
|
|
651
|
-
return
|
|
651
|
+
return J.__wrap(I);
|
|
652
652
|
}
|
|
653
653
|
/**
|
|
654
654
|
* @param {string} username
|
|
655
655
|
* @returns {SessionBuilder}
|
|
656
656
|
*/
|
|
657
657
|
username(A) {
|
|
658
|
-
const I =
|
|
659
|
-
return
|
|
658
|
+
const I = F(A, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R, B = C.sessionbuilder_username(this.__wbg_ptr, I, g);
|
|
659
|
+
return J.__wrap(B);
|
|
660
660
|
}
|
|
661
661
|
}
|
|
662
|
-
Symbol.dispose && (
|
|
663
|
-
class
|
|
662
|
+
Symbol.dispose && (J.prototype[Symbol.dispose] = J.prototype.free);
|
|
663
|
+
class P {
|
|
664
664
|
static __wrap(A) {
|
|
665
|
-
const I = Object.create(
|
|
665
|
+
const I = Object.create(P.prototype);
|
|
666
666
|
return I.__wbg_ptr = A, MA.register(I, I.__wbg_ptr, I), I;
|
|
667
667
|
}
|
|
668
668
|
__destroy_into_raw() {
|
|
@@ -680,28 +680,28 @@ class v {
|
|
|
680
680
|
let A, I;
|
|
681
681
|
try {
|
|
682
682
|
const g = C.sessionterminationinfo_reason(this.__wbg_ptr);
|
|
683
|
-
return A = g[0], I = g[1],
|
|
683
|
+
return A = g[0], I = g[1], Y(g[0], g[1]);
|
|
684
684
|
} finally {
|
|
685
685
|
C.__wbindgen_free(A, I, 1);
|
|
686
686
|
}
|
|
687
687
|
}
|
|
688
688
|
}
|
|
689
|
-
Symbol.dispose && (
|
|
690
|
-
function
|
|
691
|
-
const I =
|
|
689
|
+
Symbol.dispose && (P.prototype[Symbol.dispose] = P.prototype.free);
|
|
690
|
+
function hA(Q, A) {
|
|
691
|
+
const I = F(Q, C.__wbindgen_malloc, C.__wbindgen_realloc), g = R;
|
|
692
692
|
C.setup(I, g, A);
|
|
693
693
|
}
|
|
694
|
-
function
|
|
694
|
+
function aA() {
|
|
695
695
|
return {
|
|
696
696
|
__proto__: null,
|
|
697
697
|
"./ironrdp_web_bg.js": {
|
|
698
698
|
__proto__: null,
|
|
699
699
|
__wbg___wbindgen_boolean_get_fa956cfa2d1bd751: function(A) {
|
|
700
700
|
const I = A, g = typeof I == "boolean" ? I : void 0;
|
|
701
|
-
return
|
|
701
|
+
return S(g) ? 16777215 : g ? 1 : 0;
|
|
702
702
|
},
|
|
703
703
|
__wbg___wbindgen_debug_string_c25d447a39f5578f: function(A, I) {
|
|
704
|
-
const g = QA(I), B =
|
|
704
|
+
const g = QA(I), B = F(g, C.__wbindgen_malloc, C.__wbindgen_realloc), E = R;
|
|
705
705
|
M().setInt32(A + 4, E, true), M().setInt32(A + 0, B, true);
|
|
706
706
|
},
|
|
707
707
|
__wbg___wbindgen_is_function_1ff95bcc5517c252: function(A) {
|
|
@@ -722,27 +722,27 @@ function SA() {
|
|
|
722
722
|
},
|
|
723
723
|
__wbg___wbindgen_number_get_394265ed1e1b84ee: function(A, I) {
|
|
724
724
|
const g = I, B = typeof g == "number" ? g : void 0;
|
|
725
|
-
M().setFloat64(A + 8,
|
|
725
|
+
M().setFloat64(A + 8, S(B) ? 0 : B, true), M().setInt32(A + 0, !S(B), true);
|
|
726
726
|
},
|
|
727
727
|
__wbg___wbindgen_string_get_b0ca35b86a603356: function(A, I) {
|
|
728
728
|
const g = I, B = typeof g == "string" ? g : void 0;
|
|
729
|
-
var E =
|
|
729
|
+
var E = S(B) ? 0 : F(B, C.__wbindgen_malloc, C.__wbindgen_realloc), D = R;
|
|
730
730
|
M().setInt32(A + 4, D, true), M().setInt32(A + 0, E, true);
|
|
731
731
|
},
|
|
732
732
|
__wbg___wbindgen_throw_344f42d3211c4765: function(A, I) {
|
|
733
|
-
throw new Error(
|
|
733
|
+
throw new Error(Y(A, I));
|
|
734
734
|
},
|
|
735
735
|
__wbg__wbg_cb_unref_fffb441def202758: function(A) {
|
|
736
736
|
A._wbg_cb_unref();
|
|
737
737
|
},
|
|
738
738
|
__wbg_addEventListener_520e749bbae24529: function() {
|
|
739
739
|
return o(function(A, I, g, B, E) {
|
|
740
|
-
A.addEventListener(
|
|
740
|
+
A.addEventListener(Y(I, g), B, E);
|
|
741
741
|
}, arguments);
|
|
742
742
|
},
|
|
743
743
|
__wbg_addEventListener_d85450ee1320c989: function() {
|
|
744
744
|
return o(function(A, I, g, B) {
|
|
745
|
-
A.addEventListener(
|
|
745
|
+
A.addEventListener(Y(I, g), B);
|
|
746
746
|
}, arguments);
|
|
747
747
|
},
|
|
748
748
|
__wbg_apply_23dd4d2439189415: function() {
|
|
@@ -812,7 +812,7 @@ function SA() {
|
|
|
812
812
|
__wbg_error_a6fa202b58aa1cd3: function(A, I) {
|
|
813
813
|
let g, B;
|
|
814
814
|
try {
|
|
815
|
-
g = A, B = I, console.error(
|
|
815
|
+
g = A, B = I, console.error(Y(A, I));
|
|
816
816
|
} finally {
|
|
817
817
|
C.__wbindgen_free(g, B, 1);
|
|
818
818
|
}
|
|
@@ -825,23 +825,23 @@ function SA() {
|
|
|
825
825
|
},
|
|
826
826
|
__wbg_getContext_e79ddf6a9cb3cc76: function() {
|
|
827
827
|
return o(function(A, I, g) {
|
|
828
|
-
const B = A.getContext(
|
|
829
|
-
return
|
|
828
|
+
const B = A.getContext(Y(I, g));
|
|
829
|
+
return S(B) ? 0 : q(B);
|
|
830
830
|
}, arguments);
|
|
831
831
|
},
|
|
832
832
|
__wbg_getRandomValues_3f44b700395062e5: function() {
|
|
833
833
|
return o(function(A, I) {
|
|
834
|
-
globalThis.crypto.getRandomValues(
|
|
834
|
+
globalThis.crypto.getRandomValues(b(A, I));
|
|
835
835
|
}, arguments);
|
|
836
836
|
},
|
|
837
837
|
__wbg_getRandomValues_bf16787eede473f5: function() {
|
|
838
838
|
return o(function(A, I) {
|
|
839
|
-
globalThis.crypto.getRandomValues(
|
|
839
|
+
globalThis.crypto.getRandomValues(b(A, I));
|
|
840
840
|
}, arguments);
|
|
841
841
|
},
|
|
842
842
|
__wbg_getRandomValues_cc7f052a444bb2ce: function() {
|
|
843
843
|
return o(function(A, I) {
|
|
844
|
-
globalThis.crypto.getRandomValues(
|
|
844
|
+
globalThis.crypto.getRandomValues(b(A, I));
|
|
845
845
|
}, arguments);
|
|
846
846
|
},
|
|
847
847
|
__wbg_getTime_d6f070c088c9b5ed: function(A) {
|
|
@@ -928,7 +928,7 @@ function SA() {
|
|
|
928
928
|
return I;
|
|
929
929
|
},
|
|
930
930
|
__wbg_ironerror_new: function(A) {
|
|
931
|
-
return
|
|
931
|
+
return z.__wrap(A);
|
|
932
932
|
},
|
|
933
933
|
__wbg_isArray_0677c962b281d01a: function(A) {
|
|
934
934
|
return Array.isArray(A);
|
|
@@ -950,7 +950,7 @@ function SA() {
|
|
|
950
950
|
},
|
|
951
951
|
__wbg_new_08cb2fa678b17a48: function() {
|
|
952
952
|
return o(function(A, I) {
|
|
953
|
-
return new URL(
|
|
953
|
+
return new URL(Y(A, I));
|
|
954
954
|
}, arguments);
|
|
955
955
|
},
|
|
956
956
|
__wbg_new_0_3da9e97f24fc69be: function() {
|
|
@@ -969,7 +969,7 @@ function SA() {
|
|
|
969
969
|
},
|
|
970
970
|
__wbg_new_bf8729ffe10e9ee7: function() {
|
|
971
971
|
return o(function(A, I) {
|
|
972
|
-
return new WebSocket(
|
|
972
|
+
return new WebSocket(Y(A, I));
|
|
973
973
|
}, arguments);
|
|
974
974
|
},
|
|
975
975
|
__wbg_new_cd45aabdf6073e84: function(A) {
|
|
@@ -984,10 +984,10 @@ function SA() {
|
|
|
984
984
|
}, arguments);
|
|
985
985
|
},
|
|
986
986
|
__wbg_new_from_slice_7568ba55b4a7e81f: function(A, I) {
|
|
987
|
-
return new Uint32Array(
|
|
987
|
+
return new Uint32Array(WA(A, I));
|
|
988
988
|
},
|
|
989
989
|
__wbg_new_from_slice_77cdfb7977362f3c: function(A, I) {
|
|
990
|
-
return new Uint8Array(
|
|
990
|
+
return new Uint8Array(b(A, I));
|
|
991
991
|
},
|
|
992
992
|
__wbg_new_typed_1824d93f294193e5: function(A, I) {
|
|
993
993
|
try {
|
|
@@ -995,7 +995,7 @@ function SA() {
|
|
|
995
995
|
const w = g.a;
|
|
996
996
|
g.a = 0;
|
|
997
997
|
try {
|
|
998
|
-
return
|
|
998
|
+
return ZA(w, g.b, D, i);
|
|
999
999
|
} finally {
|
|
1000
1000
|
g.a = w;
|
|
1001
1001
|
}
|
|
@@ -1007,17 +1007,17 @@ function SA() {
|
|
|
1007
1007
|
},
|
|
1008
1008
|
__wbg_new_with_event_init_dict_7b62c0f9fb241877: function() {
|
|
1009
1009
|
return o(function(A, I, g) {
|
|
1010
|
-
return new CloseEvent(
|
|
1010
|
+
return new CloseEvent(Y(A, I), g);
|
|
1011
1011
|
}, arguments);
|
|
1012
1012
|
},
|
|
1013
1013
|
__wbg_new_with_str_54bc0f9c32770e1e: function() {
|
|
1014
1014
|
return o(function(A, I) {
|
|
1015
|
-
return new Request(
|
|
1015
|
+
return new Request(Y(A, I));
|
|
1016
1016
|
}, arguments);
|
|
1017
1017
|
},
|
|
1018
1018
|
__wbg_new_with_str_and_init_d95cbe11ce28e65e: function() {
|
|
1019
1019
|
return o(function(A, I, g) {
|
|
1020
|
-
return new Request(
|
|
1020
|
+
return new Request(Y(A, I), g);
|
|
1021
1021
|
}, arguments);
|
|
1022
1022
|
},
|
|
1023
1023
|
__wbg_new_with_u8_array_sequence_bdda73b0f202f149: function() {
|
|
@@ -1047,13 +1047,13 @@ function SA() {
|
|
|
1047
1047
|
},
|
|
1048
1048
|
__wbg_performance_3ef602e13d6c3b56: function(A) {
|
|
1049
1049
|
const I = A.performance;
|
|
1050
|
-
return
|
|
1050
|
+
return S(I) ? 0 : q(I);
|
|
1051
1051
|
},
|
|
1052
1052
|
__wbg_performance_3fcf6e32a7e1ed0a: function(A) {
|
|
1053
1053
|
return A.performance;
|
|
1054
1054
|
},
|
|
1055
1055
|
__wbg_prototypesetcall_4770620bbe4688a0: function(A, I, g) {
|
|
1056
|
-
Uint8Array.prototype.set.call(
|
|
1056
|
+
Uint8Array.prototype.set.call(b(A, I), g);
|
|
1057
1057
|
},
|
|
1058
1058
|
__wbg_push_d2ae3af0c1217ae6: function(A, I) {
|
|
1059
1059
|
return A.push(I);
|
|
@@ -1073,19 +1073,19 @@ function SA() {
|
|
|
1073
1073
|
return A.readyState;
|
|
1074
1074
|
},
|
|
1075
1075
|
__wbg_reason_5dc8e429d537d6a9: function(A, I) {
|
|
1076
|
-
const g = I.reason, B =
|
|
1076
|
+
const g = I.reason, B = F(g, C.__wbindgen_malloc, C.__wbindgen_realloc), E = R;
|
|
1077
1077
|
M().setInt32(A + 4, E, true), M().setInt32(A + 0, B, true);
|
|
1078
1078
|
},
|
|
1079
1079
|
__wbg_removeEventListener_a3f23c70077bdcc1: function() {
|
|
1080
1080
|
return o(function(A, I, g, B) {
|
|
1081
|
-
A.removeEventListener(
|
|
1081
|
+
A.removeEventListener(Y(I, g), B);
|
|
1082
1082
|
}, arguments);
|
|
1083
1083
|
},
|
|
1084
1084
|
__wbg_resolve_2191a4dfe481c25b: function(A) {
|
|
1085
1085
|
return Promise.resolve(A);
|
|
1086
1086
|
},
|
|
1087
1087
|
__wbg_search_c905fb82fd20bc6b: function(A, I) {
|
|
1088
|
-
const g = I.search, B =
|
|
1088
|
+
const g = I.search, B = F(g, C.__wbindgen_malloc, C.__wbindgen_realloc), E = R;
|
|
1089
1089
|
M().setInt32(A + 4, E, true), M().setInt32(A + 0, B, true);
|
|
1090
1090
|
},
|
|
1091
1091
|
__wbg_send_1733c45567a373ff: function() {
|
|
@@ -1095,14 +1095,14 @@ function SA() {
|
|
|
1095
1095
|
},
|
|
1096
1096
|
__wbg_send_df98dd5ede9b3f4d: function() {
|
|
1097
1097
|
return o(function(A, I, g) {
|
|
1098
|
-
A.send(
|
|
1098
|
+
A.send(Y(I, g));
|
|
1099
1099
|
}, arguments);
|
|
1100
1100
|
},
|
|
1101
1101
|
__wbg_session_new: function(A) {
|
|
1102
|
-
return
|
|
1102
|
+
return r.__wrap(A);
|
|
1103
1103
|
},
|
|
1104
1104
|
__wbg_sessionterminationinfo_new: function(A) {
|
|
1105
|
-
return
|
|
1105
|
+
return P.__wrap(A);
|
|
1106
1106
|
},
|
|
1107
1107
|
__wbg_setInterval_cbf1c35c6a692d37: function() {
|
|
1108
1108
|
return o(function(A, I) {
|
|
@@ -1116,7 +1116,7 @@ function SA() {
|
|
|
1116
1116
|
},
|
|
1117
1117
|
__wbg_set_0de9c62c23d04ad5: function() {
|
|
1118
1118
|
return o(function(A, I, g, B, E) {
|
|
1119
|
-
A.set(
|
|
1119
|
+
A.set(Y(I, g), Y(B, E));
|
|
1120
1120
|
}, arguments);
|
|
1121
1121
|
},
|
|
1122
1122
|
__wbg_set_8535240470bf2500: function() {
|
|
@@ -1140,42 +1140,42 @@ function SA() {
|
|
|
1140
1140
|
A.height = I >>> 0;
|
|
1141
1141
|
},
|
|
1142
1142
|
__wbg_set_method_5532d59b92d76467: function(A, I, g) {
|
|
1143
|
-
A.method =
|
|
1143
|
+
A.method = Y(I, g);
|
|
1144
1144
|
},
|
|
1145
1145
|
__wbg_set_once_51a9fb6b8af8a72b: function(A, I) {
|
|
1146
1146
|
A.once = I !== 0;
|
|
1147
1147
|
},
|
|
1148
1148
|
__wbg_set_reason_18dc06ea0d60243b: function(A, I, g) {
|
|
1149
|
-
A.reason =
|
|
1149
|
+
A.reason = Y(I, g);
|
|
1150
1150
|
},
|
|
1151
1151
|
__wbg_set_search_f9700de567764208: function(A, I, g) {
|
|
1152
|
-
A.search =
|
|
1152
|
+
A.search = Y(I, g);
|
|
1153
1153
|
},
|
|
1154
1154
|
__wbg_set_width_8e30d010cd66830d: function(A, I) {
|
|
1155
1155
|
A.width = I >>> 0;
|
|
1156
1156
|
},
|
|
1157
1157
|
__wbg_stack_3b0d974bbf31e44f: function(A, I) {
|
|
1158
|
-
const g = I.stack, B =
|
|
1158
|
+
const g = I.stack, B = F(g, C.__wbindgen_malloc, C.__wbindgen_realloc), E = R;
|
|
1159
1159
|
M().setInt32(A + 4, E, true), M().setInt32(A + 0, B, true);
|
|
1160
1160
|
},
|
|
1161
1161
|
__wbg_static_accessor_GLOBAL_4ef717fb391d88b7: function() {
|
|
1162
1162
|
const A = typeof global > "u" ? null : global;
|
|
1163
|
-
return
|
|
1163
|
+
return S(A) ? 0 : q(A);
|
|
1164
1164
|
},
|
|
1165
1165
|
__wbg_static_accessor_GLOBAL_THIS_8d1badc68b5a74f4: function() {
|
|
1166
1166
|
const A = typeof globalThis > "u" ? null : globalThis;
|
|
1167
|
-
return
|
|
1167
|
+
return S(A) ? 0 : q(A);
|
|
1168
1168
|
},
|
|
1169
1169
|
__wbg_static_accessor_SELF_146583524fe1469b: function() {
|
|
1170
1170
|
const A = typeof self > "u" ? null : self;
|
|
1171
|
-
return
|
|
1171
|
+
return S(A) ? 0 : q(A);
|
|
1172
1172
|
},
|
|
1173
1173
|
__wbg_static_accessor_WINDOW_f2829a2234d7819e: function() {
|
|
1174
1174
|
const A = typeof window > "u" ? null : window;
|
|
1175
|
-
return
|
|
1175
|
+
return S(A) ? 0 : q(A);
|
|
1176
1176
|
},
|
|
1177
1177
|
__wbg_statusText_9f08c32741a99815: function(A, I) {
|
|
1178
|
-
const g = I.statusText, B =
|
|
1178
|
+
const g = I.statusText, B = F(g, C.__wbindgen_malloc, C.__wbindgen_realloc), E = R;
|
|
1179
1179
|
M().setInt32(A + 4, E, true), M().setInt32(A + 0, B, true);
|
|
1180
1180
|
},
|
|
1181
1181
|
__wbg_status_c45b3b9b3033184a: function(A) {
|
|
@@ -1194,12 +1194,12 @@ function SA() {
|
|
|
1194
1194
|
return A.toString();
|
|
1195
1195
|
},
|
|
1196
1196
|
__wbg_url_f6cd241d61f89b82: function(A, I) {
|
|
1197
|
-
const g = I.url, B =
|
|
1197
|
+
const g = I.url, B = F(g, C.__wbindgen_malloc, C.__wbindgen_realloc), E = R;
|
|
1198
1198
|
M().setInt32(A + 4, E, true), M().setInt32(A + 0, B, true);
|
|
1199
1199
|
},
|
|
1200
1200
|
__wbg_userAgent_0558f0ac642f7771: function() {
|
|
1201
1201
|
return o(function(A, I) {
|
|
1202
|
-
const g = I.userAgent, B =
|
|
1202
|
+
const g = I.userAgent, B = F(g, C.__wbindgen_malloc, C.__wbindgen_realloc), E = R;
|
|
1203
1203
|
M().setInt32(A + 4, E, true), M().setInt32(A + 0, B, true);
|
|
1204
1204
|
}, arguments);
|
|
1205
1205
|
},
|
|
@@ -1213,7 +1213,7 @@ function SA() {
|
|
|
1213
1213
|
return A.width;
|
|
1214
1214
|
},
|
|
1215
1215
|
__wbindgen_cast_0000000000000001: function(A, I) {
|
|
1216
|
-
return s(A, I,
|
|
1216
|
+
return s(A, I, pA);
|
|
1217
1217
|
},
|
|
1218
1218
|
__wbindgen_cast_0000000000000002: function(A, I) {
|
|
1219
1219
|
return s(A, I, LA);
|
|
@@ -1228,7 +1228,7 @@ function SA() {
|
|
|
1228
1228
|
return s(A, I, dA);
|
|
1229
1229
|
},
|
|
1230
1230
|
__wbindgen_cast_0000000000000006: function(A, I) {
|
|
1231
|
-
return s(A, I,
|
|
1231
|
+
return s(A, I, SA);
|
|
1232
1232
|
},
|
|
1233
1233
|
__wbindgen_cast_0000000000000007: function(A, I) {
|
|
1234
1234
|
return s(A, I, HA);
|
|
@@ -1237,7 +1237,7 @@ function SA() {
|
|
|
1237
1237
|
return A;
|
|
1238
1238
|
},
|
|
1239
1239
|
__wbindgen_cast_0000000000000009: function(A, I) {
|
|
1240
|
-
return
|
|
1240
|
+
return Y(A, I);
|
|
1241
1241
|
},
|
|
1242
1242
|
__wbindgen_init_externref_table: function() {
|
|
1243
1243
|
const A = C.__wbindgen_externrefs, I = A.grow(4);
|
|
@@ -1246,7 +1246,7 @@ function SA() {
|
|
|
1246
1246
|
}
|
|
1247
1247
|
};
|
|
1248
1248
|
}
|
|
1249
|
-
function
|
|
1249
|
+
function SA(Q, A) {
|
|
1250
1250
|
C.wasm_bindgen__convert__closures_____invoke__h38edb88495230029(Q, A);
|
|
1251
1251
|
}
|
|
1252
1252
|
function HA(Q, A) {
|
|
@@ -1261,12 +1261,12 @@ function sA(Q, A, I) {
|
|
|
1261
1261
|
function qA(Q, A, I) {
|
|
1262
1262
|
C.wasm_bindgen__convert__closures_____invoke__h64a57be2ca3e0d69_3(Q, A, I);
|
|
1263
1263
|
}
|
|
1264
|
-
function
|
|
1264
|
+
function pA(Q, A, I) {
|
|
1265
1265
|
const g = C.wasm_bindgen__convert__closures_____invoke__hfbb046a5343bcac9(Q, A, I);
|
|
1266
1266
|
if (g[1])
|
|
1267
|
-
throw
|
|
1267
|
+
throw Z(g[0]);
|
|
1268
1268
|
}
|
|
1269
|
-
function
|
|
1269
|
+
function ZA(Q, A, I, g) {
|
|
1270
1270
|
C.wasm_bindgen__convert__closures_____invoke__h4cc111f3c9bb2945(Q, A, I, g);
|
|
1271
1271
|
}
|
|
1272
1272
|
function dA(Q, A, I, g, B) {
|
|
@@ -1286,11 +1286,11 @@ const VA = ["blob", "arraybuffer"], $ = typeof FinalizationRegistry > "u" ? { re
|
|
|
1286
1286
|
}, unregister: () => {
|
|
1287
1287
|
} } : new FinalizationRegistry((Q) => C.__wbg_inputtransaction_free(Q, 1)), kA = typeof FinalizationRegistry > "u" ? { register: () => {
|
|
1288
1288
|
}, unregister: () => {
|
|
1289
|
-
} } : new FinalizationRegistry((Q) => C.__wbg_ironerror_free(Q, 1)),
|
|
1289
|
+
} } : new FinalizationRegistry((Q) => C.__wbg_ironerror_free(Q, 1)), RA = typeof FinalizationRegistry > "u" ? { register: () => {
|
|
1290
1290
|
}, unregister: () => {
|
|
1291
|
-
} } : new FinalizationRegistry((Q) => C.__wbg_rdcleanpathdetails_free(Q, 1)),
|
|
1291
|
+
} } : new FinalizationRegistry((Q) => C.__wbg_rdcleanpathdetails_free(Q, 1)), FA = typeof FinalizationRegistry > "u" ? { register: () => {
|
|
1292
1292
|
}, unregister: () => {
|
|
1293
|
-
} } : new FinalizationRegistry((Q) => C.__wbg_rdpfile_free(Q, 1)),
|
|
1293
|
+
} } : new FinalizationRegistry((Q) => C.__wbg_rdpfile_free(Q, 1)), YA = typeof FinalizationRegistry > "u" ? { register: () => {
|
|
1294
1294
|
}, unregister: () => {
|
|
1295
1295
|
} } : new FinalizationRegistry((Q) => C.__wbg_session_free(Q, 1)), IA = typeof FinalizationRegistry > "u" ? { register: () => {
|
|
1296
1296
|
}, unregister: () => {
|
|
@@ -1301,14 +1301,14 @@ function q(Q) {
|
|
|
1301
1301
|
const A = C.__externref_table_alloc();
|
|
1302
1302
|
return C.__wbindgen_externrefs.set(A, Q), A;
|
|
1303
1303
|
}
|
|
1304
|
-
function
|
|
1304
|
+
function yA(Q) {
|
|
1305
1305
|
if (typeof Q == "number" && (Q >= 1114112 || Q >= 55296 && Q < 57344)) throw new Error(`expected a valid Unicode scalar value, found ${Q}`);
|
|
1306
1306
|
}
|
|
1307
1307
|
function t(Q, A) {
|
|
1308
1308
|
if (!(Q instanceof A))
|
|
1309
1309
|
throw new Error(`expected instance of ${A.name}`);
|
|
1310
1310
|
}
|
|
1311
|
-
const
|
|
1311
|
+
const JA = typeof FinalizationRegistry > "u" ? { register: () => {
|
|
1312
1312
|
}, unregister: () => {
|
|
1313
1313
|
} } : new FinalizationRegistry((Q) => C.__wbindgen_destroy_closure(Q.a, Q.b));
|
|
1314
1314
|
function QA(Q) {
|
|
@@ -1348,27 +1348,27 @@ function QA(Q) {
|
|
|
1348
1348
|
return Q instanceof Error ? `${Q.name}: ${Q.message}
|
|
1349
1349
|
${Q.stack}` : g;
|
|
1350
1350
|
}
|
|
1351
|
-
function
|
|
1351
|
+
function lA(Q, A) {
|
|
1352
1352
|
Q = Q >>> 0;
|
|
1353
1353
|
const I = M(), g = [];
|
|
1354
1354
|
for (let B = Q; B < Q + 4 * A; B += 4)
|
|
1355
1355
|
g.push(C.__wbindgen_externrefs.get(I.getUint32(B, true)));
|
|
1356
1356
|
return C.__externref_drop_slice(Q, A), g;
|
|
1357
1357
|
}
|
|
1358
|
-
function
|
|
1358
|
+
function WA(Q, A) {
|
|
1359
1359
|
return Q = Q >>> 0, xA().subarray(Q / 4, Q / 4 + A);
|
|
1360
1360
|
}
|
|
1361
|
-
function
|
|
1361
|
+
function b(Q, A) {
|
|
1362
1362
|
return Q = Q >>> 0, x().subarray(Q / 1, Q / 1 + A);
|
|
1363
1363
|
}
|
|
1364
1364
|
function tA(Q, A) {
|
|
1365
1365
|
return Q = Q >>> 0, OA().subarray(Q / 1, Q / 1 + A);
|
|
1366
1366
|
}
|
|
1367
|
-
let
|
|
1367
|
+
let p = null;
|
|
1368
1368
|
function M() {
|
|
1369
|
-
return (
|
|
1369
|
+
return (p === null || p.buffer.detached === true || p.buffer.detached === void 0 && p.buffer !== C.memory.buffer) && (p = new DataView(C.memory.buffer)), p;
|
|
1370
1370
|
}
|
|
1371
|
-
function
|
|
1371
|
+
function Y(Q, A) {
|
|
1372
1372
|
return mA(Q >>> 0, A);
|
|
1373
1373
|
}
|
|
1374
1374
|
let m = null;
|
|
@@ -1391,7 +1391,7 @@ function o(Q, A) {
|
|
|
1391
1391
|
C.__wbindgen_exn_store(g);
|
|
1392
1392
|
}
|
|
1393
1393
|
}
|
|
1394
|
-
function
|
|
1394
|
+
function S(Q) {
|
|
1395
1395
|
return Q == null;
|
|
1396
1396
|
}
|
|
1397
1397
|
function s(Q, A, I) {
|
|
@@ -1406,17 +1406,17 @@ function s(Q, A, I) {
|
|
|
1406
1406
|
}
|
|
1407
1407
|
};
|
|
1408
1408
|
return B._wbg_cb_unref = () => {
|
|
1409
|
-
--g.cnt === 0 && (C.__wbindgen_destroy_closure(g.a, g.b), g.a = 0,
|
|
1410
|
-
},
|
|
1409
|
+
--g.cnt === 0 && (C.__wbindgen_destroy_closure(g.a, g.b), g.a = 0, JA.unregister(g));
|
|
1410
|
+
}, JA.register(B, g, g), B;
|
|
1411
1411
|
}
|
|
1412
|
-
function
|
|
1412
|
+
function bA(Q, A) {
|
|
1413
1413
|
const I = A(Q.length * 1, 1) >>> 0;
|
|
1414
|
-
return x().set(Q, I / 1),
|
|
1414
|
+
return x().set(Q, I / 1), R = Q.length, I;
|
|
1415
1415
|
}
|
|
1416
|
-
function
|
|
1416
|
+
function F(Q, A, I) {
|
|
1417
1417
|
if (I === void 0) {
|
|
1418
1418
|
const i = X.encode(Q), w = A(i.length, 1) >>> 0;
|
|
1419
|
-
return x().subarray(w, w + i.length).set(i),
|
|
1419
|
+
return x().subarray(w, w + i.length).set(i), R = i.length, w;
|
|
1420
1420
|
}
|
|
1421
1421
|
let g = Q.length, B = A(g, 1) >>> 0;
|
|
1422
1422
|
const E = x();
|
|
@@ -1431,18 +1431,18 @@ function R(Q, A, I) {
|
|
|
1431
1431
|
const i = x().subarray(B + D, B + g), w = X.encodeInto(Q, i);
|
|
1432
1432
|
D += w.written, B = I(B, g, D, 1) >>> 0;
|
|
1433
1433
|
}
|
|
1434
|
-
return
|
|
1434
|
+
return R = D, B;
|
|
1435
1435
|
}
|
|
1436
|
-
function
|
|
1436
|
+
function Z(Q) {
|
|
1437
1437
|
const A = C.__wbindgen_externrefs.get(Q);
|
|
1438
1438
|
return C.__externref_table_dealloc(Q), A;
|
|
1439
1439
|
}
|
|
1440
1440
|
let u = new TextDecoder("utf-8", { ignoreBOM: true, fatal: true });
|
|
1441
1441
|
u.decode();
|
|
1442
|
-
const
|
|
1442
|
+
const jA = 2146435072;
|
|
1443
1443
|
let gA = 0;
|
|
1444
1444
|
function mA(Q, A) {
|
|
1445
|
-
return gA += A, gA >=
|
|
1445
|
+
return gA += A, gA >= jA && (u = new TextDecoder("utf-8", { ignoreBOM: true, fatal: true }), u.decode(), gA = A), u.decode(x().subarray(Q, Q + A));
|
|
1446
1446
|
}
|
|
1447
1447
|
const X = new TextEncoder();
|
|
1448
1448
|
"encodeInto" in X || (X.encodeInto = function(Q, A) {
|
|
@@ -1452,9 +1452,9 @@ const X = new TextEncoder();
|
|
|
1452
1452
|
written: I.length
|
|
1453
1453
|
};
|
|
1454
1454
|
});
|
|
1455
|
-
let
|
|
1455
|
+
let R = 0, C;
|
|
1456
1456
|
function TA(Q, A) {
|
|
1457
|
-
return C = Q.exports,
|
|
1457
|
+
return C = Q.exports, p = null, m = null, T = null, f = null, C.__wbindgen_start(), C;
|
|
1458
1458
|
}
|
|
1459
1459
|
async function fA(Q, A) {
|
|
1460
1460
|
if (typeof Response == "function" && Q instanceof Response) {
|
|
@@ -1486,13 +1486,13 @@ async function fA(Q, A) {
|
|
|
1486
1486
|
async function XA(Q) {
|
|
1487
1487
|
if (C !== void 0) return C;
|
|
1488
1488
|
Q !== void 0 && (Object.getPrototypeOf(Q) === Object.prototype ? { module_or_path: Q } = Q : console.warn("using deprecated parameters for the initialization function; pass a single object instead")), Q === void 0 && (Q = new URL("ironrdp_web_bg.wasm", import.meta.url));
|
|
1489
|
-
const A =
|
|
1489
|
+
const A = aA();
|
|
1490
1490
|
(typeof Q == "string" || typeof Request == "function" && Q instanceof Request || typeof URL == "function" && Q instanceof URL) && (Q = fetch(Q));
|
|
1491
1491
|
const { instance: I, module: g } = await fA(await Q, A);
|
|
1492
1492
|
return TA(I);
|
|
1493
1493
|
}
|
|
1494
1494
|
const nA = "avc1.640033";
|
|
1495
|
-
function
|
|
1495
|
+
function KA() {
|
|
1496
1496
|
return {
|
|
1497
1497
|
codec: nA,
|
|
1498
1498
|
optimizeForLatency: true,
|
|
@@ -1504,12 +1504,12 @@ async function EI() {
|
|
|
1504
1504
|
if (typeof VideoDecoder > "u" || typeof EncodedVideoChunk > "u")
|
|
1505
1505
|
return false;
|
|
1506
1506
|
try {
|
|
1507
|
-
return (await VideoDecoder.isConfigSupported(
|
|
1507
|
+
return (await VideoDecoder.isConfigSupported(KA())).supported === true;
|
|
1508
1508
|
} catch {
|
|
1509
1509
|
return false;
|
|
1510
1510
|
}
|
|
1511
1511
|
}
|
|
1512
|
-
const
|
|
1512
|
+
const _y = class _y {
|
|
1513
1513
|
constructor(A = {}) {
|
|
1514
1514
|
__publicField(this, "stats", {
|
|
1515
1515
|
frames: 0,
|
|
@@ -1551,9 +1551,9 @@ const _Y = class _Y {
|
|
|
1551
1551
|
__publicField(this, "watchdog", null);
|
|
1552
1552
|
__publicField(this, "canvas", null);
|
|
1553
1553
|
__publicField(this, "closed", false);
|
|
1554
|
-
if (this.options = A, this.maxDecoders = A.maxDecoders ??
|
|
1554
|
+
if (this.options = A, this.maxDecoders = A.maxDecoders ?? _y.MAX_DECODERS, !Number.isInteger(this.maxDecoders) || this.maxDecoders < 1 || this.maxDecoders > _y.MAX_DECODERS)
|
|
1555
1555
|
throw new RangeError("maxDecoders must be an integer from 1 to 32");
|
|
1556
|
-
this.stallMs = A.stallMs ?? 3e3, this.now = A.now ?? (() => performance.now()), this.opens = new
|
|
1556
|
+
this.stallMs = A.stallMs ?? 3e3, this.now = A.now ?? (() => performance.now()), this.opens = new UA(_y.SESSION_OPENS, this.now());
|
|
1557
1557
|
}
|
|
1558
1558
|
decode(A, I) {
|
|
1559
1559
|
if (this.failed !== null || this.closed) {
|
|
@@ -1579,13 +1579,13 @@ const _Y = class _Y {
|
|
|
1579
1579
|
g = this.open(A.surfaceId);
|
|
1580
1580
|
}
|
|
1581
1581
|
const B = A.data.byteLength;
|
|
1582
|
-
if (g.pending.size >=
|
|
1583
|
-
this.fail(`more than ${
|
|
1582
|
+
if (g.pending.size >= _y.MAX_PENDING_FRAMES) {
|
|
1583
|
+
this.fail(`more than ${_y.MAX_PENDING_FRAMES} frames in a decoder`), I(A.id, null, this.failed ?? void 0);
|
|
1584
1584
|
return;
|
|
1585
1585
|
}
|
|
1586
|
-
if (this.pendingBytes + B >
|
|
1586
|
+
if (this.pendingBytes + B > _y.MAX_PENDING_BYTES) {
|
|
1587
1587
|
this.fail(
|
|
1588
|
-
`more than ${
|
|
1588
|
+
`more than ${_y.MAX_PENDING_BYTES / (1024 * 1024)} MiB of H.264 in the decoders`
|
|
1589
1589
|
), I(A.id, null, this.failed ?? void 0);
|
|
1590
1590
|
return;
|
|
1591
1591
|
}
|
|
@@ -1607,7 +1607,7 @@ const _Y = class _Y {
|
|
|
1607
1607
|
close() {
|
|
1608
1608
|
this.closed = true, this.stopWatchdog();
|
|
1609
1609
|
for (const A of [...this.surfaces.values(), ...this.retiring])
|
|
1610
|
-
|
|
1610
|
+
v(A.decoder);
|
|
1611
1611
|
this.surfaces.clear(), this.retiring.clear(), this.waitingForKey.clear(), this.stats.pending = 0, this.pendingBytes = 0, this.clearReadbacks(), this.canvas = null;
|
|
1612
1612
|
}
|
|
1613
1613
|
/** Releases streams as soon as their surfaces end, including when no later H.264 frame arrives. */
|
|
@@ -1623,17 +1623,17 @@ const _Y = class _Y {
|
|
|
1623
1623
|
const I = this.now();
|
|
1624
1624
|
let g = this.surfaceOpens.get(A);
|
|
1625
1625
|
if (g === void 0) {
|
|
1626
|
-
if (this.surfaceOpens.size >=
|
|
1626
|
+
if (this.surfaceOpens.size >= _y.MAX_DECODERS)
|
|
1627
1627
|
for (const [B, E] of this.surfaceOpens)
|
|
1628
1628
|
E.rested(I) && this.surfaceOpens.delete(B);
|
|
1629
|
-
g = new
|
|
1629
|
+
g = new UA(_y.SURFACE_OPENS, I), this.surfaceOpens.set(A, g);
|
|
1630
1630
|
}
|
|
1631
1631
|
if (!g.take(I)) {
|
|
1632
|
-
const { inARow: B, perSecond: E } =
|
|
1632
|
+
const { inARow: B, perSecond: E } = _y.SURFACE_OPENS;
|
|
1633
1633
|
return `H.264 decoders opened for surface ${A} faster than ${B} in a row and ${E} a second`;
|
|
1634
1634
|
}
|
|
1635
1635
|
if (!this.opens.take(I)) {
|
|
1636
|
-
const { inARow: B, perSecond: E } =
|
|
1636
|
+
const { inARow: B, perSecond: E } = _y.SESSION_OPENS;
|
|
1637
1637
|
return `H.264 decoders opened faster than ${B} in a row and ${E} a second`;
|
|
1638
1638
|
}
|
|
1639
1639
|
return null;
|
|
@@ -1648,7 +1648,7 @@ const _Y = class _Y {
|
|
|
1648
1648
|
}),
|
|
1649
1649
|
pending: /* @__PURE__ */ new Map()
|
|
1650
1650
|
};
|
|
1651
|
-
return I.decoder.configure(
|
|
1651
|
+
return I.decoder.configure(KA()), this.surfaces.set(A, I), I;
|
|
1652
1652
|
}
|
|
1653
1653
|
/** The server is done with a surface: its decoder closes once the frames given to it are out. */
|
|
1654
1654
|
retire(A) {
|
|
@@ -1656,7 +1656,7 @@ const _Y = class _Y {
|
|
|
1656
1656
|
if (I === void 0)
|
|
1657
1657
|
return;
|
|
1658
1658
|
if (this.surfaces.delete(A), I.pending.size === 0) {
|
|
1659
|
-
|
|
1659
|
+
v(I.decoder);
|
|
1660
1660
|
return;
|
|
1661
1661
|
}
|
|
1662
1662
|
this.retiring.add(I);
|
|
@@ -1664,7 +1664,7 @@ const _Y = class _Y {
|
|
|
1664
1664
|
if (this.retiring.delete(I)) {
|
|
1665
1665
|
for (const B of [...I.pending.values()])
|
|
1666
1666
|
this.settle(I, B), this.stats.dropped++, B.done(B.frame.id, null);
|
|
1667
|
-
|
|
1667
|
+
v(I.decoder);
|
|
1668
1668
|
}
|
|
1669
1669
|
};
|
|
1670
1670
|
try {
|
|
@@ -1680,7 +1680,7 @@ const _Y = class _Y {
|
|
|
1680
1680
|
return;
|
|
1681
1681
|
}
|
|
1682
1682
|
const E = I.codedWidth * I.codedHeight;
|
|
1683
|
-
if (!Number.isSafeInteger(E) || E <= 0 || E >
|
|
1683
|
+
if (!Number.isSafeInteger(E) || E <= 0 || E > _y.MAX_PICTURE_PIXELS) {
|
|
1684
1684
|
I.close(), this.fail("decoded H.264 picture exceeds the pixel budget");
|
|
1685
1685
|
return;
|
|
1686
1686
|
}
|
|
@@ -1691,17 +1691,17 @@ const _Y = class _Y {
|
|
|
1691
1691
|
}
|
|
1692
1692
|
this.settle(A, B);
|
|
1693
1693
|
const D = B.frame.regions.reduce((w, G) => w + (G.right - G.left) * (G.bottom - G.top) * 4, 0);
|
|
1694
|
-
if (this.readbackPictures.size >=
|
|
1695
|
-
I.close(), this.fail(`more than ${
|
|
1694
|
+
if (this.readbackPictures.size >= _y.MAX_READBACKS) {
|
|
1695
|
+
I.close(), this.fail(`more than ${_y.MAX_READBACKS} pictures being read back`), B.done(g, null, this.failed ?? void 0);
|
|
1696
1696
|
return;
|
|
1697
1697
|
}
|
|
1698
|
-
if (this.readbackBytes + D >
|
|
1698
|
+
if (this.readbackBytes + D > _y.MAX_READBACK_BYTES) {
|
|
1699
1699
|
I.close(), this.fail(
|
|
1700
|
-
`more than ${
|
|
1700
|
+
`more than ${_y.MAX_READBACK_BYTES / (1024 * 1024)} MiB of pictures being read back`
|
|
1701
1701
|
), B.done(g, null, this.failed ?? void 0);
|
|
1702
1702
|
return;
|
|
1703
1703
|
}
|
|
1704
|
-
if (this.readbackPixels + E >
|
|
1704
|
+
if (this.readbackPixels + E > _y.MAX_READBACK_PIXELS) {
|
|
1705
1705
|
I.close(), this.fail("more than 128 Mi pixels of decoded pictures being read back"), B.done(g, null, this.failed ?? void 0);
|
|
1706
1706
|
return;
|
|
1707
1707
|
}
|
|
@@ -1741,17 +1741,17 @@ const _Y = class _Y {
|
|
|
1741
1741
|
const w = i.reduce((N, L) => N + L.width * L.height * 4, 0), G = new Uint8Array(w);
|
|
1742
1742
|
if (i.length === 0)
|
|
1743
1743
|
return G;
|
|
1744
|
-
let [
|
|
1744
|
+
let [a, U, c, l] = [1 / 0, 1 / 0, -1 / 0, -1 / 0];
|
|
1745
1745
|
for (const N of i)
|
|
1746
|
-
|
|
1747
|
-
const H = { x:
|
|
1746
|
+
a = Math.min(a, N.x), U = Math.min(U, N.y), c = Math.max(c, N.x + N.width), l = Math.max(l, N.y + N.height);
|
|
1747
|
+
const H = { x: a, y: U, width: c - a, height: l - U };
|
|
1748
1748
|
if (i.length === 1)
|
|
1749
1749
|
return await this.readBox(A, g, H, G), G;
|
|
1750
|
-
if (H.width * H.height * 4 > w *
|
|
1750
|
+
if (H.width * H.height * 4 > w * _y.BOX_WASTE) {
|
|
1751
1751
|
let N = 0;
|
|
1752
1752
|
for (const L of i) {
|
|
1753
|
-
const
|
|
1754
|
-
await this.readBox(A, g, L, G.subarray(N, N +
|
|
1753
|
+
const W = L.width * L.height * 4;
|
|
1754
|
+
await this.readBox(A, g, L, G.subarray(N, N + W)), N += W;
|
|
1755
1755
|
}
|
|
1756
1756
|
return G;
|
|
1757
1757
|
}
|
|
@@ -1760,8 +1760,8 @@ const _Y = class _Y {
|
|
|
1760
1760
|
let EA = 0;
|
|
1761
1761
|
for (const N of i) {
|
|
1762
1762
|
const L = N.width * 4;
|
|
1763
|
-
for (let
|
|
1764
|
-
const DA = ((N.y - H.y +
|
|
1763
|
+
for (let W = 0; W < N.height; W++) {
|
|
1764
|
+
const DA = ((N.y - H.y + W) * H.width + (N.x - H.x)) * 4;
|
|
1765
1765
|
G.set(CA.subarray(DA, DA + L), EA), EA += L;
|
|
1766
1766
|
}
|
|
1767
1767
|
}
|
|
@@ -1824,7 +1824,7 @@ const _Y = class _Y {
|
|
|
1824
1824
|
this.failed = A, this.stopWatchdog();
|
|
1825
1825
|
const I = [...this.surfaces.values(), ...this.retiring], g = I.flatMap((B) => [...B.pending.values()]);
|
|
1826
1826
|
for (const B of I)
|
|
1827
|
-
|
|
1827
|
+
v(B.decoder);
|
|
1828
1828
|
this.surfaces.clear(), this.retiring.clear(), this.waitingForKey.clear(), this.stats.pending = 0, this.pendingBytes = 0, this.clearReadbacks(), this.canvas = null, (_b = (_a = this.options).onFailure) == null ? void 0 : _b.call(_a, A);
|
|
1829
1829
|
for (const { frame: B, done: E } of g)
|
|
1830
1830
|
E(B.id, null, A);
|
|
@@ -1835,7 +1835,7 @@ const _Y = class _Y {
|
|
|
1835
1835
|
* (MS-RDPBCGR 2.2.1.3.6); after a reset, the decoders of the surfaces it destroyed may still be finishing their
|
|
1836
1836
|
* frames while those of the new ones start.
|
|
1837
1837
|
*/
|
|
1838
|
-
__publicField(
|
|
1838
|
+
__publicField(_y, "MAX_DECODERS", 32);
|
|
1839
1839
|
/**
|
|
1840
1840
|
* How fast one surface's decoders may open: 16 in a row, then 4 a second. A decoder opens for a surface's first
|
|
1841
1841
|
* frame, and again for its first frame after its stream ended (the surface deleted, created again or destroyed by
|
|
@@ -1845,24 +1845,24 @@ __publicField(_Y, "MAX_DECODERS", 32);
|
|
|
1845
1845
|
* had that done for every frame: 32,768 times for one message of 90 KB on the wire, which froze the page, and
|
|
1846
1846
|
* every session in it, for 1.4 s, message after message.
|
|
1847
1847
|
*/
|
|
1848
|
-
__publicField(
|
|
1848
|
+
__publicField(_y, "SURFACE_OPENS", { inARow: 16, perSecond: 4 });
|
|
1849
1849
|
/**
|
|
1850
1850
|
* How fast decoders may open for all surfaces together: 128 in a row, then 32 a second. That is each of 16
|
|
1851
1851
|
* monitors (MS-RDPBCGR 2.2.1.3.6) resized eight times in a row, then twice a second, and opening that many takes
|
|
1852
1852
|
* the page's thread under 6 ms, then under 1.5 ms a second.
|
|
1853
1853
|
*/
|
|
1854
|
-
__publicField(
|
|
1854
|
+
__publicField(_y, "SESSION_OPENS", { inARow: 128, perSecond: 32 });
|
|
1855
1855
|
/**
|
|
1856
1856
|
* The most frames one decoder may hold. A decoder keeps up with its stream, so frames wait in it about as long as
|
|
1857
1857
|
* one takes to decode, and the server stops at its unacknowledged frames: 256 is over two seconds of 60 Hz AVC444
|
|
1858
1858
|
* (two access units a frame), and a frame that waits longer than `stallMs` (3 s) fails the decoder anyway.
|
|
1859
1859
|
*/
|
|
1860
|
-
__publicField(
|
|
1860
|
+
__publicField(_y, "MAX_PENDING_FRAMES", 256);
|
|
1861
1861
|
/**
|
|
1862
1862
|
* The most bytes of H.264 the decoders may hold at once: over a second at the highest bitrate any H.264 level
|
|
1863
1863
|
* allows (level 6.2, High profile: 1,000 Mbit/s), where servers send a few to tens of Mbit/s.
|
|
1864
1864
|
*/
|
|
1865
|
-
__publicField(
|
|
1865
|
+
__publicField(_y, "MAX_PENDING_BYTES", 128 * 1024 * 1024);
|
|
1866
1866
|
/**
|
|
1867
1867
|
* The most bytes the pictures being read back may be read into at once: the RGBA of their frames' regions. A
|
|
1868
1868
|
* picture is read back as it comes out, while its decoder goes on, so readbacks overlap when pictures come out
|
|
@@ -1870,15 +1870,15 @@ __publicField(_Y, "MAX_PENDING_BYTES", 128 * 1024 * 1024);
|
|
|
1870
1870
|
* compositor holds), or four whole 8K pictures (7680x4320, 127 MiB each). Regions read back as their bounding box
|
|
1871
1871
|
* take the box as well while it is read, at most twice what they hold.
|
|
1872
1872
|
*/
|
|
1873
|
-
__publicField(
|
|
1874
|
-
__publicField(
|
|
1875
|
-
__publicField(
|
|
1873
|
+
__publicField(_y, "MAX_READBACK_BYTES", 512 * 1024 * 1024);
|
|
1874
|
+
__publicField(_y, "MAX_READBACKS", 64);
|
|
1875
|
+
__publicField(_y, "MAX_PICTURE_PIXELS", 64 * 1024 * 1024);
|
|
1876
1876
|
/** Four whole 8K pictures, or 512 MiB at four bytes per coded pixel, regardless of dirty-region size. */
|
|
1877
|
-
__publicField(
|
|
1877
|
+
__publicField(_y, "MAX_READBACK_PIXELS", 128 * 1024 * 1024);
|
|
1878
1878
|
/** A bounding box may be this many times what its regions hold before they are read one by one instead. */
|
|
1879
|
-
__publicField(
|
|
1880
|
-
let
|
|
1881
|
-
class
|
|
1879
|
+
__publicField(_y, "BOX_WASTE", 2);
|
|
1880
|
+
let y = _y;
|
|
1881
|
+
class UA {
|
|
1882
1882
|
constructor(A, I) {
|
|
1883
1883
|
__publicField(this, "allowance");
|
|
1884
1884
|
__publicField(this, "at");
|
|
@@ -1899,7 +1899,7 @@ class hA {
|
|
|
1899
1899
|
}
|
|
1900
1900
|
}
|
|
1901
1901
|
}
|
|
1902
|
-
function
|
|
1902
|
+
function v(Q) {
|
|
1903
1903
|
if (Q.state !== "closed")
|
|
1904
1904
|
try {
|
|
1905
1905
|
Q.close();
|
|
@@ -1909,7 +1909,7 @@ function e(Q) {
|
|
|
1909
1909
|
function BA(Q) {
|
|
1910
1910
|
return Q instanceof Error || Q instanceof DOMException ? `${Q.name}: ${Q.message}` : String(Q);
|
|
1911
1911
|
}
|
|
1912
|
-
const
|
|
1912
|
+
const j = {
|
|
1913
1913
|
/**
|
|
1914
1914
|
* Request file size (8-byte unsigned integer).
|
|
1915
1915
|
* When set: position must be 0, size must be 8.
|
|
@@ -1921,19 +1921,19 @@ const b = {
|
|
|
1921
1921
|
*/
|
|
1922
1922
|
RANGE: 2
|
|
1923
1923
|
};
|
|
1924
|
-
function
|
|
1924
|
+
function zA(Q) {
|
|
1925
1925
|
return new k("files_available_callback", Q);
|
|
1926
1926
|
}
|
|
1927
|
-
function
|
|
1927
|
+
function eA(Q) {
|
|
1928
1928
|
return new k("file_contents_request_callback", Q);
|
|
1929
1929
|
}
|
|
1930
|
-
function
|
|
1930
|
+
function rA(Q) {
|
|
1931
1931
|
return new k("file_contents_response_callback", Q);
|
|
1932
1932
|
}
|
|
1933
|
-
function
|
|
1933
|
+
function PA(Q) {
|
|
1934
1934
|
return new k("lock_callback", Q);
|
|
1935
1935
|
}
|
|
1936
|
-
function
|
|
1936
|
+
function vA(Q) {
|
|
1937
1937
|
return new k("unlock_callback", Q);
|
|
1938
1938
|
}
|
|
1939
1939
|
function uA(Q) {
|
|
@@ -1992,7 +1992,7 @@ class gI {
|
|
|
1992
1992
|
this.finalized || (this.finalized = true, this.chunks = []);
|
|
1993
1993
|
}
|
|
1994
1994
|
}
|
|
1995
|
-
class
|
|
1995
|
+
class cA {
|
|
1996
1996
|
constructor() {
|
|
1997
1997
|
__publicField(this, "name", "blob");
|
|
1998
1998
|
}
|
|
@@ -2147,7 +2147,7 @@ function QI(Q) {
|
|
|
2147
2147
|
async function CI(Q = "auto", A) {
|
|
2148
2148
|
var _a, _b;
|
|
2149
2149
|
if (Q === "blob")
|
|
2150
|
-
return new
|
|
2150
|
+
return new cA();
|
|
2151
2151
|
if (typeof ((_b = (_a = globalThis.navigator) == null ? void 0 : _a.storage) == null ? void 0 : _b.getDirectory) == "function")
|
|
2152
2152
|
try {
|
|
2153
2153
|
const I = await navigator.storage.getDirectory();
|
|
@@ -2157,9 +2157,9 @@ async function CI(Q = "auto", A) {
|
|
|
2157
2157
|
} catch (I) {
|
|
2158
2158
|
console.debug("OPFS unavailable, falling back to blob storage:", I);
|
|
2159
2159
|
}
|
|
2160
|
-
return new
|
|
2160
|
+
return new cA();
|
|
2161
2161
|
}
|
|
2162
|
-
const
|
|
2162
|
+
const _K = class _K {
|
|
2163
2163
|
constructor(A) {
|
|
2164
2164
|
__publicField(this, "session");
|
|
2165
2165
|
__publicField(this, "chunkSize");
|
|
@@ -2270,13 +2270,13 @@ const _J = class _J {
|
|
|
2270
2270
|
*/
|
|
2271
2271
|
getBuilderExtensions() {
|
|
2272
2272
|
return [
|
|
2273
|
-
|
|
2273
|
+
zA(
|
|
2274
2274
|
(A, I) => this.handleFilesAvailable(A, I)
|
|
2275
2275
|
),
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2276
|
+
eA((A) => this.handleFileContentsRequest(A)),
|
|
2277
|
+
rA((A) => this.handleFileContentsResponse(A)),
|
|
2278
|
+
PA((A) => this.handleLock(A)),
|
|
2279
|
+
vA((A) => this.handleUnlock(A)),
|
|
2280
2280
|
uA((A) => this.handleLocksExpired(A)),
|
|
2281
2281
|
_A((A) => this.handleFormatListResponse(A))
|
|
2282
2282
|
];
|
|
@@ -2360,7 +2360,7 @@ const _J = class _J {
|
|
|
2360
2360
|
this.activeDownloads.set(g, w);
|
|
2361
2361
|
});
|
|
2362
2362
|
try {
|
|
2363
|
-
this.sendRequestFileContents(g, I,
|
|
2363
|
+
this.sendRequestFileContents(g, I, j.SIZE, 0, 8, B);
|
|
2364
2364
|
} catch (D) {
|
|
2365
2365
|
this.activeDownloads.delete(g);
|
|
2366
2366
|
const i = {
|
|
@@ -2415,10 +2415,10 @@ const _J = class _J {
|
|
|
2415
2415
|
async downloadFilesConcurrent(A, I = {}) {
|
|
2416
2416
|
const g = I.maxConcurrent ?? 3, B = /* @__PURE__ */ new Map(), E = [], D = A.map((w, G) => async () => {
|
|
2417
2417
|
try {
|
|
2418
|
-
const { completion:
|
|
2419
|
-
B.set(G,
|
|
2420
|
-
} catch (
|
|
2421
|
-
E.push({ index: G, error:
|
|
2418
|
+
const { completion: a } = this.downloadFile(w, G), U = await a;
|
|
2419
|
+
B.set(G, U);
|
|
2420
|
+
} catch (a) {
|
|
2421
|
+
E.push({ index: G, error: a });
|
|
2422
2422
|
}
|
|
2423
2423
|
}), i = [];
|
|
2424
2424
|
for (const w of D) {
|
|
@@ -2453,7 +2453,7 @@ const _J = class _J {
|
|
|
2453
2453
|
*/
|
|
2454
2454
|
uploadFiles(A) {
|
|
2455
2455
|
this.uploadState !== void 0 && this.supersedeUpload(), this.retainedFiles = void 0;
|
|
2456
|
-
const I =
|
|
2456
|
+
const I = _K.normalizeToDroppedFiles(A), g = /* @__PURE__ */ new Map();
|
|
2457
2457
|
for (let w = 0; w < I.length; w++)
|
|
2458
2458
|
g.set(w, this.generateStreamId());
|
|
2459
2459
|
const B = I.map((w) => ({
|
|
@@ -2478,14 +2478,14 @@ const _J = class _J {
|
|
|
2478
2478
|
}, this.suppressUploadMonitoring();
|
|
2479
2479
|
try {
|
|
2480
2480
|
this.sendInitiateFileCopy(B), this.emit("upload-batch-started", g, I);
|
|
2481
|
-
} catch (
|
|
2481
|
+
} catch (a) {
|
|
2482
2482
|
this.uploadState = void 0, this.resumeUploadMonitoring();
|
|
2483
|
-
const
|
|
2483
|
+
const U = {
|
|
2484
2484
|
message: "Failed to initiate file upload",
|
|
2485
2485
|
direction: "upload",
|
|
2486
|
-
cause:
|
|
2486
|
+
cause: a
|
|
2487
2487
|
};
|
|
2488
|
-
this.emit("error",
|
|
2488
|
+
this.emit("error", U), G(new Error(U.message, { cause: a }));
|
|
2489
2489
|
return;
|
|
2490
2490
|
}
|
|
2491
2491
|
this.armPasteAckWatchdog();
|
|
@@ -2529,7 +2529,7 @@ const _J = class _J {
|
|
|
2529
2529
|
this.pasteAckTimeout = void 0;
|
|
2530
2530
|
const A = this.uploadState;
|
|
2531
2531
|
A !== void 0 && A.isRePaste !== true ? this.failPendingUpload("The remote did not request the files in time, so the paste was not completed") : this.resumeUploadMonitoring();
|
|
2532
|
-
},
|
|
2532
|
+
}, _K.PASTE_ACK_TIMEOUT_MS);
|
|
2533
2533
|
}
|
|
2534
2534
|
/** Disarm the paste-acknowledgment watchdog, if armed. */
|
|
2535
2535
|
clearPasteAckWatchdog() {
|
|
@@ -2547,7 +2547,7 @@ const _J = class _J {
|
|
|
2547
2547
|
this.uploadInactivityTimeout = void 0;
|
|
2548
2548
|
const A = this.uploadState;
|
|
2549
2549
|
A !== void 0 && A.isRePaste !== true && this.failPendingUpload("The remote stopped requesting the files, so the paste did not complete");
|
|
2550
|
-
},
|
|
2550
|
+
}, _K.UPLOAD_INACTIVITY_TIMEOUT_MS);
|
|
2551
2551
|
}
|
|
2552
2552
|
/** Disarm the upload inactivity watchdog, if armed. */
|
|
2553
2553
|
clearUploadInactivityWatchdog() {
|
|
@@ -2735,10 +2735,10 @@ const _J = class _J {
|
|
|
2735
2735
|
* entries into `results`.
|
|
2736
2736
|
*/
|
|
2737
2737
|
async traverseEntry(A, I, g, B) {
|
|
2738
|
-
if (!(g.length >=
|
|
2739
|
-
if (B >
|
|
2738
|
+
if (!(g.length >= _K.MAX_DIRECTORY_ENTRIES)) {
|
|
2739
|
+
if (B > _K.MAX_DIRECTORY_DEPTH) {
|
|
2740
2740
|
console.warn(
|
|
2741
|
-
`Skipping "${A.name}": directory depth exceeds ${
|
|
2741
|
+
`Skipping "${A.name}": directory depth exceeds ${_K.MAX_DIRECTORY_DEPTH}`
|
|
2742
2742
|
);
|
|
2743
2743
|
return;
|
|
2744
2744
|
}
|
|
@@ -2763,7 +2763,7 @@ const _J = class _J {
|
|
|
2763
2763
|
path: I,
|
|
2764
2764
|
isDirectory: true
|
|
2765
2765
|
});
|
|
2766
|
-
const D = A.createReader(), i = await
|
|
2766
|
+
const D = A.createReader(), i = await _K.readAllDirectoryEntries(D);
|
|
2767
2767
|
for (const w of i)
|
|
2768
2768
|
await this.traverseEntry(w, E, g, B + 1);
|
|
2769
2769
|
}
|
|
@@ -2815,8 +2815,8 @@ const _J = class _J {
|
|
|
2815
2815
|
this.failPendingUpload("Upload interrupted: the remote clipboard changed");
|
|
2816
2816
|
const g = A.map((B) => ({
|
|
2817
2817
|
...B,
|
|
2818
|
-
name:
|
|
2819
|
-
path: B.path !== void 0 ?
|
|
2818
|
+
name: _K.sanitizeFileName(B.name),
|
|
2819
|
+
path: B.path !== void 0 ? _K.sanitizePath(B.path) : void 0
|
|
2820
2820
|
}));
|
|
2821
2821
|
this.availableFiles = g, this.clipDataId = I, this.emit("files-available", g);
|
|
2822
2822
|
}
|
|
@@ -2867,7 +2867,7 @@ const _J = class _J {
|
|
|
2867
2867
|
return;
|
|
2868
2868
|
}
|
|
2869
2869
|
if (E == null) {
|
|
2870
|
-
if ((A.flags &
|
|
2870
|
+
if ((A.flags & j.SIZE) !== 0) {
|
|
2871
2871
|
const w = new Uint8Array(8);
|
|
2872
2872
|
this.sendSubmitFileContents(A.streamId, false, w);
|
|
2873
2873
|
} else
|
|
@@ -2875,55 +2875,55 @@ const _J = class _J {
|
|
|
2875
2875
|
return;
|
|
2876
2876
|
}
|
|
2877
2877
|
const i = E;
|
|
2878
|
-
if ((A.flags &
|
|
2878
|
+
if ((A.flags & j.SIZE) !== 0) {
|
|
2879
2879
|
const w = new Uint8Array(8);
|
|
2880
2880
|
new DataView(w.buffer).setBigUint64(0, BigInt(i.size), true), this.sendSubmitFileContents(A.streamId, false, w), i.size === 0 && this.markUploadFileComplete(A.index, i, I.transferIds.get(A.index) ?? -1);
|
|
2881
|
-
} else if ((A.flags &
|
|
2881
|
+
} else if ((A.flags & j.RANGE) !== 0) {
|
|
2882
2882
|
const w = i.slice(A.position, A.position + A.size), G = new FileReader();
|
|
2883
2883
|
I.activeReaders.set(A.streamId, G);
|
|
2884
|
-
const
|
|
2884
|
+
const a = setTimeout(() => {
|
|
2885
2885
|
var _a;
|
|
2886
2886
|
G.abort(), this.uploadState !== void 0 && (this.uploadState.activeReaders.delete(A.streamId), this.uploadState.readerTimeouts.delete(A.streamId)), this.sendSubmitFileContents(A.streamId, true, new Uint8Array());
|
|
2887
|
-
const
|
|
2888
|
-
message: `File read timeout after ${
|
|
2887
|
+
const U = {
|
|
2888
|
+
message: `File read timeout after ${_K.FILE_READER_TIMEOUT_MS / 1e3}s`,
|
|
2889
2889
|
transferId: (_a = this.uploadState) == null ? void 0 : _a.transferIds.get(A.index),
|
|
2890
2890
|
fileIndex: A.index,
|
|
2891
2891
|
fileName: D.name,
|
|
2892
2892
|
direction: "upload"
|
|
2893
2893
|
};
|
|
2894
|
-
this.emit("error",
|
|
2895
|
-
},
|
|
2896
|
-
I.readerTimeouts.set(A.streamId,
|
|
2894
|
+
this.emit("error", U), this.uploadState !== void 0 && (this.uploadState.failedFiles.add(A.index), this.uploadState.completedFiles.add(A.index), this.uploadState.completedFiles.size >= this.uploadState.expectedFileCount && this.finishUploadBatch(this.uploadState));
|
|
2895
|
+
}, _K.FILE_READER_TIMEOUT_MS);
|
|
2896
|
+
I.readerTimeouts.set(A.streamId, a), G.onload = () => {
|
|
2897
2897
|
if (this.uploadState !== void 0) {
|
|
2898
2898
|
this.uploadState.activeReaders.delete(A.streamId);
|
|
2899
|
-
const
|
|
2900
|
-
|
|
2899
|
+
const c = this.uploadState.readerTimeouts.get(A.streamId);
|
|
2900
|
+
c !== void 0 && (clearTimeout(c), this.uploadState.readerTimeouts.delete(A.streamId));
|
|
2901
2901
|
}
|
|
2902
|
-
const
|
|
2903
|
-
if (this.sendSubmitFileContents(A.streamId, false,
|
|
2904
|
-
const
|
|
2905
|
-
this.uploadState.bytesServed.set(A.index,
|
|
2906
|
-
const
|
|
2907
|
-
transferId:
|
|
2902
|
+
const U = new Uint8Array(G.result);
|
|
2903
|
+
if (this.sendSubmitFileContents(A.streamId, false, U), this.uploadState !== void 0) {
|
|
2904
|
+
const c = (this.uploadState.bytesServed.get(A.index) ?? 0) + U.length;
|
|
2905
|
+
this.uploadState.bytesServed.set(A.index, c);
|
|
2906
|
+
const l = this.uploadState.transferIds.get(A.index) ?? -1, H = {
|
|
2907
|
+
transferId: l,
|
|
2908
2908
|
fileIndex: A.index,
|
|
2909
2909
|
fileName: D.name,
|
|
2910
|
-
bytesTransferred:
|
|
2910
|
+
bytesTransferred: c,
|
|
2911
2911
|
totalBytes: i.size,
|
|
2912
|
-
percentage: i.size === 0 ? 100 : Math.min(
|
|
2912
|
+
percentage: i.size === 0 ? 100 : Math.min(c / i.size * 100, 100)
|
|
2913
2913
|
};
|
|
2914
|
-
this.emit("upload-progress", H),
|
|
2914
|
+
this.emit("upload-progress", H), c >= i.size && this.markUploadFileComplete(A.index, i, l);
|
|
2915
2915
|
}
|
|
2916
2916
|
}, G.onerror = () => {
|
|
2917
2917
|
var _a, _b;
|
|
2918
2918
|
if (this.uploadState !== void 0) {
|
|
2919
2919
|
this.uploadState.activeReaders.delete(A.streamId);
|
|
2920
|
-
const
|
|
2921
|
-
|
|
2920
|
+
const c = this.uploadState.readerTimeouts.get(A.streamId);
|
|
2921
|
+
c !== void 0 && (clearTimeout(c), this.uploadState.readerTimeouts.delete(A.streamId));
|
|
2922
2922
|
}
|
|
2923
2923
|
if (((_a = this.uploadState) == null ? void 0 : _a.failedFiles.has(A.index)) === true)
|
|
2924
2924
|
return;
|
|
2925
2925
|
this.sendSubmitFileContents(A.streamId, true, new Uint8Array());
|
|
2926
|
-
const
|
|
2926
|
+
const U = {
|
|
2927
2927
|
message: "Failed to read file chunk",
|
|
2928
2928
|
transferId: (_b = this.uploadState) == null ? void 0 : _b.transferIds.get(A.index),
|
|
2929
2929
|
fileIndex: A.index,
|
|
@@ -2931,7 +2931,7 @@ const _J = class _J {
|
|
|
2931
2931
|
direction: "upload",
|
|
2932
2932
|
cause: G.error
|
|
2933
2933
|
};
|
|
2934
|
-
this.emit("error",
|
|
2934
|
+
this.emit("error", U), this.uploadState !== void 0 && (this.uploadState.failedFiles.add(A.index), this.uploadState.completedFiles.add(A.index), this.uploadState.completedFiles.size >= this.uploadState.expectedFileCount && this.finishUploadBatch(this.uploadState));
|
|
2935
2935
|
}, G.readAsArrayBuffer(w);
|
|
2936
2936
|
}
|
|
2937
2937
|
}
|
|
@@ -3004,7 +3004,7 @@ const _J = class _J {
|
|
|
3004
3004
|
return;
|
|
3005
3005
|
}
|
|
3006
3006
|
const g = new DataView(A.data.buffer, A.data.byteOffset, A.data.byteLength), B = Number(g.getBigUint64(0, true));
|
|
3007
|
-
if (B >
|
|
3007
|
+
if (B > _K.MAX_FILE_SIZE) {
|
|
3008
3008
|
this.activeDownloads.delete(A.streamId), this.abortWriteHandle(I);
|
|
3009
3009
|
const E = {
|
|
3010
3010
|
message: `File size ${(B / (1024 * 1024 * 1024)).toFixed(2)}GB exceeds maximum download limit of 2GB`,
|
|
@@ -3037,7 +3037,7 @@ const _J = class _J {
|
|
|
3037
3037
|
initWriteHandleAndRequestFirstChunk(A) {
|
|
3038
3038
|
A.writeHandleReady = (async () => {
|
|
3039
3039
|
try {
|
|
3040
|
-
const I = (async () => (await this.ensureStorageBackend()).createWriteHandle(A.fileInfo.name, A.expectedSize ?? 0))(), g =
|
|
3040
|
+
const I = (async () => (await this.ensureStorageBackend()).createWriteHandle(A.fileInfo.name, A.expectedSize ?? 0))(), g = _K.WRITE_HANDLE_INIT_TIMEOUT_MS, B = await Promise.race([
|
|
3041
3041
|
I,
|
|
3042
3042
|
new Promise(
|
|
3043
3043
|
(E, D) => setTimeout(() => D(new Error(`Storage init timed out after ${g / 1e3}s`)), g)
|
|
@@ -3194,7 +3194,7 @@ const _J = class _J {
|
|
|
3194
3194
|
this.sendRequestFileContents(
|
|
3195
3195
|
A.streamId,
|
|
3196
3196
|
A.fileIndex,
|
|
3197
|
-
|
|
3197
|
+
j.RANGE,
|
|
3198
3198
|
I,
|
|
3199
3199
|
B,
|
|
3200
3200
|
A.clipDataId
|
|
@@ -3223,9 +3223,9 @@ const _J = class _J {
|
|
|
3223
3223
|
}
|
|
3224
3224
|
};
|
|
3225
3225
|
/** Maximum file size for downloads (2GB) to prevent browser out-of-memory errors */
|
|
3226
|
-
__publicField(
|
|
3226
|
+
__publicField(_K, "MAX_FILE_SIZE", 2 * 1024 * 1024 * 1024);
|
|
3227
3227
|
/** Timeout for FileReader operations (60 seconds) to prevent stalled uploads */
|
|
3228
|
-
__publicField(
|
|
3228
|
+
__publicField(_K, "FILE_READER_TIMEOUT_MS", 60 * 1e3);
|
|
3229
3229
|
/**
|
|
3230
3230
|
* How long to keep clipboard monitoring suppressed after advertising an upload
|
|
3231
3231
|
* while waiting for the remote to pull the files (first FileContentsRequest),
|
|
@@ -3235,7 +3235,7 @@ __publicField(_J, "FILE_READER_TIMEOUT_MS", 60 * 1e3);
|
|
|
3235
3235
|
* clobbered), the watchdog resumes monitoring and fails the upload so its state
|
|
3236
3236
|
* cannot wedge later uploads.
|
|
3237
3237
|
*/
|
|
3238
|
-
__publicField(
|
|
3238
|
+
__publicField(_K, "PASTE_ACK_TIMEOUT_MS", 60 * 1e3);
|
|
3239
3239
|
/**
|
|
3240
3240
|
* Upload inactivity window. After the remote starts pulling, each FileContentsRequest
|
|
3241
3241
|
* resets this; if pulls then stop for this long -- e.g. the remote grabbed the
|
|
@@ -3243,62 +3243,62 @@ __publicField(_J, "PASTE_ACK_TIMEOUT_MS", 60 * 1e3);
|
|
|
3243
3243
|
* upload is failed so `uploadState` is released and later uploads aren't wedged. A
|
|
3244
3244
|
* slow-but-progressing transfer keeps resetting it, so it is never killed.
|
|
3245
3245
|
*/
|
|
3246
|
-
__publicField(
|
|
3246
|
+
__publicField(_K, "UPLOAD_INACTIVITY_TIMEOUT_MS", 60 * 1e3);
|
|
3247
3247
|
/** Timeout for storage backend write handle initialization (30 seconds). */
|
|
3248
|
-
__publicField(
|
|
3248
|
+
__publicField(_K, "WRITE_HANDLE_INIT_TIMEOUT_MS", 30 * 1e3);
|
|
3249
3249
|
/** Maximum recursion depth when traversing dropped directories. */
|
|
3250
|
-
__publicField(
|
|
3250
|
+
__publicField(_K, "MAX_DIRECTORY_DEPTH", 32);
|
|
3251
3251
|
/** Maximum total entries (files + directories) collected from a single drop. */
|
|
3252
|
-
__publicField(
|
|
3253
|
-
let
|
|
3252
|
+
__publicField(_K, "MAX_DIRECTORY_ENTRIES", 1e3);
|
|
3253
|
+
let K = _K;
|
|
3254
3254
|
async function NI(Q, A, I) {
|
|
3255
|
-
await XA(A === void 0 ? void 0 : { module_or_path: A }),
|
|
3255
|
+
await XA(A === void 0 ? void 0 : { module_or_path: A }), hA(Q, I);
|
|
3256
3256
|
}
|
|
3257
3257
|
const kI = {
|
|
3258
3258
|
DesktopSize: V,
|
|
3259
3259
|
InputTransaction: _,
|
|
3260
|
-
SessionBuilder:
|
|
3260
|
+
SessionBuilder: J,
|
|
3261
3261
|
ClipboardData: d,
|
|
3262
|
-
DeviceEvent:
|
|
3262
|
+
DeviceEvent: h
|
|
3263
3263
|
};
|
|
3264
|
-
function
|
|
3264
|
+
function RI(Q) {
|
|
3265
3265
|
return new k("pcb", Q);
|
|
3266
3266
|
}
|
|
3267
|
-
function
|
|
3267
|
+
function FI(Q, A = "enhanced") {
|
|
3268
3268
|
if (Q.trim() === "")
|
|
3269
3269
|
throw new Error("vmconnect requires a VM ID");
|
|
3270
3270
|
const I = A === "enhanced" ? `${Q};EnhancedMode=1` : Q;
|
|
3271
3271
|
return new k("vmconnect", I);
|
|
3272
3272
|
}
|
|
3273
|
-
function
|
|
3273
|
+
function YI(Q) {
|
|
3274
3274
|
return new k("display_control", Q);
|
|
3275
3275
|
}
|
|
3276
3276
|
function MI(Q) {
|
|
3277
3277
|
return new k("graphics_pipeline", Q);
|
|
3278
3278
|
}
|
|
3279
|
-
function
|
|
3279
|
+
function yI(Q) {
|
|
3280
3280
|
return new k("h264_decoder", Q);
|
|
3281
3281
|
}
|
|
3282
|
-
function
|
|
3282
|
+
function JI(Q) {
|
|
3283
3283
|
return new k("audio_playback", Q);
|
|
3284
3284
|
}
|
|
3285
|
-
function
|
|
3285
|
+
function UI(Q) {
|
|
3286
3286
|
return new k("drive_redirection", Q);
|
|
3287
3287
|
}
|
|
3288
|
-
function
|
|
3288
|
+
function cI(Q) {
|
|
3289
3289
|
return new k("audio_input", Q);
|
|
3290
3290
|
}
|
|
3291
|
-
function
|
|
3291
|
+
function KI(Q) {
|
|
3292
3292
|
const A = Q instanceof Uint8Array ? Q : new Uint8Array(Q.buffer, Q.byteOffset, Q.byteLength);
|
|
3293
3293
|
return new k("audio_input_data", A);
|
|
3294
3294
|
}
|
|
3295
|
-
function
|
|
3295
|
+
function hI(Q) {
|
|
3296
3296
|
return new k("kdc_proxy_url", Q);
|
|
3297
3297
|
}
|
|
3298
|
-
function
|
|
3298
|
+
function aI(Q) {
|
|
3299
3299
|
return new k("outbound_message_size_limit", Q);
|
|
3300
3300
|
}
|
|
3301
|
-
function
|
|
3301
|
+
function SI(Q) {
|
|
3302
3302
|
return new k("enable_credssp", Q);
|
|
3303
3303
|
}
|
|
3304
3304
|
function HI(Q) {
|
|
@@ -3309,41 +3309,41 @@ function LI(Q) {
|
|
|
3309
3309
|
}
|
|
3310
3310
|
export {
|
|
3311
3311
|
kI as Backend,
|
|
3312
|
-
|
|
3313
|
-
|
|
3312
|
+
cA as BlobStorageBackend,
|
|
3313
|
+
j as FileContentsFlags,
|
|
3314
3314
|
O as OpfsStorageBackend,
|
|
3315
3315
|
DI as PrinterDriverName,
|
|
3316
3316
|
iA as RdpFile,
|
|
3317
|
-
|
|
3318
|
-
|
|
3319
|
-
|
|
3320
|
-
|
|
3321
|
-
|
|
3317
|
+
K as RdpFileTransferProvider,
|
|
3318
|
+
y as WebCodecsH264Decoder,
|
|
3319
|
+
cI as audioInput,
|
|
3320
|
+
KI as audioInputData,
|
|
3321
|
+
JI as audioPlayback,
|
|
3322
3322
|
CI as detectStorageBackend,
|
|
3323
|
-
|
|
3324
|
-
|
|
3325
|
-
|
|
3323
|
+
YI as displayControl,
|
|
3324
|
+
UI as driveRedirection,
|
|
3325
|
+
SI as enableCredssp,
|
|
3326
3326
|
HI as enableServerPointer,
|
|
3327
|
-
|
|
3328
|
-
|
|
3329
|
-
|
|
3327
|
+
eA as fileContentsRequestCallback,
|
|
3328
|
+
rA as fileContentsResponseCallback,
|
|
3329
|
+
zA as filesAvailableCallback,
|
|
3330
3330
|
MI as graphicsPipeline,
|
|
3331
|
-
|
|
3331
|
+
yI as h264Decoder,
|
|
3332
3332
|
EI as h264Supported,
|
|
3333
3333
|
NI as init,
|
|
3334
3334
|
II as initiateFileCopy,
|
|
3335
|
-
|
|
3335
|
+
hI as kdcProxyUrl,
|
|
3336
3336
|
LI as legacyGraphics,
|
|
3337
|
-
|
|
3337
|
+
PA as lockCallback,
|
|
3338
3338
|
uA as locksExpiredCallback,
|
|
3339
|
-
|
|
3340
|
-
|
|
3339
|
+
aI as outboundMessageSizeLimit,
|
|
3340
|
+
RI as preConnectionBlob,
|
|
3341
3341
|
iI as printJobStreamCallbacks,
|
|
3342
3342
|
GI as printerDeviceId,
|
|
3343
3343
|
oI as printerDriverName,
|
|
3344
3344
|
wI as printerName,
|
|
3345
3345
|
$A as requestFileContents,
|
|
3346
3346
|
AI as submitFileContents,
|
|
3347
|
-
|
|
3348
|
-
|
|
3347
|
+
vA as unlockCallback,
|
|
3348
|
+
FI as vmConnect
|
|
3349
3349
|
};
|