diff options
| author | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-08-09 00:13:48 +1000 |
|---|---|---|
| committer | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-08-09 00:13:48 +1000 |
| commit | 88a3f09de553e11985f12ecaf40f334fad729ab9 (patch) | |
| tree | 71d0a1ff00b54ed61e50cafcab8617173b8bc0ad /modules/launcher | |
| parent | paths: better to string (diff) | |
| download | caelestia-shell-88a3f09de553e11985f12ecaf40f334fad729ab9.tar.gz caelestia-shell-88a3f09de553e11985f12ecaf40f334fad729ab9.tar.bz2 caelestia-shell-88a3f09de553e11985f12ecaf40f334fad729ab9.zip | |
config: make appearance configurable
Diffstat (limited to 'modules/launcher')
| -rw-r--r-- | modules/launcher/WallpaperList.qml | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/modules/launcher/WallpaperList.qml b/modules/launcher/WallpaperList.qml index 4e2a175..9c402ad 100644 --- a/modules/launcher/WallpaperList.qml +++ b/modules/launcher/WallpaperList.qml @@ -1,3 +1,5 @@ +pragma ComponentBehavior: Bound + import "items" import qs.services import qs.config @@ -18,11 +20,11 @@ PathView { const max = Config.launcher.maxWallpapers; const maxItemsOnScreen = Math.floor(screenWidth / itemWidth); - const visible = Math.min(maxItemsOnScreen, max, scriptModel.values.length) + const visible = Math.min(maxItemsOnScreen, max, scriptModel.values.length); if (visible === 2) - return 1 - else if (visible > 1 && visible %2 === 0) - return visible - 1 + return 1; + else if (visible > 1 && visible % 2 === 0) + return visible - 1; return visible; } |