diff options
author | Christian Ehrlicher <ch.ehrlicher@gmx.de> | 2019-03-03 19:31:26 +0100 |
---|---|---|
committer | Christian Ehrlicher <ch.ehrlicher@gmx.de> | 2019-03-04 16:54:52 +0000 |
commit | d8ac4b40b5acb5582b1491f48f3d3c2cfc044666 (patch) | |
tree | 2e0363bf395de47daa3c91b8402ff701c6822263 /examples/widgets/graphicsview/diagramscene/mainwindow.cpp | |
parent | 332f295743019a5b70eb923d6ad93352b0cb4079 (diff) |
Examples: replace deprecated QComboBox functions
Replace the deprecated currentIndexChanged(QString) and
activated(QString) with the new currentTextChanged() and textActivated()
functions
Change-Id: I8616354fa06cc63dce6f5cfef0902f4b55981043
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'examples/widgets/graphicsview/diagramscene/mainwindow.cpp')
-rw-r--r-- | examples/widgets/graphicsview/diagramscene/mainwindow.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/examples/widgets/graphicsview/diagramscene/mainwindow.cpp b/examples/widgets/graphicsview/diagramscene/mainwindow.cpp index 07f92f61c1..3327d4d5df 100644 --- a/examples/widgets/graphicsview/diagramscene/mainwindow.cpp +++ b/examples/widgets/graphicsview/diagramscene/mainwindow.cpp @@ -473,7 +473,7 @@ void MainWindow::createToolbars() fontSizeCombo->addItem(QString().setNum(i)); QIntValidator *validator = new QIntValidator(2, 64, this); fontSizeCombo->setValidator(validator); - connect(fontSizeCombo, QOverload<const QString &>::of(&QComboBox::currentIndexChanged), + connect(fontSizeCombo, &QComboBox::currentTextChanged, this, &MainWindow::fontSizeChanged); fontColorToolButton = new QToolButton; @@ -536,7 +536,7 @@ void MainWindow::createToolbars() scales << tr("50%") << tr("75%") << tr("100%") << tr("125%") << tr("150%"); sceneScaleCombo->addItems(scales); sceneScaleCombo->setCurrentIndex(2); - connect(sceneScaleCombo, QOverload<const QString &>::of(&QComboBox::currentIndexChanged), + connect(sceneScaleCombo, &QComboBox::currentTextChanged, this, &MainWindow::sceneScaleChanged); pointerToolbar = addToolBar(tr("Pointer type")); |