Title: [129821] trunk
Revision
129821
Author
[email protected]
Date
2012-09-27 17:05:04 -0700 (Thu, 27 Sep 2012)

Log Message

Source/WebKit/chromium: Remove unused methods from Chromium WebKit API.
https://bugs.webkit.org/show_bug.cgi?id=95254

Patch by Nasko Oskov <[email protected]> on 2012-09-27
Reviewed by Adam Barth.

Removing methods, which are no longer in use.

* public/WebFrame.h:
* public/WebFrameClient.h:
(WebKit::WebFrameClient::willCheckAndDispatchMessageEvent):
* src/WebFrameImpl.cpp:
* src/WebFrameImpl.h:
(WebFrameImpl):

Tools: Move DumpRenderTree to use newer version of the name method of
WebFrame and the willCheckAndDispatchMessageEvent method of WebFrameClient
https://bugs.webkit.org/show_bug.cgi?id=95254

Patch by Nasko Oskov <[email protected]> on 2012-09-27
Reviewed by Adam Barth.

The WebFrame name() method is removed and replaced by better named
uniqueName() method, so DRT needs to be updated to use this new version.
Also the willCheckAndDispatchMessageEvent in WebFrameClient gained
one more parameter, which had to be added in DRT.

* DumpRenderTree/chromium/TestShell.cpp:
(dumpFramesAsText):
(dumpFramesAsPrintedText):
(dumpFrameScrollPosition):
* DumpRenderTree/chromium/WebViewHost.cpp:
(WebViewHost::unableToImplementPolicyWithError):
(WebViewHost::willCheckAndDispatchMessageEvent):
(WebViewHost::printFrameDescription):
* DumpRenderTree/chromium/WebViewHost.h:
(WebViewHost):

Modified Paths

Diff

Modified: trunk/Source/WebKit/chromium/ChangeLog (129820 => 129821)


--- trunk/Source/WebKit/chromium/ChangeLog	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Source/WebKit/chromium/ChangeLog	2012-09-28 00:05:04 UTC (rev 129821)
@@ -1,3 +1,19 @@
+2012-09-27  Nasko Oskov  <[email protected]>
+
+        Remove unused methods from Chromium WebKit API.
+        https://bugs.webkit.org/show_bug.cgi?id=95254
+
+        Reviewed by Adam Barth.
+
+        Removing methods, which are no longer in use.
+
+        * public/WebFrame.h:
+        * public/WebFrameClient.h:
+        (WebKit::WebFrameClient::willCheckAndDispatchMessageEvent):
+        * src/WebFrameImpl.cpp:
+        * src/WebFrameImpl.h:
+        (WebFrameImpl):
+
 2012-09-27  Mark Pilgrim  <[email protected]>
 
         [Chromium][Mac] Move Mac-specific theme functions out of PlatformSupport

Modified: trunk/Source/WebKit/chromium/public/WebFrame.h (129820 => 129821)


--- trunk/Source/WebKit/chromium/public/WebFrame.h	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Source/WebKit/chromium/public/WebFrame.h	2012-09-28 00:05:04 UTC (rev 129821)
@@ -132,14 +132,7 @@
 
     // Basic properties ---------------------------------------------------
 
-    // The name of this frame.
-    virtual WebString name() const = 0;
-
     // The unique name of this frame.
-    //
-    // This is temporarily identical to the above name() function. Once this
-    // change makes it over to the Chromium tree, I will change all callers to
-    // use this function and will subsequently move assignedName() to name().
     virtual WebString uniqueName() const = 0;
 
     // The name of this frame. If no name is given, empty string is returned.

Modified: trunk/Source/WebKit/chromium/public/WebFrameClient.h (129820 => 129821)


--- trunk/Source/WebKit/chromium/public/WebFrameClient.h	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Source/WebKit/chromium/public/WebFrameClient.h	2012-09-28 00:05:04 UTC (rev 129821)
@@ -404,18 +404,10 @@
     // gives the embedder a chance to handle it instead of WebKit. Returns true
     // if the embedder handled it.
     virtual bool willCheckAndDispatchMessageEvent(
-        WebFrame* source,
-        WebSecurityOrigin target,
-        WebDOMMessageEvent) { return false; }
-
-    virtual bool willCheckAndDispatchMessageEvent(
         WebFrame* sourceFrame,
         WebFrame* targetFrame,
         WebSecurityOrigin target,
-        WebDOMMessageEvent event)
-    {
-        return willCheckAndDispatchMessageEvent(sourceFrame, target, event);
-    }
+        WebDOMMessageEvent event) { return false; }
 
     // Asks the embedder if a specific user agent should be used for the given
     // URL. Non-empty strings indicate an override should be used. Otherwise,

Modified: trunk/Source/WebKit/chromium/src/WebFrameImpl.cpp (129820 => 129821)


--- trunk/Source/WebKit/chromium/src/WebFrameImpl.cpp	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Source/WebKit/chromium/src/WebFrameImpl.cpp	2012-09-28 00:05:04 UTC (rev 129821)
@@ -598,11 +598,6 @@
         PassRefPtr<Element>(element).get());
 }
 
-WebString WebFrameImpl::name() const
-{
-    return m_frame->tree()->uniqueName();
-}
-
 WebString WebFrameImpl::uniqueName() const
 {
     return m_frame->tree()->uniqueName();

Modified: trunk/Source/WebKit/chromium/src/WebFrameImpl.h (129820 => 129821)


--- trunk/Source/WebKit/chromium/src/WebFrameImpl.h	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Source/WebKit/chromium/src/WebFrameImpl.h	2012-09-28 00:05:04 UTC (rev 129821)
@@ -72,7 +72,6 @@
 class WebFrameImpl : public WebFrame, public RefCounted<WebFrameImpl> {
 public:
     // WebFrame methods:
-    virtual WebString name() const;
     virtual WebString uniqueName() const;
     virtual WebString assignedName() const;
     virtual void setName(const WebString&);

Modified: trunk/Tools/ChangeLog (129820 => 129821)


--- trunk/Tools/ChangeLog	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Tools/ChangeLog	2012-09-28 00:05:04 UTC (rev 129821)
@@ -1,3 +1,27 @@
+2012-09-27  Nasko Oskov  <[email protected]>
+
+        Move DumpRenderTree to use newer version of the name method of
+        WebFrame and the willCheckAndDispatchMessageEvent method of WebFrameClient
+        https://bugs.webkit.org/show_bug.cgi?id=95254
+
+        Reviewed by Adam Barth.
+
+        The WebFrame name() method is removed and replaced by better named
+        uniqueName() method, so DRT needs to be updated to use this new version.
+        Also the willCheckAndDispatchMessageEvent in WebFrameClient gained
+        one more parameter, which had to be added in DRT.
+
+        * DumpRenderTree/chromium/TestShell.cpp:
+        (dumpFramesAsText):
+        (dumpFramesAsPrintedText):
+        (dumpFrameScrollPosition):
+        * DumpRenderTree/chromium/WebViewHost.cpp:
+        (WebViewHost::unableToImplementPolicyWithError):
+        (WebViewHost::willCheckAndDispatchMessageEvent):
+        (WebViewHost::printFrameDescription):
+        * DumpRenderTree/chromium/WebViewHost.h:
+        (WebViewHost):
+
 2012-09-27  Julie Parent  <[email protected]>
 
         Add webkit_unit_tests to the flakiness dashboard

Modified: trunk/Tools/DumpRenderTree/chromium/TestShell.cpp (129820 => 129821)


--- trunk/Tools/DumpRenderTree/chromium/TestShell.cpp	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Tools/DumpRenderTree/chromium/TestShell.cpp	2012-09-28 00:05:04 UTC (rev 129821)
@@ -399,7 +399,7 @@
     // Add header for all but the main frame. Skip empty frames.
     if (frame->parent() && !frame->document().documentElement().isNull()) {
         result.append("\n--------\nFrame: '");
-        result.append(frame->name().utf8().data());
+        result.append(frame->uniqueName().utf8().data());
         result.append("'\n--------\n");
     }
 
@@ -425,7 +425,7 @@
     // Add header for all but the main frame. Skip empty frames.
     if (frame->parent() && !frame->document().documentElement().isNull()) {
         result.append("\n--------\nFrame: '");
-        result.append(frame->name().utf8().data());
+        result.append(frame->uniqueName().utf8().data());
         result.append("'\n--------\n");
     }
 
@@ -445,7 +445,7 @@
     WebSize offset = frame->scrollOffset();
     if (offset.width > 0 || offset.height > 0) {
         if (frame->parent())
-            printf("frame '%s' ", frame->name().utf8().data());
+            printf("frame '%s' ", frame->uniqueName().utf8().data());
         printf("scrolled to %d,%d\n", offset.width, offset.height);
     }
 

Modified: trunk/Tools/DumpRenderTree/chromium/WebViewHost.cpp (129820 => 129821)


--- trunk/Tools/DumpRenderTree/chromium/WebViewHost.cpp	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Tools/DumpRenderTree/chromium/WebViewHost.cpp	2012-09-28 00:05:04 UTC (rev 129821)
@@ -1096,7 +1096,7 @@
 {
     printf("Policy delegate: unable to implement policy with error domain '%s', "
            "error code %d, in frame '%s'\n",
-           error.domain.utf8().data(), error.reason, frame->name().utf8().data());
+            error.domain.utf8().data(), error.reason, frame->uniqueName().utf8().data());
 }
 
 void WebViewHost::willPerformClientRedirect(WebFrame* frame, const WebURL& from, const WebURL& to,
@@ -1399,7 +1399,7 @@
     webkit_support::DeleteFileSystem(frame, type, callbacks);
 }
 
-bool WebViewHost::willCheckAndDispatchMessageEvent(WebFrame* source, WebSecurityOrigin target, WebDOMMessageEvent event)
+bool WebViewHost::willCheckAndDispatchMessageEvent(WebFrame* sourceFrame, WebFrame* targetFrame, WebSecurityOrigin target, WebDOMMessageEvent event)
 {
     if (m_shell->testRunner()->shouldInterceptPostMessage()) {
         fputs("intercepted postMessage\n", stdout);
@@ -1745,7 +1745,7 @@
 
 void WebViewHost::printFrameDescription(WebFrame* webframe)
 {
-    string name8 = webframe->name().utf8();
+    string name8 = webframe->uniqueName().utf8();
     if (webframe == webView()->mainFrame()) {
         if (!name8.length()) {
             fputs("main frame", stdout);

Modified: trunk/Tools/DumpRenderTree/chromium/WebViewHost.h (129820 => 129821)


--- trunk/Tools/DumpRenderTree/chromium/WebViewHost.h	2012-09-28 00:02:32 UTC (rev 129820)
+++ trunk/Tools/DumpRenderTree/chromium/WebViewHost.h	2012-09-28 00:05:04 UTC (rev 129821)
@@ -268,7 +268,9 @@
     virtual void didDetectXSS(WebKit::WebFrame*, const WebKit::WebURL&, bool didBlockEntirePage);
     virtual void openFileSystem(WebKit::WebFrame*, WebKit::WebFileSystem::Type, long long size, bool create, WebKit::WebFileSystemCallbacks*);
     virtual void deleteFileSystem(WebKit::WebFrame*, WebKit::WebFileSystem::Type, WebKit::WebFileSystemCallbacks*);
-    virtual bool willCheckAndDispatchMessageEvent(WebKit::WebFrame* source, WebKit::WebSecurityOrigin target, WebKit::WebDOMMessageEvent);
+    virtual bool willCheckAndDispatchMessageEvent(
+        WebKit::WebFrame* sourceFrame, WebKit::WebFrame* targetFrame, 
+        WebKit::WebSecurityOrigin target, WebKit::WebDOMMessageEvent);
     virtual void registerIntentService(WebKit::WebFrame*, const WebKit::WebIntentServiceInfo&);
     virtual void dispatchIntent(WebKit::WebFrame*, const WebKit::WebIntentRequest&);
     virtual void deliveredIntentResult(WebKit::WebFrame*, int, const WebKit::WebSerializedScriptValue&);
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to