build: raise minimum Qt version to 6.8 and drop pre-6.8 fallbacks

This commit is contained in:
yyc12345 committed 2026-10-19 21:30:00 +08:00
1 parent 124c69bf8b
commit ceb240d01a
6 files changed
+9 -48

No files matched your search

+4 -12
View File
@@ -98,27 +98,19 @@ SettingsDialog::SettingsDialog(QWidget *parent)
Qt::HighDpiScaleFactorRoundingPolicy hidpi = settings->hiDpiScaleFactorBehavior();
ui->m_hiDpiRoundingPolicyBehavior->setCurrentIndex(HIDPI_OPTIONS.to_index(hidpi));
#if QT_VERSION >= QT_VERSION_CHECK(6, 7, 0)
# define QCHECKBOX_CHECKSTATECHANGED QCheckBox::checkStateChanged
# define QT_CHECKSTATE Qt::CheckState
#else
# define QCHECKBOX_CHECKSTATECHANGED QCheckBox::stateChanged
# define QT_CHECKSTATE int
#endif // QT_VERSION >= QT_VERSION_CHECK(6, 7, 0)
connect(ui->m_showNavigatorView, &QCHECKBOX_CHECKSTATECHANGED, this, [ = ](QT_CHECKSTATE state){
connect(ui->m_showNavigatorView, &QCheckBox::checkStateChanged, this, [ = ](Qt::CheckState state){
Settings::instance()->setShowNavigatorView(state == Qt::Checked);
});
connect(ui->m_useLightCheckerboard, &QCHECKBOX_CHECKSTATECHANGED, this, [ = ](QT_CHECKSTATE state){
connect(ui->m_useLightCheckerboard, &QCheckBox::checkStateChanged, this, [ = ](Qt::CheckState state){
Settings::instance()->setUseLightCheckerboard(state == Qt::Checked);
});
connect(ui->m_loopGallery, &QCHECKBOX_CHECKSTATECHANGED, this, [ = ](QT_CHECKSTATE state){
connect(ui->m_loopGallery, &QCheckBox::checkStateChanged, this, [ = ](Qt::CheckState state){
Settings::instance()->setLoopGallery(state == Qt::Checked);
});
connect(ui->m_svgTiny12Only, &QCHECKBOX_CHECKSTATECHANGED, this, [ = ](QT_CHECKSTATE state){
connect(ui->m_svgTiny12Only, &QCheckBox::checkStateChanged, this, [ = ](Qt::CheckState state){
Settings::instance()->setSvgTiny12Only(state == Qt::Checked);
});