Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 4 additions & 3 deletions src/widgets/dprintpreviewdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1155,11 +1155,11 @@ void DPrintPreviewDialogPrivate::initconnections()
}
});
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
QObject::connect(sidebysideCheckBox, &DCheckBox::checkStateChanged, q, [this](int status) {
QObject::connect(sidebysideCheckBox, &DCheckBox::checkStateChanged, q, [this](Qt::CheckState status) {
#else
QObject::connect(sidebysideCheckBox, &DCheckBox::stateChanged, q, [this](int status) {
#endif
if (status == 0) {
if (status == Qt::Unchecked) {
if (isActualPrinter(printDeviceCombo->currentText()))
settingHelper->setSubControlEnabled(DPrintPreviewSettingInterface::SC_PageOrder_SequentialPrint, true);
setPageLayoutEnable(false);
Expand Down Expand Up @@ -1268,7 +1268,8 @@ void DPrintPreviewDialogPrivate::initconnections()
QObject::connect(marginLeftSpin, SIGNAL(valueChanged(double)), q, SLOT(_q_marginspinChanged(double)));
QObject::connect(marginBottomSpin, SIGNAL(valueChanged(double)), q, SLOT(_q_marginspinChanged(double)));
#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0)
QObject::connect(duplexCheckBox, SIGNAL(checkStateChanged(int)), q, SLOT(_q_checkStateChanged(int)));
QObject::connect(duplexCheckBox, &DCheckBox::checkStateChanged, q,
[this](Qt::CheckState state) { _q_checkStateChanged(int(state)); });
#else
QObject::connect(duplexCheckBox, SIGNAL(stateChanged(int)), q, SLOT(_q_checkStateChanged(int)));
#endif
Expand Down
6 changes: 3 additions & 3 deletions src/widgets/dsettingswidgetfactory.cpp
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// SPDX-FileCopyrightText: 2016 - 2022 UnionTech Software Technology Co., Ltd.
// SPDX-FileCopyrightText: 2016 - 2026 UnionTech Software Technology Co., Ltd.
//
// SPDX-License-Identifier: LGPL-3.0-or-later

Expand Down Expand Up @@ -275,8 +275,8 @@ QPair<QWidget *, QWidget *> createCheckboxOptionHandle(QObject *opt)
#else
option->connect(rightWidget, &QCheckBox::stateChanged,
#endif
option, [ = ](int status) {
option->setValue(status == Qt::Checked);
option, [ = ] {
option->setValue(rightWidget->isChecked());
});
option->connect(option, &DTK_CORE_NAMESPACE::DSettingsOption::valueChanged,
rightWidget, [ = ](const QVariant & value) {
Expand Down
Loading