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

Side by Side Diff: content/renderer/devtools/devtools_agent.cc

Issue 1942523002: DevTools: render parsed manifest data in the resources panel. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments addressed Created 4 years, 7 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 | « no previous file | third_party/WebKit/Source/devtools/devtools.gypi » ('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 "content/renderer/devtools/devtools_agent.h" 5 #include "content/renderer/devtools/devtools_agent.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 8
9 #include <map> 9 #include <map>
10 10
(...skipping 287 matching lines...) Expand 10 before | Expand all | Expand 10 after
298 for (const auto& error : debug_info.errors) { 298 for (const auto& error : debug_info.errors) {
299 base::DictionaryValue* error_value = new base::DictionaryValue(); 299 base::DictionaryValue* error_value = new base::DictionaryValue();
300 errors->Append(error_value); 300 errors->Append(error_value);
301 error_value->SetString("message", error.message); 301 error_value->SetString("message", error.message);
302 error_value->SetBoolean("critical", error.critical); 302 error_value->SetBoolean("critical", error.critical);
303 error_value->SetInteger("line", error.line); 303 error_value->SetInteger("line", error.line);
304 error_value->SetInteger("column", error.column); 304 error_value->SetInteger("column", error.column);
305 if (error.critical) 305 if (error.critical)
306 failed = true; 306 failed = true;
307 } 307 }
308
309 WebString url = frame_->GetWebFrame()->document().manifestURL().string();
310 result->SetString("url", url);
308 if (!failed) 311 if (!failed)
309 result->SetString("data", debug_info.raw_data); 312 result->SetString("data", debug_info.raw_data);
310 result->Set("errors", errors.release()); 313 result->Set("errors", errors.release());
311 response->Set("result", result.release()); 314 response->Set("result", result.release());
312 315
313 std::string json_message; 316 std::string json_message;
314 base::JSONWriter::Write(*response, &json_message); 317 base::JSONWriter::Write(*response, &json_message);
315 SendChunkedProtocolMessage(this, routing_id(), session_id, call_id, 318 SendChunkedProtocolMessage(this, routing_id(), session_id, call_id,
316 json_message, std::string()); 319 json_message, std::string());
317 } 320 }
318 321
319 } // namespace content 322 } // namespace content
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/devtools/devtools.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698