Add a dev setting to allow relations to be sent to any message

Add a dev setting to allow relations to be sent to any message using the right click delegate menu. This shouldn't be a main feature, but since it's technically allowed in matrix this will help any future debugging
This commit is contained in:
James Graham
2025-07-28 19:47:29 +01:00
parent 6082bc89b0
commit f288367653
10 changed files with 63 additions and 19 deletions

View File

@@ -71,4 +71,26 @@ RowLayout {
cursorShape: parent.hoveredLink ? Qt.PointingHandCursor : Qt.IBeamCursor
}
}
TapHandler {
acceptedDevices: PointerDevice.Mouse | PointerDevice.TouchPad | PointerDevice.Stylus
acceptedButtons: Qt.RightButton
onTapped: _private.showMessageMenu()
}
TapHandler {
acceptedDevices: PointerDevice.TouchScreen
acceptedButtons: Qt.LeftButton
onLongPressed: _private.showMessageMenu()
}
QtObject {
id: _private
function showMessageMenu() {
if (!NeoChatConfig.developerTools) {
return;
}
RoomManager.viewEventMenu(root.modelData.eventId, root.Message.room, root.author, "", "");
}
}
}