From 867444a29ce57a88cf8db54ef7ba3f2d371e6c44 Mon Sep 17 00:00:00 2001 From: quadbyte Date: Fri, 15 Aug 2025 06:49:24 -0400 Subject: [PATCH] Fix Matugen, NPanel overlay and probably SWWW --- Services/Colors.qml | 10 ++++++++-- Services/Settings.qml | 2 +- Services/Wallpapers.qml | 15 ++++++++++++--- Widgets/NPanel.qml | 2 +- 4 files changed, 22 insertions(+), 7 deletions(-) diff --git a/Services/Colors.qml b/Services/Colors.qml index df0cc39..d77af2d 100644 --- a/Services/Colors.qml +++ b/Services/Colors.qml @@ -97,8 +97,14 @@ Singleton { id: customColorsFile path: Settings.configDir + "colors.json" watchChanges: true - onFileChanged: reload() - onAdapterUpdated: writeAdapter() + onFileChanged: { + console.log("[Colors] reloading colors file from disk") + reload() + } + onAdapterUpdated: { + console.log("[Colors] writing colors to disk, primary color:", mPrimary) + writeAdapter() + } onLoadFailed: function (error) { if (error.toString().includes("No such file") || error === 2) { // File doesn't exist, create it with default values diff --git a/Services/Settings.qml b/Services/Settings.qml index a6a5f4c..5e2d4f4 100644 --- a/Services/Settings.qml +++ b/Services/Settings.qml @@ -48,7 +48,7 @@ Singleton { console.log("[Settings] Loaded") Qt.callLater(function () { if (adapter.wallpaper.current !== "") { - console.log("[Settings] Set current wallpaper") + console.log("[Settings] Set current wallpaper", adapter.wallpaper.current) Wallpapers.setCurrentWallpaper(adapter.wallpaper.current, true) } }) diff --git a/Services/Wallpapers.qml b/Services/Wallpapers.qml index e3a1895..82e9e38 100644 --- a/Services/Wallpapers.qml +++ b/Services/Wallpapers.qml @@ -19,6 +19,8 @@ Singleton { property var wallpaperList: [] property string currentWallpaper: Settings.data.wallpaper.current property bool scanning: false + + // SWWW property string transitionType: Settings.data.wallpaper.swww.transitionType property var randomChoices: ["simple", "fade", "left", "right", "top", "bottom", "wipe", "wave", "grow", "center", "any", "outer"] @@ -120,7 +122,8 @@ Singleton { if (status === FolderListModel.Ready) { var files = [] for (var i = 0; i < count; i++) { - var filepath = folderModel.folder + "/" + get(i, "fileName") + var directory = (Settings.data.wallpaper.directory !== undefined ? Settings.data.wallpaper.directory : "") + var filepath = directory + "/" + get(i, "fileName") files.push(filepath) } wallpaperList = files @@ -157,8 +160,14 @@ Singleton { running: false stdout: StdioCollector { onStreamFinished: { - - //console.log(this.text) + console.log("[Wallpapers] generated colors from image") + } + } + stderr: StdioCollector { + onStreamFinished: { + if (this.text !== "") { + console.error(this.text) + } } } } diff --git a/Widgets/NPanel.qml b/Widgets/NPanel.qml index 58353b1..8c1c67e 100644 --- a/Widgets/NPanel.qml +++ b/Widgets/NPanel.qml @@ -9,7 +9,7 @@ PanelWindow { readonly property real scaling: Scaling.scale(screen) property bool showOverlay: Settings.data.general.dimDesktop property int topMargin: Style.barHeight * scaling - property color overlayColor: showOverlay ? Colors.overlay : "transparent" + property color overlayColor: showOverlay ? Colors.applyOpacity(Colors.mShadow, "AA") : "transparent" signal dismissed