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

Unified Diff: content/browser/renderer_host/input/touch_event_queue.cc

Issue 25022003: Report LatencyInfo through trace buffer (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: address sadrul's comments Created 7 years, 2 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/renderer_host/input/touch_event_queue.cc
diff --git a/content/browser/renderer_host/input/touch_event_queue.cc b/content/browser/renderer_host/input/touch_event_queue.cc
index 9d0394ef162d034a0f43ebe90cb34969011867de..6e207000fd780c36d834cc178de11cd3ec821c74 100644
--- a/content/browser/renderer_host/input/touch_event_queue.cc
+++ b/content/browser/renderer_host/input/touch_event_queue.cc
@@ -69,11 +69,11 @@ class CoalescedWebTouchEvent {
return coalesced_event_;
}
- WebTouchEventWithLatencyList::const_iterator begin() const {
+ WebTouchEventWithLatencyList::iterator begin() {
return events_.begin();
}
- WebTouchEventWithLatencyList::const_iterator end() const {
+ WebTouchEventWithLatencyList::iterator end() {
return events_.end();
}
@@ -194,14 +194,10 @@ void TouchEventQueue::PopTouchEventToClient(
// to the renderer, or touch-events being queued.
base::AutoReset<bool> dispatching_touch_ack(&dispatching_touch_ack_, true);
- base::TimeTicks now = base::TimeTicks::HighResNow();
- for (WebTouchEventWithLatencyList::const_iterator iter = acked_event->begin(),
+ for (WebTouchEventWithLatencyList::iterator iter = acked_event->begin(),
end = acked_event->end();
iter != end; ++iter) {
- ui::LatencyInfo* latency = const_cast<ui::LatencyInfo*>(&(iter->latency));
- latency->AddNewLatencyFrom(renderer_latency_info);
- latency->AddLatencyNumberWithTimestamp(
- ui::INPUT_EVENT_LATENCY_ACKED_COMPONENT, 0, 0, now, 1);
+ iter->latency.AddNewLatencyFrom(renderer_latency_info);
client_->OnTouchEventAck((*iter), ack_result);
}
}

Powered by Google App Engine
This is Rietveld 408576698