diff options
| author | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-05-05 17:06:12 +1000 |
|---|---|---|
| committer | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-05-05 17:06:12 +1000 |
| commit | 97ea9d49929b223036e96388c66d700ea731d6db (patch) | |
| tree | 74b80e05731e7c14903a253b2d972731584f375f /modules/launcher | |
| parent | feat: wallpaper (diff) | |
| download | caelestia-shell-97ea9d49929b223036e96388c66d700ea731d6db.tar.gz caelestia-shell-97ea9d49929b223036e96388c66d700ea731d6db.tar.bz2 caelestia-shell-97ea9d49929b223036e96388c66d700ea731d6db.zip | |
feat: wallpaper and colour preview
Diffstat (limited to 'modules/launcher')
| -rw-r--r-- | modules/launcher/WallpaperList.qml | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/launcher/WallpaperList.qml b/modules/launcher/WallpaperList.qml index 9582957..430964e 100644 --- a/modules/launcher/WallpaperList.qml +++ b/modules/launcher/WallpaperList.qml @@ -24,6 +24,12 @@ PathView { } Component.onCompleted: currentIndex = Wallpapers.list.findIndex(w => w.path === Wallpapers.current) + Component.onDestruction: Wallpapers.stopPreview() + + onCurrentItemChanged: { + if (currentItem) + Wallpapers.preview(currentItem.modelData.path); + } implicitWidth: Math.min(LauncherConfig.maxWallpapers, count) * (LauncherConfig.sizes.wallpaperWidth * 0.8 + Appearance.padding.larger * 2) pathItemCount: LauncherConfig.maxWallpapers |