You've already forked AstralRinth
forked from didirus/AstralRinth
Initialize main window with visible: false to prevent white flash (#4177)
This commit is contained in:
@@ -191,6 +191,11 @@ fn main() {
|
|||||||
.plugin(
|
.plugin(
|
||||||
tauri_plugin_window_state::Builder::default()
|
tauri_plugin_window_state::Builder::default()
|
||||||
.with_filename("app-window-state.json")
|
.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(),
|
.build(),
|
||||||
)
|
)
|
||||||
.setup(|app| {
|
.setup(|app| {
|
||||||
|
|||||||
@@ -67,7 +67,7 @@
|
|||||||
"width": 1280,
|
"width": 1280,
|
||||||
"minHeight": 700,
|
"minHeight": 700,
|
||||||
"minWidth": 1100,
|
"minWidth": 1100,
|
||||||
"visible": true,
|
"visible": false,
|
||||||
"zoomHotkeysEnabled": false,
|
"zoomHotkeysEnabled": false,
|
||||||
"decorations": false
|
"decorations": false
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user