mirror of
https://github.com/qTox/qTox.git
synced 2024-03-22 14:00:36 +08:00
fix(ui): groupcolors fix1
This commit is contained in:
parent
aaf5229ece
commit
ab89ca2d8e
|
@ -242,7 +242,7 @@ void Settings::loadGlobal()
|
||||||
else
|
else
|
||||||
style = "None";
|
style = "None";
|
||||||
}
|
}
|
||||||
groupNameColors = s.value("groupNameColors", false).toBool();
|
nameColors = s.value("nameColors", false).toBool();
|
||||||
}
|
}
|
||||||
s.endGroup();
|
s.endGroup();
|
||||||
|
|
||||||
|
@ -548,7 +548,7 @@ void Settings::saveGlobal()
|
||||||
s.setValue("useEmoticons", useEmoticons);
|
s.setValue("useEmoticons", useEmoticons);
|
||||||
s.setValue("themeColor", themeColor);
|
s.setValue("themeColor", themeColor);
|
||||||
s.setValue("style", style);
|
s.setValue("style", style);
|
||||||
s.setValue("groupNameColors", groupNameColors);
|
s.setValue("nameColors", nameColors);
|
||||||
s.setValue("statusChangeNotificationEnabled", statusChangeNotificationEnabled);
|
s.setValue("statusChangeNotificationEnabled", statusChangeNotificationEnabled);
|
||||||
s.setValue("spellCheckingEnabled", spellCheckingEnabled);
|
s.setValue("spellCheckingEnabled", spellCheckingEnabled);
|
||||||
}
|
}
|
||||||
|
@ -2422,12 +2422,12 @@ void Settings::setAutoLogin(bool state)
|
||||||
void Settings::setEnableGroupChatsColor(bool state)
|
void Settings::setEnableGroupChatsColor(bool state)
|
||||||
{
|
{
|
||||||
QMutexLocker locker{&bigLock};
|
QMutexLocker locker{&bigLock};
|
||||||
groupNameColors = state;
|
nameColors = state;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool Settings::getEnableGroupChatsColor() const
|
bool Settings::getEnableGroupChatsColor() const
|
||||||
{
|
{
|
||||||
return groupNameColors;
|
return nameColors;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -608,7 +608,7 @@ private:
|
||||||
bool notifySound;
|
bool notifySound;
|
||||||
bool busySound;
|
bool busySound;
|
||||||
bool groupAlwaysNotify;
|
bool groupAlwaysNotify;
|
||||||
bool groupNameColors;
|
bool nameColors;
|
||||||
|
|
||||||
bool forceTCP;
|
bool forceTCP;
|
||||||
bool enableLanDiscovery;
|
bool enableLanDiscovery;
|
||||||
|
|
|
@ -73,7 +73,7 @@ UserInterfaceForm::UserInterfaceForm(SettingsWidget* myParent)
|
||||||
bodyUI->txtChatFont->setCurrentFont(chatBaseFont);
|
bodyUI->txtChatFont->setCurrentFont(chatBaseFont);
|
||||||
int index = static_cast<int>(s.getStylePreference());
|
int index = static_cast<int>(s.getStylePreference());
|
||||||
bodyUI->textStyleComboBox->setCurrentIndex(index);
|
bodyUI->textStyleComboBox->setCurrentIndex(index);
|
||||||
bodyUI->gcColors->setChecked(s.getEnableGroupChatsColor());
|
bodyUI->useNameColors->setChecked(s.getEnableGroupChatsColor());
|
||||||
|
|
||||||
bodyUI->notify->setChecked(s.getNotify());
|
bodyUI->notify->setChecked(s.getNotify());
|
||||||
// Note: UI is boolean inversed from settings to maintain setting file backwards compatibility
|
// Note: UI is boolean inversed from settings to maintain setting file backwards compatibility
|
||||||
|
@ -376,7 +376,7 @@ void UserInterfaceForm::on_txtChatFontSize_valueChanged(int px)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void UserInterfaceForm::on_gcColors_stateChanged(int arg1)
|
void UserInterfaceForm::on_useNameColors_stateChanged(int arg1)
|
||||||
{
|
{
|
||||||
Settings::getInstance().setEnableGroupChatsColor(arg1);
|
Settings::getInstance().setEnableGroupChatsColor(arg1);
|
||||||
}
|
}
|
||||||
|
|
|
@ -62,10 +62,8 @@ private slots:
|
||||||
|
|
||||||
void on_txtChatFont_currentFontChanged(const QFont& f);
|
void on_txtChatFont_currentFontChanged(const QFont& f);
|
||||||
void on_txtChatFontSize_valueChanged(int arg1);
|
void on_txtChatFontSize_valueChanged(int arg1);
|
||||||
|
void on_useNameColors_stateChanged(int arg1);
|
||||||
|
|
||||||
|
|
||||||
void on_gcColors_stateChanged(int arg1);
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void retranslateUi();
|
void retranslateUi();
|
||||||
void reloadSmileys();
|
void reloadSmileys();
|
||||||
|
|
|
@ -150,9 +150,9 @@
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
<item row="2" column="1">
|
<item row="2" column="1">
|
||||||
<widget class="QCheckBox" name="gcColors">
|
<widget class="QCheckBox" name="useNameColors">
|
||||||
<property name="text">
|
<property name="text">
|
||||||
<string>Use colors in group chats</string>
|
<string>Use colored nicknames in chats</string>
|
||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user