Qt: Fix default-true checkboxes

This commit is contained in:
Vicki Pfau 2017-09-07 22:05:39 -07:00
parent b750c76d02
commit 076ec733fd
1 changed files with 1 additions and 1 deletions

View File

@ -533,7 +533,7 @@ void SettingsView::saveSetting(const char* key, const QVariant& field) {
void SettingsView::loadSetting(const char* key, QAbstractButton* field, bool defaultVal) {
QString option = loadSetting(key);
field->setChecked((!option.isNull() && option != "0") || defaultVal);
field->setChecked(option.isNull() ? defaultVal : option != "0");
}
void SettingsView::loadSetting(const char* key, QComboBox* field) {