From fc0e788d029beac251fda40650154fc6865e1649 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20Lefebvre?= Date: Thu, 2 Jan 2025 09:04:00 +0100 Subject: [PATCH] Tst_QGestureRecognizer::panGesture set FramelessWindowHint tst_QGestureRecognizer::panGesture() is flaky as sometimes the gesture event is being sent before the frame and position has had time to update. The event then starts in the frame and is not received by the widget. Set FramelessWindowHint flag to the widget, to remove the need of updating its frame position and position. Fix flakiness on Opensuse 15 Pick-to: 6.9 6.8 6.5 Change-Id: Id88510a91e3ed0d5ff92fdc31422503744448b3e Reviewed-by: Axel Spoerl --- .../widgets/kernel/qgesturerecognizer/tst_qgesturerecognizer.cpp | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/auto/widgets/kernel/qgesturerecognizer/tst_qgesturerecognizer.cpp b/tests/auto/widgets/kernel/qgesturerecognizer/tst_qgesturerecognizer.cpp index b09a1227d24..febb9e2c9dc 100644 --- a/tests/auto/widgets/kernel/qgesturerecognizer/tst_qgesturerecognizer.cpp +++ b/tests/auto/widgets/kernel/qgesturerecognizer/tst_qgesturerecognizer.cpp @@ -158,6 +158,7 @@ void tst_QGestureRecognizer::panGesture() const Qt::GestureType gestureType = Qt::PanGesture; TestWidget widget(GestureTypeVector(1, gestureType)); widget.setWindowTitle(QTest::currentTestFunction()); + widget.setWindowFlag(Qt::FramelessWindowHint); widget.show(); QVERIFY(QTest::qWaitForWindowExposed(&widget));