Index: base/debug/trace_event_impl.h |
diff --git a/base/debug/trace_event_impl.h b/base/debug/trace_event_impl.h |
index f405e00116463b52bb53e00946c40cfd58ebb1a6..8e044d3a6661f4b96fb06e84fc09f6c2fd360ab4 100644 |
--- a/base/debug/trace_event_impl.h |
+++ b/base/debug/trace_event_impl.h |
@@ -208,6 +208,11 @@ class BASE_EXPORT TraceLog { |
void SetEnabled(bool enabled); |
bool IsEnabled() { return !!enable_count_; } |
+ void SetContinuousTracing(bool continuous_tracing) { |
nduca
2013/02/12 19:42:22
I like it, but can we make it a mode and a require
dsinclair
2013/02/25 19:04:34
Done.
|
+ continuous_tracing_ = continuous_tracing; |
+ } |
+ bool GetContinuousTracing() { return continuous_tracing_; } |
+ |
#if defined(OS_ANDROID) |
static void InitATrace(); |
#endif |
@@ -364,6 +369,8 @@ class BASE_EXPORT TraceLog { |
static void ApplyATraceEnabledFlag(unsigned char* category_enabled); |
#endif |
+ void AddEvent(const TraceEvent& event); |
+ |
// TODO(nduca): switch to per-thread trace buffers to reduce thread |
// synchronization. |
// This lock protects TraceLog member accesses from arbitrary threads. |
@@ -371,6 +378,9 @@ class BASE_EXPORT TraceLog { |
int enable_count_; |
NotificationCallback notification_callback_; |
std::vector<TraceEvent> logged_events_; |
+ bool continuous_tracing_; |
nduca
2013/02/12 19:42:22
Hm... can you factor out logged_events and logged_
dsinclair
2013/02/15 19:38:55
Done.
|
+ uint32 logged_events_newest_; |
+ uint32 logged_events_oldest_; |
std::vector<std::string> included_categories_; |
std::vector<std::string> excluded_categories_; |
bool dispatching_to_observer_list_; |