From c2c7078957a93dc4e6919cb93917d0568edd4584 Mon Sep 17 00:00:00 2001 From: end-4 <97237370+end-4@users.noreply.github.com> Date: Wed, 11 Jun 2025 22:30:55 +0200 Subject: [PATCH] translator: remove debug print --- .../quickshell/modules/sidebarLeft/Translator.qml | 6 +++--- .config/quickshell/services/ConfigLoader.qml | 14 ++------------ 2 files changed, 5 insertions(+), 15 deletions(-) diff --git a/.config/quickshell/modules/sidebarLeft/Translator.qml b/.config/quickshell/modules/sidebarLeft/Translator.qml index 8f93b50d7..999fe3e44 100644 --- a/.config/quickshell/modules/sidebarLeft/Translator.qml +++ b/.config/quickshell/modules/sidebarLeft/Translator.qml @@ -47,7 +47,7 @@ Item { repeat: false onTriggered: () => { if (root.inputField.text.trim().length > 0) { - console.log("Translating with command:", translateProc.command); + // console.log("Translating with command:", translateProc.command); translateProc.running = false; translateProc.buffer = ""; // Clear the buffer translateProc.running = true; // Restart the process @@ -72,8 +72,8 @@ Item { onExited: (exitCode, exitStatus) => { // 1. Split into sections by double newlines const sections = translateProc.buffer.trim().split(/\n\s*\n/); - console.log("BUFFER:", translateProc.buffer); - console.log("SECTIONS:", sections); + // console.log("BUFFER:", translateProc.buffer); + // console.log("SECTIONS:", sections); // 2. Extract relevant data root.translatedText = sections.length > 1 ? sections[1].trim() : ""; diff --git a/.config/quickshell/services/ConfigLoader.qml b/.config/quickshell/services/ConfigLoader.qml index 688bb47bb..347e8f400 100644 --- a/.config/quickshell/services/ConfigLoader.qml +++ b/.config/quickshell/services/ConfigLoader.qml @@ -23,16 +23,11 @@ Singleton { property bool preventNextLoad: false property var preventNextNotification: false - onPreventNextNotificationChanged: { - console.log("HMM: preventNextNotification:", root.preventNextNotification); - } - function loadConfig() { configFileView.reload() } function applyConfig(fileContent) { - console.log("[ConfigLoader] Applying config from file:", root.filePath); try { if (fileContent.trim() === "") { console.warn("[ConfigLoader] Config file is empty, skipping load."); @@ -82,8 +77,6 @@ Singleton { } } - console.log(parents.join(".")); - console.log(`[ConfigLoader] Setting live config value: ${nestedKey} = ${convertedValue}`); obj[keys[keys.length - 1]] = convertedValue; } @@ -95,7 +88,6 @@ Singleton { function setConfigValueAndSave(nestedKey, value, preventNextNotification = true) { setLiveConfigValue(nestedKey, value); root.preventNextNotification = preventNextNotification; - console.log("SETTING: preventNextNotification:", root.preventNextNotification); saveConfig(); } @@ -104,7 +96,6 @@ Singleton { interval: ConfigOptions.hacks.arbitraryRaceConditionDelay running: false onTriggered: { - console.log("GONNA APPLY KONFIG preventNextNotification:", root.preventNextNotification); if (root.preventNextLoad) { root.preventNextLoad = false; return; @@ -112,12 +103,11 @@ Singleton { if (root.firstLoad) { root.applyConfig(configFileView.text()) } else { - console.log("APPLYING: preventNextNotification:", root.preventNextNotification); root.applyConfig(configFileView.text()) if (!root.preventNextNotification) { - Hyprland.dispatch(`exec notify-send "${qsTr("Shell configuration reloaded")}" "${root.filePath}"`) + // Hyprland.dispatch(`exec notify-send "${qsTr("Shell configuration reloaded")}" "${root.filePath}"`) } else { - // root.preventNextNotification = false; + root.preventNextNotification = false; } } }