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

Unified Diff: content/browser/tracing/tracing_controller_impl.h

Issue 425593002: Refactor trace_event_impl's SetEnabled to use TraceOptions. Propagate this through the whole stack. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address joechan's comments Created 6 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
Index: content/browser/tracing/tracing_controller_impl.h
diff --git a/content/browser/tracing/tracing_controller_impl.h b/content/browser/tracing/tracing_controller_impl.h
index d4d5722d85be15dcdbd0648d88f38d5de494da38..bd4aaa10aaabf0e1e33bbd3a0b64b5441f88ea67 100644
--- a/content/browser/tracing/tracing_controller_impl.h
+++ b/content/browser/tracing/tracing_controller_impl.h
@@ -30,21 +30,22 @@ class TracingControllerImpl : public TracingController {
virtual bool GetCategories(
const GetCategoriesDoneCallback& callback) OVERRIDE;
virtual bool EnableRecording(
- const std::string& category_filter,
- TracingController::Options options,
+ const base::debug::CategoryFilter& category_filter,
+ const base::debug::TraceOptions& trace_options,
const EnableRecordingDoneCallback& callback) OVERRIDE;
virtual bool DisableRecording(
const base::FilePath& result_file_path,
const TracingFileResultCallback& callback) OVERRIDE;
- virtual bool EnableMonitoring(const std::string& category_filter,
- TracingController::Options options,
+ virtual bool EnableMonitoring(
+ const base::debug::CategoryFilter& category_filter,
+ const base::debug::TraceOptions& trace_options,
const EnableMonitoringDoneCallback& callback) OVERRIDE;
virtual bool DisableMonitoring(
const DisableMonitoringDoneCallback& callback) OVERRIDE;
virtual void GetMonitoringStatus(
bool* out_enabled,
- std::string* out_category_filter,
- TracingController::Options* out_options) OVERRIDE;
+ base::debug::CategoryFilter* out_category_filter,
+ base::debug::TraceOptions* out_trace_options) OVERRIDE;
virtual bool CaptureMonitoringSnapshot(
const base::FilePath& result_file_path,
const TracingFileResultCallback& callback) OVERRIDE;
@@ -131,19 +132,21 @@ class TracingControllerImpl : public TracingController {
void OnWatchEventMatched();
- void SetEnabledOnFileThread(const std::string& category_filter,
- int mode,
- int options,
- const base::Closure& callback);
+ void SetEnabledOnFileThread(
+ const base::debug::CategoryFilter& category_filter,
+ int mode,
+ const base::debug::TraceOptions& trace_options,
+ const base::Closure& callback);
void SetDisabledOnFileThread(const base::Closure& callback);
- void OnEnableRecordingDone(const std::string& category_filter,
- int trace_options,
+ void OnEnableRecordingDone(const base::debug::CategoryFilter& category_filter,
+ const base::debug::TraceOptions& trace_options,
const EnableRecordingDoneCallback& callback);
void OnDisableRecordingDone(const base::FilePath& result_file_path,
const TracingFileResultCallback& callback);
- void OnEnableMonitoringDone(const std::string& category_filter,
- int trace_options,
- const EnableMonitoringDoneCallback& callback);
+ void OnEnableMonitoringDone(
+ const base::debug::CategoryFilter& category_filter,
+ const base::debug::TraceOptions& trace_options,
+ const EnableMonitoringDoneCallback& callback);
void OnDisableMonitoringDone(const DisableMonitoringDoneCallback& callback);
void OnMonitoringStateChanged(bool is_monitoring);
@@ -166,7 +169,7 @@ class TracingControllerImpl : public TracingController {
#endif
bool is_recording_;
bool is_monitoring_;
- TracingController::Options options_;
+ base::debug::TraceOptions trace_options_;
GetCategoriesDoneCallback pending_get_categories_done_callback_;
TracingFileResultCallback pending_disable_recording_done_callback_;
« no previous file with comments | « content/browser/tracing/tracing_controller_browsertest.cc ('k') | content/browser/tracing/tracing_controller_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698