| OLD | NEW |
| 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 // Implements the Chrome Extensions Debugger API. | 5 // Implements the Chrome Extensions Debugger API. |
| 6 | 6 |
| 7 #include "chrome/browser/extensions/extension_debugger_api.h" | 7 #include "chrome/browser/extensions/extension_debugger_api.h" |
| 8 | 8 |
| 9 #include <map> | 9 #include <map> |
| 10 #include <set> | 10 #include <set> |
| (...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 478 DictionaryValue* dictionary) { | 478 DictionaryValue* dictionary) { |
| 479 Value* error_body; | 479 Value* error_body; |
| 480 if (dictionary->Get("error", &error_body)) { | 480 if (dictionary->Get("error", &error_body)) { |
| 481 base::JSONWriter::Write(error_body, &error_); | 481 base::JSONWriter::Write(error_body, &error_); |
| 482 SendResponse(false); | 482 SendResponse(false); |
| 483 return; | 483 return; |
| 484 } | 484 } |
| 485 | 485 |
| 486 Value* result_body; | 486 Value* result_body; |
| 487 if (dictionary->Get("result", &result_body)) | 487 if (dictionary->Get("result", &result_body)) |
| 488 result_.reset(result_body->DeepCopy()); | 488 SetSingleResult(result_body->DeepCopy()); |
| 489 else | 489 else |
| 490 result_.reset(new DictionaryValue()); | 490 SetSingleResult(new DictionaryValue()); |
| 491 SendResponse(true); | 491 SendResponse(true); |
| 492 } | 492 } |
| OLD | NEW |