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

Unified Diff: ui/base/latency_info.cc

Issue 19670007: Send input event's LatencyInfo back from renderer to browser when acked (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: fix compile error in immediate_input_router_unittest.cc Created 7 years, 4 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 | « ui/base/latency_info.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/latency_info.cc
diff --git a/ui/base/latency_info.cc b/ui/base/latency_info.cc
index 459fc2ab689a3183eede3c51a43042c2542a1c83..9551450fab5d592fdaa3d3c720c40cf48a13f1c0 100644
--- a/ui/base/latency_info.cc
+++ b/ui/base/latency_info.cc
@@ -26,6 +26,20 @@ void LatencyInfo::MergeWith(const LatencyInfo& other) {
}
}
+void LatencyInfo::AddNewLatencyFrom(const LatencyInfo& other) {
+ for (LatencyMap::const_iterator it = other.latency_components.begin();
+ it != other.latency_components.end();
+ ++it) {
+ if (!FindLatency(it->first.first, it->first.second, NULL)) {
+ AddLatencyNumberWithTimestamp(it->first.first,
+ it->first.second,
+ it->second.sequence_number,
+ it->second.event_time,
+ it->second.event_count);
+ }
+ }
+}
+
void LatencyInfo::AddLatencyNumber(LatencyComponentType component,
int64 id,
int64 component_sequence_number) {
« no previous file with comments | « ui/base/latency_info.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698