summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.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/widgets/qpushbutton/tst_qpushbutton.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/widgets/qpushbutton/tst_qpushbutton.cpp')
-rw-r--r--tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp b/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp
index d3314494d5..94f6923c42 100644
--- a/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp
+++ b/tests/auto/widgets/widgets/qpushbutton/tst_qpushbutton.cpp
@@ -338,7 +338,7 @@ void tst_QPushButton::setAccel()
QSKIP("Wayland: This fails. Figure out why.");
testWidget->setText("&AccelTest");
- QKeySequence seq( Qt::ALT + Qt::Key_A );
+ QKeySequence seq( Qt::ALT | Qt::Key_A );
testWidget->setShortcut( seq );
// The shortcut will not be activated unless the button is in a active
@@ -610,7 +610,7 @@ void tst_QPushButton::taskQTBUG_20191_shortcutWithKeypadModifer()
// add shortcut 'keypad 5' to button2
spy1.clear();
QSignalSpy spy2(button2, SIGNAL(clicked()));
- button2->setShortcut(Qt::Key_5 + Qt::KeypadModifier);
+ button2->setShortcut(Qt::Key_5 | Qt::KeypadModifier);
QTest::keyClick(&dialog, Qt::Key_5);
QTest::qWait(300);
QTest::keyClick(&dialog, Qt::Key_5, Qt::KeypadModifier);