1
0

Initialize main window with visible: false to prevent white flash (#4177)

This commit is contained in:
z0
2025-08-26 13:43:38 +03:00
committed by GitHub
parent 8cf42471a3
commit 0925abfd1c
2 changed files with 6 additions and 1 deletions

View File

@@ -191,6 +191,11 @@ fn main() {
.plugin(
tauri_plugin_window_state::Builder::default()
.with_filename("app-window-state.json")
// Use *only* POSITION and SIZE state flags, because saving VISIBLE causes the `visible: false` to not take effect
.with_state_flags(
tauri_plugin_window_state::StateFlags::POSITION
| tauri_plugin_window_state::StateFlags::SIZE,
)
.build(),
)
.setup(|app| {

View File

@@ -67,7 +67,7 @@
"width": 1280,
"minHeight": 700,
"minWidth": 1100,
"visible": true,
"visible": false,
"zoomHotkeysEnabled": false,
"decorations": false
}