diff --git a/electron/Index.vue b/electron/Index.vue index 3441c6b..61cebe4 100644 --- a/electron/Index.vue +++ b/electron/Index.vue @@ -296,8 +296,10 @@ Vue.set(core.state, 'generalSettings', this.settings); - electron.ipcRenderer.on('settings', - (_e: Event, settings: GeneralSettings) => core.state.generalSettings = this.settings = settings); + electron.ipcRenderer.on('settings', (_e: Event, settings: GeneralSettings) => { + log.debug('settings.update.index'); + core.state.generalSettings = this.settings = settings; + }); electron.ipcRenderer.on('open-profile', (_e: Event, name: string) => { const profileViewer = this.$refs['profileViewer']; @@ -486,6 +488,8 @@ getThemeClass(): Record { + // console.log('getThemeClassIndex', core.state.generalSettings?.risingDisableWindowsHighContrast); + try { return { [`theme-${this.settings.theme}`]: true, diff --git a/electron/Window.vue b/electron/Window.vue index 0bcd141..628e327 100644 --- a/electron/Window.vue +++ b/electron/Window.vue @@ -48,7 +48,6 @@ import {GeneralSettings} from './common'; import { getSafeLanguages, updateSupportedLanguages } from './language'; import log from 'electron-log'; - import core from '../chat/core'; // tslint:disable-line: match-default-export-name const browserWindow = remote.getCurrentWindow(); @@ -147,6 +146,8 @@ log.debug('init.window.languages'); electron.ipcRenderer.on('settings', (_e: Event, settings: GeneralSettings) => { + log.debug('settings.update.window'); + this.settings = settings; log.transports.file.level = settings.risingSystemLogLevel; @@ -381,10 +382,12 @@ } getThemeClass() { + // console.log('getThemeClassWindow', this.settings?.risingDisableWindowsHighContrast); + try { return { ['platform-' + this.platform]: true, - disableWindowsHighContrast: core.state.generalSettings?.risingDisableWindowsHighContrast || false + disableWindowsHighContrast: this.settings?.risingDisableWindowsHighContrast || false }; } catch (err) { return {