diff options
author | Marc Mutz <marc.mutz@qt.io> | 2023-07-11 08:48:55 +0200 |
---|---|---|
committer | Marc Mutz <marc.mutz@qt.io> | 2023-07-12 19:05:05 +0200 |
commit | 7db33bef41f24c86e844c3982daaa0747cf28b0c (patch) | |
tree | fcab5005dd4bbac2ab9bf829c3b64f6d577f8c70 /tests/auto/quick | |
parent | 87e3099812b4dd8c19ed022d8983d468b330471f (diff) |
Normalize signal/slot signatures
This is the result of running util/normalize on the code base. The
following manual edits were needed:
- skipped the hits in IS_SIGNAL_CONNECTED, which is using function
pointers under the hood
- restored the space before * in Q_SIGNAL void foo(QType *arg)
Pick-to: 6.6
Change-Id: I299b3747c1aa2f6b3bc5ae1794edeb6fadfd75c6
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Diffstat (limited to 'tests/auto/quick')
9 files changed, 20 insertions, 20 deletions
diff --git a/tests/auto/quick/pointerhandlers/qquickpinchhandler/tst_qquickpinchhandler.cpp b/tests/auto/quick/pointerhandlers/qquickpinchhandler/tst_qquickpinchhandler.cpp index 610d03c440..0d60aec37a 100644 --- a/tests/auto/quick/pointerhandlers/qquickpinchhandler/tst_qquickpinchhandler.cpp +++ b/tests/auto/quick/pointerhandlers/qquickpinchhandler/tst_qquickpinchhandler.cpp @@ -232,7 +232,7 @@ void tst_QQuickPinchHandler::scale() QVERIFY(pinchHandler != nullptr); QQuickItem *blackRect = (hasTarget ? pinchHandler->target() : pinchHandler->parentItem()); QVERIFY(blackRect != nullptr); - QSignalSpy grabChangedSpy(pinchHandler, SIGNAL(grabChanged(QPointingDevice::GrabTransition, QEventPoint))); + QSignalSpy grabChangedSpy(pinchHandler, SIGNAL(grabChanged(QPointingDevice::GrabTransition,QEventPoint))); QSignalSpy scaleChangedSpy(pinchHandler, &QQuickPinchHandler::scaleChanged); if (lcPointerTests().isDebugEnabled()) QTest::qWait(500); diff --git a/tests/auto/quick/pointerhandlers/qquicktaphandler/tst_qquicktaphandler.cpp b/tests/auto/quick/pointerhandlers/qquicktaphandler/tst_qquicktaphandler.cpp index e02e4135b5..a2ea404d62 100644 --- a/tests/auto/quick/pointerhandlers/qquicktaphandler/tst_qquicktaphandler.cpp +++ b/tests/auto/quick/pointerhandlers/qquicktaphandler/tst_qquicktaphandler.cpp @@ -963,8 +963,8 @@ void tst_TapHandler::componentUserBehavioralOverride() QQuickTapHandler *userTapHandler = button->findChild<QQuickTapHandler*>("override"); QVERIFY(userTapHandler); QSignalSpy tappedSpy(button, SIGNAL(tapped())); - QSignalSpy innerGrabChangedSpy(innerTapHandler, SIGNAL(grabChanged(QPointingDevice::GrabTransition, QEventPoint))); - QSignalSpy userGrabChangedSpy(userTapHandler, SIGNAL(grabChanged(QPointingDevice::GrabTransition, QEventPoint))); + QSignalSpy innerGrabChangedSpy(innerTapHandler, SIGNAL(grabChanged(QPointingDevice::GrabTransition,QEventPoint))); + QSignalSpy userGrabChangedSpy(userTapHandler, SIGNAL(grabChanged(QPointingDevice::GrabTransition,QEventPoint))); QSignalSpy innerPressedChangedSpy(innerTapHandler, SIGNAL(pressedChanged())); QSignalSpy userPressedChangedSpy(userTapHandler, SIGNAL(pressedChanged())); diff --git a/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp b/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp index 105bb0189d..d376976759 100644 --- a/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp +++ b/tests/auto/quick/qquickflickable/tst_qquickflickable.cpp @@ -2878,7 +2878,7 @@ void tst_qquickflickable::receiveTapOutsideContentItem() QVERIFY(QTest::qWaitForWindowActive(&window)); QQuickTapHandler tapHandler(&flickable); - QSignalSpy clickedSpy(&tapHandler, SIGNAL(tapped(QEventPoint, Qt::MouseButton))); + QSignalSpy clickedSpy(&tapHandler, SIGNAL(tapped(QEventPoint,Qt::MouseButton))); // Tap outside the content item in the top-left corner QTest::mouseClick(&window, Qt::LeftButton, {}, QPoint(5, 5)); diff --git a/tests/auto/quick/qquickmultipointtoucharea/tst_qquickmultipointtoucharea.cpp b/tests/auto/quick/qquickmultipointtoucharea/tst_qquickmultipointtoucharea.cpp index 81e57bfd12..88e1c8f1e1 100644 --- a/tests/auto/quick/qquickmultipointtoucharea/tst_qquickmultipointtoucharea.cpp +++ b/tests/auto/quick/qquickmultipointtoucharea/tst_qquickmultipointtoucharea.cpp @@ -1277,7 +1277,7 @@ void tst_QQuickMultiPointTouchArea::mouseGestureStarted() // QTBUG-70258 area->setProperty("grabGesture", grabGesture); QQuickTouchPoint *point1 = view->rootObject()->findChild<QQuickTouchPoint*>("point1"); QCOMPARE(point1->pressed(), false); - QSignalSpy gestureStartedSpy(area, SIGNAL(gestureStarted(QQuickGrabGestureEvent *))); + QSignalSpy gestureStartedSpy(area, SIGNAL(gestureStarted(QQuickGrabGestureEvent*))); QPoint p1 = QPoint(distanceFromOrigin, distanceFromOrigin); QTest::mousePress(view.data(), Qt::LeftButton, Qt::NoModifier, p1); diff --git a/tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp b/tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp index 51e0cc68c3..9a3c6efba3 100644 --- a/tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp +++ b/tests/auto/quick/qquicktextinput/tst_qquicktextinput.cpp @@ -6433,7 +6433,7 @@ void tst_qquicktextinput::setInputMask() // inputMaskChanged signal QString unescapedMask = mask; // mask is escaped, because '\' is also escape in a JS string unescapedMask.replace(QLatin1String("\\\\"), QLatin1String("\\")); // simple unescape - QSignalSpy spy(textInput, SIGNAL(inputMaskChanged(const QString &))); + QSignalSpy spy(textInput, SIGNAL(inputMaskChanged(QString))); textInput->setInputMask(unescapedMask); QCOMPARE(spy.size(), 0); diff --git a/tests/auto/quick/qquicktreeview/tst_qquicktreeview.cpp b/tests/auto/quick/qquicktreeview/tst_qquicktreeview.cpp index 10865744ad..2450046e21 100644 --- a/tests/auto/quick/qquicktreeview/tst_qquicktreeview.cpp +++ b/tests/auto/quick/qquicktreeview/tst_qquicktreeview.cpp @@ -141,7 +141,7 @@ void tst_qquicktreeview::expandAndCollapseRoot() // Check that the view only has one row loaded so far (the root of the tree) QCOMPARE(treeViewPrivate->loadedRows.count(), 1); - QSignalSpy expandedSpy(treeView, SIGNAL(expanded(int, int))); + QSignalSpy expandedSpy(treeView, SIGNAL(expanded(int,int))); // Expand the root treeView->expand(0); @@ -186,7 +186,7 @@ void tst_qquicktreeview::expandAndCollapseChildren() LOAD_TREEVIEW("normaltreeview.qml"); const int childCount = 4; - QSignalSpy expandedSpy(treeView, SIGNAL(expanded(int, int))); + QSignalSpy expandedSpy(treeView, SIGNAL(expanded(int,int))); // Expand the last child of a parent recursively four times for (int level = 0; level < 4; ++level) { @@ -436,7 +436,7 @@ void tst_qquicktreeview::expandRecursivelyRoot() QFETCH(int, depth); LOAD_TREEVIEW("normaltreeview.qml"); - QSignalSpy spy(treeView, SIGNAL(expanded(int, int))); + QSignalSpy spy(treeView, SIGNAL(expanded(int,int))); treeView->expandRecursively(rowToExpand, depth); @@ -493,7 +493,7 @@ void tst_qquicktreeview::expandRecursivelyChild() QFETCH(int, depth); LOAD_TREEVIEW("normaltreeview.qml"); - QSignalSpy spy(treeView, SIGNAL(expanded(int, int))); + QSignalSpy spy(treeView, SIGNAL(expanded(int,int))); treeView->expand(0); @@ -545,7 +545,7 @@ void tst_qquicktreeview::expandRecursivelyWholeTree() { // Check that we expand the whole tree recursively by passing -1, -1 LOAD_TREEVIEW("normaltreeview.qml"); - QSignalSpy spy(treeView, SIGNAL(expanded(int, int))); + QSignalSpy spy(treeView, SIGNAL(expanded(int,int))); treeView->expandRecursively(-1, -1); QCOMPARE(spy.size(), 1); @@ -577,7 +577,7 @@ void tst_qquicktreeview::collapseRecursivelyRoot() const int expectedRowCount = 1 + (model->maxDepth() * 8) - 4; QCOMPARE(treeView->rows(), expectedRowCount); - QSignalSpy spy(treeView, SIGNAL(collapsed(int, bool))); + QSignalSpy spy(treeView, SIGNAL(collapsed(int,bool))); // Collapse the whole tree again. This time, only the root should end up visible treeView->collapseRecursively(); @@ -624,7 +624,7 @@ void tst_qquicktreeview::collapseRecursivelyChild() const int expectedRowCount = 1 + (model->maxDepth() * 8) - 4; QCOMPARE(treeView->rows(), expectedRowCount); - QSignalSpy spy(treeView, SIGNAL(collapsed(int, bool))); + QSignalSpy spy(treeView, SIGNAL(collapsed(int,bool))); // Collapse the 8th child recursive const int rowToCollapse = 8; @@ -671,7 +671,7 @@ void tst_qquicktreeview::collapseRecursivelyWholeTree() { // Check that we collapse the whole tree recursively by passing -1 LOAD_TREEVIEW("normaltreeview.qml"); - QSignalSpy spy(treeView, SIGNAL(collapsed(int, bool))); + QSignalSpy spy(treeView, SIGNAL(collapsed(int,bool))); treeView->expandRecursively(); treeView->collapseRecursively(); @@ -690,7 +690,7 @@ void tst_qquicktreeview::expandToIndex() // Check that expandToIndex(index) expands the tree so // that index becomes visible in the view LOAD_TREEVIEW("normaltreeview.qml"); - QSignalSpy spy(treeView, SIGNAL(expanded(int, int))); + QSignalSpy spy(treeView, SIGNAL(expanded(int,int))); const QModelIndex root = model->index(0, 0); const QModelIndex child1 = model->index(3, 0, root); diff --git a/tests/auto/quick/qquickview_extra/tst_qquickview_extra.cpp b/tests/auto/quick/qquickview_extra/tst_qquickview_extra.cpp index 0cd4b69e00..dbd428e0ae 100644 --- a/tests/auto/quick/qquickview_extra/tst_qquickview_extra.cpp +++ b/tests/auto/quick/qquickview_extra/tst_qquickview_extra.cpp @@ -42,7 +42,7 @@ void tst_QQuickViewExtra::qtbug_87228() auto children = contentItem->childItems(); QVERIFY(children.size() > 0); // for the sake of this test, any child would be suitable, so pick first - deletionSpy.reset(new QSignalSpy(children[0], SIGNAL(destroyed(QObject *)))); + deletionSpy.reset(new QSignalSpy(children[0], SIGNAL(destroyed(QObject*)))); } QCOMPARE(deletionSpy->size(), 1); } diff --git a/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp b/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp index f79c3bd23c..7133e74769 100644 --- a/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp +++ b/tests/auto/quick/qquickwindow/tst_qquickwindow.cpp @@ -2926,8 +2926,8 @@ void tst_qquickwindow::test_circleMapItem() mat->setObjectName("Top Item/MouseArea"); mat->setSize(QSizeF(40, 40)); - QSignalSpy bottomSpy(mab, SIGNAL(clicked(QQuickMouseEvent *))); - QSignalSpy topSpy(mat, SIGNAL(clicked(QQuickMouseEvent *))); + QSignalSpy bottomSpy(mab, SIGNAL(clicked(QQuickMouseEvent*))); + QSignalSpy topSpy(mat, SIGNAL(clicked(QQuickMouseEvent*))); window.show(); QVERIFY(QTest::qWaitForWindowExposed(&window)); diff --git a/tests/auto/quick/touchmouse/tst_touchmouse.cpp b/tests/auto/quick/touchmouse/tst_touchmouse.cpp index 8e8ee223d9..ec521fe0e7 100644 --- a/tests/auto/quick/touchmouse/tst_touchmouse.cpp +++ b/tests/auto/quick/touchmouse/tst_touchmouse.cpp @@ -1450,11 +1450,11 @@ void tst_TouchMouse::hoverEnabled() // QTBUG-40856 QSignalSpy enterSpy1(mouseArea1, SIGNAL(entered())); QSignalSpy exitSpy1(mouseArea1, SIGNAL(exited())); - QSignalSpy clickSpy1(mouseArea1, SIGNAL(clicked(QQuickMouseEvent *))); + QSignalSpy clickSpy1(mouseArea1, SIGNAL(clicked(QQuickMouseEvent*))); QSignalSpy enterSpy2(mouseArea2, SIGNAL(entered())); QSignalSpy exitSpy2(mouseArea2, SIGNAL(exited())); - QSignalSpy clickSpy2(mouseArea2, SIGNAL(clicked(QQuickMouseEvent *))); + QSignalSpy clickSpy2(mouseArea2, SIGNAL(clicked(QQuickMouseEvent*))); QPoint p1(150, 150); QPoint p2(150, 250); |