diff options
author | Sergio Ahumada <sergio.ahumada@digia.com> | 2012-10-21 23:56:14 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2012-10-25 16:22:43 +0200 |
commit | c3237f58abef192c49320bf39c2d4cbe9a791c27 (patch) | |
tree | 0139428499283f0067df5e48ad8de31fd2f7e7b6 | |
parent | 044f5b7fb8695423c2a44c899ce61383c8286a0c (diff) |
test: Remove tst_QPixmap::grabWindow() function
QPixmap::grabWindow() was deprecated by 41914453d38d01b9b69e16ccee69444d1a304bf7
Task-number: QTBUG-20863
Change-Id: I7e675c124cd96cf1815b65e57f3fba19e5065066
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
-rw-r--r-- | tests/auto/gui/image/qpixmap/tst_qpixmap.cpp | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp b/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp index dd6d97043d..1918841d24 100644 --- a/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp +++ b/tests/auto/gui/image/qpixmap/tst_qpixmap.cpp @@ -109,7 +109,6 @@ private slots: void setGetMask(); void cacheKey(); void drawBitmap(); - void grabWindow(); void isNull(); void task_246446(); @@ -723,36 +722,6 @@ void tst_QPixmap::drawBitmap() QVERIFY(lenientCompare(pixmap, expected)); } -void tst_QPixmap::grabWindow() -{ -// ### fixme: Check platforms - QSKIP("QTBUG-20863 grabWindow is broken on most qpa backends"); -#ifndef QT_NO_WIDGETS -#ifdef Q_OS_WINCE - // We get out of memory, if the desktop itself is too big. - if (QApplication::desktop()->width() <= 480) -#endif - QVERIFY(QPixmap::grabWindow(QApplication::desktop()->winId()).isNull() == false); - QWidget w; - w.resize(640, 480); - w.show(); - QVERIFY(QTest::qWaitForWindowExposed(&w)); - QVERIFY(QPixmap::grabWindow(w.winId()).isNull() == false); - - QWidget child(&w); - child.setGeometry(50, 50, 100, 100); - child.setPalette(Qt::red); - child.setAutoFillBackground(true); - child.show(); - QTest::qWait(20); - const QPixmap grabWidgetPixmap = child.grab(); - const WId childWinId = child.winId(); // Create native child - QVERIFY(QTest::qWaitForWindowExposed(child.windowHandle())); - const QPixmap grabWindowPixmap = QPixmap::grabWindow(childWinId); - QVERIFY(lenientCompare(grabWindowPixmap, grabWidgetPixmap)); -#endif -} - void tst_QPixmap::isNull() { { |