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

@@ -27,11 +27,6 @@ import org.kde.neochat
DelegateContextMenu {
id: root
/**
* @brief The delegate type of the message.
*/
required property int messageComponentType
/**
* @brief The display text of the message as rich text.
*/
@@ -52,7 +47,8 @@ DelegateContextMenu {
DelegateContextMenu.ReplyThreadMessageAction {}
QQC2.Action {
Kirigami.Action {
visible: root.messageComponentType !== MessageComponentType.Other
text: i18nc("@action:inmenu As in 'Forward this message'", "Forward…")
icon.name: "mail-forward-symbolic"
onTriggered: {
@@ -69,6 +65,7 @@ DelegateContextMenu {
}
}
Kirigami.Action {
visible: root.messageComponentType !== MessageComponentType.Other || NeoChatConfig.relateAnyEvent
separator: true
}
DelegateContextMenu.RemoveMessageAction {}