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

Side by Side Diff: content/common/gpu/client/gl_helper_unittest.cc

Issue 1165673002: [Startup Tracing] Hook up TraceConfig and remove CategoryFilter & TraceOptions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 6 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 unified diff | Download patch
« no previous file with comments | « content/browser/tracing/tracing_ui.cc ('k') | content/public/browser/tracing_controller.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stdio.h> 5 #include <stdio.h>
6 #include <cmath> 6 #include <cmath>
7 #include <string> 7 #include <string>
8 #include <vector> 8 #include <vector>
9 9
10 #include <GLES2/gl2.h> 10 #include <GLES2/gl2.h>
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after
70 } 70 }
71 71
72 void TearDown() override { 72 void TearDown() override {
73 helper_scaling_.reset(NULL); 73 helper_scaling_.reset(NULL);
74 helper_.reset(NULL); 74 helper_.reset(NULL);
75 context_.reset(NULL); 75 context_.reset(NULL);
76 } 76 }
77 77
78 void StartTracing(const std::string& filter) { 78 void StartTracing(const std::string& filter) {
79 base::trace_event::TraceLog::GetInstance()->SetEnabled( 79 base::trace_event::TraceLog::GetInstance()->SetEnabled(
80 base::trace_event::CategoryFilter(filter), 80 base::trace_event::TraceConfig(filter,
81 base::trace_event::TraceLog::RECORDING_MODE, 81 base::trace_event::RECORD_UNTIL_FULL),
82 base::trace_event::TraceOptions( 82 base::trace_event::TraceLog::RECORDING_MODE);
83 base::trace_event::RECORD_UNTIL_FULL));
84 } 83 }
85 84
86 static void TraceDataCB( 85 static void TraceDataCB(
87 const base::Callback<void()>& callback, 86 const base::Callback<void()>& callback,
88 std::string* output, 87 std::string* output,
89 const scoped_refptr<base::RefCountedString>& json_events_str, 88 const scoped_refptr<base::RefCountedString>& json_events_str,
90 bool has_more_events) { 89 bool has_more_events) {
91 if (output->size() > 1 && !json_events_str->data().empty()) { 90 if (output->size() > 1 && !json_events_str->data().empty()) {
92 output->append(","); 91 output->append(",");
93 } 92 }
(...skipping 1891 matching lines...) Expand 10 before | Expand all | Expand 10 after
1985 base::TestSuite* suite = new content::ContentTestSuite(argc, argv); 1984 base::TestSuite* suite = new content::ContentTestSuite(argc, argv);
1986 #if defined(OS_MACOSX) 1985 #if defined(OS_MACOSX)
1987 base::mac::ScopedNSAutoreleasePool pool; 1986 base::mac::ScopedNSAutoreleasePool pool;
1988 #endif 1987 #endif
1989 1988
1990 return base::LaunchUnitTestsSerially( 1989 return base::LaunchUnitTestsSerially(
1991 argc, 1990 argc,
1992 argv, 1991 argv,
1993 base::Bind(&RunHelper, base::Unretained(suite))); 1992 base::Bind(&RunHelper, base::Unretained(suite)));
1994 } 1993 }
OLDNEW
« no previous file with comments | « content/browser/tracing/tracing_ui.cc ('k') | content/public/browser/tracing_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698