| 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 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 262 extension_id_, keys::kOnDetach, json_args, profile, GURL()); | 262 extension_id_, keys::kOnDetach, json_args, profile, GURL()); |
| 263 } | 263 } |
| 264 } | 264 } |
| 265 | 265 |
| 266 void ExtensionDevToolsClientHost::Observe( | 266 void ExtensionDevToolsClientHost::Observe( |
| 267 int type, | 267 int type, |
| 268 const content::NotificationSource& source, | 268 const content::NotificationSource& source, |
| 269 const content::NotificationDetails& details) { | 269 const content::NotificationDetails& details) { |
| 270 if (type == chrome::NOTIFICATION_EXTENSION_UNLOADED) { | 270 if (type == chrome::NOTIFICATION_EXTENSION_UNLOADED) { |
| 271 std::string id = | 271 std::string id = |
| 272 content::Details<UnloadedExtensionInfo>(details)->extension->id(); | 272 content::Details<extensions::UnloadedExtensionInfo>(details)-> |
| 273 extension->id(); |
| 273 if (id == extension_id_) | 274 if (id == extension_id_) |
| 274 Close(); | 275 Close(); |
| 275 } else { | 276 } else { |
| 276 DCHECK_EQ(chrome::NOTIFICATION_TAB_CONTENTS_INFOBAR_REMOVED, type); | 277 DCHECK_EQ(chrome::NOTIFICATION_TAB_CONTENTS_INFOBAR_REMOVED, type); |
| 277 if (content::Details<InfoBarRemovedDetails>(details)->first == | 278 if (content::Details<InfoBarRemovedDetails>(details)->first == |
| 278 infobar_delegate_) { | 279 infobar_delegate_) { |
| 279 infobar_delegate_ = NULL; | 280 infobar_delegate_ = NULL; |
| 280 SendDetachedEvent(); | 281 SendDetachedEvent(); |
| 281 Close(); | 282 Close(); |
| 282 } | 283 } |
| (...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 486 return; | 487 return; |
| 487 } | 488 } |
| 488 | 489 |
| 489 Value* result_body; | 490 Value* result_body; |
| 490 if (dictionary->Get("result", &result_body)) | 491 if (dictionary->Get("result", &result_body)) |
| 491 result_.reset(result_body->DeepCopy()); | 492 result_.reset(result_body->DeepCopy()); |
| 492 else | 493 else |
| 493 result_.reset(new DictionaryValue()); | 494 result_.reset(new DictionaryValue()); |
| 494 SendResponse(true); | 495 SendResponse(true); |
| 495 } | 496 } |
| OLD | NEW |