Commit 5369cba0 authored by Fushan Wen's avatar Fushan Wen 💬 Committed by Ben Cooksley
Browse files

WidgetExplorer: Do not auto focus the search field on tablet mode

On tablet mode, when opening Widget Explorer, the virtual keyboard will
be automatically opened, which makes the screen crowded. Only call
forceActiveFocus() when tablet mode is off.

BUG: 444716
parent cad50cb7
Pipeline #111091 passed with stage
in 5 minutes and 14 seconds
......@@ -7,6 +7,7 @@
import QtQuick 2.7
import QtQuick.Controls 2.5 as QQC2
import org.kde.kirigami 2.0 as Kirigami
import org.kde.plasma.components 2.0 as PC2 // for DialogStatus, ModelCOntextMenu, and Highlight
import org.kde.plasma.components 3.0 as PC3
import org.kde.plasma.core 2.0 as PlasmaCore
......@@ -230,7 +231,7 @@ PC3.Page {
widgetExplorer.widgetsModel.searchTerm = text
}
Component.onCompleted: forceActiveFocus()
Component.onCompleted: if (!Kirigami.Settings.tabletMode) forceActiveFocus()
}
PC3.ToolButton {
id: categoryButton
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment