Title: [88616] trunk
Revision
88616
Author
[email protected]
Date
2011-06-12 10:23:28 -0700 (Sun, 12 Jun 2011)

Log Message

[Qt] LayoutTestController needs setTextDirection implementation
https://bugs.webkit.org/show_bug.cgi?id=62442

Reviewed by Antonio Gomes.

Tools: 

Implements LayoutController.setTextDirection.

* DumpRenderTree/qt/LayoutTestControllerQt.cpp:
(LayoutTestController::setTextDirection):
* DumpRenderTree/qt/LayoutTestControllerQt.h:

LayoutTests: 

Unskipping fast/html/set-text-direction.html. 

* platform/qt/Skipped:

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (88615 => 88616)


--- trunk/LayoutTests/ChangeLog	2011-06-12 16:57:54 UTC (rev 88615)
+++ trunk/LayoutTests/ChangeLog	2011-06-12 17:23:28 UTC (rev 88616)
@@ -1,3 +1,14 @@
+2011-06-12  Mahesh Kulkarni  <[email protected]>
+
+        Reviewed by Antonio Gomes.
+
+        [Qt] LayoutTestController needs setTextDirection implementation
+        https://bugs.webkit.org/show_bug.cgi?id=62442
+
+        Unskipping fast/html/set-text-direction.html. 
+
+        * platform/qt/Skipped:
+
 2011-06-12  Robert Hogan  <[email protected]>
 
         Reviewed by Andreas Kling.

Modified: trunk/LayoutTests/platform/qt/Skipped (88615 => 88616)


--- trunk/LayoutTests/platform/qt/Skipped	2011-06-12 16:57:54 UTC (rev 88615)
+++ trunk/LayoutTests/platform/qt/Skipped	2011-06-12 17:23:28 UTC (rev 88616)
@@ -653,7 +653,7 @@
 loader/go-back-to-different-window-size.html
 
 # Missing layoutTestController.findString() http://webkit.org/b/50236
-editing/text-iterator/findString.html
+#editing/text-iterator/findString.html
 
 # Missing layoutTestController.setAlwaysAcceptCookies()
 http/tests/xmlhttprequest/access-control-basic-allow-preflight-cache-timeout.html
@@ -2505,9 +2505,6 @@
 fast/events/selectstart-by-double-triple-clicks.html
 fast/events/selectstart-by-drag.html
 
-# LayoutTestController::setTextDirection is not implemented.
-fast/html/set-text-direction.html
-
 # JSC does not support setIsolatedWorldSecurityOrigin (http://webkit.org/b/61540)
 http/tests/security/isolatedWorld/cross-origin-xhr.html
 

Modified: trunk/Tools/ChangeLog (88615 => 88616)


--- trunk/Tools/ChangeLog	2011-06-12 16:57:54 UTC (rev 88615)
+++ trunk/Tools/ChangeLog	2011-06-12 17:23:28 UTC (rev 88616)
@@ -1,3 +1,16 @@
+2011-06-12  Mahesh Kulkarni  <[email protected]>
+
+        Reviewed by Antonio Gomes.
+
+        [Qt] LayoutTestController needs setTextDirection implementation
+        https://bugs.webkit.org/show_bug.cgi?id=62442
+
+        Implements LayoutController.setTextDirection.
+
+        * DumpRenderTree/qt/LayoutTestControllerQt.cpp:
+        (LayoutTestController::setTextDirection):
+        * DumpRenderTree/qt/LayoutTestControllerQt.h:
+
 2011-06-10  Ryosuke Niwa  <[email protected]>
 
         Reviewed by Ojan Vafai.

Modified: trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.cpp (88615 => 88616)


--- trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.cpp	2011-06-12 16:57:54 UTC (rev 88615)
+++ trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.cpp	2011-06-12 17:23:28 UTC (rev 88616)
@@ -954,5 +954,15 @@
     return DumpRenderTreeSupportQt::layerTreeAsText(m_drt->webPage()->mainFrame());
 }
 
+void LayoutTestController::setTextDirection(const QString& directionName)
+{
+    if (directionName == "auto")
+        m_drt->webPage()->triggerAction(QWebPage::SetTextDirectionDefault);
+    else if (directionName == "rtl")
+        m_drt->webPage()->triggerAction(QWebPage::SetTextDirectionRightToLeft);
+    else if (directionName == "ltr")
+        m_drt->webPage()->triggerAction(QWebPage::SetTextDirectionLeftToRight);
+}
+
 const unsigned LayoutTestController::maxViewWidth = 800;
 const unsigned LayoutTestController::maxViewHeight = 600;

Modified: trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.h (88615 => 88616)


--- trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.h	2011-06-12 16:57:54 UTC (rev 88615)
+++ trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.h	2011-06-12 17:23:28 UTC (rev 88616)
@@ -274,6 +274,7 @@
     void observeStorageTrackerNotifications(unsigned number);
     void syncLocalStorage();
     QString layerTreeAsText();
+    void setTextDirection(const QString& directionName);
 
 private slots:
     void processWork();
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to