| Index: content/browser/renderer_host/input/synthetic_gesture_controller.cc
|
| diff --git a/content/browser/renderer_host/input/synthetic_gesture_controller.cc b/content/browser/renderer_host/input/synthetic_gesture_controller.cc
|
| index 9e5bc84403eb18e01f09e43b26b9db51fbd20211..f227a2a64f3e5796875073a4e8fab574edfce4ed 100644
|
| --- a/content/browser/renderer_host/input/synthetic_gesture_controller.cc
|
| +++ b/content/browser/renderer_host/input/synthetic_gesture_controller.cc
|
| @@ -16,7 +16,10 @@ namespace content {
|
|
|
| SyntheticGestureController::SyntheticGestureController(
|
| std::unique_ptr<SyntheticGestureTarget> gesture_target)
|
| - : gesture_target_(std::move(gesture_target)) {}
|
| + : gesture_target_(std::move(gesture_target)) {
|
| + pointer_action_controller_.SetDefaultGestureSourceType(
|
| + gesture_target_->GetDefaultSyntheticGestureSourceType());
|
| +}
|
|
|
| SyntheticGestureController::~SyntheticGestureController() {}
|
|
|
| @@ -29,11 +32,30 @@ void SyntheticGestureController::QueueSyntheticGesture(
|
|
|
| pending_gesture_queue_.Push(std::move(synthetic_gesture),
|
| completion_callback);
|
| -
|
| if (was_empty)
|
| StartGesture(*pending_gesture_queue_.FrontGesture());
|
| }
|
|
|
| +void SyntheticGestureController::QueueSyntheticPointerAction(
|
| + const SyntheticGestureParams& gesture_params,
|
| + const OnGestureCompleteCallback& completion_callback) {
|
| + std::unique_ptr<SyntheticGesture> synthetic_gesture;
|
| + if (gesture_params.GetGestureType() ==
|
| + SyntheticGestureParams::POINTER_ACTION_LIST) {
|
| + synthetic_gesture = pointer_action_controller_.CreateSyntheticPointerAction(
|
| + *SyntheticPointerActionListParams::Cast(&gesture_params));
|
| + } else
|
| + synthetic_gesture = SyntheticGesture::Create(gesture_params);
|
| +
|
| + if (synthetic_gesture) {
|
| + QueueSyntheticGesture(std::move(synthetic_gesture), completion_callback);
|
| + }
|
| +}
|
| +
|
| +void SyntheticGestureController::ResetSyntheticPointer() {
|
| + pointer_action_controller_.ResetSyntheticPointer();
|
| +}
|
| +
|
| void SyntheticGestureController::Flush(base::TimeTicks timestamp) {
|
| TRACE_EVENT0("input", "SyntheticGestureController::Flush");
|
| if (pending_gesture_queue_.IsEmpty())
|
|
|