diff --git a/src/gui/Base/HTile.qml b/src/gui/Base/HTile.qml index bb6bcccd..c4aca9db 100644 --- a/src/gui/Base/HTile.qml +++ b/src/gui/Base/HTile.qml @@ -110,12 +110,21 @@ HButton { TapHandler { acceptedButtons: Qt.RightButton + acceptedPointerTypes: PointerDevice.GenericPointer onTapped: { rightClicked() if (contextMenu) contextMenuLoader.active = true } } + TapHandler { + acceptedPointerTypes: PointerDevice.Finger | PointerDevice.Pen + onLongPressed: { + rightClicked() + if (contextMenu) contextMenuLoader.active = true + } + } + Connections { enabled: contextMenuLoader.status === Loader.Ready target: contextMenuLoader.item diff --git a/src/gui/Pages/Chat/Timeline/EventDelegate.qml b/src/gui/Pages/Chat/Timeline/EventDelegate.qml index d0139dd8..393ade52 100644 --- a/src/gui/Pages/Chat/Timeline/EventDelegate.qml +++ b/src/gui/Pages/Chat/Timeline/EventDelegate.qml @@ -106,9 +106,15 @@ HColumnLayout { TapHandler { acceptedButtons: Qt.RightButton + acceptedPointerTypes: PointerDevice.GenericPointer onTapped: openContextMenu() } + TapHandler { + acceptedPointerTypes: PointerDevice.Finger | PointerDevice.Pen + onLongPressed: openContextMenu() + } + HMenu { id: contextMenu