summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/dialogs/qmessagebox/tst_qmessagebox.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2020-09-11 13:50:30 +0200
committerLars Knoll <lars.knoll@qt.io>2020-09-28 17:23:20 +0200
commit09025084110702a17b1edd7e2e80cd9e063e64fd (patch)
tree980bed89411f5dd79bf5db5d6dea4803261ea8d1 /tests/auto/widgets/dialogs/qmessagebox/tst_qmessagebox.cpp
parent673da7d4607cd5597b3c58f8c118459efdcaaeb3 (diff)
Fix compiler warnings from QKeyCombination
Change lots of code to avoid the deprecated operator+() or implicit casts to int. Change-Id: I0c343cd5b28603afdf1214eefb85e928313345e2 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
Diffstat (limited to 'tests/auto/widgets/dialogs/qmessagebox/tst_qmessagebox.cpp')
-rw-r--r--tests/auto/widgets/dialogs/qmessagebox/tst_qmessagebox.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/widgets/dialogs/qmessagebox/tst_qmessagebox.cpp b/tests/auto/widgets/dialogs/qmessagebox/tst_qmessagebox.cpp
index dfb8dc1c37..1d379acc46 100644
--- a/tests/auto/widgets/dialogs/qmessagebox/tst_qmessagebox.cpp
+++ b/tests/auto/widgets/dialogs/qmessagebox/tst_qmessagebox.cpp
@@ -457,9 +457,9 @@ void tst_QMessageBox::instanceSourceCompat()
QCOMPARE(mb.exec(), int(QMessageBox::Cancel));
#ifndef Q_OS_MAC
// mnemonics are not used on OS X
- closeHelper.start(Qt::ALT + Qt::Key_R, &mb);
+ closeHelper.start(QKeyCombination(Qt::ALT | Qt::Key_R).toCombined(), &mb);
QCOMPARE(mb.exec(), 0);
- closeHelper.start(Qt::ALT + Qt::Key_Z, &mb);
+ closeHelper.start(QKeyCombination(Qt::ALT | Qt::Key_Z).toCombined(), &mb);
QCOMPARE(mb.exec(), 1);
#endif
}