Index: content/browser/renderer_host/input/synthetic_gesture_target_aura.cc |
diff --git a/content/browser/renderer_host/input/synthetic_gesture_target_aura.cc b/content/browser/renderer_host/input/synthetic_gesture_target_aura.cc |
index 64e1c16b9f72172561d84f1da9cb712e9c378fa6..ac0dc6b71f05e4bf335cb9371bd408205ebcd6eb 100644 |
--- a/content/browser/renderer_host/input/synthetic_gesture_target_aura.cc |
+++ b/content/browser/renderer_host/input/synthetic_gesture_target_aura.cc |
@@ -11,6 +11,7 @@ |
#include "content/browser/renderer_host/ui_events_helper.h" |
#include "third_party/WebKit/public/platform/WebScreenInfo.h" |
#include "ui/aura/window.h" |
+#include "ui/aura/window_event_dispatcher.h" |
#include "ui/aura/window_tree_host.h" |
#include "ui/events/event_processor.h" |
#include "ui/events/event_utils.h" |
@@ -37,15 +38,20 @@ void SyntheticGestureTargetAura::DispatchWebTouchEventToPlatform( |
touch_with_latency.event.touches[i].position.x *= device_scale_factor_; |
touch_with_latency.event.touches[i].position.y *= device_scale_factor_; |
touch_with_latency.event.touches[i].radiusX *= device_scale_factor_; |
- touch_with_latency.event.touches[i].radiusY *= device_scale_factor_; |
+ touch_with_latency.event.touches[i].radiusY *= device_scale_factor_;; |
tdresser
2016/08/24 12:27:48
Remove extra ;
lanwei
2016/08/25 02:28:55
Done.
|
} |
ScopedVector<ui::TouchEvent> events; |
bool conversion_success = MakeUITouchEventsFromWebTouchEvents( |
- touch_with_latency, &events, LOCAL_COORDINATES); |
+ touch_with_latency, &events, SCREEN_COORDINATES); |
bokan
2016/08/24 15:56:57
Why is this change needed? The call below to Conve
lanwei
2016/08/25 02:28:55
Actually for SyntheticTouchEvents, the screen posi
bokan
2016/08/25 12:36:51
Ugh, it looks like the synthetic gestures don't re
|
DCHECK(conversion_success); |
aura::Window* window = GetWindow(); |
aura::WindowTreeHost* host = window->GetHost(); |
+ |
+ // Synthetic touch events will be transformed here before send to |
tdresser
2016/08/24 12:27:48
before being sent to the EventProcessor
lanwei
2016/08/25 02:28:55
Done.
|
+ // EventProcessor, so it should not be transformed again later in |
tdresser
2016/08/24 12:27:49
so they should not be transformed again later
lanwei
2016/08/25 02:28:55
Done.
|
+ // WindowEventDispatcher. |
+ host->dispatcher()->set_transform_events(false); |
for (ScopedVector<ui::TouchEvent>::iterator iter = events.begin(), |
end = events.end(); iter != end; ++iter) { |
(*iter)->ConvertLocationToTarget(window, host->window()); |