aboutsummaryrefslogtreecommitdiffstats
path: root/desktop/modules/appearance/WallEngine.qml
diff options
context:
space:
mode:
Diffstat (limited to 'desktop/modules/appearance/WallEngine.qml')
-rw-r--r--desktop/modules/appearance/WallEngine.qml14
1 files changed, 14 insertions, 0 deletions
diff --git a/desktop/modules/appearance/WallEngine.qml b/desktop/modules/appearance/WallEngine.qml
index 54705f6..f8d96ac 100644
--- a/desktop/modules/appearance/WallEngine.qml
+++ b/desktop/modules/appearance/WallEngine.qml
@@ -135,6 +135,20 @@ Singleton {
nextAt = Date.now() + timer.interval;
}
+ // The pair up now differs from home only when a tick put it there, with
+ // the light run.
+ readonly property bool keepable: on
+ && (cfg.homeH !== Wallpapers.currentH || cfg.homeV !== Wallpapers.currentV)
+ // Liked what a tick put up: a full run of the same pair brings GRUB, the
+ // homepage and SDDM along, and it becomes home, so switching off does not
+ // undo that, and stays up a full interval like a pick by hand.
+ function keep() {
+ const h = Wallpapers.currentH, v = Wallpapers.currentV;
+ if (!keepable || !Wallpapers.run(h, v, "keep")) return;
+ Prefs.setWallEngine({ homeH: h, homeV: v });
+ restartTimer();
+ }
+
// A switch-off during a run cannot start its own; it goes when that run
// finishes.
property bool homeWaiting: false