From dff3843d98d52e2c32fea07371f91117de0667e9 Mon Sep 17 00:00:00 2001 From: Friedemann Kleint Date: Fri, 18 Oct 2019 09:07:37 +0200 Subject: QShortcut: Properly port to the new configure system Move the feature to corelib so that the QMetaType enumeration values can be properly excluded and there is no need for a dummy class. Use QT_REQUIRE_CONFIG in the headers of classes to be disabled. Add headers/source files in the .pro file depending on the configure feature in libraries and tests. Add the necessary exclusions and use QT_CONFIG. Task-number: QTBUG-76493 Change-Id: I02499ebee1a3d6d9a1e5afd02517beed5f4536b7 Reviewed-by: Mitch Curtis --- tests/auto/widgets/widgets/qdoublespinbox/tst_qdoublespinbox.cpp | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'tests/auto/widgets/widgets/qdoublespinbox/tst_qdoublespinbox.cpp') diff --git a/tests/auto/widgets/widgets/qdoublespinbox/tst_qdoublespinbox.cpp b/tests/auto/widgets/widgets/qdoublespinbox/tst_qdoublespinbox.cpp index c293a4bdd2..c6de750482 100644 --- a/tests/auto/widgets/widgets/qdoublespinbox/tst_qdoublespinbox.cpp +++ b/tests/auto/widgets/widgets/qdoublespinbox/tst_qdoublespinbox.cpp @@ -166,7 +166,9 @@ private slots: void doubleDot(); +#if QT_CONFIG(shortcut) void undoRedo(); +#endif void valueFromTextAndValidate_data(); void valueFromTextAndValidate(); @@ -1025,6 +1027,8 @@ void tst_QDoubleSpinBox::doubleDot() QCOMPARE(spin.lineEdit()->cursorPosition(), 2); } +#if QT_CONFIG(shortcut) + void tst_QDoubleSpinBox::undoRedo() { //test undo/redo feature (in conjunction with the "undoRedoEnabled" property) @@ -1073,6 +1077,8 @@ void tst_QDoubleSpinBox::undoRedo() QVERIFY(!spin.lineEdit()->isRedoAvailable()); } +#endif // QT_CONFIG(shortcut) + struct task199226_DoubleSpinBox : public QDoubleSpinBox { task199226_DoubleSpinBox(QWidget *parent = 0) : QDoubleSpinBox(parent) {} -- cgit v1.2.3