fix: save window state (#313)

This commit is contained in:
lencx
2023-02-12 00:49:55 +08:00
parent 4cba634d4a
commit 522f7b86b8
3 changed files with 26 additions and 0 deletions

View File

@@ -30,6 +30,7 @@ tauri = { version = "1.2.4", features = ["api-all", "devtools", "global-shortcut
tauri-plugin-positioner = { version = "1.0.4", features = ["system-tray"] }
tauri-plugin-log = { git = "https://github.com/lencx/tauri-plugins-workspace", branch = "dev", features = ["colored"] }
tauri-plugin-autostart = { git = "https://github.com/lencx/tauri-plugins-workspace", branch = "dev" }
tauri-plugin-window-state = { git = "https://github.com/lencx/tauri-plugins-workspace", branch = "dev" }
# sqlx = { version = "0.6.2", features = ["runtime-tokio-rustls", "sqlite"] }

View File

@@ -52,6 +52,7 @@ async fn main() {
MacosLauncher::LaunchAgent,
None,
))
.plugin(tauri_plugin_window_state::Builder::default().build())
.invoke_handler(tauri::generate_handler![
cmd::drag_window,
cmd::fullscreen,