Source/WebCore/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 The existing API was overloaded and could be simplified by passing all the bool arguments in
 9 a HitTestRequest argument. This should also help clarify the call as the enum values explicitely
 10 state what they do.
 11
 12 * WebCore.exp.in:
 13 * WebCore.order:
 14 * dom/Document.cpp:
 15 (WebCore::Document::nodesFromRect):
 16 * dom/Document.h:
 17 (Document):
 18 * page/ContextMenuController.cpp:
 19 (WebCore::ContextMenuController::createContextMenu):
 20 * page/DragController.cpp:
 21 (WebCore::DragController::canProcessDrag):
 22 (WebCore::DragController::startDrag):
 23 * page/EventHandler.cpp:
 24 (WebCore::EventHandler::hitTestResultAtPoint):
 25 (WebCore::EventHandler::handleMousePressEvent):
 26 (WebCore::EventHandler::handleGestureEvent):
 27 (WebCore::EventHandler::handleGestureForTextSelectionOrContextMenu):
 28 (WebCore::EventHandler::bestClickableNodeForTouchPoint):
 29 (WebCore::EventHandler::bestContextMenuNodeForTouchPoint):
 30 (WebCore::EventHandler::bestZoomableAreaForTouchPoint):
 31 (WebCore::EventHandler::handleTouchEvent):
 32 * page/EventHandler.h:
 33 (WebCore):
 34 (EventHandler):
 35 * page/FocusController.cpp:
 36 (WebCore::updateFocusCandidateIfNeeded):
 37 * page/Frame.cpp:
 38 (WebCore::Frame::visiblePositionForPoint):
 39 (WebCore::Frame::documentAtPoint):
 40 * page/TouchDisambiguation.cpp:
 41 (WebCore::findGoodTouchTargets):
 42 * rendering/HitTestRequest.h:
 43 (WebCore::HitTestRequest::allowsFrameScrollbars):
 44 * testing/Internals.cpp:
 45 (WebCore::Internals::nodesFromRect):
 46
1472013-02-13 Andrew Wilson <atwilson@chromium.org>
248
349 Unreviewed Chromium gyp-file cleanup after glib backend removal.

Source/WebKit/blackberry/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update calls to new API.
 9
 10 * Api/WebPage.cpp:
 11 (BlackBerry::WebKit::WebPagePrivate::contextNode):
 12 (BlackBerry::WebKit::WebPagePrivate::nodeForZoomUnderPoint):
 13 (BlackBerry::WebKit::WebPagePrivate::handleMouseEvent):
 14 (BlackBerry::WebKit::WebPage::nodeAtDocumentPoint):
 15 (BlackBerry::WebKit::WebPagePrivate::hitTestResult):
 16 * WebKitSupport/SelectionHandler.cpp:
 17 (BlackBerry::WebKit::visiblePositionForPointIgnoringClipping):
 18
1192013-02-12 Jakob Petsovits <jpetsovits@rim.com>
220
321 [BlackBerry] Assume setScrollingOrZooming() to be called on the WebKit thread.

Source/WebKit/chromium/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update calls to new API.
 9
 10 * src/ContextMenuClientImpl.cpp:
 11 (WebKit::selectMisspelledWord):
 12 * src/FrameLoaderClientImpl.cpp:
 13 (WebKit::FrameLoaderClientImpl::dispatchDecidePolicyForNavigationAction):
 14 * src/WebFrameImpl.cpp:
 15 (WebKit::WebFrameImpl::characterIndexForPoint):
 16 * src/WebPluginContainerImpl.cpp:
 17 (WebKit::WebPluginContainerImpl::isRectTopmost):
 18 * src/WebViewImpl.cpp:
 19 (WebKit::WebViewImpl::handleMouseDown):
 20 (WebKit::WebViewImpl::computeBlockBounds):
 21 (WebKit::WebViewImpl::bestTouchLinkNode):
 22
1232013-02-12 Yoshifumi Inoue <yosin@chromium.org>
224
325 Unreviewed. Build fix for Chromium-Win.

Source/WebKit/efl/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update calls to new API.
 9
 10 * ewk/ewk_frame.cpp:
 11 (ewk_frame_hit_test_new):
 12
1132013-02-12 Huang Dongsung <luxtella@company100.net>
214
315 [TexMap] Apply frames-per-second debug counter to WK1.

Source/WebKit/mac/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update calls to new API.
 9
 10 * WebCoreSupport/WebFrameLoaderClient.mm:
 11 (WebFrameLoaderClient::actionDictionary):
 12 * WebView/WebHTMLView.mm:
 13 (-[WebHTMLView elementAtPoint:allowShadowContent:]):
 14
1152013-02-12 Joseph Pecoraro <pecoraro@apple.com>
216
317 [iOS] Enable PAGE_VISIBILITY_API

Source/WebKit/qt/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update calls to new API.
 9
 10 * WebCoreSupport/FrameLoaderClientQt.cpp:
 11 (WebCore::FrameLoaderClientQt::dispatchDecidePolicyForNavigationAction):
 12 * WebCoreSupport/QWebFrameAdapter.cpp:
 13 (QWebFrameAdapter::hitTestContent):
 14 * WebCoreSupport/QWebPageAdapter.cpp:
 15 (QWebPageAdapter::TouchAdjuster::findCandidatePointForTouch):
 16 (QWebPageAdapter::handleSoftwareInputPanel):
 17 (QWebPageAdapter::updatePositionDependentMenuActions):
 18
1192013-02-12 Huang Dongsung <luxtella@company100.net>
220
321 [TexMap] Apply frames-per-second debug counter to WK1.

Source/WebKit/win/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update calls to new API.
 9
 10 * WebActionPropertyBag.cpp:
 11 (WebActionPropertyBag::Read):
 12 * WebKit.vcproj/WebKitExports.def.in:
 13 * WebView.cpp:
 14 (WebView::handleContextMenuEvent):
 15 (WebView::elementAtPoint):
 16
1172013-02-11 Ryosuke Niwa <rniwa@webkit.org>
218
319 Disable delete button controller on non-Mac ports and delete EditorClient::shouldShowDeleteInterface

Source/WebKit/wx/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update calls to new API.
 9
 10 * WebFrame.cpp:
 11 (WebKit::WebFrame::HitTest):
 12
1132013-02-11 Ryosuke Niwa <rniwa@webkit.org>
214
315 Disable delete button controller on non-Mac ports and delete EditorClient::shouldShowDeleteInterface

Source/WebKit2/ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update calls to new API and update exported symbols.
 9
 10 * WebProcess/InjectedBundle/InjectedBundleNavigationAction.cpp:
 11 (WebKit::InjectedBundleNavigationAction::InjectedBundleNavigationAction):
 12 * WebProcess/WebPage/WebFrame.cpp:
 13 (WebKit::WebFrame::hitTest):
 14 * WebProcess/WebPage/WebPage.cpp:
 15 (WebKit::handleContextMenuEvent):
 16 (WebKit::WebPage::highlightPotentialActivation):
 17 (WebKit::WebPage::findZoomableAreaForPoint):
 18 * WebProcess/WebPage/mac/WebPageMac.mm:
 19 (WebKit::WebPage::characterIndexForPoint):
 20 (WebKit::WebPage::performDictionaryLookupAtLocation):
 21 (WebKit::WebPage::shouldDelayWindowOrderingEvent):
 22 (WebKit::WebPage::acceptsFirstMouse):
 23
1242013-02-12 Adenilson Cavalcanti <cavalcantii@gmail.com>
225
326 [WK2] Page reloading will crash UIProcess after WebProcess was killed

Source/WebCore/WebCore.exp.in

@@__ZN7WebCore12EventHandler14scrollOverflowENS_15ScrollDirectionENS_17ScrollGranu
175175__ZN7WebCore12EventHandler15handleAccessKeyERKNS_21PlatformKeyboardEventE
176176__ZN7WebCore12EventHandler16handleWheelEventERKNS_18PlatformWheelEventE
177177__ZN7WebCore12EventHandler17scrollRecursivelyENS_15ScrollDirectionENS_17ScrollGranularityEPNS_4NodeE
178 __ZN7WebCore12EventHandler20hitTestResultAtPointERKNS_11LayoutPointEbbNS_17HitTestScrollbarsEjRKNS_10LayoutSizeE
 178__ZN7WebCore12EventHandler20hitTestResultAtPointERKNS_11LayoutPointEjRKNS_10LayoutSizeE
179179__ZN7WebCore12EventHandler21handleMousePressEventERKNS_18PlatformMouseEventE
180180__ZN7WebCore12EventHandler23handleMouseReleaseEventERKNS_18PlatformMouseEventE
181181__ZN7WebCore12EventHandler24logicalScrollRecursivelyENS_22ScrollLogicalDirectionENS_17ScrollGranularityEPNS_4NodeE

@@__ZNK7WebCore7IntRectcv6CGRectEv
14801480__ZNK7WebCore7RunLoop9TimerBase8isActiveEv
14811481__ZNK7WebCore8Document11completeURLERKN3WTF6StringE
14821482__ZNK7WebCore8Document13axObjectCacheEv
1483 __ZNK7WebCore8Document13nodesFromRectEiijjjjbb
 1483__ZNK7WebCore8Document13nodesFromRectEiijjjjj
14841484__ZNK7WebCore8Document14getElementByIdERKN3WTF12AtomicStringE
14851485__ZNK7WebCore8Document31displayStringModifiedByEncodingERKN3WTF6StringE
14861486__ZNK7WebCore8Document4bodyEv

Source/WebCore/WebCore.order

@@__ZNK7WebCore12NodeIterator20updateForNodeRemovalEPNS_4NodeERNS0_11NodePointerE
2274822748__ZN7WebCore27jsNodeIteratorReferenceNodeEPN3JSC9ExecStateENS0_7JSValueERKNS0_10IdentifierE
2274922749__ZNK7WebCore4Node20traversePreviousNodeEPKS0_
2275022750__ZN7WebCore37jsNodeIteratorPrototypeFunctionDetachEPN3JSC9ExecStateE
22751 __ZNK7WebCore8Document13nodesFromRectEiijjjjb
 22751__ZNK7WebCore8Document13nodesFromRectEiijjjjj
2275222752__ZNK7WebCore8Document17handleZeroPaddingERKNS_14HitTestRequestERNS_13HitTestResultE
2275322753__ZN3WTF21ListHashSetTranslatorINS_6RefPtrIN7WebCore4NodeEEELm256ENS_7PtrHashIS4_EEE9translateERPNS_15ListHashSetNodeIS4_Lm256EEERKS4_PNS_24ListHashSetNodeAllocatorIS4_Lm256EEE
2275422754__ZN7WebCore21StaticHashSetNodeListC1ERN3WTF11ListHashSetINS1_6RefPtrINS_4NodeEEELm256ENS1_7PtrHashIS5_EEEE

Source/WebCore/dom/Document.cpp

@@String Document::suggestedMIMEType() const
13511351// * making it receive a rect as parameter, i.e. nodesFromRect(x, y, w, h);
13521352// * making it receive the expading size of each direction separately,
13531353// i.e. nodesFromRect(x, y, topSize, rightSize, bottomSize, leftSize);
1354 PassRefPtr<NodeList> Document::nodesFromRect(int centerX, int centerY, unsigned topPadding, unsigned rightPadding, unsigned bottomPadding, unsigned leftPadding, bool ignoreClipping, bool allowShadowContent) const
 1354PassRefPtr<NodeList> Document::nodesFromRect(int centerX, int centerY, unsigned topPadding, unsigned rightPadding, unsigned bottomPadding, unsigned leftPadding, HitTestRequest::HitTestRequestType hitType) const
13551355{
13561356 // FIXME: Share code between this, elementFromPoint and caretRangeFromPoint.
13571357 if (!renderer())

@@PassRefPtr<NodeList> Document::nodesFromRect(int centerX, int centerY, unsigned
13661366 float zoomFactor = frame->pageZoomFactor();
13671367 LayoutPoint point = roundedLayoutPoint(FloatPoint(centerX * zoomFactor + view()->scrollX(), centerY * zoomFactor + view()->scrollY()));
13681368
1369  int type = HitTestRequest::ReadOnly | HitTestRequest::Active;
 1369 HitTestRequest request(hitType);
13701370
13711371 // When ignoreClipping is false, this method returns null for coordinates outside of the viewport.
1372  if (ignoreClipping)
1373  type |= HitTestRequest::IgnoreClipping;
1374  else if (!frameView->visibleContentRect().intersects(HitTestLocation::rectForPoint(point, topPadding, rightPadding, bottomPadding, leftPadding)))
 1372 if (!request.ignoreClipping() && !frameView->visibleContentRect().intersects(HitTestLocation::rectForPoint(point, topPadding, rightPadding, bottomPadding, leftPadding)))
13751373 return 0;
1376  if (allowShadowContent)
1377  type |= HitTestRequest::AllowShadowContent;
1378 
1379  HitTestRequest request(type);
13801374
13811375 // Passing a zero padding will trigger a rect hit test, however for the purposes of nodesFromRect,
13821376 // we special handle this case in order to return a valid NodeList.

Source/WebCore/dom/Document.h

3535#include "DocumentEventQueue.h"
3636#include "DocumentTiming.h"
3737#include "FocusDirection.h"
 38#include "HitTestRequest.h"
3839#include "IconURL.h"
3940#include "InspectorCounters.h"
4041#include "IntRect.h"

@@public:
380381 * @param rightPadding How much to expand the right of the rectangle
381382 * @param bottomPadding How much to expand the bottom of the rectangle
382383 * @param leftPadding How much to expand the left of the rectangle
383  * @param ignoreClipping whether or not to ignore the root scroll frame when retrieving the element.
384  * If false, this method returns null for coordinates outside of the viewport.
385384 */
386  PassRefPtr<NodeList> nodesFromRect(int centerX, int centerY, unsigned topPadding, unsigned rightPadding,
387  unsigned bottomPadding, unsigned leftPadding, bool ignoreClipping, bool allowShadowContent) const;
 385 PassRefPtr<NodeList> nodesFromRect(int centerX, int centerY,
 386 unsigned topPadding, unsigned rightPadding, unsigned bottomPadding, unsigned leftPadding,
 387 HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active) const;
388388 Element* elementFromPoint(int x, int y) const;
389389 PassRefPtr<Range> caretRangeFromPoint(int x, int y);
390390

Source/WebCore/page/ContextMenuController.cpp

@@PassOwnPtr<ContextMenu> ContextMenuController::createContextMenu(Event* event)
152152 HitTestResult result(mouseEvent->absoluteLocation());
153153
154154 if (Frame* frame = event->target()->toNode()->document()->frame())
155  result = frame->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation(), false);
 155 result = frame->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation());
156156
157157 if (!result.innerNonSharedNode())
158158 return nullptr;

Source/WebCore/page/DragController.cpp

@@bool DragController::canProcessDrag(DragData* dragData)
560560 if (!m_page->mainFrame()->contentRenderer())
561561 return false;
562562
563  result = m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(point, true);
 563 result = m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(point, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent);
564564
565565 if (!result.innerNonSharedNode())
566566 return false;

@@bool DragController::startDrag(Frame* src, const DragState& state, DragOperation
744744 if (!src->view() || !src->contentRenderer())
745745 return false;
746746
747  HitTestResult hitTestResult = src->eventHandler()->hitTestResultAtPoint(dragOrigin, true);
 747 HitTestResult hitTestResult = src->eventHandler()->hitTestResultAtPoint(dragOrigin, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent);
748748 if (!state.m_dragSrc->contains(hitTestResult.innerNode()))
749749 // The original node being dragged isn't under the drag origin anymore... maybe it was
750750 // hidden or moved out from under the cursor. Regardless, we don't want to start a drag on

Source/WebCore/page/EventHandler.cpp

@@DragSourceAction EventHandler::updateDragSourceActionsAllowed() const
10011001}
10021002#endif // ENABLE(DRAG_SUPPORT)
10031003
1004 HitTestResult EventHandler::hitTestResultAtPoint(const LayoutPoint& point, bool allowShadowContent, bool ignoreClipping, HitTestScrollbars testScrollbars, HitTestRequest::HitTestRequestType hitType, const LayoutSize& padding)
 1004HitTestResult EventHandler::hitTestResultAtPoint(const LayoutPoint& point, HitTestRequest::HitTestRequestType hitType, const LayoutSize& padding)
10051005{
10061006 // We always send hitTestResultAtPoint to the main frame if we have one,
10071007 // otherwise we might hit areas that are obscured by higher frames.

@@HitTestResult EventHandler::hitTestResultAtPoint(const LayoutPoint& point, bool
10121012 FrameView* mainView = mainFrame->view();
10131013 if (frameView && mainView) {
10141014 IntPoint mainFramePoint = mainView->rootViewToContents(frameView->contentsToRootView(roundedIntPoint(point)));
1015  return mainFrame->eventHandler()->hitTestResultAtPoint(mainFramePoint, allowShadowContent, ignoreClipping, testScrollbars, hitType, padding);
 1015 return mainFrame->eventHandler()->hitTestResultAtPoint(mainFramePoint, hitType, padding);
10161016 }
10171017 }
10181018 }

@@HitTestResult EventHandler::hitTestResultAtPoint(const LayoutPoint& point, bool
10211021
10221022 if (!m_frame->contentRenderer())
10231023 return result;
1024  if (ignoreClipping)
1025  hitType |= HitTestRequest::IgnoreClipping;
1026  if (allowShadowContent)
1027  hitType |= HitTestRequest::AllowShadowContent;
 1024
10281025 HitTestRequest request(hitType);
10291026 m_frame->contentRenderer()->hitTest(request, result);
10301027

@@HitTestResult EventHandler::hitTestResultAtPoint(const LayoutPoint& point, bool
10471044 frame->contentRenderer()->hitTest(request, widgetHitTestResult);
10481045 result = widgetHitTestResult;
10491046
1050  if (testScrollbars == ShouldHitTestScrollbars) {
 1047 if (request.allowsFrameScrollbars()) {
10511048 Scrollbar* eventScrollbar = view->scrollbarAtPoint(roundedIntPoint(point));
10521049 if (eventScrollbar)
10531050 result.setScrollbar(eventScrollbar);
10541051 }
10551052 }
10561053
1057  if (!allowShadowContent)
 1054 if (!request.allowsShadowContent())
10581055 result.setToNonShadowAncestor();
10591056
10601057 return result;

@@bool EventHandler::handleMousePressEvent(const PlatformMouseEvent& mouseEvent)
14521449 m_mouseDownWasInSubframe = false;
14531450
14541451 HitTestRequest request(HitTestRequest::Active);
1455  // Save the document point we generate in case the window coordinate is invalidated by what happens
 1452 // Save the document point we generate in case the window coordinate is invalidated by what happens
14561453 // when we dispatch the event.
14571454 LayoutPoint documentPoint = documentPointForWindowPoint(m_frame, mouseEvent.position());
14581455 MouseEventWithHitTestResults mev = m_frame->document()->prepareMouseEvent(request, documentPoint, mouseEvent);

@@bool EventHandler::handleGestureEvent(const PlatformGestureEvent& gestureEvent)
24562453
24572454 if ((!scrollbar && !eventTarget) || !(hitType & HitTestRequest::ReadOnly)) {
24582455 IntPoint hitTestPoint = m_frame->view()->windowToContents(adjustedPoint);
2459  HitTestResult result = hitTestResultAtPoint(hitTestPoint, false, false, ShouldHitTestScrollbars, hitType);
 2456 HitTestResult result = hitTestResultAtPoint(hitTestPoint, hitType | HitTestRequest::AllowFrameScrollbars);
24602457 eventTarget = result.targetNode();
24612458 if (!scrollbar) {
24622459 FrameView* view = m_frame->view();

@@bool EventHandler::handleGestureForTextSelectionOrContextMenu(const PlatformGest
25952592{
25962593#if OS(ANDROID)
25972594 IntPoint hitTestPoint = m_frame->view()->windowToContents(gestureEvent.position());
2598  HitTestResult result = hitTestResultAtPoint(hitTestPoint, true);
 2595 HitTestResult result = hitTestResultAtPoint(hitTestPoint, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent);
25992596 Node* innerNode = result.targetNode();
26002597 if (!result.isLiveLink() && innerNode && (innerNode->isContentEditable() || innerNode->isTextNode())) {
26012598 selectClosestWordFromHitTestResult(result, DontAppendTrailingWhitespace);

@@bool EventHandler::shouldApplyTouchAdjustment(const PlatformGestureEvent& event)
27372734
27382735bool EventHandler::bestClickableNodeForTouchPoint(const IntPoint& touchCenter, const IntSize& touchRadius, IntPoint& targetPoint, Node*& targetNode)
27392736{
2740  HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active;
27412737 IntPoint hitTestPoint = m_frame->view()->windowToContents(touchCenter);
2742  HitTestResult result = hitTestResultAtPoint(hitTestPoint, /*allowShadowContent*/ true, /*ignoreClipping*/ false, DontHitTestScrollbars, hitType, touchRadius);
 2738 HitTestResult result = hitTestResultAtPoint(hitTestPoint, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent, touchRadius);
27432739
27442740 IntRect touchRect(touchCenter - touchRadius, touchRadius + touchRadius);
27452741 RefPtr<StaticHashSetNodeList> nodeList = StaticHashSetNodeList::adopt(result.rectBasedTestResult());

@@bool EventHandler::bestClickableNodeForTouchPoint(const IntPoint& touchCenter, c
27562752
27572753bool EventHandler::bestContextMenuNodeForTouchPoint(const IntPoint& touchCenter, const IntSize& touchRadius, IntPoint& targetPoint, Node*& targetNode)
27582754{
2759  HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active;
27602755 IntPoint hitTestPoint = m_frame->view()->windowToContents(touchCenter);
2761  HitTestResult result = hitTestResultAtPoint(hitTestPoint, /*allowShadowContent*/ true, /*ignoreClipping*/ false, DontHitTestScrollbars, hitType, touchRadius);
 2756 HitTestResult result = hitTestResultAtPoint(hitTestPoint, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent, touchRadius);
27622757
27632758 IntRect touchRect(touchCenter - touchRadius, touchRadius + touchRadius);
27642759 RefPtr<StaticHashSetNodeList> nodeList = StaticHashSetNodeList::adopt(result.rectBasedTestResult());

@@bool EventHandler::bestContextMenuNodeForTouchPoint(const IntPoint& touchCenter,
27672762
27682763bool EventHandler::bestZoomableAreaForTouchPoint(const IntPoint& touchCenter, const IntSize& touchRadius, IntRect& targetArea, Node*& targetNode)
27692764{
2770  HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active;
27712765 IntPoint hitTestPoint = m_frame->view()->windowToContents(touchCenter);
2772  HitTestResult result = hitTestResultAtPoint(hitTestPoint, /*allowShadowContent*/ false, /*ignoreClipping*/ false, DontHitTestScrollbars, hitType, touchRadius);
 2766 HitTestResult result = hitTestResultAtPoint(hitTestPoint, HitTestRequest::ReadOnly | HitTestRequest::Active, touchRadius);
27732767
27742768 IntRect touchRect(touchCenter - touchRadius, touchRadius + touchRadius);
27752769 RefPtr<StaticHashSetNodeList> nodeList = StaticHashSetNodeList::adopt(result.rectBasedTestResult());

@@bool EventHandler::handleTouchEvent(const PlatformTouchEvent& event)
38623856 if (pointState == PlatformTouchPoint::TouchPressed) {
38633857 HitTestResult result;
38643858 if (freshTouchEvents) {
3865  result = hitTestResultAtPoint(pagePoint, /*allowShadowContent*/ true, false, DontHitTestScrollbars, hitType);
 3859 result = hitTestResultAtPoint(pagePoint, hitType | HitTestRequest::AllowShadowContent);
38663860 m_originatingTouchPointTargetKey = touchPointTargetKey;
38673861 } else if (m_originatingTouchPointDocument.get() && m_originatingTouchPointDocument->frame()) {
38683862 LayoutPoint pagePointInOriginatingDocument = documentPointForWindowPoint(m_originatingTouchPointDocument->frame(), point.pos());

@@bool EventHandler::handleTouchEvent(const PlatformTouchEvent& event)
38963890 } else if (pointState == PlatformTouchPoint::TouchReleased || pointState == PlatformTouchPoint::TouchCancelled) {
38973891 // We only perform a hittest on release or cancel to unset :active or :hover state.
38983892 if (touchPointTargetKey == m_originatingTouchPointTargetKey) {
3899  hitTestResultAtPoint(pagePoint, /*allowShadowContent*/ true, false, DontHitTestScrollbars, hitType);
 3893 hitTestResultAtPoint(pagePoint, hitType | HitTestRequest::AllowShadowContent);
39003894 m_originatingTouchPointTargetKey = 0;
39013895 } else if (m_originatingTouchPointDocument.get() && m_originatingTouchPointDocument->frame()) {
39023896 LayoutPoint pagePointInOriginatingDocument = documentPointForWindowPoint(m_originatingTouchPointDocument->frame(), point.pos());

Source/WebCore/page/EventHandler.h

@@extern const int TextDragHysteresis;
9191extern const int GeneralDragHysteresis;
9292#endif // ENABLE(DRAG_SUPPORT)
9393
94 enum HitTestScrollbars { ShouldHitTestScrollbars, DontHitTestScrollbars };
9594enum AppendTrailingWhitespace { ShouldAppendTrailingWhitespace, DontAppendTrailingWhitespace };
9695enum CheckDragHysteresis { ShouldCheckDragHysteresis, DontCheckDragHysteresis };
9796

@@public:
127126 void dispatchFakeMouseMoveEventSoon();
128127 void dispatchFakeMouseMoveEventSoonInQuad(const FloatQuad&);
129128
130  HitTestResult hitTestResultAtPoint(const LayoutPoint&, bool allowShadowContent, bool ignoreClipping = false,
131  HitTestScrollbars scrollbars = DontHitTestScrollbars,
 129 HitTestResult hitTestResultAtPoint(const LayoutPoint&,
132130 HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active,
133131 const LayoutSize& padding = LayoutSize());
134132

Source/WebCore/page/FocusController.cpp

@@static void updateFocusCandidateIfNeeded(FocusDirection direction, const FocusCa
717717 // If 2 nodes are intersecting, do hit test to find which node in on top.
718718 LayoutUnit x = intersectionRect.x() + intersectionRect.width() / 2;
719719 LayoutUnit y = intersectionRect.y() + intersectionRect.height() / 2;
720  HitTestResult result = candidate.visibleNode->document()->page()->mainFrame()->eventHandler()->hitTestResultAtPoint(IntPoint(x, y), false, true);
 720 HitTestResult result = candidate.visibleNode->document()->page()->mainFrame()->eventHandler()->hitTestResultAtPoint(IntPoint(x, y), HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::IgnoreClipping);
721721 if (candidate.visibleNode->contains(result.innerNode())) {
722722 closest = candidate;
723723 return;

Source/WebCore/page/Frame.cpp

@@String Frame::displayStringModifiedByEncoding(const String& str) const
721721
722722VisiblePosition Frame::visiblePositionForPoint(const IntPoint& framePoint)
723723{
724  HitTestResult result = eventHandler()->hitTestResultAtPoint(framePoint, true);
 724 HitTestResult result = eventHandler()->hitTestResultAtPoint(framePoint, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent);
725725 Node* node = result.innerNonSharedNode();
726726 if (!node)
727727 return VisiblePosition();

@@Document* Frame::documentAtPoint(const IntPoint& point)
743743 HitTestResult result = HitTestResult(pt);
744744
745745 if (contentRenderer())
746  result = eventHandler()->hitTestResultAtPoint(pt, false);
 746 result = eventHandler()->hitTestResultAtPoint(pt);
747747 return result.innerNode() ? result.innerNode()->document() : 0;
748748}
749749

Source/WebCore/page/TouchDisambiguation.cpp

@@void findGoodTouchTargets(const IntRect& touchBox, Frame* mainFrame, Vector<IntR
9898 IntPoint touchPoint = touchBox.center();
9999 IntPoint contentsPoint = mainFrame->view()->windowToContents(touchPoint);
100100
101  HitTestResult result = mainFrame->eventHandler()->hitTestResultAtPoint(contentsPoint, false, false, DontHitTestScrollbars, HitTestRequest::Active | HitTestRequest::ReadOnly, IntSize(padding, padding));
 101 HitTestResult result = mainFrame->eventHandler()->hitTestResultAtPoint(contentsPoint, HitTestRequest::ReadOnly | HitTestRequest::Active, IntSize(padding, padding));
102102 const ListHashSet<RefPtr<Node> >& hitResults = result.rectBasedTestResult();
103103
104104 // Blacklist nodes that are container of disambiguated nodes.

Source/WebCore/rendering/HitTestRequest.h

@@public:
3535 IgnoreClipping = 1 << 5,
3636 SVGClipContent = 1 << 6,
3737 TouchEvent = 1 << 7,
38  AllowShadowContent = 1 << 8
 38 AllowShadowContent = 1 << 8,
 39 AllowFrameScrollbars = 1 << 9
3940 };
4041
4142 typedef unsigned HitTestRequestType;

@@public:
5455 bool touchEvent() const { return m_requestType & TouchEvent; }
5556 bool mouseEvent() const { return !touchEvent(); }
5657 bool allowsShadowContent() const { return m_requestType & AllowShadowContent; }
 58 bool allowsFrameScrollbars() const { return m_requestType & AllowFrameScrollbars; }
5759
5860 // Convenience functions
5961 bool touchMove() const { return move() && touchEvent(); }

Source/WebCore/testing/Internals.cpp

@@PassRefPtr<NodeList> Internals::nodesFromRect(Document* document, int x, int y,
13851385 return 0;
13861386 }
13871387
1388  return document->nodesFromRect(x, y, topPadding, rightPadding, bottomPadding, leftPadding, ignoreClipping, allowShadowContent);
 1388 HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active;
 1389 if (ignoreClipping)
 1390 hitType |= HitTestRequest::IgnoreClipping;
 1391 if (allowShadowContent)
 1392 hitType |= HitTestRequest::AllowShadowContent;
 1393
 1394 return document->nodesFromRect(x, y, topPadding, rightPadding, bottomPadding, leftPadding, hitType);
13891395}
13901396
13911397void Internals::emitInspectorDidBeginFrame()

Source/WebKit/blackberry/Api/WebPage.cpp

@@PassRefPtr<Node> WebPagePrivate::contextNode(TargetDetectionStrategy strategy)
27012701 else
27022702 contentPos = mapFromViewportToContents(m_lastMouseEvent.position());
27032703
2704  HitTestResult result = eventHandler->hitTestResultAtPoint(contentPos, false /*allowShadowContent*/);
 2704 HitTestResult result = eventHandler->hitTestResultAtPoint(contentPos);
27052705 return result.innerNode();
27062706}
27072707

@@Node* WebPagePrivate::nodeForZoomUnderPoint(const IntPoint& documentPoint)
27722772 if (!m_mainFrame)
27732773 return 0;
27742774
2775  HitTestResult result = m_mainFrame->eventHandler()->hitTestResultAtPoint(documentPoint, false);
 2775 HitTestResult result = m_mainFrame->eventHandler()->hitTestResultAtPoint(documentPoint);
27762776
27772777 Node* node = result.innerNonSharedNode();
27782778

@@bool WebPagePrivate::handleMouseEvent(PlatformMouseEvent& mouseEvent)
40094009 }
40104010
40114011 if (!node) {
4012  HitTestResult result = eventHandler->hitTestResultAtPoint(mapFromViewportToContents(mouseEvent.position()), false /*allowShadowContent*/);
 4012 HitTestResult result = eventHandler->hitTestResultAtPoint(mapFromViewportToContents(mouseEvent.position()));
40134013 node = result.innerNode();
40144014 }
40154015

@@WebDOMDocument WebPage::document() const
49854985
49864986WebDOMNode WebPage::nodeAtDocumentPoint(const Platform::IntPoint& documentPoint)
49874987{
4988  HitTestResult result = d->m_mainFrame->eventHandler()->hitTestResultAtPoint(WebCore::IntPoint(documentPoint), false);
 4988 HitTestResult result = d->m_mainFrame->eventHandler()->hitTestResultAtPoint(WebCore::IntPoint(documentPoint));
49894989 Node* node = result.innerNonSharedNode();
49904990 return WebDOMNode(node);
49914991}

@@const HitTestResult& WebPagePrivate::hitTestResult(const IntPoint& contentPos)
62436243{
62446244 if (m_cachedHitTestContentPos != contentPos) {
62456245 m_cachedHitTestContentPos = contentPos;
6246  m_cachedHitTestResult = m_mainFrame->eventHandler()->hitTestResultAtPoint(m_cachedHitTestContentPos, true /*allowShadowContent*/);
 6246 m_cachedHitTestResult = m_mainFrame->eventHandler()->hitTestResultAtPoint(m_cachedHitTestContentPos, HitTestResult::ReadOnly | HitTestResult::Active | HitTestResult::AllowShadowContent);
62476247 }
62486248
62496249 return m_cachedHitTestResult;

Source/WebKit/blackberry/WebKitSupport/SelectionHandler.cpp

@@static VisiblePosition visiblePositionForPointIgnoringClipping(const Frame& fram
167167 // outside the visible rect. To work around the bug, this is a copy of
168168 // visiblePositionAtPoint which which passes ignoreClipping=true.
169169 // See RIM Bug #4315.
170  HitTestResult result = frame.eventHandler()->hitTestResultAtPoint(framePoint, true /* allowShadowContent */, true /* ignoreClipping */);
 170 HitTestResult result = frame.eventHandler()->hitTestResultAtPoint(framePoint, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent | HitTestRequest::IgnoreClipping);
171171
172172 Node* node = result.innerNode();
173173 if (!node || node->document() != frame.document())

Source/WebKit/chromium/src/ContextMenuClientImpl.cpp

@@static String selectMisspelledWord(const ContextMenu* defaultMenu, Frame* select
121121
122122 // Selection is empty, so change the selection to the word under the cursor.
123123 HitTestResult hitTestResult = selectedFrame->eventHandler()->
124  hitTestResultAtPoint(selectedFrame->page()->contextMenuController()->hitTestResult().pointInInnerNodeFrame(), true);
 124 hitTestResultAtPoint(selectedFrame->page()->contextMenuController()->hitTestResult().pointInInnerNodeFrame(), HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent);
125125 Node* innerNode = hitTestResult.innerNode();
126126 VisiblePosition pos(innerNode->renderer()->positionForPoint(
127127 hitTestResult.localPoint()));

Source/WebKit/chromium/src/FrameLoaderClientImpl.cpp

@@void FrameLoaderClientImpl::dispatchDecidePolicyForNavigationAction(
10081008 if (event->isMouseEvent()) {
10091009 const MouseEvent* mouseEvent =
10101010 static_cast<const MouseEvent*>(event);
1011  node = m_webFrame->frame()->eventHandler()->hitTestResultAtPoint(
1012  mouseEvent->absoluteLocation(), false).innerNonSharedNode();
 1011 node = m_webFrame->frame()->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation()).innerNonSharedNode();
10131012 break;
10141013 }
10151014 }

Source/WebKit/chromium/src/WebFrameImpl.cpp

@@size_t WebFrameImpl::characterIndexForPoint(const WebPoint& webPoint) const
11811181 return notFound;
11821182
11831183 IntPoint point = frame()->view()->windowToContents(webPoint);
1184  HitTestResult result = frame()->eventHandler()->hitTestResultAtPoint(point, false);
 1184 HitTestResult result = frame()->eventHandler()->hitTestResultAtPoint(point);
11851185 RefPtr<Range> range = frame()->rangeForPoint(result.roundedPointInInnerNodeFrame());
11861186 if (!range)
11871187 return notFound;

Source/WebKit/chromium/src/WebPluginContainerImpl.cpp

@@bool WebPluginContainerImpl::isRectTopmost(const WebRect& rect)
462462 LayoutPoint center = documentRect.center();
463463 // Make the rect we're checking (the point surrounded by padding rects) contained inside the requested rect. (Note that -1/2 is 0.)
464464 LayoutSize padding((documentRect.width() - 1) / 2, (documentRect.height() - 1) / 2);
465  HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(center, false, false, DontHitTestScrollbars, HitTestRequest::ReadOnly | HitTestRequest::Active, padding);
 465 HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(center, HitTestRequest::ReadOnly | HitTestRequest::Active, padding);
466466 const HitTestResult::NodeSet& nodes = result.rectBasedTestResult();
467467 if (nodes.size() != 1)
468468 return false;

Source/WebKit/chromium/src/WebViewImpl.cpp

@@void WebViewImpl::handleMouseDown(Frame& mainFrame, const WebMouseEvent& event)
569569 if (event.button == WebMouseEvent::ButtonLeft) {
570570 IntPoint point(event.x, event.y);
571571 point = m_page->mainFrame()->view()->windowToContents(point);
572  HitTestResult result(m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(point, false));
 572 HitTestResult result(m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(point));
573573 Node* hitNode = result.innerNonSharedNode();
574574
575575 // Take capture on a mouse down on a plugin so we can send it mouse events.

@@WebRect WebViewImpl::computeBlockBounds(const WebRect& rect, AutoZoomType zoomTy
10911091
10921092 // Use the rect-based hit test to find the node.
10931093 IntPoint point = mainFrameImpl()->frameView()->windowToContents(IntPoint(rect.x, rect.y));
1094  HitTestResult result = mainFrameImpl()->frame()->eventHandler()->hitTestResultAtPoint(point,
1095  false, zoomType == FindInPage, DontHitTestScrollbars, HitTestRequest::Active | HitTestRequest::ReadOnly,
1096  IntSize(rect.width, rect.height));
 1094 HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active | ((zoomType == FindInPage) ? HitTestRequest::IgnoreClipping : 0);
 1095 HitTestResult result = mainFrameImpl()->frame()->eventHandler()->hitTestResultAtPoint(point, hitType, IntSize(rect.width, rect.height));
10971096
10981097 Node* node = result.innerNonSharedNode();
10991098 if (!node)

@@Node* WebViewImpl::bestTouchLinkNode(const WebGestureEvent& touchEvent)
12851284#endif
12861285
12871286 IntPoint hitTestPoint = m_page->mainFrame()->view()->windowToContents(touchEventLocation);
1288  HitTestResult result = m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(
1289  hitTestPoint, false, false, DontHitTestScrollbars, HitTestRequest::TouchEvent);
 1287 HitTestResult result = m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(hitTestPoint, HitTestRequest::TouchEvent);
12901288 bestTouchNode = result.targetNode();
12911289
12921290 // Make sure our highlight candidate uses a hand cursor as a heuristic to

@@Node* WebViewImpl::focusedWebCoreNode()
39373935HitTestResult WebViewImpl::hitTestResultForWindowPos(const IntPoint& pos)
39383936{
39393937 IntPoint docPoint(m_page->mainFrame()->view()->windowToContents(pos));
3940  return m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(docPoint, false);
 3938 return m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(docPoint);
39413939}
39423940
39433941void WebViewImpl::setTabsToLinks(bool enable)

Source/WebKit/efl/ewk/ewk_frame.cpp

3737#include "HTMLNames.h"
3838#include "HTMLPlugInElement.h"
3939#include "HistoryItem.h"
 40#include "HitTestRequest.h"
4041#include "HitTestResult.h"
4142#include "IntSize.h"
4243#include "KURL.h"

@@Ewk_Hit_Test* ewk_frame_hit_test_new(const Evas_Object* ewkFrame, int x, int y)
691692 EINA_SAFETY_ON_NULL_RETURN_VAL(smartData->frame->contentRenderer(), 0);
692693
693694 WebCore::HitTestResult result = smartData->frame->eventHandler()->hitTestResultAtPoint
694  (view->windowToContents(WebCore::IntPoint(x, y)),
695  /*allowShadowContent*/ false, /*ignoreClipping*/ true);
 695 (view->windowToContents(WebCore::IntPoint(x, y)),
 696 WebCore::HitTestRequest::ReadOnly | WebCore::HitTestRequest::Active | WebCore::HitTestRequest::IgnoreClipping);
696697
697698 if (result.scrollbar())
698699 return 0;

Source/WebKit/mac/WebCoreSupport/WebFrameLoaderClient.mm

@@NSDictionary *WebFrameLoaderClient::actionDictionary(const NavigationAction& act
13441344
13451345 if (const MouseEvent* mouseEvent = findMouseEvent(event)) {
13461346 WebElementDictionary *element = [[WebElementDictionary alloc]
1347  initWithHitTestResult:core(m_webFrame.get())->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation(), false)];
 1347 initWithHitTestResult:core(m_webFrame.get())->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation())];
13481348 [result setObject:element forKey:WebActionElementKey];
13491349 [element release];
13501350

Source/WebKit/mac/WebView/WebFrame.mm

@@static inline WebDataSource *dataSource(DocumentLoader* loader)
12161216 Frame* coreFrame = _private->coreFrame;
12171217 if (!coreFrame)
12181218 return nil;
1219  return [[[WebElementDictionary alloc] initWithHitTestResult:coreFrame->eventHandler()->hitTestResultAtPoint(IntPoint(point), false, true)] autorelease];
 1219 return [[[WebElementDictionary alloc] initWithHitTestResult:coreFrame->eventHandler()->hitTestResultAtPoint(IntPoint(point), HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::IgnoreClipping)] autorelease];
12201220}
12211221
12221222@end

Source/WebKit/mac/WebView/WebHTMLView.mm

@@static void extractUnderlines(NSAttributedString *string, Vector<CompositionUnde
62026202 Frame* coreFrame = core([self _frame]);
62036203 if (!coreFrame)
62046204 return nil;
6205  return [[[WebElementDictionary alloc] initWithHitTestResult:coreFrame->eventHandler()->hitTestResultAtPoint(IntPoint(point), allow)] autorelease];
 6205 HitTestRequest::HitTestRequestType hitType = HitTestRequest::ReadOnly | HitTestRequest::Active | (allow ? HitTestRequest::AllowShadowContent : 0);
 6206 return [[[WebElementDictionary alloc] initWithHitTestResult:coreFrame->eventHandler()->hitTestResultAtPoint(IntPoint(point), hitType)] autorelease];
62066207}
62076208
62086209- (NSUInteger)countMatchesForText:(NSString *)string inDOMRange:(DOMRange *)range options:(WebFindOptions)options limit:(NSUInteger)limit markMatches:(BOOL)markMatches

Source/WebKit/qt/WebCoreSupport/FrameLoaderClientQt.cpp

@@void FrameLoaderClientQt::dispatchDecidePolicyForNavigationAction(FramePolicyFun
12501250 if (event->isMouseEvent()) {
12511251 const MouseEvent* mouseEvent = static_cast<const MouseEvent*>(event);
12521252 node = m_webFrame->frame->eventHandler()->hitTestResultAtPoint(
1253  mouseEvent->absoluteLocation(), false).innerNonSharedNode();
 1253 mouseEvent->absoluteLocation()).innerNonSharedNode();
12541254 break;
12551255 }
12561256 }

Source/WebKit/qt/WebCoreSupport/QWebFrameAdapter.cpp

@@QWebHitTestResultPrivate* QWebFrameAdapter::hitTestContent(const QPoint& pos) co
389389 if (!frame->view() || !frame->contentRenderer())
390390 return 0;
391391
392  HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(pos), /*allowShadowContent*/ false, /*ignoreClipping*/ true);
 392 HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(pos), HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::IgnoreClipping);
393393
394394 if (result.scrollbar())
395395 return 0;

Source/WebKit/qt/WebCoreSupport/QWebPageAdapter.cpp

@@IntPoint QWebPageAdapter::TouchAdjuster::findCandidatePointForTouch(const IntPoi
429429 int x = touchPoint.x();
430430 int y = touchPoint.y();
431431
432  RefPtr<NodeList> intersectedNodes = document->nodesFromRect(x, y, m_topPadding, m_rightPadding, m_bottomPadding, m_leftPadding, false /*ignoreClipping*/, false /*allowShadowContent*/);
 432 RefPtr<NodeList> intersectedNodes = document->nodesFromRect(x, y, m_topPadding, m_rightPadding, m_bottomPadding, m_leftPadding);
433433 if (!intersectedNodes)
434434 return IntPoint();
435435

@@void QWebPageAdapter::handleSoftwareInputPanel(Qt::MouseButton button, const QPo
585585 && frame->document()->focusedNode()
586586 && button == Qt::LeftButton && qGuiApp->property("autoSipEnabled").toBool()) {
587587 if (!clickCausedFocus || requestSoftwareInputPanel()) {
588  HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(pos), false);
 588 HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(pos));
589589 if (result.isContentEditable()) {
590590 QEvent event(QEvent::RequestSoftwareInputPanel);
591591 QGuiApplication::sendEvent(client->ownerWidget(), &event);

@@QWebHitTestResultPrivate* QWebPageAdapter::updatePositionDependentMenuActions(co
927927{
928928 ASSERT(visitedWebActions);
929929 WebCore::Frame* focusedFrame = page->focusController()->focusedOrMainFrame();
930  HitTestResult result = focusedFrame->eventHandler()->hitTestResultAtPoint(focusedFrame->view()->windowToContents(pos), /*allowShadowContent*/ false);
 930 HitTestResult result = focusedFrame->eventHandler()->hitTestResultAtPoint(focusedFrame->view()->windowToContents(pos));
931931 page->contextMenuController()->setHitTestResult(result);
932932
933933#if ENABLE(INSPECTOR)

Source/WebKit/win/WebActionPropertyBag.cpp

@@HRESULT STDMETHODCALLTYPE WebActionPropertyBag::Read(LPCOLESTR pszPropName, VARI
121121 if (isEqual(pszPropName, WebActionElementKey)) {
122122 if (const MouseEvent* mouseEvent = findMouseEvent(m_action.event())) {
123123 V_VT(pVar) = VT_UNKNOWN;
124  V_UNKNOWN(pVar) = WebElementPropertyBag::createInstance(m_frame->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation(), false));
 124 V_UNKNOWN(pVar) = WebElementPropertyBag::createInstance(m_frame->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation()));
125125 return S_OK;
126126 }
127127 }

Source/WebKit/win/WebKit.vcproj/WebKitExports.def.in

@@EXPORTS
306306 ??1ContextDestructionObserver@WebCore@@MAE@XZ
307307 ?contextDestroyed@ContextDestructionObserver@WebCore@@UAEXXZ
308308 ??0ContextDestructionObserver@WebCore@@QAE@PAVScriptExecutionContext@1@@Z
309  ?nodesFromRect@Document@WebCore@@QBE?AV?$PassRefPtr@VNodeList@WebCore@@@WTF@@HHIIII_N0@Z
 309 ?nodesFromRect@Document@WebCore@@QBE?AV?$PassRefPtr@VNodeList@WebCore@@@WTF@@HHIIIII@Z
310310 ?selectionStartHasMarkerFor@Editor@WebCore@@QBE_NW4MarkerType@DocumentMarker@2@HH@Z
311311#if ENABLE(FULLSCREEN_API)
312312 ?webkitWillEnterFullScreenForElement@Document@WebCore@@QAEXPAVElement@2@@Z

Source/WebKit/win/WebView.cpp

@@bool WebView::handleContextMenuEvent(WPARAM wParam, LPARAM lParam)
13341334 m_page->contextMenuController()->clearContextMenu();
13351335
13361336 IntPoint documentPoint(m_page->mainFrame()->view()->windowToContents(coords));
1337  HitTestResult result = m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(documentPoint, false);
 1337 HitTestResult result = m_page->mainFrame()->eventHandler()->hitTestResultAtPoint(documentPoint);
13381338 Frame* targetFrame = result.innerNonSharedNode() ? result.innerNonSharedNode()->document()->frame() : m_page->focusController()->focusedOrMainFrame();
13391339
13401340 targetFrame->view()->setCursor(pointerCursor());

@@HRESULT STDMETHODCALLTYPE WebView::elementAtPoint(
36033603 IntPoint webCorePoint = IntPoint(point->x, point->y);
36043604 HitTestResult result = HitTestResult(webCorePoint);
36053605 if (frame->contentRenderer())
3606  result = frame->eventHandler()->hitTestResultAtPoint(webCorePoint, false);
 3606 result = frame->eventHandler()->hitTestResultAtPoint(webCorePoint);
36073607 *elementDictionary = WebElementPropertyBag::createInstance(result);
36083608 return S_OK;
36093609}

Source/WebKit/wx/WebFrame.cpp

@@WebViewDOMElementInfo WebFrame::HitTest(const wxPoint& pos) const
690690 WebViewDOMElementInfo domInfo;
691691
692692 if (m_impl->frame->view()) {
693  WebCore::HitTestResult result = m_impl->frame->eventHandler()->hitTestResultAtPoint(m_impl->frame->view()->windowToContents(pos), false);
 693 WebCore::HitTestResult result = m_impl->frame->eventHandler()->hitTestResultAtPoint(m_impl->frame->view()->windowToContents(pos));
694694 if (result.innerNode()) {
695695 domInfo.SetLink(result.absoluteLinkURL().string());
696696 domInfo.SetText(result.textContent());

Source/WebKit2/WebProcess/InjectedBundle/InjectedBundleNavigationAction.cpp

@@InjectedBundleNavigationAction::InjectedBundleNavigationAction(WebFrame* frame,
9191 , m_mouseButton(WebMouseEvent::NoButton)
9292{
9393 if (const MouseEvent* mouseEvent = mouseEventForNavigationAction(navigationAction)) {
94  m_hitTestResult = InjectedBundleHitTestResult::create(frame->coreFrame()->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation(), false));
 94 m_hitTestResult = InjectedBundleHitTestResult::create(frame->coreFrame()->eventHandler()->hitTestResultAtPoint(mouseEvent->absoluteLocation()));
9595 m_mouseButton = mouseButtonForMouseEvent(mouseEvent);
9696 }
9797

Source/WebKit2/WebProcess/WebPage/WebFrame.cpp

@@PassRefPtr<InjectedBundleHitTestResult> WebFrame::hitTest(const IntPoint point)
540540 if (!m_coreFrame)
541541 return 0;
542542
543  return InjectedBundleHitTestResult::create(m_coreFrame->eventHandler()->hitTestResultAtPoint(point, false, true));
 543 return InjectedBundleHitTestResult::create(m_coreFrame->eventHandler()->hitTestResultAtPoint(point, HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::IgnoreClipping));
544544}
545545
546546bool WebFrame::getDocumentBackgroundColor(double* red, double* green, double* blue, double* alpha)

Source/WebKit2/WebProcess/WebPage/WebPage.cpp

@@static bool isContextClick(const PlatformMouseEvent& event)
15091509static bool handleContextMenuEvent(const PlatformMouseEvent& platformMouseEvent, WebPage* page)
15101510{
15111511 IntPoint point = page->corePage()->mainFrame()->view()->windowToContents(platformMouseEvent.position());
1512  HitTestResult result = page->corePage()->mainFrame()->eventHandler()->hitTestResultAtPoint(point, false);
 1512 HitTestResult result = page->corePage()->mainFrame()->eventHandler()->hitTestResultAtPoint(point);
15131513
15141514 Frame* frame = page->corePage()->mainFrame();
15151515 if (result.innerNonSharedNode())

@@void WebPage::highlightPotentialActivation(const IntPoint& point, const IntSize&
17631763 return;
17641764
17651765#else
1766  HitTestResult result = mainframe->eventHandler()->hitTestResultAtPoint(mainframe->view()->windowToContents(point), /*allowShadowContent*/ false, /*ignoreClipping*/ true);
 1766 HitTestResult result = mainframe->eventHandler()->hitTestResultAtPoint(mainframe->view()->windowToContents(point), HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent);
17671767 adjustedNode = result.innerNode();
17681768#endif
17691769 // Find the node to highlight. This is not the same as the node responding the tap gesture, because many

@@void WebPage::findZoomableAreaForPoint(const WebCore::IntPoint& point, const Web
30313031{
30323032 UNUSED_PARAM(area);
30333033 Frame* mainframe = m_mainFrame->coreFrame();
3034  HitTestResult result = mainframe->eventHandler()->hitTestResultAtPoint(mainframe->view()->windowToContents(point), /*allowShadowContent*/ false, /*ignoreClipping*/ true);
 3034 HitTestResult result = mainframe->eventHandler()->hitTestResultAtPoint(mainframe->view()->windowToContents(point), HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::IgnoreClipping);
30353035
30363036 Node* node = result.innerNode();
30373037

Source/WebKit2/WebProcess/WebPage/mac/WebPageMac.mm

@@void WebPage::characterIndexForPoint(IntPoint point, uint64_t& index)
385385 if (!frame)
386386 return;
387387
388  HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(point, false);
 388 HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(point);
389389 frame = result.innerNonSharedNode() ? result.innerNodeFrame() : m_page->focusController()->focusedOrMainFrame();
390390
391391 RefPtr<Range> range = frame->rangeForPoint(result.roundedPointInInnerNodeFrame());

@@void WebPage::performDictionaryLookupAtLocation(const FloatPoint& floatPoint)
482482
483483 // Find the frame the point is over.
484484 IntPoint point = roundedIntPoint(floatPoint);
485  HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(point), false);
 485 HitTestResult result = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(point));
486486 frame = result.innerNonSharedNode() ? result.innerNonSharedNode()->document()->frame() : m_page->focusController()->focusedOrMainFrame();
487487
488488 IntPoint translatedPoint = frame->view()->windowToContents(point);

@@void WebPage::shouldDelayWindowOrderingEvent(const WebKit::WebMouseEvent& event,
740740 return;
741741
742742#if ENABLE(DRAG_SUPPORT)
743  HitTestResult hitResult = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(event.position()), true);
 743 HitTestResult hitResult = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(event.position()), HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent);
744744 if (hitResult.isSelected())
745745 result = frame->eventHandler()->eventMayStartDrag(platform(event));
746746#endif

@@void WebPage::acceptsFirstMouse(int eventNumber, const WebKit::WebMouseEvent& ev
753753 if (!frame)
754754 return;
755755
756  HitTestResult hitResult = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(event.position()), true);
 756 HitTestResult hitResult = frame->eventHandler()->hitTestResultAtPoint(frame->view()->windowToContents(event.position()), HitTestRequest::ReadOnly | HitTestRequest::Active | HitTestRequest::AllowShadowContent);
757757 frame->eventHandler()->setActivationEventNumber(eventNumber);
758758#if ENABLE(DRAG_SUPPORT)
759759 if (hitResult.isSelected())

Source/autotools/symbols.filter

@@_ZN7WebCore22RuntimeEnabledFeatures40isLangAttributeAwareFormControlUIEnabledE;
221221_ZN7WebCore22RuntimeEnabledFeatures22isDialogElementEnabledE;
222222_ZN7WebCore22RuntimeEnabledFeatures37isAuthorShadowDOMForAnyElementEnabledE;
223223_ZN7WebCore22RuntimeEnabledFeatures20isStyleScopedEnabledE;
224 _ZNK7WebCore8Document13nodesFromRectEiijjjjbb;
 224_ZNK7WebCore8Document13nodesFromRectEiijjjjj;
225225_ZN7WebCore4toJSEPN3JSC9ExecStateEPNS_17JSDOMGlobalObjectEPNS_8NodeListE;
226226_ZNK7WebCore6Editor26selectionStartHasMarkerForENS_14DocumentMarker10MarkerTypeEii;
227227_ZN7WebCore8Document33webkitDidExitFullScreenForElementEPNS_7ElementE;

ChangeLog

 12013-02-13 Allan Sandfeld Jensen <allan.jensen@digia.com>
 2
 3 Simplify hitTestResultAtPoint and nodesFromRect APIs
 4 https://bugs.webkit.org/show_bug.cgi?id=95720
 5
 6 Reviewed by NOBODY (OOPS!).
 7
 8 Update exported symbols.
 9
 10 * Source/autotools/symbols.filter:
 11
1122013-02-12 Martin Robinson <mrobinson@igalia.com>
213
314 [GTK] Remove the GLib unicode backend