| Index: content/renderer/input/input_handler_proxy.cc
|
| diff --git a/content/renderer/input/input_handler_proxy.cc b/content/renderer/input/input_handler_proxy.cc
|
| index 0d4b17320a1986903d7c6942d404731474f9c534..817643397f4a68141383fe65fb93cba8b07e3596 100644
|
| --- a/content/renderer/input/input_handler_proxy.cc
|
| +++ b/content/renderer/input/input_handler_proxy.cc
|
| @@ -118,8 +118,12 @@ WebGestureEvent ObtainGestureScrollBegin(const WebGestureEvent& event) {
|
| void SendScrollLatencyUma(const WebInputEvent& event,
|
| const ui::LatencyInfo& latency_info) {
|
| if (!(event.type == WebInputEvent::GestureScrollBegin ||
|
| - event.type == WebInputEvent::GestureScrollUpdate))
|
| + event.type == WebInputEvent::GestureScrollUpdate ||
|
| + event.type == WebInputEvent::GesturePinchBegin ||
|
| + event.type == WebInputEvent::GesturePinchUpdate ||
|
| + event.type == WebInputEvent::GestureFlingStart)) {
|
| return;
|
| + }
|
|
|
| ui::LatencyInfo::LatencyMap::const_iterator it =
|
| latency_info.latency_components.find(std::make_pair(
|
| @@ -130,17 +134,42 @@ void SendScrollLatencyUma(const WebInputEvent& event,
|
|
|
| base::TimeDelta delta = base::TimeTicks::HighResNow() - it->second.event_time;
|
| for (size_t i = 0; i < it->second.event_count; ++i) {
|
| - UMA_HISTOGRAM_CUSTOM_COUNTS(
|
| - "Event.Latency.RendererImpl.GestureScroll2",
|
| - delta.InMicroseconds(),
|
| - 1,
|
| - 1000000,
|
| - 100);
|
| + switch (event.type) {
|
| + case blink::WebInputEvent::GestureScrollBegin:
|
| + UMA_HISTOGRAM_CUSTOM_COUNTS(
|
| + "Event.Latency.RendererImpl.GestureScrollBegin",
|
| + delta.InMicroseconds(), 1, 1000000, 100);
|
| + break;
|
| + case blink::WebInputEvent::GestureScrollUpdate:
|
| + UMA_HISTOGRAM_CUSTOM_COUNTS(
|
| + // So named for historical reasons.
|
| + "Event.Latency.RendererImpl.GestureScroll2",
|
| + delta.InMicroseconds(), 1, 1000000, 100);
|
| + break;
|
| + case blink::WebInputEvent::GesturePinchBegin:
|
| + UMA_HISTOGRAM_CUSTOM_COUNTS(
|
| + "Event.Latency.RendererImpl.GesturePinchBegin",
|
| + delta.InMicroseconds(), 1, 1000000, 100);
|
| + break;
|
| + case blink::WebInputEvent::GesturePinchUpdate:
|
| + UMA_HISTOGRAM_CUSTOM_COUNTS(
|
| + "Event.Latency.RendererImpl.GesturePinchUpdate",
|
| + delta.InMicroseconds(), 1, 1000000, 100);
|
| + break;
|
| + case blink::WebInputEvent::GestureFlingStart:
|
| + UMA_HISTOGRAM_CUSTOM_COUNTS(
|
| + "Event.Latency.RendererImpl.GestureFlingStart",
|
| + delta.InMicroseconds(), 1, 1000000, 100);
|
| + break;
|
| + default:
|
| + NOTREACHED();
|
| + break;
|
| + }
|
| }
|
| -} // namespace
|
| -
|
| }
|
|
|
| +} // namespace
|
| +
|
| namespace content {
|
|
|
| InputHandlerProxy::InputHandlerProxy(cc::InputHandler* input_handler,
|
|
|