mirror of
https://github.com/CherryHQ/cherry-studio.git
synced 2025-12-23 10:00:08 +08:00
fix: electron-store config.json missing
* Added 'electron-store' to the Vite configuration for Electron. * Imported configuration from '@main/config' in the main index file. * Changed default return value for getTrayOnClose method in ConfigManager to false
This commit is contained in:
parent
f7b5bd8d22
commit
b2ceea2483
@ -1,3 +1,5 @@
|
||||
import '@main/config'
|
||||
|
||||
import { electronApp, optimizer } from '@electron-toolkit/utils'
|
||||
import { replaceDevtoolsFont } from '@main/utils/windowUtil'
|
||||
import { IpcChannel } from '@shared/IpcChannel'
|
||||
@ -42,7 +44,7 @@ if (!app.requestSingleInstanceLock()) {
|
||||
} else {
|
||||
// Portable dir must be setup before app ready
|
||||
setUserDataDir()
|
||||
|
||||
|
||||
// This method will be called when Electron has finished
|
||||
// initialization and is ready to create browser windows.
|
||||
// Some APIs can only be used after this event occurs.
|
||||
|
||||
@ -62,7 +62,7 @@ export class ConfigManager {
|
||||
}
|
||||
|
||||
getTrayOnClose(): boolean {
|
||||
return !!this.get(ConfigKeys.TrayOnClose, true)
|
||||
return !!this.get(ConfigKeys.TrayOnClose, false)
|
||||
}
|
||||
|
||||
setTrayOnClose(value: boolean) {
|
||||
|
||||
Loading…
Reference in New Issue
Block a user