chore: fix launcher linter warnings
This commit is contained in:
parent
20c7482b2b
commit
83cd02b90d
9 changed files with 11 additions and 11 deletions
|
|
@ -1,7 +1,7 @@
|
|||
pragma ComponentBehavior: Bound
|
||||
|
||||
import "items"
|
||||
import "services"
|
||||
import qs.modules.launcher.items
|
||||
import qs.modules.launcher.services
|
||||
import qs.components
|
||||
import qs.components.controls
|
||||
import qs.components.containers
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
pragma ComponentBehavior: Bound
|
||||
|
||||
import "services"
|
||||
import qs.modules.launcher.services
|
||||
import qs.components
|
||||
import qs.components.controls
|
||||
import qs.services
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@ Item {
|
|||
required property int rounding
|
||||
|
||||
readonly property bool showWallpapers: search.text.startsWith(`${Config.launcher.actionPrefix}wallpaper `)
|
||||
readonly property Item currentList: showWallpapers ? wallpaperList.item : appList.item
|
||||
readonly property var currentList: showWallpapers ? wallpaperList.item : appList.item // Can be either ListView or PathView, so can't type properly
|
||||
|
||||
anchors.horizontalCenter: parent.horizontalCenter
|
||||
anchors.bottom: parent.bottom
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@ PathView {
|
|||
readonly property int itemWidth: Config.launcher.sizes.wallpaperWidth * 0.8 + Appearance.padding.larger * 2
|
||||
|
||||
readonly property int numItems: {
|
||||
const screen = QsWindow.window?.screen;
|
||||
const screen = (QsWindow.window as QsWindow)?.screen;
|
||||
if (!screen)
|
||||
return 0;
|
||||
|
||||
|
|
@ -58,7 +58,7 @@ PathView {
|
|||
|
||||
onCurrentItemChanged: {
|
||||
if (currentItem)
|
||||
Wallpapers.preview(currentItem.modelData.path);
|
||||
Wallpapers.preview((currentItem as WallpaperItem).modelData.path);
|
||||
}
|
||||
|
||||
implicitWidth: Math.min(numItems, count) * itemWidth
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import "../services"
|
||||
import qs.modules.launcher.services
|
||||
import qs.components
|
||||
import qs.services
|
||||
import qs.config
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import "../services"
|
||||
import qs.modules.launcher.services
|
||||
import qs.components
|
||||
import qs.services
|
||||
import qs.config
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
import "../services"
|
||||
import qs.modules.launcher.services
|
||||
import qs.components
|
||||
import qs.services
|
||||
import qs.config
|
||||
|
|
|
|||
|
|
@ -14,7 +14,7 @@ Item {
|
|||
|
||||
scale: 0.5
|
||||
opacity: 0
|
||||
z: PathView.z ?? 0
|
||||
z: PathView.z ?? 0 // qmllint disable missing-property
|
||||
|
||||
Component.onCompleted: {
|
||||
scale = Qt.binding(() => PathView.isCurrentItem ? 1 : PathView.onPath ? 0.8 : 0);
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ Searcher {
|
|||
for (const f of s)
|
||||
flat.push(f);
|
||||
|
||||
schemes.model = flat.sort((a, b) => (a.name + a.flavour).localeCompare((b.name + b.flavour)));
|
||||
schemes.model = flat.sort((a, b) => String(a.name + a.flavour).localeCompare((b.name + b.flavour)));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue