forked from blue/squawk
trust level display in delegate, list size tweaking
This commit is contained in:
parent
d4bf7e599a
commit
b72a837754
10 changed files with 203 additions and 27 deletions
|
@ -113,6 +113,14 @@ Shared::Global::Global():
|
|||
tr("Always Ask", "AccountPassword"),
|
||||
tr("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")
|
||||
}),
|
||||
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"),
|
||||
|
@ -123,10 +131,12 @@ Shared::Global::Global():
|
|||
defaultSystemPalette(QApplication::palette()),
|
||||
omemoSupport(OMEMO_SUPPORT),
|
||||
defaultFont(QFontDatabase::systemFont(QFontDatabase::GeneralFont)),
|
||||
monospaceFont(QFontDatabase::systemFont(QFontDatabase::FixedFont)),
|
||||
smallFont(getFont(QFontDatabase::SmallestReadableFont, false, true)),
|
||||
headerFont(getFont(QFontDatabase::TitleFont, true, false, 1.1)),
|
||||
titleFont(getFont(QFontDatabase::TitleFont, true, false, 1.3)),
|
||||
defaultFontMetrics(defaultFont),
|
||||
monospaceMetrics(monospaceFont),
|
||||
smallFontMetrics(smallFont),
|
||||
headerFontMetrics(headerFont),
|
||||
titleFontMetrics(titleFont),
|
||||
|
@ -256,6 +266,11 @@ QString Shared::Global::getName(Shared::AccountPassword ap)
|
|||
return instance->accountPassword[static_cast<int>(ap)];
|
||||
}
|
||||
|
||||
QString Shared::Global::getName(Shared::TrustLevel tl)
|
||||
{
|
||||
return instance->trustLevel[static_cast<int>(tl)];
|
||||
}
|
||||
|
||||
void Shared::Global::setSupported(const QString& pluginName, bool support)
|
||||
{
|
||||
std::map<QString, bool>::iterator itr = instance->pluginSupport.find(pluginName);
|
||||
|
@ -405,3 +420,4 @@ FROM_INT_INPL(Shared::SubscriptionState)
|
|||
FROM_INT_INPL(Shared::AccountPassword)
|
||||
FROM_INT_INPL(Shared::Avatar)
|
||||
FROM_INT_INPL(Shared::Availability)
|
||||
FROM_INT_INPL(Shared::TrustLevel)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue