Title: [110594] trunk
Revision
110594
Author
[email protected]
Date
2012-03-13 13:05:01 -0700 (Tue, 13 Mar 2012)

Log Message

Convert nodesFromRect tests to use Internals interface
https://bugs.webkit.org/show_bug.cgi?id=80886

Reviewed by Ryosuke Niwa.
Patch by Antonio Gomes <[email protected]>

Source/WebCore:

Add Internals::nodesFromRect implementation to unify
the codepath for testing Document::nodesFromRect in a
cross port way.

No new tests, since we are improving here the infra-structure
for testing a specific method.

* testing/Internals.cpp:
(WebCore::Internals::nodesFromRect):
(WebCore):
* testing/Internals.h:
(Internals):
* testing/Internals.idl:

Source/WebKit/gtk:

Removed DRTSupportGtk::nodesFromRect support, since
it can work in the cross-port way through the
Internals interface.

* WebCoreSupport/DumpRenderTreeSupportGtk.cpp:
* WebCoreSupport/DumpRenderTreeSupportGtk.h:
(DumpRenderTreeSupportGtk):

Source/WebKit/mac:

Removed mac specific support for nodesFromRect for testing purposes only,
since it can work in a cross-port way through the Internals interface.

* WebKit.order:
* WebView/WebView.mm:
* WebView/WebViewPrivate.h:

Source/WebKit/qt:

Removed DRTSupportQt::nodesFromRect support, since
it can work in the cross-port way through the
Internals interface.

* WebCoreSupport/DumpRenderTreeSupportQt.cpp:
* WebCoreSupport/DumpRenderTreeSupportQt.h:

Tools:

This clean up allows to remove port specific bits of each
DRT implementation that supports testing Document::nodesFromRect,
in favor of making use of the 'Internals' interface to test it.

This makes its code conveniently more expansible and cleaner.

Also removed stubs from Win and EFL, Wn and BlackBerry DRTs.

* DumpRenderTree/LayoutTestController.cpp:
(LayoutTestController::staticFunctions):
* DumpRenderTree/LayoutTestController.h:
(LayoutTestController):
* DumpRenderTree/efl/LayoutTestControllerEfl.cpp:
* DumpRenderTree/gtk/LayoutTestControllerGtk.cpp:
* DumpRenderTree/mac/LayoutTestControllerMac.mm:
* DumpRenderTree/qt/LayoutTestControllerQt.cpp:
* DumpRenderTree/qt/LayoutTestControllerQt.h:
(LayoutTestController):
* DumpRenderTree/win/LayoutTestControllerWin.cpp:

LayoutTests:

Adjust nodesFromRect tests to use Internals
instead of LayoutTestController interface.

* fast/dom/resources/nodesFromRect.js:
(check):

Modified Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (110593 => 110594)


--- trunk/LayoutTests/ChangeLog	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/LayoutTests/ChangeLog	2012-03-13 20:05:01 UTC (rev 110594)
@@ -1,3 +1,16 @@
+2012-03-12  Antonio Gomes  <[email protected]>
+
+        Convert nodesFromRect tests to use Internals interface
+        https://bugs.webkit.org/show_bug.cgi?id=80886
+
+        Reviewed by Ryosuke Niwa.
+
+        Adjust nodesFromRect tests to use Internals
+        instead of LayoutTestController interface.
+
+        * fast/dom/resources/nodesFromRect.js:
+        (check):
+
 2012-03-13  Philip Rogers  <[email protected]>
 
         Fix the use of stale text fragments

Modified: trunk/LayoutTests/fast/dom/resources/nodesFromRect.js (110593 => 110594)


--- trunk/LayoutTests/fast/dom/resources/nodesFromRect.js	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/LayoutTests/fast/dom/resources/nodesFromRect.js	2012-03-13 20:05:01 UTC (rev 110594)
@@ -5,13 +5,13 @@
 
 function check(x, y, topPadding, rightPadding, bottomPadding, leftPadding, list, doc)
 {
-  if (!window.layoutTestController)
+  if (!window.internals)
     return;
 
   if (!doc)
     doc = document;
 
-  var nodes = layoutTestController.nodesFromRect(doc, x, y, topPadding, rightPadding, bottomPadding, leftPadding, true /* ignoreClipping */);
+  var nodes = internals.nodesFromRect(doc, x, y, topPadding, rightPadding, bottomPadding, leftPadding, true /* ignoreClipping */);
   if (!nodes)
     return;
 

Modified: trunk/Source/WebCore/ChangeLog (110593 => 110594)


--- trunk/Source/WebCore/ChangeLog	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebCore/ChangeLog	2012-03-13 20:05:01 UTC (rev 110594)
@@ -1,3 +1,24 @@
+2012-03-12  Antonio Gomes  <[email protected]>
+
+        Convert nodesFromRect tests to use Internals interface
+        https://bugs.webkit.org/show_bug.cgi?id=80886
+
+        Reviewed by Ryosuke Niwa.
+
+        Add Internals::nodesFromRect implementation to unify
+        the codepath for testing Document::nodesFromRect in a
+        cross port way.
+
+        No new tests, since we are improving here the infra-structure
+        for testing a specific method.
+
+        * testing/Internals.cpp:
+        (WebCore::Internals::nodesFromRect):
+        (WebCore):
+        * testing/Internals.h:
+        (Internals):
+        * testing/Internals.idl:
+
 2012-03-13  Philip Rogers  <[email protected]>
 
         Fix the use of stale text fragments

Modified: trunk/Source/WebCore/testing/Internals.cpp (110593 => 110594)


--- trunk/Source/WebCore/testing/Internals.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebCore/testing/Internals.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -692,4 +692,15 @@
     return document->touchEventHandlerCount();
 }
 
+PassRefPtr<NodeList> Internals::nodesFromRect(Document* document, int x, int y, unsigned topPadding, unsigned rightPadding,
+    unsigned bottomPadding, unsigned leftPadding, bool ignoreClipping, ExceptionCode& ec) const
+{
+    if (!document || !document->frame() || !document->frame()->view()) {
+        ec = INVALID_ACCESS_ERR;
+        return 0;
+    }
+
+    return document->nodesFromRect(x, y, topPadding, rightPadding, bottomPadding, leftPadding, ignoreClipping);
 }
+
+}

Modified: trunk/Source/WebCore/testing/Internals.h (110593 => 110594)


--- trunk/Source/WebCore/testing/Internals.h	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebCore/testing/Internals.h	2012-03-13 20:05:01 UTC (rev 110594)
@@ -27,6 +27,7 @@
 #define Internals_h
 
 #include "FrameDestructionObserver.h"
+#include "NodeList.h"
 #include "PlatformString.h"
 #include <wtf/PassRefPtr.h>
 #include <wtf/RefCounted.h>
@@ -125,6 +126,9 @@
     unsigned wheelEventHandlerCount(Document*, ExceptionCode&);
     unsigned touchEventHandlerCount(Document*, ExceptionCode&);
 
+    PassRefPtr<NodeList> nodesFromRect(Document*, int x, int y, unsigned topPadding, unsigned rightPadding,
+        unsigned bottomPadding, unsigned leftPadding, bool ignoreClipping, ExceptionCode&) const;
+
     static const char* internalsId;
 
     InternalSettings* settings() const { return m_settings.get(); }

Modified: trunk/Source/WebCore/testing/Internals.idl (110593 => 110594)


--- trunk/Source/WebCore/testing/Internals.idl	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebCore/testing/Internals.idl	2012-03-13 20:05:01 UTC (rev 110594)
@@ -101,6 +101,10 @@
         unsigned long wheelEventHandlerCount(in Document document) raises (DOMException);
         unsigned long touchEventHandlerCount(in Document document) raises (DOMException);
 
+        NodeList nodesFromRect(in Document document, in long x, in long y,
+            in unsigned long topPadding, in unsigned long rightPadding, in unsigned long bottomPadding, in unsigned long leftPadding,
+            in boolean ignoreClipping) raises (DOMException);
+
         readonly attribute InternalSettings settings;
     };
 }

Modified: trunk/Source/WebKit/gtk/ChangeLog (110593 => 110594)


--- trunk/Source/WebKit/gtk/ChangeLog	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/gtk/ChangeLog	2012-03-13 20:05:01 UTC (rev 110594)
@@ -1,3 +1,18 @@
+2012-03-12  Antonio Gomes  <[email protected]>
+
+        Convert nodesFromRect tests to use Internals interface
+        https://bugs.webkit.org/show_bug.cgi?id=80886
+
+        Reviewed by Ryosuke Niwa.
+
+        Removed DRTSupportGtk::nodesFromRect support, since
+        it can work in the cross-port way through the
+        Internals interface.
+
+        * WebCoreSupport/DumpRenderTreeSupportGtk.cpp:
+        * WebCoreSupport/DumpRenderTreeSupportGtk.h:
+        (DumpRenderTreeSupportGtk):
+
 2012-03-07  Kangil Han  <[email protected]>
 
         [DRT] Remove PlainTextController implementations.

Modified: trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.cpp (110593 => 110594)


--- trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -113,22 +113,6 @@
     return s_selectTrailingWhitespaceEnabled;
 }
 
-JSValueRef DumpRenderTreeSupportGtk::nodesFromRect(JSContextRef context, JSValueRef value, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping)
-{
-    JSLock lock(SilenceAssertionsOnly);
-    ExecState* exec = toJS(context);
-    if (!value)
-        return JSValueMakeUndefined(context);
-    JSValue jsValue = toJS(exec, value);
-    if (!jsValue.inherits(&JSDocument::s_info))
-       return JSValueMakeUndefined(context);
-
-    JSDocument* jsDocument = static_cast<JSDocument*>(asObject(jsValue));
-    Document* document = jsDocument->impl();
-    RefPtr<NodeList> nodes = document->nodesFromRect(x, y, top, right, bottom, left, ignoreClipping);
-    return toRef(exec, toJS(exec, jsDocument->globalObject(), nodes.get()));
-}
-
 /**
  * getFrameChildren:
  * @frame: a #WebKitWebFrame

Modified: trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.h (110593 => 110594)


--- trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.h	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/gtk/WebCoreSupport/DumpRenderTreeSupportGtk.h	2012-03-13 20:05:01 UTC (rev 110594)
@@ -53,7 +53,6 @@
     static void setSelectTrailingWhitespaceEnabled(bool);
     static bool selectTrailingWhitespaceEnabled();
 
-    static JSValueRef nodesFromRect(JSContextRef context, JSValueRef value, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping);
     static void dumpConfigurationForViewport(WebKitWebView* webView, gint deviceDPI, gint deviceWidth, gint deviceHeight, gint availableWidth, gint availableHeight);
 
     static void clearOpener(WebKitWebFrame*);

Modified: trunk/Source/WebKit/mac/ChangeLog (110593 => 110594)


--- trunk/Source/WebKit/mac/ChangeLog	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/mac/ChangeLog	2012-03-13 20:05:01 UTC (rev 110594)
@@ -1,3 +1,17 @@
+2012-03-12  Antonio Gomes  <[email protected]>
+
+        Convert nodesFromRect tests to use Internals interface
+        https://bugs.webkit.org/show_bug.cgi?id=80886
+
+        Reviewed by Ryosuke Niwa.
+
+        Removed mac specific support for nodesFromRect for testing purposes only,
+        since it can work in a cross-port way through the Internals interface.
+
+        * WebKit.order:
+        * WebView/WebView.mm:
+        * WebView/WebViewPrivate.h:
+
 2012-03-13  Anders Carlsson  <[email protected]>
 
         Remove a nonexistent WebUIDelegate method from WebUIDelegatePrivate.h

Modified: trunk/Source/WebKit/mac/WebKit.order (110593 => 110594)


--- trunk/Source/WebKit/mac/WebKit.order	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/mac/WebKit.order	2012-03-13 20:05:01 UTC (rev 110594)
@@ -1815,7 +1815,6 @@
 __ZN15WebChromeClient15closeWindowSoonEv
 -[WebView(WebIBActions) stopLoading:]
 -[WebView(WebPrivate) _closeWindow]
--[WebView(WebViewPrivateNodesFromRect) _nodesFromRect:forDocument:x:y:top:right:bottom:left:ignoreClipping:]
 __ZN20WebFrameLoaderClient38dispatchDecidePolicyForNewWindowActionEMN7WebCore13PolicyCheckerEFvNS0_12PolicyActionEERKNS0_16NavigationActionERKNS0_15ResourceRequestEN3WTF10PassRefPtrINS0_9FormStateEEERKNSB_6StringE
 -[WebDefaultPolicyDelegate webView:decidePolicyForNewWindowAction:request:newFrameName:decisionListener:]
 __ZN20WebFrameLoaderClient18dispatchCreatePageERKN7WebCore16NavigationActionE

Modified: trunk/Source/WebKit/mac/WebView/WebView.mm (110593 => 110594)


--- trunk/Source/WebKit/mac/WebView/WebView.mm	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/mac/WebView/WebView.mm	2012-03-13 20:05:01 UTC (rev 110594)
@@ -6461,25 +6461,6 @@
 
 @end
 
-@implementation WebView (WebViewPrivateNodesFromRect)
-
-- (JSValueRef)_nodesFromRect:(JSContextRef)context forDocument:(JSValueRef)value x:(int)x  y:(int)y top:(unsigned)top right:(unsigned)right bottom:(unsigned)bottom left:(unsigned)left ignoreClipping:(BOOL)ignoreClipping
-{
-    JSLock lock(SilenceAssertionsOnly);
-    ExecState* exec = toJS(context);
-    if (!value)
-        return JSValueMakeUndefined(context);
-    JSValue jsValue = toJS(exec, value);
-    if (!jsValue.inherits(&JSDocument::s_info))
-        return JSValueMakeUndefined(context);
-    JSDocument* jsDocument = static_cast<JSDocument*>(asObject(jsValue));
-    Document* document = jsDocument->impl();
-    RefPtr<NodeList> nodes = document->nodesFromRect(x, y, top, right, bottom, left, ignoreClipping);
-    return toRef(exec, toJS(exec, jsDocument->globalObject(), nodes.get()));
-}
-
-@end
-
 void WebInstallMemoryPressureHandler(void)
 {
     memoryPressureHandler().install();

Modified: trunk/Source/WebKit/mac/WebView/WebViewPrivate.h (110593 => 110594)


--- trunk/Source/WebKit/mac/WebView/WebViewPrivate.h	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/mac/WebView/WebViewPrivate.h	2012-03-13 20:05:01 UTC (rev 110594)
@@ -747,10 +747,6 @@
 - (JSValueRef)_computedStyleIncludingVisitedInfo:(JSContextRef)context forElement:(JSValueRef)value;
 @end
 
-@interface WebView (WebViewPrivateNodesFromRect)
-- (JSValueRef)_nodesFromRect:(JSContextRef)context forDocument:(JSValueRef)value x:(int)x  y:(int)y top:(unsigned)top right:(unsigned)right bottom:(unsigned)bottom left:(unsigned)left ignoreClipping:(BOOL)ignoreClipping;
-@end
-
 @interface NSObject (WebViewFrameLoadDelegatePrivate)
 - (void)webView:(WebView *)sender didFirstLayoutInFrame:(WebFrame *)frame;
 

Modified: trunk/Source/WebKit/qt/ChangeLog (110593 => 110594)


--- trunk/Source/WebKit/qt/ChangeLog	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/qt/ChangeLog	2012-03-13 20:05:01 UTC (rev 110594)
@@ -1,3 +1,17 @@
+2012-03-12  Antonio Gomes  <[email protected]>
+
+        Convert nodesFromRect tests to use Internals interface
+        https://bugs.webkit.org/show_bug.cgi?id=80886
+
+        Reviewed by Ryosuke Niwa.
+
+        Removed DRTSupportQt::nodesFromRect support, since
+        it can work in the cross-port way through the
+        Internals interface.
+
+        * WebCoreSupport/DumpRenderTreeSupportQt.cpp:
+        * WebCoreSupport/DumpRenderTreeSupportQt.h:
+
 2012-03-09  Jon Lee  <[email protected]>
 
         Rename NotificationPresenter to NotificationClient

Modified: trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp (110593 => 110594)


--- trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -992,27 +992,6 @@
 #endif
 }
 
-QVariantList DumpRenderTreeSupportQt::nodesFromRect(const QWebElement& document, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping)
-{
-    QVariantList res;
-    WebCore::Element* webElement = document.m_element;
-    if (!webElement)
-        return res;
-
-    Document* doc = webElement->document();
-    if (!doc)
-        return res;
-    RefPtr<NodeList> nodes = doc->nodesFromRect(x, y, top, right, bottom, left, ignoreClipping);
-    for (unsigned i = 0; i < nodes->length(); i++) {
-        // QWebElement will be null if the Node is not an HTML Element
-        if (nodes->item(i)->isHTMLElement())
-            res << QVariant::fromValue(QWebElement(nodes->item(i)));
-        else
-            res << QVariant::fromValue(QDRTNode(nodes->item(i)));
-    }
-    return res;
-}
-
 void DumpRenderTreeSupportQt::setDefersLoading(QWebPage* page, bool flag)
 {
     Page* corePage = QWebPagePrivate::core(page);

Modified: trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h (110593 => 110594)


--- trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit/qt/WebCoreSupport/DumpRenderTreeSupportQt.h	2012-03-13 20:05:01 UTC (rev 110594)
@@ -206,7 +206,6 @@
 
     static void scalePageBy(QWebFrame*, float scale, const QPoint& origin);
 
-    static QVariantList nodesFromRect(const QWebElement& document, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping);
     static QString responseMimeType(QWebFrame*);
     static void clearOpener(QWebFrame*);
     static void addURLToRedirect(const QString& origin, const QString& destination);

Modified: trunk/Source/WebKit2/win/WebKit2.def (110593 => 110594)


--- trunk/Source/WebKit2/win/WebKit2.def	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/WebKit2/win/WebKit2.def	2012-03-13 20:05:01 UTC (rev 110594)
@@ -204,8 +204,10 @@
         ?toJS@WebCore@@YA?AVJSValue@JSC@@PAVExecState@3@PAVJSDOMGlobalObject@1@PAVClientRectList@1@@Z
         ?toJS@WebCore@@YA?AVJSValue@JSC@@PAVExecState@3@PAVJSDOMGlobalObject@1@PAVNode@1@@Z
         ?toJS@WebCore@@YA?AVJSValue@JSC@@PAVExecState@3@PAVJSDOMGlobalObject@1@PAVRange@1@@Z
+        ?toJS@WebCore@@YA?AVJSValue@JSC@@PAVExecState@3@PAVJSDOMGlobalObject@1@PAVNodeList@1@@Z
         ?toRange@WebCore@@YAPAVRange@1@VJSValue@JSC@@@Z
         ?updateLayoutIgnorePendingStylesheets@Document@WebCore@@QAEXXZ
         ?userPreferredLanguages@WebCore@@YA?AV?$Vector@VString@WTF@@$0A@@WTF@@XZ
         ?view@Document@WebCore@@QBEPAVFrameView@2@XZ
         ?willDetachPage@FrameDestructionObserver@WebCore@@UAEXXZ
+        ?nodesFromRect@Document@WebCore@@QBE?AV?$PassRefPtr@VNodeList@WebCore@@@WTF@@HHIIII_N@Z

Modified: trunk/Source/autotools/symbols.filter (110593 => 110594)


--- trunk/Source/autotools/symbols.filter	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Source/autotools/symbols.filter	2012-03-13 20:05:01 UTC (rev 110594)
@@ -107,6 +107,8 @@
 _ZN7WebCore22RuntimeEnabledFeatures31isMultipleShadowSubtreesEnabledE;
 _ZN7WebCore22RuntimeEnabledFeatures32setMultipleShadowSubtreesEnabledEb;
 _ZN7WebCore22RuntimeEnabledFeatures18isShadowDOMEnabledE;
+_ZNK7WebCore8Document13nodesFromRectEiijjjjb;
+_ZN7WebCore4toJSEPN3JSC9ExecStateEPNS_17JSDOMGlobalObjectEPNS_8NodeListE;
 local:
 _Z*;
 cti*;

Modified: trunk/Tools/ChangeLog (110593 => 110594)


--- trunk/Tools/ChangeLog	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/ChangeLog	2012-03-13 20:05:01 UTC (rev 110594)
@@ -1,3 +1,30 @@
+2012-03-12  Antonio Gomes  <[email protected]>
+
+        Convert nodesFromRect tests to use Internals interface
+        https://bugs.webkit.org/show_bug.cgi?id=80886
+
+        Reviewed by Ryosuke Niwa.
+
+        This clean up allows to remove port specific bits of each
+        DRT implementation that supports testing Document::nodesFromRect,
+        in favor of making use of the 'Internals' interface to test it.
+
+        This makes its code conveniently more expansible and cleaner.
+
+        Also removed stubs from Win and EFL DRTs.
+
+        * DumpRenderTree/LayoutTestController.cpp:
+        (LayoutTestController::staticFunctions):
+        * DumpRenderTree/LayoutTestController.h:
+        (LayoutTestController):
+        * DumpRenderTree/efl/LayoutTestControllerEfl.cpp:
+        * DumpRenderTree/gtk/LayoutTestControllerGtk.cpp:
+        * DumpRenderTree/mac/LayoutTestControllerMac.mm:
+        * DumpRenderTree/qt/LayoutTestControllerQt.cpp:
+        * DumpRenderTree/qt/LayoutTestControllerQt.h:
+        (LayoutTestController):
+        * DumpRenderTree/win/LayoutTestControllerWin.cpp:
+
 2012-03-13  Ojan Vafai  <[email protected]>
 
         Rebaselining for a new port doesn't work right with multiple fallback ports

Modified: trunk/Tools/DumpRenderTree/LayoutTestController.cpp (110593 => 110594)


--- trunk/Tools/DumpRenderTree/LayoutTestController.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/LayoutTestController.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -747,24 +747,6 @@
     return controller->computedStyleIncludingVisitedInfo(context, arguments[0]);
 }
 
-static JSValueRef nodesFromRectCallback(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argumentCount, const JSValueRef arguments[], JSValueRef* exception)
-{
-    if (argumentCount != 8)
-        return JSValueMakeUndefined(context);
-
-    int x = JSValueToNumber(context, arguments[1], NULL);
-    int y = JSValueToNumber(context, arguments[2], NULL);
-    int top = static_cast<unsigned>(JSValueToNumber(context, arguments[3], NULL));
-    int right = static_cast<unsigned>(JSValueToNumber(context, arguments[4], NULL));
-    int bottom = static_cast<unsigned>(JSValueToNumber(context, arguments[5], NULL));
-    int left = static_cast<unsigned>(JSValueToNumber(context, arguments[6], NULL));
-    bool ignoreClipping = JSValueToBoolean(context, arguments[7]);
-
-    // Has mac implementation.
-    LayoutTestController* controller = static_cast<LayoutTestController*>(JSObjectGetPrivate(thisObject));
-    return controller->nodesFromRect(context, arguments[0], x, y, top, right, bottom, left, ignoreClipping);
-}
-
 static JSValueRef layerTreeAsTextCallback(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argumentCount, const JSValueRef arguments[], JSValueRef* exception)
 {
     // Has mac & windows implementation
@@ -2353,7 +2335,6 @@
         { "clearPersistentUserStyleSheet", clearPersistentUserStyleSheetCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "closeWebInspector", closeWebInspectorCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "computedStyleIncludingVisitedInfo", computedStyleIncludingVisitedInfoCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
-        { "nodesFromRect", nodesFromRectCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "decodeHostName", decodeHostNameCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "disableImageLoading", disableImageLoadingCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },
         { "disallowIncreaseForApplicationCacheQuota", disallowIncreaseForApplicationCacheQuotaCallback, kJSPropertyAttributeReadOnly | kJSPropertyAttributeDontDelete },

Modified: trunk/Tools/DumpRenderTree/LayoutTestController.h (110593 => 110594)


--- trunk/Tools/DumpRenderTree/LayoutTestController.h	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/LayoutTestController.h	2012-03-13 20:05:01 UTC (rev 110594)
@@ -69,7 +69,6 @@
     bool isCommandEnabled(JSStringRef name);
     void keepWebHistory();
     JSValueRef computedStyleIncludingVisitedInfo(JSContextRef, JSValueRef);
-    JSValueRef nodesFromRect(JSContextRef, JSValueRef, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping);
     void notifyDone();
     int numberOfPages(float pageWidthInPixels, float pageHeightInPixels);
     int numberOfPendingGeolocationPermissionRequests();

Modified: trunk/Tools/DumpRenderTree/blackberry/LayoutTestControllerBlackBerry.cpp (110593 => 110594)


--- trunk/Tools/DumpRenderTree/blackberry/LayoutTestControllerBlackBerry.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/blackberry/LayoutTestControllerBlackBerry.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -723,12 +723,6 @@
     return mainFrame->editor()->selectionStartHasMarkerFor(WebCore::DocumentMarker::Spelling, from, length);
 }
 
-JSValueRef LayoutTestController::nodesFromRect(JSContextRef context, JSValueRef value, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping)
-{
-    notImplemented();
-    return JSValueMakeUndefined(context);
-}
-
 void LayoutTestController::setSerializeHTTPLoads(bool)
 {
     // FIXME: Implement if needed for https://bugs.webkit.org/show_bug.cgi?id=50758.

Modified: trunk/Tools/DumpRenderTree/efl/LayoutTestControllerEfl.cpp (110593 => 110594)


--- trunk/Tools/DumpRenderTree/efl/LayoutTestControllerEfl.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/efl/LayoutTestControllerEfl.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -109,12 +109,6 @@
     return JSValueMakeUndefined(context);
 }
 
-JSValueRef LayoutTestController::nodesFromRect(JSContextRef context, JSValueRef, int, int, unsigned, unsigned, unsigned, unsigned, bool)
-{
-    notImplemented();
-    return JSValueMakeUndefined(context);
-}
-
 JSRetainPtr<JSStringRef> LayoutTestController::layerTreeAsText() const
 {
     notImplemented();

Modified: trunk/Tools/DumpRenderTree/gtk/LayoutTestControllerGtk.cpp (110593 => 110594)


--- trunk/Tools/DumpRenderTree/gtk/LayoutTestControllerGtk.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/gtk/LayoutTestControllerGtk.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -124,11 +124,6 @@
     return JSValueMakeUndefined(context);
 }
 
-JSValueRef LayoutTestController::nodesFromRect(JSContextRef context, JSValueRef value, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping)
-{
-    return DumpRenderTreeSupportGtk::nodesFromRect(context, value, x, y, top, right, bottom, left, ignoreClipping);
-}
-
 JSRetainPtr<JSStringRef> LayoutTestController::layerTreeAsText() const
 {
     // FIXME: implement

Modified: trunk/Tools/DumpRenderTree/mac/LayoutTestControllerMac.mm (110593 => 110594)


--- trunk/Tools/DumpRenderTree/mac/LayoutTestControllerMac.mm	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/mac/LayoutTestControllerMac.mm	2012-03-13 20:05:01 UTC (rev 110594)
@@ -276,11 +276,6 @@
     return [[mainFrame webView] _computedStyleIncludingVisitedInfo:context forElement:value];
 }
 
-JSValueRef LayoutTestController::nodesFromRect(JSContextRef context, JSValueRef value, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping)
-{
-    return [[mainFrame webView] _nodesFromRect:context forDocument:value x:x y:y top:top right:right bottom:bottom left:left ignoreClipping:ignoreClipping];
-}
-
 JSRetainPtr<JSStringRef> LayoutTestController::layerTreeAsText() const
 {
     JSRetainPtr<JSStringRef> string(Adopt, JSStringCreateWithCFString((CFStringRef)[mainFrame _layerTreeAsText]));

Modified: trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.cpp (110593 => 110594)


--- trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -949,11 +949,6 @@
     return false;
 }
 
-QVariantList LayoutTestController::nodesFromRect(const QWebElement& document, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping)
-{
-    return DumpRenderTreeSupportQt::nodesFromRect(document, x, y, top, right, bottom, left, ignoreClipping);
-}
-
 void LayoutTestController::addURLToRedirect(const QString& origin, const QString& destination)
 {
     DumpRenderTreeSupportQt::addURLToRedirect(origin, destination);

Modified: trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.h (110593 => 110594)


--- trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.h	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/qt/LayoutTestControllerQt.h	2012-03-13 20:05:01 UTC (rev 110594)
@@ -243,8 +243,6 @@
     void abortModal() {}
     bool hasSpellingMarker(int from, int length);
 
-    QVariantList nodesFromRect(const QWebElement& document, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping);
-
     void addURLToRedirect(const QString& origin, const QString& destination);
 
     /*

Modified: trunk/Tools/DumpRenderTree/win/LayoutTestControllerWin.cpp (110593 => 110594)


--- trunk/Tools/DumpRenderTree/win/LayoutTestControllerWin.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/win/LayoutTestControllerWin.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -179,12 +179,6 @@
     return JSValueMakeUndefined(context);
 }
 
-JSValueRef LayoutTestController::nodesFromRect(JSContextRef context, JSValueRef value, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping)
-{
-    // FIXME: Implement this.
-    return JSValueMakeUndefined(context);
-}
-
 JSRetainPtr<JSStringRef> LayoutTestController::layerTreeAsText() const
 {
     COMPtr<IWebFramePrivate> framePrivate(Query, frame);

Modified: trunk/Tools/DumpRenderTree/wx/LayoutTestControllerWx.cpp (110593 => 110594)


--- trunk/Tools/DumpRenderTree/wx/LayoutTestControllerWx.cpp	2012-03-13 19:48:20 UTC (rev 110593)
+++ trunk/Tools/DumpRenderTree/wx/LayoutTestControllerWx.cpp	2012-03-13 20:05:01 UTC (rev 110594)
@@ -537,12 +537,6 @@
     return 0;
 }
 
-JSValueRef LayoutTestController::nodesFromRect(JSContextRef context, JSValueRef value, int x, int y, unsigned top, unsigned right, unsigned bottom, unsigned left, bool ignoreClipping)
-{
-    // FIXME: Implement this.
-    return 0;
-}
-
 void LayoutTestController::authenticateSession(JSStringRef, JSStringRef, JSStringRef)
 {
 }
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo.cgi/webkit-changes

Reply via email to