- Revision
- 139795
- Author
- [email protected]
- Date
- 2013-01-15 14:46:47 -0800 (Tue, 15 Jan 2013)
Log Message
[chromium] route more webkit_support and webviewhost callbacks through WebTestDelegate
https://bugs.webkit.org/show_bug.cgi?id=106904
Reverting 139794. It broke the build. It appears that a header file,
WebTextDirection.h, was left out.
* DumpRenderTree/chromium/DRTTestRunner.cpp:
(DRTTestRunner::DRTTestRunner):
(DRTTestRunner::reset):
* DumpRenderTree/chromium/DRTTestRunner.h:
(DRTTestRunner::setTitleTextDirection):
* DumpRenderTree/chromium/TestRunner/public/WebTestRunner.h:
(WebTestRunner::WebTestRunner::shouldStayOnPageAfterHandlingBeforeUnload):
* DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp:
(WebTestRunner::TestRunner::TestRunner):
(WebTestRunner::TestRunner::reset):
(WebTestRunner::TestRunner::shouldStayOnPageAfterHandlingBeforeUnload):
* DumpRenderTree/chromium/TestRunner/src/TestRunner.h:
(TestRunner):
* DumpRenderTree/chromium/TestRunner/src/WebTestProxy.cpp:
(WebTestRunner::WebTestProxyBase::didReceiveTitle):
* DumpRenderTree/chromium/WebViewHost.cpp:
(WebViewHost::didReceiveTitle):
Modified Paths
Diff
Modified: trunk/Tools/ChangeLog (139794 => 139795)
--- trunk/Tools/ChangeLog 2013-01-15 22:30:54 UTC (rev 139794)
+++ trunk/Tools/ChangeLog 2013-01-15 22:46:47 UTC (rev 139795)
@@ -1,3 +1,29 @@
+2013-01-15 Levi Weintraub <[email protected]>
+
+ [chromium] route more webkit_support and webviewhost callbacks through WebTestDelegate
+ https://bugs.webkit.org/show_bug.cgi?id=106904
+
+ Reverting 139794. It broke the build. It appears that a header file,
+ WebTextDirection.h, was left out.
+
+ * DumpRenderTree/chromium/DRTTestRunner.cpp:
+ (DRTTestRunner::DRTTestRunner):
+ (DRTTestRunner::reset):
+ * DumpRenderTree/chromium/DRTTestRunner.h:
+ (DRTTestRunner::setTitleTextDirection):
+ * DumpRenderTree/chromium/TestRunner/public/WebTestRunner.h:
+ (WebTestRunner::WebTestRunner::shouldStayOnPageAfterHandlingBeforeUnload):
+ * DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp:
+ (WebTestRunner::TestRunner::TestRunner):
+ (WebTestRunner::TestRunner::reset):
+ (WebTestRunner::TestRunner::shouldStayOnPageAfterHandlingBeforeUnload):
+ * DumpRenderTree/chromium/TestRunner/src/TestRunner.h:
+ (TestRunner):
+ * DumpRenderTree/chromium/TestRunner/src/WebTestProxy.cpp:
+ (WebTestRunner::WebTestProxyBase::didReceiveTitle):
+ * DumpRenderTree/chromium/WebViewHost.cpp:
+ (WebViewHost::didReceiveTitle):
+
2013-01-15 Jochen Eisinger <[email protected]>
[chromium] route more webkit_support and webviewhost callbacks through WebTestDelegate
Modified: trunk/Tools/DumpRenderTree/chromium/DRTTestRunner.cpp (139794 => 139795)
--- trunk/Tools/DumpRenderTree/chromium/DRTTestRunner.cpp 2013-01-15 22:30:54 UTC (rev 139794)
+++ trunk/Tools/DumpRenderTree/chromium/DRTTestRunner.cpp 2013-01-15 22:46:47 UTC (rev 139795)
@@ -146,6 +146,7 @@
// Shared properties.
// webHistoryItemCount is used by tests in LayoutTests\http\tests\history
bindProperty("webHistoryItemCount", &m_webHistoryItemCount);
+ bindProperty("titleTextDirection", &m_titleTextDirection);
bindProperty("interceptPostMessage", &m_interceptPostMessage);
}
@@ -385,6 +386,7 @@
TestRunner::reset();
m_waitUntilDone = false;
m_webHistoryItemCount.set(0);
+ m_titleTextDirection.set("ltr");
m_interceptPostMessage.set(false);
if (m_closeRemainingWindows)
Modified: trunk/Tools/DumpRenderTree/chromium/DRTTestRunner.h (139794 => 139795)
--- trunk/Tools/DumpRenderTree/chromium/DRTTestRunner.h 2013-01-15 22:30:54 UTC (rev 139794)
+++ trunk/Tools/DumpRenderTree/chromium/DRTTestRunner.h 2013-01-15 22:46:47 UTC (rev 139795)
@@ -44,6 +44,7 @@
#include "TestRunner/src/TestRunner.h"
#include "WebTask.h"
+#include "WebTextDirection.h"
#include "platform/WebArrayBufferView.h"
#include "platform/WebString.h"
#include "platform/WebURL.h"
@@ -156,6 +157,10 @@
void setWorkQueueFrozen(bool frozen) { m_workQueue.setFrozen(frozen); }
void setShowDebugLayerTree(bool value) { m_showDebugLayerTree = value; }
+ void setTitleTextDirection(WebKit::WebTextDirection dir)
+ {
+ m_titleTextDirection.set(dir == WebKit::WebTextDirectionLeftToRight ? "ltr" : "rtl");
+ }
bool shouldInterceptPostMessage()
{
@@ -242,6 +247,9 @@
// Bound variable counting the number of top URLs visited.
CppVariant m_webHistoryItemCount;
+ // Bound variable tracking the directionality of the <title> tag.
+ CppVariant m_titleTextDirection;
+
// Bound variable to set whether postMessages should be intercepted or not
CppVariant m_interceptPostMessage;
};
Modified: trunk/Tools/DumpRenderTree/chromium/TestRunner/public/WebTestRunner.h (139794 => 139795)
--- trunk/Tools/DumpRenderTree/chromium/TestRunner/public/WebTestRunner.h 2013-01-15 22:30:54 UTC (rev 139794)
+++ trunk/Tools/DumpRenderTree/chromium/TestRunner/public/WebTestRunner.h 2013-01-15 22:46:47 UTC (rev 139795)
@@ -31,8 +31,6 @@
#ifndef WebTestRunner_h
#define WebTestRunner_h
-#include "WebTextDirection.h"
-
namespace WebKit {
class WebArrayBufferView;
class WebPermissionClient;
@@ -74,7 +72,6 @@
virtual bool sweepHorizontally() const { return false; }
virtual bool isPrinting() const { return false; }
virtual bool shouldStayOnPageAfterHandlingBeforeUnload() const { return false; }
- virtual void setTitleTextDirection(WebKit::WebTextDirection) { }
};
}
Modified: trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp (139794 => 139795)
--- trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp 2013-01-15 22:30:54 UTC (rev 139794)
+++ trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.cpp 2013-01-15 22:46:47 UTC (rev 139795)
@@ -211,7 +211,6 @@
// Properties.
bindProperty("workerThreadCount", &TestRunner::workerThreadCount);
bindProperty("globalFlag", &m_globalFlag);
- bindProperty("titleTextDirection", &m_titleTextDirection);
bindProperty("platformName", &m_platformName);
// The following are stubs.
@@ -306,7 +305,6 @@
m_shouldStayOnPageAfterHandlingBeforeUnload = false;
m_globalFlag.set(false);
- m_titleTextDirection.set("ltr");
m_platformName.set("chromium");
m_userStyleSheetLocation = WebURL();
@@ -466,11 +464,6 @@
return m_shouldStayOnPageAfterHandlingBeforeUnload;
}
-void TestRunner::setTitleTextDirection(WebKit::WebTextDirection dir)
-{
- m_titleTextDirection.set(dir == WebKit::WebTextDirectionLeftToRight ? "ltr" : "rtl");
-}
-
void TestRunner::dumpPermissionClientCallbacks(const CppArgumentList&, CppVariant* result)
{
m_webPermissions->setDumpCallbacks(true);
Modified: trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.h (139794 => 139795)
--- trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.h 2013-01-15 22:30:54 UTC (rev 139794)
+++ trunk/Tools/DumpRenderTree/chromium/TestRunner/src/TestRunner.h 2013-01-15 22:46:47 UTC (rev 139795)
@@ -93,7 +93,6 @@
virtual bool sweepHorizontally() const OVERRIDE;
virtual bool isPrinting() const OVERRIDE;
virtual bool shouldStayOnPageAfterHandlingBeforeUnload() const OVERRIDE;
- virtual void setTitleTextDirection(WebKit::WebTextDirection) OVERRIDE;
protected:
// FIXME: make these private once the move from DRTTestRunner to TestRunner
@@ -390,9 +389,6 @@
// Bound variable to return the name of this platform (chromium).
CppVariant m_platformName;
- // Bound variable tracking the directionality of the <title> tag.
- CppVariant m_titleTextDirection;
-
// If true, the test_shell will write a descriptive line for each editing
// command.
bool m_dumpEditingCallbacks;
Modified: trunk/Tools/DumpRenderTree/chromium/TestRunner/src/WebTestProxy.cpp (139794 => 139795)
--- trunk/Tools/DumpRenderTree/chromium/TestRunner/src/WebTestProxy.cpp 2013-01-15 22:30:54 UTC (rev 139794)
+++ trunk/Tools/DumpRenderTree/chromium/TestRunner/src/WebTestProxy.cpp 2013-01-15 22:46:47 UTC (rev 139795)
@@ -580,7 +580,7 @@
}
}
-void WebTestProxyBase::didReceiveTitle(WebFrame* frame, const WebString& title, WebTextDirection direction)
+void WebTestProxyBase::didReceiveTitle(WebFrame* frame, const WebString& title, WebTextDirection)
{
WebCString title8 = title.utf8();
@@ -592,8 +592,6 @@
if (m_testInterfaces->testRunner() && m_testInterfaces->testRunner()->shouldDumpTitleChanges())
m_delegate->printMessage(string("TITLE CHANGED: '") + title8.data() + "'\n");
- if (m_testInterfaces->testRunner())
- m_testInterfaces->testRunner()->setTitleTextDirection(direction);
}
void WebTestProxyBase::didFinishDocumentLoad(WebFrame* frame)
Modified: trunk/Tools/DumpRenderTree/chromium/WebViewHost.cpp (139794 => 139795)
--- trunk/Tools/DumpRenderTree/chromium/WebViewHost.cpp 2013-01-15 22:30:54 UTC (rev 139794)
+++ trunk/Tools/DumpRenderTree/chromium/WebViewHost.cpp 2013-01-15 22:46:47 UTC (rev 139795)
@@ -856,6 +856,7 @@
void WebViewHost::didReceiveTitle(WebFrame* frame, const WebString& title, WebTextDirection direction)
{
setPageTitle(title);
+ testRunner()->setTitleTextDirection(direction);
}
void WebViewHost::didFailLoad(WebFrame* frame, const WebURLError& error)