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

Side by Side Diff: content/browser/histogram_internals_request_job.cc

Issue 686963002: Switching profiler instrumentations from ScopedProfile to ScopedTracker (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "content/browser/histogram_internals_request_job.h" 5 #include "content/browser/histogram_internals_request_job.h"
6 6
7 #include "base/metrics/histogram.h" 7 #include "base/metrics/histogram.h"
8 #include "base/metrics/statistics_recorder.h" 8 #include "base/metrics/statistics_recorder.h"
9 #include "base/profiler/scoped_profile.h" 9 #include "base/profiler/scoped_tracker.h"
10 #include "content/browser/histogram_synchronizer.h" 10 #include "content/browser/histogram_synchronizer.h"
11 #include "net/base/escape.h" 11 #include "net/base/escape.h"
12 #include "net/base/net_errors.h" 12 #include "net/base/net_errors.h"
13 #include "net/url_request/url_request.h" 13 #include "net/url_request/url_request.h"
14 #include "url/gurl.h" 14 #include "url/gurl.h"
15 15
16 namespace content { 16 namespace content {
17 17
18 HistogramInternalsRequestJob::HistogramInternalsRequestJob( 18 HistogramInternalsRequestJob::HistogramInternalsRequestJob(
19 net::URLRequest* request, net::NetworkDelegate* network_delegate) 19 net::URLRequest* request, net::NetworkDelegate* network_delegate)
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 data->append("<table width=\"100%\">\n"); 53 data->append("<table width=\"100%\">\n");
54 54
55 base::StatisticsRecorder::WriteHTMLGraph(unescaped_query, data); 55 base::StatisticsRecorder::WriteHTMLGraph(unescaped_query, data);
56 } 56 }
57 57
58 int HistogramInternalsRequestJob::GetData( 58 int HistogramInternalsRequestJob::GetData(
59 std::string* mime_type, 59 std::string* mime_type,
60 std::string* charset, 60 std::string* charset,
61 std::string* data, 61 std::string* data,
62 const net::CompletionCallback& callback) const { 62 const net::CompletionCallback& callback) const {
63 // TODO(vadimt): Remove ScopedProfile below once crbug.com/422489 is fixed. 63 // TODO(vadimt): Remove ScopedTracker below once crbug.com/422489 is fixed.
64 tracked_objects::ScopedProfile tracking_profile( 64 tracked_objects::ScopedTracker tracking_profile(
65 FROM_HERE_WITH_EXPLICIT_FUNCTION( 65 FROM_HERE_WITH_EXPLICIT_FUNCTION(
66 "422489 HistogramInternalsRequestJob::GetData")); 66 "422489 HistogramInternalsRequestJob::GetData"));
67 67
68 mime_type->assign("text/html"); 68 mime_type->assign("text/html");
69 charset->assign("UTF8"); 69 charset->assign("UTF8");
70 70
71 data->clear(); 71 data->clear();
72 AboutHistogram(data, path_); 72 AboutHistogram(data, path_);
73 return net::OK; 73 return net::OK;
74 } 74 }
75 75
76 } // namespace content 76 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/gpu/shader_disk_cache.cc ('k') | content/browser/tcmalloc_internals_request_job.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698