Changeset 155188 in webkit


Ignore:
Timestamp:
Sep 6, 2013 6:33:03 AM (11 years ago)
Author:
Csaba Osztrogonác
Message:

[Qt] REGRESSION(r155140) Pixel tests is still broken on Qt with QT_WEBKIT_DISABLE_UIPROCESS_DUMPPIXELS=1
https://bugs.webkit.org/show_bug.cgi?id=120847

Patch by Gabor Abraham <abrhm@inf.u-szeged.hu> on 2013-09-06
Reviewed by Csaba Osztrogonác.

Move the force repaint code back to if (PlatformWebView::windowSnapshotEnabled()) block to support Qt.
Typo fixed: windowShapshotEnabled -> windowSnapshotEnabled.
Add a default PlatformWebView::windowSnapshotEnabled() to the !PLATFORM(QT).

  • WebKitTestRunner/PlatformWebView.h:

(WTR::PlatformWebView::windowSnapshotEnabled):

  • WebKitTestRunner/TestInvocation.cpp:

(WTR::TestInvocation::dumpResults):

  • WebKitTestRunner/qt/PlatformWebViewQt.cpp:

(WTR::WrapperWindow::handleStatusChanged):
(WTR::PlatformWebView::windowSnapshotEnabled):

  • WebKitTestRunner/qt/TestInvocationQt.cpp:

(WTR::TestInvocation::dumpPixelsAndCompareWithExpected):

Location:
trunk/Tools
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Tools/ChangeLog

    r155187 r155188  
     12013-09-06  Gabor Abraham  <abrhm@inf.u-szeged.hu>
     2
     3        [Qt] REGRESSION(r155140) Pixel tests is still broken on Qt with QT_WEBKIT_DISABLE_UIPROCESS_DUMPPIXELS=1
     4        https://bugs.webkit.org/show_bug.cgi?id=120847
     5
     6        Reviewed by Csaba Osztrogonác.
     7
     8        Move the force repaint code back to if (PlatformWebView::windowSnapshotEnabled()) block to support Qt.
     9        Typo fixed: windowShapshotEnabled -> windowSnapshotEnabled.
     10        Add a default PlatformWebView::windowSnapshotEnabled() to the !PLATFORM(QT).
     11
     12        * WebKitTestRunner/PlatformWebView.h:
     13        (WTR::PlatformWebView::windowSnapshotEnabled):
     14        * WebKitTestRunner/TestInvocation.cpp:
     15        (WTR::TestInvocation::dumpResults):
     16        * WebKitTestRunner/qt/PlatformWebViewQt.cpp:
     17        (WTR::WrapperWindow::handleStatusChanged):
     18        (WTR::PlatformWebView::windowSnapshotEnabled):
     19        * WebKitTestRunner/qt/TestInvocationQt.cpp:
     20        (WTR::TestInvocation::dumpPixelsAndCompareWithExpected):
     21
    1222013-09-06  Allan Sandfeld Jensen  <allan.jensen@digia.com>
    223
  • trunk/Tools/WebKitTestRunner/PlatformWebView.h

    r149148 r155188  
    8282    void postEvent(QEvent*);
    8383    void setModalEventLoop(QEventLoop* eventLoop) { m_modalEventLoop = eventLoop; }
    84     static bool windowShapshotEnabled();
     84    // Window snapshot can be disabled on Qt with QT_WEBKIT_DISABLE_UIPROCESS_DUMPPIXELS=1 environment variable (necessary for xvfb)
     85    static bool windowSnapshotEnabled();
     86#else
     87    // Window snapshot is always enabled by default on all other platform.
     88    static bool windowSnapshotEnabled() { return true; }
    8589#endif
    8690
  • trunk/Tools/WebKitTestRunner/TestInvocation.cpp

    r155187 r155188  
    326326
    327327    if (m_dumpPixels && m_pixelResult) {
    328         m_gotRepaint = false;
    329         WKPageForceRepaint(TestController::shared().mainWebView()->page(), this, TestInvocation::forceRepaintDoneCallback);
    330         TestController::shared().runUntil(m_gotRepaint, TestController::ShortTimeout);
    331         if (!m_gotRepaint) {
    332             m_errorMessage = "Timed out waiting for pre-pixel dump repaint\n";
    333             m_webProcessIsUnresponsive = true;
    334             return;
     328        if (PlatformWebView::windowSnapshotEnabled()) {
     329            m_gotRepaint = false;
     330            WKPageForceRepaint(TestController::shared().mainWebView()->page(), this, TestInvocation::forceRepaintDoneCallback);
     331            TestController::shared().runUntil(m_gotRepaint, TestController::ShortTimeout);
     332            if (!m_gotRepaint) {
     333                m_errorMessage = "Timed out waiting for pre-pixel dump repaint\n";
     334                m_webProcessIsUnresponsive = true;
     335                return;
     336            }
    335337        }
    336338        dumpPixelsAndCompareWithExpected(m_pixelResult.get(), m_repaintRects.get());
  • trunk/Tools/WebKitTestRunner/qt/PlatformWebViewQt.cpp

    r155182 r155188  
    6666        QQmlProperty::write(m_view, "anchors.fill", qVariantFromValue(rootObject()));
    6767
    68         if (PlatformWebView::windowShapshotEnabled()) {
     68        if (PlatformWebView::windowSnapshotEnabled()) {
    6969            setSurfaceType(OpenGLSurface);
    7070            create();
     
    176176}
    177177
    178 bool PlatformWebView::windowShapshotEnabled()
     178bool PlatformWebView::windowSnapshotEnabled()
    179179{
    180180    // We need a way to disable UI side rendering for tests because it is
  • trunk/Tools/WebKitTestRunner/qt/TestInvocationQt.cpp

    r155140 r155188  
    6868{
    6969    QImage image;
    70     if (PlatformWebView::windowShapshotEnabled()) {
     70    if (PlatformWebView::windowSnapshotEnabled()) {
    7171        image = WKImageCreateQImage(TestController::shared().mainWebView()->windowSnapshotImage().get());
    7272    } else
Note: See TracChangeset for help on using the changeset viewer.