1
0
mirror of https://github.com/bitwarden/browser synced 2026-02-10 21:50:15 +00:00

Moved reset to be in main / process launch

This commit is contained in:
Anders Åberg
2025-01-07 16:19:44 +01:00
parent 8b30e71525
commit 74995862e6
2 changed files with 2 additions and 3 deletions

View File

@@ -21,7 +21,6 @@ import { UserId } from "@bitwarden/common/types/guid";
import { KeyService as KeyServiceAbstraction } from "@bitwarden/key-management";
import { DesktopAutofillService } from "../../autofill/services/desktop-autofill.service";
import { DesktopSettingsService } from "../../platform/services/desktop-settings.service";
import { I18nRendererService } from "../../platform/services/i18n.renderer.service";
import { SshAgentService } from "../../platform/services/ssh-agent.service";
import { VersionService } from "../../platform/services/version.service";
@@ -48,7 +47,6 @@ export class InitService {
private versionService: VersionService,
private sshAgentService: SshAgentService,
private autofillService: DesktopAutofillService,
private desktopSettingsService: DesktopSettingsService,
@Inject(DOCUMENT) private document: Document,
) {}
@@ -81,7 +79,6 @@ export class InitService {
const htmlEl = this.win.document.documentElement;
htmlEl.classList.add("os_" + this.platformUtilsService.getDeviceString());
this.themingService.applyThemeChangesTo(this.document);
await this.desktopSettingsService.resetInModalMode();
this.versionService.init();

View File

@@ -272,6 +272,8 @@ export class Main {
this.migrationRunner.run().then(
async () => {
await this.toggleHardwareAcceleration();
// Reset modal mode to make sure main window is displayed correctly
await this.desktopSettingsService.resetInModalMode();
await this.windowMain.init();
await this.i18nService.init();
await this.messagingMain.init();