From 0dc791bbba53b67e9a3a66f6aa565568d5bd8ab7 Mon Sep 17 00:00:00 2001 From: Skyler Lehmkuhl Date: Sun, 22 Dec 2024 05:33:06 -0500 Subject: [PATCH] Try to update window title --- src-tauri/capabilities/default.json | 1 + src/main.js | 2 ++ 2 files changed, 3 insertions(+) diff --git a/src-tauri/capabilities/default.json b/src-tauri/capabilities/default.json index 189b315..973db24 100644 --- a/src-tauri/capabilities/default.json +++ b/src-tauri/capabilities/default.json @@ -8,6 +8,7 @@ "permissions": [ "core:default", "core:window:allow-close", + "core:window:allow-set-title", "shell:allow-open", "fs:default", { diff --git a/src/main.js b/src/main.js index 34ea47a..d29abf6 100644 --- a/src/main.js +++ b/src/main.js @@ -2553,6 +2553,8 @@ async function _open(path) { } lastSaveIndex = undoStack.length; filePath = path + // Tauri thinks it is setting the title here, but it isn't getting updated + await getCurrentWindow().setTitle(await basename(filePath)) addRecentFile(path) updateUI() } else {