summaryrefslogtreecommitdiffstats
path: root/tests/auto/widgets/kernel
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2016-06-01 11:07:22 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2016-06-04 18:47:54 +0000
commit23bed9f8203bb6d475622c02ea9a96efdea78108 (patch)
tree64666d56a394c1b579f08be2592434d99f5b2258 /tests/auto/widgets/kernel
parentcf19b06f221430db7eba00e792237abe14df4a3d (diff)
Remove tst_QWidget::immediateRepaintAfterShow().
It tested whether a paint event was received when calling QWidget::repaint() right after QWidget::show() without waiting for the window to be exposed. This caused a QEvent::UpdateRequest to be sent, which ended up in QWidgetBackingStore::sync() which returns after checking QWidgetBackingStore::discardSyncRequest(), since Qt::WA_Mapped is not set on the non-exposed widget. The test passed on Windows since it contains one call to QCoreApplication::processEvents() which causes the the initial WM_PAINT message to be processed in QWindowsWindow::handleWmPaint() which calls QWindowSystemInterface::flushWindowSystemEvents() and causes Qt::WA_Mapped to be set. This seems counter to the intention of the test. Remove the test since it won't pass anymore in Qt 5 unless Qt::WA_Mapped is set. Task-number: QTBUG-26424 Task-number: QTBUG-38327 Task-number: QTBUG-39842 Change-Id: Iede026d52825dcf1f2e9014a316d26d260309214 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Diffstat (limited to 'tests/auto/widgets/kernel')
-rw-r--r--tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp20
1 files changed, 0 insertions, 20 deletions
diff --git a/tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp b/tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp
index 10d32472be..b7c152603c 100644
--- a/tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp
+++ b/tests/auto/widgets/kernel/qwidget/tst_qwidget.cpp
@@ -378,7 +378,6 @@ private slots:
void setMaskInResizeEvent();
void moveInResizeEvent();
- void immediateRepaintAfterShow();
void immediateRepaintAfterInvalidateBuffer();
void effectiveWinId();
@@ -8145,25 +8144,6 @@ void tst_QWidget::moveInResizeEvent()
QTRY_COMPARE(testWidget.geometry(), expectedGeometry);
}
-void tst_QWidget::immediateRepaintAfterShow()
-{
- if (m_platform == QStringLiteral("xcb"))
- QSKIP("QTBUG-26424");
- if (m_platform != QStringLiteral("xcb") && m_platform != QStringLiteral("windows"))
- QSKIP("We don't support immediate repaint right after show on other platforms.");
-
- UpdateWidget widget;
- centerOnScreen(&widget);
- widget.show();
- qApp->processEvents();
- // On X11 in particular, we are now waiting for a MapNotify event before
- // syncing the backing store. However, if someone request a repaint()
- // we must repaint immediately regardless of the current state.
- widget.numPaintEvents = 0;
- widget.repaint();
- QCOMPARE(widget.numPaintEvents, 1);
-}
-
void tst_QWidget::immediateRepaintAfterInvalidateBuffer()
{
if (m_platform != QStringLiteral("xcb") && m_platform != QStringLiteral("windows"))