From 9eda8aaa99bb38b49dd52fa2e5502501f2be0389 Mon Sep 17 00:00:00 2001 From: Your Name Date: Tue, 17 Feb 2026 21:36:30 +0200 Subject: [PATCH] =?UTF-8?q?fix:=20window=20dragging=20=E2=80=94=20use=20st?= =?UTF-8?q?artDragging()=20API=20instead=20of=20data=20attribute?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src-tauri/capabilities/default.json | 2 ++ src/components/TitleBar.vue | 18 +++++++++++++----- 2 files changed, 15 insertions(+), 5 deletions(-) diff --git a/src-tauri/capabilities/default.json b/src-tauri/capabilities/default.json index 4241219..b095b2c 100644 --- a/src-tauri/capabilities/default.json +++ b/src-tauri/capabilities/default.json @@ -13,6 +13,8 @@ "core:window:allow-hide", "core:window:allow-set-focus", "core:window:allow-is-maximized", + "core:window:allow-start-dragging", + "core:window:allow-toggle-maximize", "shell:allow-open", "dialog:allow-open", "dialog:allow-save", diff --git a/src/components/TitleBar.vue b/src/components/TitleBar.vue index 2589b9c..4cb16fa 100644 --- a/src/components/TitleBar.vue +++ b/src/components/TitleBar.vue @@ -31,18 +31,26 @@ async function toggleMaximize() { async function close() { await appWindow.close() } + +async function startDrag() { + await appWindow.startDragging() +} + +async function handleDoubleClick() { + await toggleMaximize() +}