Feature(custom): change default value of show window on startup to true

This commit is contained in:
Kuingsmile
2025-08-28 15:11:34 +08:00
parent 94027733fc
commit ca0b9251d3
6 changed files with 6 additions and 6 deletions

View File

@@ -281,7 +281,7 @@ winget install OpenListTeam.OpenListDesktop
"gh_proxy_api": false,
"open_links_in_browser": true,
"admin_password": "",
"show_window_on_startup": false
"show_window_on_startup": true
}
}
```

View File

@@ -281,7 +281,7 @@ Add custom Rclone flags for optimal performance:
"gh_proxy_api": false,
"open_links_in_browser": true,
"admin_password": "",
"show_window_on_startup": false
"show_window_on_startup": true
}
}
```

View File

@@ -20,7 +20,7 @@ impl AppConfig {
gh_proxy_api: Some(false),
open_links_in_browser: Some(false),
admin_password: None,
show_window_on_startup: Some(false),
show_window_on_startup: Some(true),
}
}
}

View File

@@ -186,7 +186,7 @@ pub fn run() {
utils::init_log::init_log()?;
utils::path::get_app_config_dir()?;
let settings = conf::config::MergedSettings::load().unwrap_or_default();
let show_window = settings.app.show_window_on_startup.unwrap_or(false);
let show_window = settings.app.show_window_on_startup.unwrap_or(true);
let app_state = app.state::<AppState>();
if let Err(e) = app_state.init(app_handle) {

View File

@@ -16,7 +16,7 @@ export const useAppStore = defineStore('app', () => {
gh_proxy_api: false,
open_links_in_browser: false,
admin_password: undefined,
show_window_on_startup: false
show_window_on_startup: true
}
})
const openlistCoreStatus = ref<OpenListCoreStatus>({ running: false })

View File

@@ -96,7 +96,7 @@ onMounted(async () => {
if (!appSettings.gh_proxy) appSettings.gh_proxy = ''
if (appSettings.gh_proxy_api === undefined) appSettings.gh_proxy_api = false
if (appSettings.open_links_in_browser === undefined) appSettings.open_links_in_browser = false
if (appSettings.show_window_on_startup === undefined) appSettings.show_window_on_startup = false
if (appSettings.show_window_on_startup === undefined) appSettings.show_window_on_startup = true
if (!appSettings.admin_password) appSettings.admin_password = ''
originalOpenlistPort = openlistCoreSettings.port || 5244
originalDataDir = openlistCoreSettings.data_dir