Title: [154974] trunk
Revision
154974
Author
allan.jen...@digia.com
Date
2013-09-03 01:54:26 -0700 (Tue, 03 Sep 2013)

Log Message

[Qt][WK1] PageVisibility tests are flaky
https://bugs.webkit.org/show_bug.cgi?id=120418

Reviewed by Jocelyn Turcotte.

Source/WebKit/qt:

* WebCoreSupport/DumpRenderTreeSupportQt.cpp:
(DumpRenderTreeSupportQt::resetPageVisibility):
* WebCoreSupport/DumpRenderTreeSupportQt.h:

Tools:

Implement resetPageVisibility so we can reset visibility without
emiting visibility state change events.

* DumpRenderTree/qt/TestRunnerQt.cpp:
(TestRunner::resetPageVisibility):

Modified Paths

Diff

Modified: trunk/Source/WebKit/qt/ChangeLog (154973 => 154974)


--- trunk/Source/WebKit/qt/ChangeLog	2013-09-03 08:21:16 UTC (rev 154973)
+++ trunk/Source/WebKit/qt/ChangeLog	2013-09-03 08:54:26 UTC (rev 154974)
@@ -1,3 +1,14 @@
+2013-09-03  Allan Sandfeld Jensen  <allan.jen...@digia.com>
+
+        [Qt][WK1] PageVisibility tests are flaky
+        https://bugs.webkit.org/show_bug.cgi?id=120418
+
+        Reviewed by Jocelyn Turcotte.
+
+        * WebCoreSupport/DumpRenderTreeSupportQt.cpp:
+        (DumpRenderTreeSupportQt::resetPageVisibility):
+        * WebCoreSupport/DumpRenderTreeSupportQt.h:
+
 2013-08-28  Zeno Albisser  <z...@webkit.org>
 
         [Qt] Option key combinations do not work in Input Elements.

Modified: trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp (154973 => 154974)


--- trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp	2013-09-03 08:21:16 UTC (rev 154973)
+++ trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp	2013-09-03 08:54:26 UTC (rev 154974)
@@ -893,6 +893,16 @@
     WebCore::Font::setDefaultTypesettingFeatures(0);
 }
 
+void DumpRenderTreeSupportQt::resetPageVisibility(QWebPageAdapter* adapter)
+{
+#if ENABLE(PAGE_VISIBILITY_API)
+    // Set visibility without emitting an event.
+    adapter->page->setVisibilityState(PageVisibilityStateVisible, true);
+#else
+    UNUSED_PARAM(adapter);
+#endif
+}
+
 void DumpRenderTreeSupportQt::getJSWindowObject(QWebFrameAdapter* adapter, JSContextRef* context, JSObjectRef* object)
 {
     JSDOMWindow* window = toJSDOMWindow(adapter->frame, mainThreadNormalWorld());

Modified: trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h (154973 => 154974)


--- trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h	2013-09-03 08:21:16 UTC (rev 154973)
+++ trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h	2013-09-03 08:54:26 UTC (rev 154974)
@@ -205,6 +205,7 @@
     static void clearNotificationPermissions();
 
     static void disableDefaultTypesettingFeatures();
+    static void resetPageVisibility(QWebPageAdapter*);
 
     static void getJSWindowObject(QWebFrameAdapter*, JSContextRef*, JSObjectRef*);
 };

Modified: trunk/Tools/ChangeLog (154973 => 154974)


--- trunk/Tools/ChangeLog	2013-09-03 08:21:16 UTC (rev 154973)
+++ trunk/Tools/ChangeLog	2013-09-03 08:54:26 UTC (rev 154974)
@@ -1,3 +1,16 @@
+2013-09-03  Allan Sandfeld Jensen  <allan.jen...@digia.com>
+
+        [Qt][WK1] PageVisibility tests are flaky
+        https://bugs.webkit.org/show_bug.cgi?id=120418
+
+        Reviewed by Jocelyn Turcotte.
+
+        Implement resetPageVisibility so we can reset visibility without
+        emiting visibility state change events.
+
+        * DumpRenderTree/qt/TestRunnerQt.cpp:
+        (TestRunner::resetPageVisibility):
+
 2013-09-03  ChangSeok Oh  <changseok...@collabora.com>
 
         [GTK] libsoup upversion to fix a gstreamer issue, bug115354

Modified: trunk/Tools/DumpRenderTree/qt/TestRunnerQt.cpp (154973 => 154974)


--- trunk/Tools/DumpRenderTree/qt/TestRunnerQt.cpp	2013-09-03 08:21:16 UTC (rev 154973)
+++ trunk/Tools/DumpRenderTree/qt/TestRunnerQt.cpp	2013-09-03 08:54:26 UTC (rev 154974)
@@ -950,7 +950,7 @@
 
 void TestRunner::resetPageVisibility()
 {
-    // No need to implement it because the visibility state is correctly initialised when the page is created.
+    DumpRenderTreeSupportQt::resetPageVisibility(DumpRenderTree::instance()->pageAdapter());
 }
 
 void TestRunner::setPageVisibility(const char* visibility)
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to