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

Unified Diff: content/browser/android/content_view_core_impl.cc

Issue 2770613002: Forward GenericMotionEvent to EventForwarder (Closed)
Patch Set: comments Created 3 years, 9 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
Index: content/browser/android/content_view_core_impl.cc
diff --git a/content/browser/android/content_view_core_impl.cc b/content/browser/android/content_view_core_impl.cc
index 08eaec6cb10d0e2a3b1d20cab45fcfb1b2634122..b3156c8933910772454537b92bc5d52cab2830b8 100644
--- a/content/browser/android/content_view_core_impl.cc
+++ b/content/browser/android/content_view_core_impl.cc
@@ -865,38 +865,6 @@ void ContentViewCoreImpl::SendOrientationChangeEvent(
}
}
-jboolean ContentViewCoreImpl::SendMouseWheelEvent(
- JNIEnv* env,
- const JavaParamRef<jobject>& obj,
- jlong time_ms,
- jfloat x,
- jfloat y,
- jfloat ticks_x,
- jfloat ticks_y,
- jfloat pixels_per_tick) {
- RenderWidgetHostViewAndroid* rwhv = GetRenderWidgetHostViewAndroid();
- if (!rwhv)
- return false;
-
- if (!ticks_x && !ticks_y)
- return false;
-
- // Compute Event.Latency.OS.MOUSE_WHEEL histogram.
- base::TimeTicks current_time = ui::EventTimeForNow();
- base::TimeTicks event_time = base::TimeTicks() +
- base::TimeDelta::FromMilliseconds(time_ms);
- base::TimeDelta delta = current_time - event_time;
- UMA_HISTOGRAM_CUSTOM_COUNTS("Event.Latency.OS.MOUSE_WHEEL",
- delta.InMicroseconds(), 1, 1000000, 50);
-
- blink::WebMouseWheelEvent event = WebMouseWheelEventBuilder::Build(
- ticks_x, ticks_y, pixels_per_tick / dpi_scale(), time_ms / 1000.0,
- x / dpi_scale(), y / dpi_scale());
-
- rwhv->SendMouseWheelEvent(event);
- return true;
-}
-
WebGestureEvent ContentViewCoreImpl::MakeGestureEvent(WebInputEvent::Type type,
int64_t time_ms,
float x,
« no previous file with comments | « content/browser/android/browser_jni_registrar.cc ('k') | content/browser/android/joystick_scroll_provider.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698