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

Unified Diff: ui/events/latency_info.h

Issue 140663003: Removed requirement for the renderer to know it's process ID (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed Windows Created 6 years, 11 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: ui/events/latency_info.h
diff --git a/ui/events/latency_info.h b/ui/events/latency_info.h
index 3e50cc4f80c127b917513b65a07ebf7d29ab5571..6a55663b40ad39f824a73775065c55405d929255 100644
--- a/ui/events/latency_info.h
+++ b/ui/events/latency_info.h
@@ -9,6 +9,7 @@
#include <utility>
#include "base/basictypes.h"
+#include "base/process/process_handle.h"
#include "base/time/time.h"
#include "ui/events/events_base_export.h"
@@ -123,6 +124,15 @@ struct EVENTS_BASE_EXPORT LatencyInfo {
// Records the |event_type| in trace buffer as TRACE_EVENT_ASYNC_STEP.
void TraceEventType(const char* event_type);
+ static void AnnotateWithProcessId(std::vector<ui::LatencyInfo>& latency_info,
+ base::ProcessId process_id);
jamesr 2014/01/16 23:07:21 nit: i don't think that the ID used here is actual
+
+ // Some LatencyComponents generated in the renderer, specifically
+ // WINDOW_SNAPSHOT_FRAME_NUMBER_COMPONENTs, require a ProcessId to route
+ // notifications correctly. Since that cannot be given in the renderer
+ // this function patches the ProcessId in from the browser process.
+ void AnnotateComponentsWithProcessId(base::ProcessId process_id);
+
LatencyMap latency_components;
// The unique id for matching the ASYNC_BEGIN/END trace event.
int64 trace_id;

Powered by Google App Engine
This is Rietveld 408576698