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

Side by Side Diff: content/browser/renderer_host/input/input_router_impl.h

Issue 2624783002: Fix movementX/Y attributes for touch pointer events (Closed)
Patch Set: Wrap ForwardTouchEventWithLatencyInfo to always reset points Created 3 years, 10 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
« no previous file with comments | « no previous file | content/browser/renderer_host/input/input_router_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 CONTENT_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_IMPL_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_IMPL_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_IMPL_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_IMPL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 80
81 void SetFrameTreeNodeId(int frameTreeNodeId) override; 81 void SetFrameTreeNodeId(int frameTreeNodeId) override;
82 82
83 private: 83 private:
84 friend class InputRouterImplTest; 84 friend class InputRouterImplTest;
85 FRIEND_TEST_ALL_PREFIXES(SitePerProcessBrowserTest, 85 FRIEND_TEST_ALL_PREFIXES(SitePerProcessBrowserTest,
86 SubframeTouchEventRouting); 86 SubframeTouchEventRouting);
87 FRIEND_TEST_ALL_PREFIXES(SitePerProcessBrowserTest, 87 FRIEND_TEST_ALL_PREFIXES(SitePerProcessBrowserTest,
88 MainframeTouchEventRouting); 88 MainframeTouchEventRouting);
89 89
90 // Keeps track of last position of touch points and sets MovementXY for them.
91 void SetMovementXYForTouchPoints(blink::WebTouchEvent* event);
92
90 // TouchpadTapSuppressionControllerClient 93 // TouchpadTapSuppressionControllerClient
91 void SendMouseEventImmediately( 94 void SendMouseEventImmediately(
92 const MouseEventWithLatencyInfo& mouse_event) override; 95 const MouseEventWithLatencyInfo& mouse_event) override;
93 96
94 // TouchEventQueueClient 97 // TouchEventQueueClient
95 void SendTouchEventImmediately( 98 void SendTouchEventImmediately(
96 const TouchEventWithLatencyInfo& touch_event) override; 99 const TouchEventWithLatencyInfo& touch_event) override;
97 void OnTouchEventAck(const TouchEventWithLatencyInfo& event, 100 void OnTouchEventAck(const TouchEventWithLatencyInfo& event,
98 InputEventAckState ack_result) override; 101 InputEventAckState ack_result) override;
99 void OnFilteringTouchEvent( 102 void OnFilteringTouchEvent(
(...skipping 153 matching lines...) Expand 10 before | Expand all | Expand 10 after
253 256
254 MouseWheelEventQueue wheel_event_queue_; 257 MouseWheelEventQueue wheel_event_queue_;
255 std::unique_ptr<TouchEventQueue> touch_event_queue_; 258 std::unique_ptr<TouchEventQueue> touch_event_queue_;
256 GestureEventQueue gesture_event_queue_; 259 GestureEventQueue gesture_event_queue_;
257 TouchActionFilter touch_action_filter_; 260 TouchActionFilter touch_action_filter_;
258 InputEventStreamValidator input_stream_validator_; 261 InputEventStreamValidator input_stream_validator_;
259 InputEventStreamValidator output_stream_validator_; 262 InputEventStreamValidator output_stream_validator_;
260 263
261 float device_scale_factor_; 264 float device_scale_factor_;
262 265
266 // Last touch position relative to screen. Used to compute movementX/Y.
267 std::map<int, gfx::Point> global_touch_position_;
268
263 DISALLOW_COPY_AND_ASSIGN(InputRouterImpl); 269 DISALLOW_COPY_AND_ASSIGN(InputRouterImpl);
264 }; 270 };
265 271
266 } // namespace content 272 } // namespace content
267 273
268 #endif // CONTENT_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_IMPL_H_ 274 #endif // CONTENT_BROWSER_RENDERER_HOST_INPUT_INPUT_ROUTER_IMPL_H_
OLDNEW
« no previous file with comments | « no previous file | content/browser/renderer_host/input/input_router_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698