mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-15 15:52:21 +00:00
Keep Contacts, active layer intents and mapped sites across globe switches
This commit is contained in:
1 parent
81bcae907f
commit
87bbe14748
35 files changed
+465
-118
No files matched your search
@@ -124,12 +124,19 @@ async function reconcile(remember = false) {
|
||||
const previous = kind;
|
||||
let cover;
|
||||
let cockpit;
|
||||
const handoffHash = remember ? location.hash : null;
|
||||
try {
|
||||
while (pageEngineKind() !== kind) {
|
||||
cover ??= keepGlobeFrame(application.getComponents().scene.engine);
|
||||
cockpit = application
|
||||
.getComponents()
|
||||
.controls.styleManager.getCockpitState();
|
||||
const manager = application.getComponents().data.dataManager;
|
||||
layerSession.handoffLayers = location.hash === handoffHash
|
||||
? new Map([...manager.layers].map(([id, entry]) => [
|
||||
id, { entry: entry.module.attachRenderer ? entry : null, enabled: manager.isEffectivelyEnabled(id) },
|
||||
]))
|
||||
: null;
|
||||
renderers.retain(kind);
|
||||
await application.destroy();
|
||||
await start(pageEngineKind(), true, cockpit);
|
||||
@@ -156,6 +163,7 @@ async function reconcile(remember = false) {
|
||||
report(recoveryError);
|
||||
}
|
||||
} finally {
|
||||
layerSession.handoffLayers = null;
|
||||
cover?.remove();
|
||||
busy = false;
|
||||
present();
|
||||
|
||||
Reference in new issue
Block a user