Support menu key for room/member lists currentItem
Allow opening context menu for AccountDelegate, RoomDelegate and MemberDelegate by selecting an item with up/down (when focusing filter field) and pressing the menu key.
This commit is contained in:
@@ -55,6 +55,10 @@ Rectangle {
|
|||||||
if (window.settings.clearRoomFilterOnEnter) text = ""
|
if (window.settings.clearRoomFilterOnEnter) text = ""
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Keys.onMenuPressed:
|
||||||
|
if (roomList.currentItem)
|
||||||
|
roomList.currentItem.doRightClick(false)
|
||||||
|
|
||||||
Keys.onEscapePressed: {
|
Keys.onEscapePressed: {
|
||||||
mainPane.toggleFocus()
|
mainPane.toggleFocus()
|
||||||
if (window.settings.clearRoomFilterOnEscape) text = ""
|
if (window.settings.clearRoomFilterOnEscape) text = ""
|
||||||
|
@@ -43,6 +43,9 @@ HColumnLayout {
|
|||||||
currentItem.leftClicked()
|
currentItem.leftClicked()
|
||||||
currentItem.clicked()
|
currentItem.clicked()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Keys.onMenuPressed:
|
||||||
|
if (currentItem) currentItem.doRightClick(false)
|
||||||
}
|
}
|
||||||
|
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
Reference in New Issue
Block a user