QML TreeView - handle Keyboard array events
Unsolved
QML and Qt Quick
-
Dear
I am currently trying to work an application with on the left side, a tree view and on the right size detailed info on the selected item.
Currently I'm able to catch the mouse event in the rowDeleagete:
rowDelegate : Rectangle{ color: styleData.alternate ? "white" : "#ffeeeeee" height: treeview.rowHeight MouseArea { anchors.fill: parent propagateComposedEvents: true onPressed: { __root.selectedItem = model console.log(model) mouse.accepted = false; } onReleased: mouse.accepted = false; onPositionChanged: mouse.accepted = false; onPressAndHold: mouse.accepted = false; } }
I am however not able to catch the keyboard event in the rowDelegate. It has been processed by another element already. The keyboard event can however be processed in the TreeView element but in that case, I don't find a way to access the selected item model data.
Can anyone assist me in this?
Kind regards
Pieter Cardoen