forked from blue/squawk
encrypted messages now are displayed in the feed
This commit is contained in:
parent
637eb702a8
commit
0a530bfa93
34 changed files with 439 additions and 245 deletions
|
@ -62,70 +62,78 @@ Shared::Global::ColorSchemeName Shared::Global::colorSchemeName = 0;
|
|||
Shared::Global::CreatePalette Shared::Global::createPalette = 0;
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
Shared::Global::Global():
|
||||
availability({
|
||||
tr("Online", "Availability"),
|
||||
tr("Away", "Availability"),
|
||||
tr("Absent", "Availability"),
|
||||
tr("Busy", "Availability"),
|
||||
tr("Chatty", "Availability"),
|
||||
tr("Invisible", "Availability"),
|
||||
tr("Offline", "Availability")
|
||||
QCoreApplication::translate("Global", "Online", "Availability"),
|
||||
QCoreApplication::translate("Global", "Away", "Availability"),
|
||||
QCoreApplication::translate("Global", "Absent", "Availability"),
|
||||
QCoreApplication::translate("Global", "Busy", "Availability"),
|
||||
QCoreApplication::translate("Global", "Chatty", "Availability"),
|
||||
QCoreApplication::translate("Global", "Invisible", "Availability"),
|
||||
QCoreApplication::translate("Global", "Offline", "Availability")
|
||||
}),
|
||||
connectionState({
|
||||
tr("Disconnected", "ConnectionState"),
|
||||
tr("Scheduled", "ConnectionState"),
|
||||
tr("Connecting", "ConnectionState"),
|
||||
tr("Connected", "ConnectionState"),
|
||||
tr("Error", "ConnectionState")
|
||||
QCoreApplication::translate("Global", "Disconnected", "ConnectionState"),
|
||||
QCoreApplication::translate("Global", "Scheduled", "ConnectionState"),
|
||||
QCoreApplication::translate("Global", "Connecting", "ConnectionState"),
|
||||
QCoreApplication::translate("Global", "Connected", "ConnectionState"),
|
||||
QCoreApplication::translate("Global", "Error", "ConnectionState")
|
||||
}),
|
||||
subscriptionState({
|
||||
tr("None", "SubscriptionState"),
|
||||
tr("From", "SubscriptionState"),
|
||||
tr("To", "SubscriptionState"),
|
||||
tr("Both", "SubscriptionState"),
|
||||
tr("Unknown", "SubscriptionState")
|
||||
QCoreApplication::translate("Global", "None", "SubscriptionState"),
|
||||
QCoreApplication::translate("Global", "From", "SubscriptionState"),
|
||||
QCoreApplication::translate("Global", "To", "SubscriptionState"),
|
||||
QCoreApplication::translate("Global", "Both", "SubscriptionState"),
|
||||
QCoreApplication::translate("Global", "Unknown", "SubscriptionState")
|
||||
}),
|
||||
affiliation({
|
||||
tr("Unspecified", "Affiliation"),
|
||||
tr("Outcast", "Affiliation"),
|
||||
tr("Nobody", "Affiliation"),
|
||||
tr("Member", "Affiliation"),
|
||||
tr("Admin", "Affiliation"),
|
||||
tr("Owner", "Affiliation")
|
||||
QCoreApplication::translate("Global", "Unspecified", "Affiliation"),
|
||||
QCoreApplication::translate("Global", "Outcast", "Affiliation"),
|
||||
QCoreApplication::translate("Global", "Nobody", "Affiliation"),
|
||||
QCoreApplication::translate("Global", "Member", "Affiliation"),
|
||||
QCoreApplication::translate("Global", "Admin", "Affiliation"),
|
||||
QCoreApplication::translate("Global", "Owner", "Affiliation")
|
||||
}),
|
||||
role({
|
||||
tr("Unspecified", "Role"),
|
||||
tr("Nobody", "Role"),
|
||||
tr("Visitor", "Role"),
|
||||
tr("Participant", "Role"),
|
||||
tr("Moderator", "Role")
|
||||
QCoreApplication::translate("Global", "Unspecified", "Role"),
|
||||
QCoreApplication::translate("Global", "Nobody", "Role"),
|
||||
QCoreApplication::translate("Global", "Visitor", "Role"),
|
||||
QCoreApplication::translate("Global", "Participant", "Role"),
|
||||
QCoreApplication::translate("Global", "Moderator", "Role")
|
||||
}),
|
||||
messageState({
|
||||
tr("Pending", "MessageState"),
|
||||
tr("Sent", "MessageState"),
|
||||
tr("Delivered", "MessageState"),
|
||||
tr("Error", "MessageState")
|
||||
QCoreApplication::translate("Global", "Pending", "MessageState"),
|
||||
QCoreApplication::translate("Global", "Sent", "MessageState"),
|
||||
QCoreApplication::translate("Global", "Delivered", "MessageState"),
|
||||
QCoreApplication::translate("Global", "Error", "MessageState")
|
||||
}),
|
||||
accountPassword({
|
||||
tr("Plain", "AccountPassword"),
|
||||
tr("Jammed", "AccountPassword"),
|
||||
tr("Always Ask", "AccountPassword"),
|
||||
tr("KWallet", "AccountPassword")
|
||||
QCoreApplication::translate("Global", "Plain", "AccountPassword"),
|
||||
QCoreApplication::translate("Global", "Jammed", "AccountPassword"),
|
||||
QCoreApplication::translate("Global", "Always Ask", "AccountPassword"),
|
||||
QCoreApplication::translate("Global", "KWallet", "AccountPassword")
|
||||
}),
|
||||
trustLevel({
|
||||
tr("Undecided", "TrustLevel"),
|
||||
tr("Automatically distrusted", "TrustLevel"),
|
||||
tr("Manually distrusted", "TrustLevel"),
|
||||
tr("Automatically trusted", "TrustLevel"),
|
||||
tr("Manually trusted", "TrustLevel"),
|
||||
tr("Authenticated", "TrustLevel")
|
||||
QCoreApplication::translate("Global", "Undecided", "TrustLevel"),
|
||||
QCoreApplication::translate("Global", "Automatically distrusted", "TrustLevel"),
|
||||
QCoreApplication::translate("Global", "Manually distrusted", "TrustLevel"),
|
||||
QCoreApplication::translate("Global", "Automatically trusted", "TrustLevel"),
|
||||
QCoreApplication::translate("Global", "Manually trusted", "TrustLevel"),
|
||||
QCoreApplication::translate("Global", "Authenticated", "TrustLevel")
|
||||
}),
|
||||
encryptionProtocols({
|
||||
QCoreApplication::translate("Global", "None", "EncryptionProtocol"),
|
||||
QCoreApplication::translate("Global", "OMEMO 0", "EncryptionProtocol"),
|
||||
QCoreApplication::translate("Global", "OMEMO 1", "EncryptionProtocol"),
|
||||
QCoreApplication::translate("Global", "OMEMO 2", "EncryptionProtocol")
|
||||
}),
|
||||
accountPasswordDescription({
|
||||
tr("Your password is going to be stored in config file in plain text", "AccountPasswordDescription"),
|
||||
tr("Your password is going to be stored in config file but jammed with constant encryption key you can find in program source code. It might look like encryption but it's not", "AccountPasswordDescription"),
|
||||
tr("Squawk is going to query you for the password on every start of the program", "AccountPasswordDescription"),
|
||||
tr("Your password is going to be stored in KDE wallet storage (KWallet). You're going to be queried for permissions", "AccountPasswordDescription")
|
||||
QCoreApplication::translate("Global", "Your password is going to be stored in config file in plain text", "AccountPasswordDescription"),
|
||||
QCoreApplication::translate("Global", "Your password is going to be stored in config file but jammed with constant encryption key you can find in program source code. It might look like encryption but it's not", "AccountPasswordDescription"),
|
||||
QCoreApplication::translate("Global", "Squawk is going to query you for the password on every start of the program", "AccountPasswordDescription"),
|
||||
QCoreApplication::translate("Global", "Your password is going to be stored in KDE wallet storage (KWallet). You're going to be queried for permissions", "AccountPasswordDescription")
|
||||
}),
|
||||
defaultSystemStyle(QApplication::style()->objectName()),
|
||||
defaultSystemPalette(QApplication::palette()),
|
||||
|
@ -262,6 +270,10 @@ QString Shared::Global::getName(Shared::TrustLevel tl) {
|
|||
return instance->trustLevel[static_cast<int>(tl)];
|
||||
}
|
||||
|
||||
QString Shared::Global::getName(EncryptionProtocol ep) {
|
||||
return instance->encryptionProtocols[static_cast<int>(ep)];
|
||||
}
|
||||
|
||||
void Shared::Global::setSupported(const QString& pluginName, bool support) {
|
||||
std::map<QString, bool>::iterator itr = instance->pluginSupport.find(pluginName);
|
||||
if (itr != instance->pluginSupport.end()) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue