| Index: ui/base/latency_info.cc
|
| diff --git a/ui/base/latency_info.cc b/ui/base/latency_info.cc
|
| index eb8b34ca0ccd520a526ae502fee49361a87a1af5..b2ff6ef1c43fe0f03e520552bbf195250de8e28f 100644
|
| --- a/ui/base/latency_info.cc
|
| +++ b/ui/base/latency_info.cc
|
| @@ -58,9 +58,19 @@ void LatencyInfo::AddLatencyNumberWithTimestamp(LatencyComponentType component,
|
| }
|
| }
|
|
|
| +bool LatencyInfo::FindLatency(LatencyComponentType type,
|
| + int64 id,
|
| + LatencyComponent* output) const {
|
| + LatencyMap::const_iterator it = latency_components.find(
|
| + std::make_pair(type, id));
|
| + if (it == latency_components.end())
|
| + return false;
|
| + *output = it->second;
|
| + return true;
|
| +}
|
| +
|
| void LatencyInfo::Clear() {
|
| latency_components.clear();
|
| }
|
|
|
| } // namespace ui
|
| -
|
|
|