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

Unified Diff: content/browser/renderer_host/input/synthetic_touch_driver.h

Issue 2336803003: Make SyntheticPointerAction to flush the pointer action sequence (Closed)
Patch Set: controller Created 4 years 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/renderer_host/input/synthetic_touch_driver.h
diff --git a/content/browser/renderer_host/input/synthetic_touch_driver.h b/content/browser/renderer_host/input/synthetic_touch_driver.h
index 5db84cf1b69a6b05d45f115970e854d35389ec6a..7987c4f59c431323e6baf5e49a1ecc7669258afe 100644
--- a/content/browser/renderer_host/input/synthetic_touch_driver.h
+++ b/content/browser/renderer_host/input/synthetic_touch_driver.h
@@ -11,6 +11,8 @@
#include "content/common/content_export.h"
#include "content/common/input/synthetic_web_input_event_builders.h"
+using blink::WebTouchEvent;
+
namespace content {
class CONTENT_EXPORT SyntheticTouchDriver : public SyntheticPointerDriver {
@@ -22,7 +24,7 @@ class CONTENT_EXPORT SyntheticTouchDriver : public SyntheticPointerDriver {
void DispatchEvent(SyntheticGestureTarget* target,
const base::TimeTicks& timestamp) override;
- int Press(float x, float y) override;
+ void Press(float x, float y, int index) override;
void Move(float x, float y, int index) override;
void Release(int index) override;
@@ -30,7 +32,11 @@ class CONTENT_EXPORT SyntheticTouchDriver : public SyntheticPointerDriver {
const SyntheticPointerActionParams& params) const override;
private:
+ using IndexMap = std::array<int, WebTouchEvent::kTouchesLengthCap>;
samuong 2016/12/21 00:02:27 I think you should just write blink::WebTouchEvent
lanwei 2016/12/21 20:01:14 Done.
+
SyntheticWebTouchEvent touch_event_;
+ IndexMap index_map_;
+
DISALLOW_COPY_AND_ASSIGN(SyntheticTouchDriver);
};

Powered by Google App Engine
This is Rietveld 408576698