дзеркало
https://github.com/l0ng-ai/openidea.git
синхронізовано 2026-11-09 19:25:54 +02:00
fix(editor): auto-save when the app is deactivated while focus is in a frame (#1636)
With focus in a plugin's web view, the window's blur fires when the frame takes focus, before any edit, and not again when the user switches applications, so edits made in the frame weren't auto-saved. The editor now also saves on the application-deactivated event.
Цей коміт міститься в:
1 джерело
83d2f67b4f
коміт
a6cf4442d8
3 files changed
+31
No files matched your search
@@ -353,6 +353,8 @@ export class EditorController implements SlotHost {
|
||||
void this.saveCustomDocuments(true).catch((e) => this.documentError(e));
|
||||
}
|
||||
};
|
||||
if (this.manager.backend.onApplicationDeactivated)
|
||||
this.disposers.push(this.manager.backend.onApplicationDeactivated(onWindowBlur));
|
||||
const onPageHide = () => this.saveSession();
|
||||
if (typeof window !== "undefined") {
|
||||
if (this.manager.backend.syncFromDisk)
|
||||
|
||||
Reference in new issue
Заблокувати користувача