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

Side by Side Diff: storage/browser/blob/view_blob_internals_job.cc

Issue 747443002: Undoing instrumentations for task URLRequestSimpleJob::StartAsync (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Removing changes that conflict with another CL 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
« no previous file with comments | « net/url_request/url_request_data_job.cc ('k') | ui/base/resource/resource_bundle.cc » ('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 (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 "storage/browser/blob/view_blob_internals_job.h" 5 #include "storage/browser/blob/view_blob_internals_job.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/format_macros.h" 9 #include "base/format_macros.h"
10 #include "base/i18n/number_formatting.h" 10 #include "base/i18n/number_formatting.h"
11 #include "base/i18n/time_formatting.h" 11 #include "base/i18n/time_formatting.h"
12 #include "base/logging.h" 12 #include "base/logging.h"
13 #include "base/message_loop/message_loop.h" 13 #include "base/message_loop/message_loop.h"
14 #include "base/profiler/scoped_tracker.h"
15 #include "base/strings/string_number_conversions.h" 14 #include "base/strings/string_number_conversions.h"
16 #include "base/strings/string_util.h" 15 #include "base/strings/string_util.h"
17 #include "base/strings/stringprintf.h" 16 #include "base/strings/stringprintf.h"
18 #include "base/strings/utf_string_conversions.h" 17 #include "base/strings/utf_string_conversions.h"
19 #include "net/base/escape.h" 18 #include "net/base/escape.h"
20 #include "net/base/net_errors.h" 19 #include "net/base/net_errors.h"
21 #include "net/url_request/url_request.h" 20 #include "net/url_request/url_request.h"
22 #include "storage/browser/blob/blob_storage_context.h" 21 #include "storage/browser/blob/blob_storage_context.h"
23 #include "storage/common/blob/blob_data.h" 22 #include "storage/common/blob/blob_data.h"
24 23
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 void ViewBlobInternalsJob::Kill() { 124 void ViewBlobInternalsJob::Kill() {
126 net::URLRequestSimpleJob::Kill(); 125 net::URLRequestSimpleJob::Kill();
127 weak_factory_.InvalidateWeakPtrs(); 126 weak_factory_.InvalidateWeakPtrs();
128 } 127 }
129 128
130 int ViewBlobInternalsJob::GetData( 129 int ViewBlobInternalsJob::GetData(
131 std::string* mime_type, 130 std::string* mime_type,
132 std::string* charset, 131 std::string* charset,
133 std::string* data, 132 std::string* data,
134 const net::CompletionCallback& callback) const { 133 const net::CompletionCallback& callback) const {
135 // TODO(vadimt): Remove ScopedTracker below once crbug.com/422489 is fixed.
136 tracked_objects::ScopedTracker tracking_profile(
137 FROM_HERE_WITH_EXPLICIT_FUNCTION("422489 ViewBlobInternalsJob::GetData"));
138
139 mime_type->assign("text/html"); 134 mime_type->assign("text/html");
140 charset->assign("UTF-8"); 135 charset->assign("UTF-8");
141 136
142 data->clear(); 137 data->clear();
143 StartHTML(data); 138 StartHTML(data);
144 if (blob_storage_context_->blob_map_.empty()) 139 if (blob_storage_context_->blob_map_.empty())
145 data->append(kEmptyBlobStorageMessage); 140 data->append(kEmptyBlobStorageMessage);
146 else 141 else
147 GenerateHTML(data); 142 GenerateHTML(data);
148 EndHTML(data); 143 EndHTML(data);
(...skipping 89 matching lines...) Expand 10 before | Expand all | Expand 10 after
238 } 233 }
239 234
240 if (has_multi_items) 235 if (has_multi_items)
241 EndHTMLList(out); 236 EndHTMLList(out);
242 } 237 }
243 238
244 EndHTMLList(out); 239 EndHTMLList(out);
245 } 240 }
246 241
247 } // namespace storage 242 } // namespace storage
OLDNEW
« no previous file with comments | « net/url_request/url_request_data_job.cc ('k') | ui/base/resource/resource_bundle.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698