diff options
author | Ben Murdoch <benm@google.com> | 2011-05-16 16:35:58 +0100 |
---|---|---|
committer | Ben Murdoch <benm@google.com> | 2011-05-23 18:54:14 +0100 |
commit | 6fbaea61d241814b015fd7e022796e68d8ef3e8e (patch) | |
tree | 09be7d423f6dbab5995e21265a9a54650d013a64 /Source/WebCore/page | |
parent | 61f2d6a1f71aa7a52ec56b93958324b8b6de1b6a (diff) | |
download | external_webkit-6fbaea61d241814b015fd7e022796e68d8ef3e8e.zip external_webkit-6fbaea61d241814b015fd7e022796e68d8ef3e8e.tar.gz external_webkit-6fbaea61d241814b015fd7e022796e68d8ef3e8e.tar.bz2 |
Merge WebKit at r76408: Fix conflicts.
Android.jscbindings.mk
Conflict due to local addition of EntrySyncCustom.cpp and http://trac.webkit.org/changeset/76216
V8NPUtils.cpp
Conflict due to local cherry pick of http://trac.webkit.org/changeset/78994 and
merge of http://trac.webkit.org/changeset/76264
FrameView.h
Conflict due to local addition of updatePositionedObjects() and http://trac.webkit.org/changeset/76278
RangeInputType.cpp
SliderThumbElement.cpp
Conflicts due to Android addition of touch handling code in slider code.
See http://trac.webkit.org/changeset/76147
.gitignore - keep ours
Change-Id: I38aeb361a37e7939f805c6689d7cc8fc720b3e52
Diffstat (limited to 'Source/WebCore/page')
-rw-r--r-- | Source/WebCore/page/EventHandler.cpp | 34 | ||||
-rw-r--r-- | Source/WebCore/page/EventHandler.h | 6 | ||||
-rw-r--r-- | Source/WebCore/page/FrameView.h | 9 |
3 files changed, 43 insertions, 6 deletions
diff --git a/Source/WebCore/page/EventHandler.cpp b/Source/WebCore/page/EventHandler.cpp index 476921e..8432c10 100644 --- a/Source/WebCore/page/EventHandler.cpp +++ b/Source/WebCore/page/EventHandler.cpp @@ -249,6 +249,9 @@ void EventHandler::clear() m_previousWheelScrolledNode = 0; #if ENABLE(TOUCH_EVENTS) m_originatingTouchPointTargets.clear(); +#if PLATFORM(ANDROID) + m_capturingTouchEventsNode = 0; +#endif #endif } @@ -1788,6 +1791,13 @@ void EventHandler::clearDragState() } #endif // ENABLE(DRAG_SUPPORT) +#if PLATFORM(ANDROID) && ENABLE(TOUCH_EVENTS) +void EventHandler::setCapturingTouchEventsNode(PassRefPtr<Node> n) +{ + m_capturingTouchEventsNode = n; +} +#endif + void EventHandler::setCapturingMouseEventsNode(PassRefPtr<Node> n) { m_capturingMouseEventsNode = n; @@ -2921,7 +2931,20 @@ bool EventHandler::handleTouchEvent(const PlatformTouchEvent& event) default: break; } +#if PLATFORM(ANDROID) + Node* node = 0; + if (m_capturingTouchEventsNode) + node = m_capturingTouchEventsNode.get(); + else { + HitTestResult result = hitTestResultAtPoint(pagePoint, /*allowShadowContent*/ false, false, DontHitTestScrollbars, hitType); + node = result.innerNode(); + ASSERT(node); + // Touch events should not go to text nodes + if (node->isTextNode()) + node = node->parentNode(); + } +#else HitTestResult result = hitTestResultAtPoint(pagePoint, /*allowShadowContent*/ false, false, DontHitTestScrollbars, hitType); Node* node = result.innerNode(); ASSERT(node); @@ -2929,6 +2952,8 @@ bool EventHandler::handleTouchEvent(const PlatformTouchEvent& event) // Touch events should not go to text nodes if (node->isTextNode()) node = node->parentNode(); +#endif + Document* doc = node->document(); if (!doc) @@ -2947,6 +2972,11 @@ bool EventHandler::handleTouchEvent(const PlatformTouchEvent& event) // Increment the platform touch id by 1 to avoid storing a key of 0 in the hashmap. unsigned touchPointTargetKey = point.id() + 1; RefPtr<EventTarget> touchTarget; +#if PLATFORM(ANDROID) + if (m_capturingTouchEventsNode) + touchTarget = node; + else { +#endif if (pointState == PlatformTouchPoint::TouchPressed) { m_originatingTouchPointTargets.set(touchPointTargetKey, node); touchTarget = node; @@ -2956,7 +2986,9 @@ bool EventHandler::handleTouchEvent(const PlatformTouchEvent& event) touchTarget = m_originatingTouchPointTargets.take(touchPointTargetKey); } else touchTarget = m_originatingTouchPointTargets.get(touchPointTargetKey); - +#if PLATFORM(ANDROID) + } +#endif if (!touchTarget.get()) continue; diff --git a/Source/WebCore/page/EventHandler.h b/Source/WebCore/page/EventHandler.h index d12a56e..77668f1 100644 --- a/Source/WebCore/page/EventHandler.h +++ b/Source/WebCore/page/EventHandler.h @@ -215,6 +215,9 @@ public: #if ENABLE(TOUCH_EVENTS) bool handleTouchEvent(const PlatformTouchEvent&); +#if PLATFORM(ANDROID) + void setCapturingTouchEventsNode(PassRefPtr<Node>); +#endif #endif private: @@ -440,6 +443,9 @@ private: typedef HashMap<int, RefPtr<EventTarget> > TouchTargetMap; TouchTargetMap m_originatingTouchPointTargets; bool m_touchPressed; +#if PLATFORM(ANDROID) + RefPtr<Node> m_capturingTouchEventsNode; +#endif #endif }; diff --git a/Source/WebCore/page/FrameView.h b/Source/WebCore/page/FrameView.h index c75aab8..e61099e 100644 --- a/Source/WebCore/page/FrameView.h +++ b/Source/WebCore/page/FrameView.h @@ -100,13 +100,8 @@ public: bool needsFullRepaint() const { return m_doFullRepaint; } -<<<<<<< HEAD -#if PLATFORM(ANDROID) - void updatePositionedObjects(); -======= #if ENABLE(REQUEST_ANIMATION_FRAME) void serviceScriptedAnimations(); ->>>>>>> WebKit.org at r76408 #endif #if USE(ACCELERATED_COMPOSITING) @@ -121,6 +116,10 @@ public: bool hasOverflowScroll() const { return m_hasOverflowScroll; } #endif +#if PLATFORM(ANDROID) + void updatePositionedObjects(); +#endif + bool hasCompositedContent() const; bool hasCompositedContentIncludingDescendants() const; bool hasCompositingAncestor() const; |