Partially working keyboard navigation support

This commit is contained in:
Cameron Gutman
2018-09-23 15:16:27 -07:00
parent f2e40889b2
commit 2e3de32810
6 changed files with 91 additions and 8 deletions
+24
View File
@@ -0,0 +1,24 @@
import QtQuick 2.0
import QtQuick.Controls 2.2
ItemDelegate {
property GridView grid
Keys.onLeftPressed: {
grid.moveCurrentIndexLeft()
}
Keys.onRightPressed: {
grid.moveCurrentIndexRight()
}
Keys.onDownPressed: {
grid.moveCurrentIndexDown()
}
Keys.onUpPressed: {
grid.moveCurrentIndexUp()
}
Keys.onReturnPressed: {
clicked()
}
}