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

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

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 unified diff | Download patch
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 virtual void TearDown() { 70 virtual void TearDown() {
71 helper_scaling_.reset(NULL); 71 helper_scaling_.reset(NULL);
72 helper_.reset(NULL); 72 helper_.reset(NULL);
73 context_.reset(NULL); 73 context_.reset(NULL);
74 } 74 }
75 75
76 void StartTracing(const std::string& filter) { 76 void StartTracing(const std::string& filter) {
77 base::debug::TraceLog::GetInstance()->SetEnabled( 77 base::debug::TraceLog::GetInstance()->SetEnabled(
78 base::debug::CategoryFilter(filter), 78 base::debug::CategoryFilter(filter),
79 base::debug::TraceLog::RECORDING_MODE, 79 base::debug::TraceLog::RECORDING_MODE,
80 base::debug::TraceLog::RECORD_UNTIL_FULL); 80 base::debug::TraceOptions(
81 base::debug::RECORD_UNTIL_FULL));
81 } 82 }
82 83
83 static void TraceDataCB( 84 static void TraceDataCB(
84 const base::Callback<void()>& callback, 85 const base::Callback<void()>& callback,
85 std::string* output, 86 std::string* output,
86 const scoped_refptr<base::RefCountedString>& json_events_str, 87 const scoped_refptr<base::RefCountedString>& json_events_str,
87 bool has_more_events) { 88 bool has_more_events) {
88 if (output->size() > 1) { 89 if (output->size() > 1) {
89 output->append(","); 90 output->append(",");
90 } 91 }
(...skipping 1609 matching lines...) Expand 10 before | Expand all | Expand 10 after
1700 CommandLine::Init(argc, argv); 1701 CommandLine::Init(argc, argv);
1701 base::TestSuite* suite = new content::ContentTestSuite(argc, argv); 1702 base::TestSuite* suite = new content::ContentTestSuite(argc, argv);
1702 #if defined(OS_MACOSX) 1703 #if defined(OS_MACOSX)
1703 base::mac::ScopedNSAutoreleasePool pool; 1704 base::mac::ScopedNSAutoreleasePool pool;
1704 #endif 1705 #endif
1705 1706
1706 content::UnitTestTestSuite runner(suite); 1707 content::UnitTestTestSuite runner(suite);
1707 base::MessageLoop message_loop; 1708 base::MessageLoop message_loop;
1708 return runner.Run(); 1709 return runner.Run();
1709 } 1710 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698