Add an option to disable encryption in new chats

Right now NeoChat (or more technically, libQuotient) decides to use
encryption by default in new chats. Some users may not prefer or need
this, so a new option is added under Security to change this behavior.

BUG: 498375
This commit is contained in:
Joshua Goins
2025-01-08 16:38:39 -05:00
parent 6fde07a20d
commit c315e817b2
3 changed files with 23 additions and 0 deletions

View File

@@ -145,6 +145,10 @@ void NeoChatConnection::connectSignals()
});
},
Qt::SingleShotConnection);
setDirectChatEncryptionDefault(NeoChatConfig::preferUsingEncryption());
connect(NeoChatConfig::self(), &NeoChatConfig::PreferUsingEncryptionChanged, this, [] {
setDirectChatEncryptionDefault(NeoChatConfig::preferUsingEncryption());
});
}
int NeoChatConnection::badgeNotificationCount() const