From b0cdaa3ec8fd2f445712574506bec090a69bc146 Mon Sep 17 00:00:00 2001 From: BiggerRain <15911122312@163.COM> Date: Mon, 5 Jan 2026 16:41:14 +0800 Subject: [PATCH] fix: force check window to center on every show (#1044) --- src-tauri/src/lib.rs | 1 + src-tauri/tauri.conf.json | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src-tauri/src/lib.rs b/src-tauri/src/lib.rs index e16ed86d..1c5e74fc 100644 --- a/src-tauri/src/lib.rs +++ b/src-tauri/src/lib.rs @@ -401,6 +401,7 @@ async fn show_check(app_handle: AppHandle) { .get_webview_window(CHECK_WINDOW_LABEL) .expect("we have a check window"); + window.center().unwrap(); window.show().unwrap(); window.unminimize().unwrap(); window.set_focus().unwrap(); diff --git a/src-tauri/tauri.conf.json b/src-tauri/tauri.conf.json index 5ad8899d..3da062c7 100644 --- a/src-tauri/tauri.conf.json +++ b/src-tauri/tauri.conf.json @@ -64,7 +64,7 @@ "minWidth": 340, "height": 260, "minHeight": 260, - "center": false, + "center": true, "decorations": false, "transparent": true, "maximizable": false,