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

Unified Diff: content/browser/browser_plugin/browser_plugin_guest.cc

Issue 2317253005: SourceEventType added to LatencyInfo (Closed)
Patch Set: Added a fake return to the end of EventTypeToLatencySourceEventType, for compilers that don't know … Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | content/browser/frame_host/render_widget_host_view_guest.cc » ('j') | ui/events/event.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/browser_plugin/browser_plugin_guest.cc
diff --git a/content/browser/browser_plugin/browser_plugin_guest.cc b/content/browser/browser_plugin/browser_plugin_guest.cc
index 6d06122d6ab931eb89bad7cb5c679c152c8c77d6..65ad76bbca94595d979393370bb2479998bfbf81 100644
--- a/content/browser/browser_plugin/browser_plugin_guest.cc
+++ b/content/browser/browser_plugin/browser_plugin_guest.cc
@@ -48,6 +48,7 @@
#include "content/public/browser/web_contents_observer.h"
#include "content/public/common/browser_plugin_guest_mode.h"
#include "content/public/common/drop_data.h"
+#include "ui/events/blink/web_input_event_traits.h"
#include "ui/gfx/geometry/size_conversions.h"
#if defined(OS_MACOSX)
@@ -457,7 +458,10 @@ void BrowserPluginGuest::ResendEventToEmbedder(
// Mark the resend source with the browser plugin's instance id, so the
// correct browser_plugin will know to ignore the event.
resent_gesture_event.resendingPluginId = browser_plugin_instance_id_;
- view->ProcessGestureEvent(resent_gesture_event, ui::LatencyInfo());
+ ui::LatencyInfo latency_info =
+ ui::WebInputEventTraits::CreateLatencyInfoForWebGestureEvent(
+ resent_gesture_event);
+ view->ProcessGestureEvent(resent_gesture_event, latency_info);
} else if (event.type == blink::WebInputEvent::MouseWheel) {
blink::WebMouseWheelEvent resent_wheel_event;
memcpy(&resent_wheel_event, &event, sizeof(blink::WebMouseWheelEvent));
@@ -466,7 +470,7 @@ void BrowserPluginGuest::ResendEventToEmbedder(
resent_wheel_event.resendingPluginId = browser_plugin_instance_id_;
// TODO(wjmaclean): Initialize latency info correctly for OOPIFs.
// https://crbug.com/613628
- ui::LatencyInfo latency_info;
+ ui::LatencyInfo latency_info(ui::SourceEventType::WHEEL);
view->ProcessMouseWheelEvent(resent_wheel_event, latency_info);
} else {
NOTIMPLEMENTED();
« no previous file with comments | « no previous file | content/browser/frame_host/render_widget_host_view_guest.cc » ('j') | ui/events/event.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698