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

Unified Diff: third_party/WebKit/Source/core/input/MouseEventManager.cpp

Issue 2539283002: Remove PlatformGestureEvent in favour of using WebGestureEvent (Closed)
Patch Set: Add missing copyright on new file 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: third_party/WebKit/Source/core/input/MouseEventManager.cpp
diff --git a/third_party/WebKit/Source/core/input/MouseEventManager.cpp b/third_party/WebKit/Source/core/input/MouseEventManager.cpp
index 1a99cf8fcfe81a5b2fe36e4e67721574b17df9bc..d10d731b1f3352dc99bebbcda089f7e1e206e507 100644
--- a/third_party/WebKit/Source/core/input/MouseEventManager.cpp
+++ b/third_party/WebKit/Source/core/input/MouseEventManager.cpp
@@ -645,15 +645,14 @@ bool MouseEventManager::handleDragDropIfPossible(
const GestureEventWithHitTestResults& targetedEvent) {
if (m_frame->settings() && m_frame->settings()->touchDragDropEnabled() &&
m_frame->view()) {
- const PlatformGestureEvent& gestureEvent = targetedEvent.event();
- IntPoint adjustedPoint = gestureEvent.position();
- unsigned modifiers = gestureEvent.getModifiers();
+ const WebGestureEvent& gestureEvent = targetedEvent.event();
+ unsigned modifiers = gestureEvent.modifiers;
// TODO(mustaq): Suppressing long-tap MouseEvents could break
// drag-drop. Will do separately because of the risk. crbug.com/606938.
PlatformMouseEvent mouseDownEvent(
- adjustedPoint, gestureEvent.globalPosition(),
- WebPointerProperties::Button::Left, PlatformEvent::MousePressed, 1,
+ gestureEvent, WebPointerProperties::Button::Left,
+ PlatformEvent::MousePressed, 1,
static_cast<PlatformEvent::Modifiers>(modifiers |
PlatformEvent::LeftButtonDown),
PlatformMouseEvent::FromTouch, TimeTicks::Now(),
@@ -661,8 +660,8 @@ bool MouseEventManager::handleDragDropIfPossible(
m_mouseDown = mouseDownEvent;
PlatformMouseEvent mouseDragEvent(
- adjustedPoint, gestureEvent.globalPosition(),
- WebPointerProperties::Button::Left, PlatformEvent::MouseMoved, 1,
+ gestureEvent, WebPointerProperties::Button::Left,
+ PlatformEvent::MouseMoved, 1,
static_cast<PlatformEvent::Modifiers>(modifiers |
PlatformEvent::LeftButtonDown),
PlatformMouseEvent::FromTouch, TimeTicks::Now(),
« no previous file with comments | « third_party/WebKit/Source/core/input/GestureManager.cpp ('k') | third_party/WebKit/Source/core/input/ScrollManager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698