Fix tab order after expanding categories or using search

This reimplements the behavior of pressing tab/backtab to force the correct order of items in the listview.
This commit is contained in:
fieldOfView 2017-06-26 14:35:37 +02:00
parent 8917762ed5
commit 0f9cfa0304
8 changed files with 93 additions and 2 deletions

View file

@ -9,6 +9,7 @@ import UM 1.1 as UM
SettingItem
{
id: base
property var focusItem: input
contents: Rectangle
{
@ -93,7 +94,15 @@ SettingItem
right: parent.right
verticalCenter: parent.verticalCenter
}
activeFocusOnTab: true
Keys.onTabPressed:
{
base.setActiveFocusToNextSetting(true)
}
Keys.onBacktabPressed:
{
base.setActiveFocusToNextSetting(false)
}
Keys.onReleased:
{