diff options
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; } |