@forgeax/app-shell 0.66.0 → 0.66.1
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.
|
@@ -264,7 +264,8 @@ function createDockLayoutPersistence(adapter) {
|
|
|
264
264
|
}
|
|
265
265
|
function installDockLayoutObservation(source, adapter) {
|
|
266
266
|
let active = true;
|
|
267
|
-
|
|
267
|
+
let subscription;
|
|
268
|
+
const onDidLayoutChange = () => {
|
|
268
269
|
if (!active) return;
|
|
269
270
|
let scope;
|
|
270
271
|
try {
|
|
@@ -285,12 +286,21 @@ function installDockLayoutObservation(source, adapter) {
|
|
|
285
286
|
adapter.onCommitted();
|
|
286
287
|
} catch {
|
|
287
288
|
}
|
|
288
|
-
}
|
|
289
|
+
};
|
|
290
|
+
try {
|
|
291
|
+
subscription = source.onDidLayoutChange(onDidLayoutChange);
|
|
292
|
+
} catch {
|
|
293
|
+
active = false;
|
|
294
|
+
try {
|
|
295
|
+
subscription?.dispose();
|
|
296
|
+
} catch {
|
|
297
|
+
}
|
|
298
|
+
}
|
|
289
299
|
return () => {
|
|
290
300
|
if (!active) return;
|
|
291
301
|
active = false;
|
|
292
302
|
try {
|
|
293
|
-
subscription
|
|
303
|
+
subscription?.dispose();
|
|
294
304
|
} catch {
|
|
295
305
|
}
|
|
296
306
|
};
|
package/dist/dock.js
CHANGED
package/dist/react.js
CHANGED