Bump project requirement to C++17

This commit is contained in:
Chocobo1 2020-12-19 14:52:01 +08:00
parent a579b4a519
commit d70b893852
No known key found for this signature in database
GPG key ID: 210D9C873253A68C
19 changed files with 101 additions and 139 deletions

View file

@ -715,12 +715,12 @@ void AdvancedSettings::addRow(const int row, const QString &text, T *widget)
setCellWidget(row, PROPERTY, label);
setCellWidget(row, VALUE, widget);
if (std::is_same<T, QCheckBox>::value)
if (std::is_same_v<T, QCheckBox>)
connect(widget, SIGNAL(stateChanged(int)), this, SIGNAL(settingsChanged()));
else if (std::is_same<T, QSpinBox>::value)
else if (std::is_same_v<T, QSpinBox>)
connect(widget, SIGNAL(valueChanged(int)), this, SIGNAL(settingsChanged()));
else if (std::is_same<T, QComboBox>::value)
else if (std::is_same_v<T, QComboBox>)
connect(widget, SIGNAL(currentIndexChanged(int)), this, SIGNAL(settingsChanged()));
else if (std::is_same<T, QLineEdit>::value)
else if (std::is_same_v<T, QLineEdit>)
connect(widget, SIGNAL(textChanged(QString)), this, SIGNAL(settingsChanged()));
}