summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--services/Colours.qml6
-rw-r--r--services/Wallpapers.qml2
2 files changed, 7 insertions, 1 deletions
diff --git a/services/Colours.qml b/services/Colours.qml
index 8b6ce00..aa4282f 100644
--- a/services/Colours.qml
+++ b/services/Colours.qml
@@ -12,6 +12,7 @@ Singleton {
readonly property list<string> colourNames: ["rosewater", "flamingo", "pink", "mauve", "red", "maroon", "peach", "yellow", "green", "teal", "sky", "sapphire", "blue", "lavender"]
property bool showPreview
+ property bool endPreviewOnNextChange
property bool light
readonly property Colours palette: showPreview ? preview : current
readonly property Colours current: Colours {}
@@ -42,6 +43,11 @@ Singleton {
if (colours.hasOwnProperty(name))
colours[name] = `#${colour.trim()}`;
}
+
+ if (isPreview && endPreviewOnNextChange) {
+ showPreview = false;
+ endPreviewOnNextChange = false;
+ }
}
function setMode(mode: string): void {
diff --git a/services/Wallpapers.qml b/services/Wallpapers.qml
index 1de5227..0b2efa0 100644
--- a/services/Wallpapers.qml
+++ b/services/Wallpapers.qml
@@ -46,7 +46,7 @@ Singleton {
function stopPreview(): void {
showPreview = false;
- Colours.showPreview = false;
+ Colours.endPreviewOnNextChange = true;
}
reloadableId: "wallpapers"