refactor: when updating the tray, the logic is split to improve performance.

This commit is contained in:
huzibaca
2024-12-24 04:52:14 +08:00
parent 0669f7a10b
commit d9291d4f79
4 changed files with 143 additions and 80 deletions

View File

@@ -73,7 +73,7 @@ pub async fn patch_profiles_config(profiles: IProfiles) -> CmdResult {
match CoreManager::global().update_config().await {
Ok(_) => {
handle::Handle::refresh_clash();
let _ = handle::Handle::update_systray_part();
let _ = handle::Handle::update_systray_tooltip();
Config::profiles().apply();
wrap_err!(Config::profiles().data().save_file())?;
Ok(())