Wallpaper Selector: auto-focus search field

This commit is contained in:
LemmyCook
2025-09-18 17:47:26 -04:00
parent 4e67f26576
commit 6fe498ce19
@@ -148,6 +148,7 @@ NPanel {
}
NTextInput {
id: searchInput
placeholderText: "Type to filter wallpapers..."
text: filterText
onTextChanged: {
@@ -155,6 +156,11 @@ NPanel {
updateFiltered()
}
Layout.fillWidth: true
Component.onCompleted: {
if (searchInput.inputItem && searchInput.inputItem.visible) {
searchInput.inputItem.forceActiveFocus()
}
}
}
}
@@ -187,7 +193,6 @@ NPanel {
anchors.fill: parent
model: filteredWallpapers
interactive: false
clip: true
property int columns: 4
property int itemSize: Math.floor((width - leftMargin - rightMargin - (columns * Style.marginS * scaling)) / columns)