Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(65)

Side by Side Diff: third_party/WebKit/Source/core/input/PointerEventManager.h

Issue 2914673002: Refactor TouchEventManager::TouchInfo class (Closed)
Patch Set: Rebase Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef PointerEventManager_h 5 #ifndef PointerEventManager_h
6 #define PointerEventManager_h 6 #define PointerEventManager_h
7 7
8 #include "core/CoreExport.h" 8 #include "core/CoreExport.h"
9 #include "core/events/PointerEvent.h" 9 #include "core/events/PointerEvent.h"
10 #include "core/events/PointerEventFactory.h" 10 #include "core/events/PointerEventFactory.h"
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 // Inhibits firing of touch-type PointerEvents until unblocked by 134 // Inhibits firing of touch-type PointerEvents until unblocked by
135 // unblockTouchPointers(). Also sends pointercancels for existing touch-type 135 // unblockTouchPointers(). Also sends pointercancels for existing touch-type
136 // PointerEvents. See: 136 // PointerEvents. See:
137 // www.w3.org/TR/pointerevents/#declaring-candidate-regions-for-default-touch- behaviors 137 // www.w3.org/TR/pointerevents/#declaring-candidate-regions-for-default-touch- behaviors
138 void BlockTouchPointers(TimeTicks platform_time_stamp); 138 void BlockTouchPointers(TimeTicks platform_time_stamp);
139 139
140 // Enables firing of touch-type PointerEvents after they were inhibited by 140 // Enables firing of touch-type PointerEvents after they were inhibited by
141 // blockTouchPointers(). 141 // blockTouchPointers().
142 void UnblockTouchPointers(); 142 void UnblockTouchPointers();
143 143
144 // Generate the TouchInfos for a WebTouchEvent, hit-testing as necessary. 144 // Returns PointerEventTarget for a WebTouchPoint, hit-testing as necessary.
145 void ComputeTouchTargets(const WebTouchEvent&, 145 EventHandlingUtil::PointerEventTarget ComputePointerEventTarget(
146 HeapVector<TouchEventManager::TouchInfo>&); 146 const WebTouchPoint&);
147 147
148 // Sends touch pointer events and sets consumed bits in TouchInfo array 148 // Sends touch pointer events and sets consumed bits in TouchInfo array
149 // based on the return value of pointer event handlers. 149 // based on the return value of pointer event handlers.
150 void DispatchTouchPointerEvents(const WebTouchEvent&, 150 void DispatchTouchPointerEvent(
151 const Vector<WebTouchEvent>& coalesced_events, 151 const WebTouchPoint&,
152 HeapVector<TouchEventManager::TouchInfo>&); 152 const EventHandlingUtil::PointerEventTarget&,
153 const Vector<std::pair<WebTouchPoint, TimeTicks>>& coalesced_events,
154 WebInputEvent::Modifiers,
155 double timestamp,
156 uint32_t unique_touch_event_id);
153 157
154 // Returns whether the event is consumed or not. 158 // Returns whether the event is consumed or not.
155 WebInputEventResult SendTouchPointerEvent(EventTarget*, PointerEvent*); 159 WebInputEventResult SendTouchPointerEvent(EventTarget*, PointerEvent*);
156 160
157 void SendBoundaryEvents(EventTarget* exited_target, 161 void SendBoundaryEvents(EventTarget* exited_target,
158 EventTarget* entered_target, 162 EventTarget* entered_target,
159 PointerEvent*); 163 PointerEvent*);
160 void SetNodeUnderPointer(PointerEvent*, EventTarget*); 164 void SetNodeUnderPointer(PointerEvent*, EventTarget*);
161 165
162 // Processes the assignment of |m_pointerCaptureTarget| from 166 // Processes the assignment of |m_pointerCaptureTarget| from
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
228 Member<MouseEventManager> mouse_event_manager_; 232 Member<MouseEventManager> mouse_event_manager_;
229 233
230 // The pointerId of the PointerEvent currently being dispatched within this 234 // The pointerId of the PointerEvent currently being dispatched within this
231 // frame or 0 if none. 235 // frame or 0 if none.
232 int dispatching_pointer_id_; 236 int dispatching_pointer_id_;
233 }; 237 };
234 238
235 } // namespace blink 239 } // namespace blink
236 240
237 #endif // PointerEventManager_h 241 #endif // PointerEventManager_h
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/input/EventHandlingUtil.h ('k') | third_party/WebKit/Source/core/input/PointerEventManager.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698