diff options
Diffstat (limited to 'framework/qml/ComboBox.qml')
-rw-r--r-- | framework/qml/ComboBox.qml | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/framework/qml/ComboBox.qml b/framework/qml/ComboBox.qml index 71c9bcc3..64a1c7b3 100644 --- a/framework/qml/ComboBox.qml +++ b/framework/qml/ComboBox.qml | |||
@@ -32,6 +32,13 @@ T.ComboBox { | |||
32 | spacing: Kube.Units.largeSpacing | 32 | spacing: Kube.Units.largeSpacing |
33 | padding: Kube.Units.smallSpacing | 33 | padding: Kube.Units.smallSpacing |
34 | 34 | ||
35 | //Autoselect the first item | ||
36 | onCountChanged: { | ||
37 | if (currentIndex < 0) { | ||
38 | currentIndex = 0 | ||
39 | } | ||
40 | } | ||
41 | |||
35 | contentItem: Kube.Label { | 42 | contentItem: Kube.Label { |
36 | leftPadding: Kube.Units.smallSpacing | 43 | leftPadding: Kube.Units.smallSpacing |
37 | rightPadding: Kube.Units.largeSpacing | 44 | rightPadding: Kube.Units.largeSpacing |