summaryrefslogtreecommitdiffstats
path: root/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
diff options
context:
space:
mode:
authorLaurent Montel <laurent.montel@kdab.com>2017-10-10 11:02:12 +0200
committerJędrzej Nowacki <jedrzej.nowacki@qt.io>2017-11-30 20:40:21 +0000
commit0fe3ff5c517e6dfae26600d79d07e92b1ab86843 (patch)
tree7307eff40e9d6dc9c607f5bd8a954e3e4d81cbb4 /src/printsupport/dialogs/qpagesetupdialog_unix.cpp
parent6a3f41aa4622194977b1ae5bc45f4806193c6871 (diff)
PrintSupport: modernize connection signal/slot
Change-Id: I6e482cd9503e96cc43ead21122d3690cdb18151c Reviewed-by: David Faure <david.faure@kdab.com>
Diffstat (limited to 'src/printsupport/dialogs/qpagesetupdialog_unix.cpp')
-rw-r--r--src/printsupport/dialogs/qpagesetupdialog_unix.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/printsupport/dialogs/qpagesetupdialog_unix.cpp b/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
index 0715dfa548..ee7bc62491 100644
--- a/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
+++ b/src/printsupport/dialogs/qpagesetupdialog_unix.cpp
@@ -260,21 +260,21 @@ QPageSetupWidget::QPageSetupWidget(QWidget *parent)
initUnits();
initPagesPerSheet();
- connect(m_ui.unitCombo, SIGNAL(activated(int)), this, SLOT(unitChanged()));
+ connect(m_ui.unitCombo, QOverload<int>::of(&QComboBox::activated), this, &QPageSetupWidget::unitChanged);
- connect(m_ui.pageSizeCombo, SIGNAL(currentIndexChanged(int)), this, SLOT(pageSizeChanged()));
- connect(m_ui.pageWidth, SIGNAL(valueChanged(double)), this, SLOT(pageSizeChanged()));
- connect(m_ui.pageHeight, SIGNAL(valueChanged(double)), this, SLOT(pageSizeChanged()));
+ connect(m_ui.pageSizeCombo, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &QPageSetupWidget::pageSizeChanged);
+ connect(m_ui.pageWidth, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &QPageSetupWidget::pageSizeChanged);
+ connect(m_ui.pageHeight, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &QPageSetupWidget::pageSizeChanged);
- connect(m_ui.leftMargin, SIGNAL(valueChanged(double)), this, SLOT(leftMarginChanged(double)));
- connect(m_ui.topMargin, SIGNAL(valueChanged(double)), this, SLOT(topMarginChanged(double)));
- connect(m_ui.rightMargin, SIGNAL(valueChanged(double)), this, SLOT(rightMarginChanged(double)));
- connect(m_ui.bottomMargin, SIGNAL(valueChanged(double)), this, SLOT(bottomMarginChanged(double)));
+ connect(m_ui.leftMargin, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &QPageSetupWidget::leftMarginChanged);
+ connect(m_ui.topMargin, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &QPageSetupWidget::topMarginChanged);
+ connect(m_ui.rightMargin, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &QPageSetupWidget::rightMarginChanged);
+ connect(m_ui.bottomMargin, QOverload<double>::of(&QDoubleSpinBox::valueChanged), this, &QPageSetupWidget::bottomMarginChanged);
- connect(m_ui.portrait, SIGNAL(clicked()), this, SLOT(pageOrientationChanged()));
- connect(m_ui.landscape, SIGNAL(clicked()), this, SLOT(pageOrientationChanged()));
+ connect(m_ui.portrait, &QRadioButton::clicked, this, &QPageSetupWidget::pageOrientationChanged);
+ connect(m_ui.landscape, &QRadioButton::clicked, this, &QPageSetupWidget::pageOrientationChanged);
- connect(m_ui.pagesPerSheetCombo, SIGNAL(currentIndexChanged(int)), this, SLOT(pagesPerSheetChanged()));
+ connect(m_ui.pagesPerSheetCombo, QOverload<int>::of(&QComboBox::currentIndexChanged), this, &QPageSetupWidget::pagesPerSheetChanged);
}
// Init the Units combo box