From 8dd5ba745f138ee9230f16684d41133a4021143f Mon Sep 17 00:00:00 2001 From: Joshua Goins Date: Wed, 11 Feb 2026 18:46:31 -0500 Subject: [PATCH] Add an option to toggle whether a room is a direct chat or not This is useful if you accidentally created a room with someone, but not as a "direct chat". Since this is a weird option, I stuck it under developer tools for now but it could possibly surface into the regular UI in the future. --- src/devtools/RoomData.qml | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/src/devtools/RoomData.qml b/src/devtools/RoomData.qml index 5b175b49e..9e480d5e0 100644 --- a/src/devtools/RoomData.qml +++ b/src/devtools/RoomData.qml @@ -36,10 +36,25 @@ ColumnLayout { dialog.chosen.connect(id => root.room = root.connection.room(id)) } } + FormCard.FormDelegateSeparator {} FormCard.FormTextDelegate { visible: root.room text: i18n("Room Id: %1", root.room.id) } + FormCard.FormDelegateSeparator {} + FormCard.FormCheckDelegate { + visible: root.room + text: i18nc("@option:check Toggle for whether this room is considered a direct chat or not", "Direct Chat") + checked: root.room.isDirectChat() + enabled: root.room.totalMemberCount === 2 + onCheckedChanged: { + if (checked) { + root.room.markAsDirectChat(); + } else { + root.connection.removeFromDirectChats(root.room.id); + } + } + } } FormCard.FormHeader { title: i18n("Room Account Data")