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

Unified Diff: chrome/browser/extensions/api/debugger/debugger_api.cc

Issue 16295003: Update chrome/ to use scoped_refptr<T>::get() rather than implicit "operator T*" (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/api/debugger/debugger_api.cc
diff --git a/chrome/browser/extensions/api/debugger/debugger_api.cc b/chrome/browser/extensions/api/debugger/debugger_api.cc
index 3a52784d890d46a5accd416ae3649de11c7a89db..a4b98cb9b0cefc9ac9a8992a058efdb9f0ec3fec 100644
--- a/chrome/browser/extensions/api/debugger/debugger_api.cc
+++ b/chrome/browser/extensions/api/debugger/debugger_api.cc
@@ -407,8 +407,8 @@ ExtensionDevToolsClientHost::ExtensionDevToolsClientHost(
content::NotificationService::AllSources());
// Attach to debugger and tell it we are ready.
- DevToolsManager::GetInstance()->
- RegisterDevToolsClientHostFor(agent_host_, this);
+ DevToolsManager::GetInstance()->RegisterDevToolsClientHostFor(
+ agent_host_.get(), this);
if (infobar_delegate_) {
infobar_delegate_->AttachClientHost(this);
@@ -537,7 +537,7 @@ void ExtensionDevToolsClientHost::DispatchOnInspectorFrontend(
extensions::ExtensionSystem::Get(profile_)->event_router()->
DispatchEventToExtension(extension_id_, event.Pass());
} else {
- DebuggerSendCommandFunction* function = pending_requests_[id];
+ DebuggerSendCommandFunction* function = pending_requests_[id].get();
if (!function)
return;
@@ -599,7 +599,7 @@ bool DebuggerFunction::InitAgentHost() {
return false;
}
- if (!agent_host_) {
+ if (!agent_host_.get()) {
FormatErrorMessage(keys::kNoTargetError);
return false;
}
@@ -610,8 +610,8 @@ bool DebuggerFunction::InitClientHost() {
if (!InitAgentHost())
return false;
- client_host_ = AttachedClientHosts::GetInstance()->
- Lookup(agent_host_, GetExtension()->id());
+ client_host_ = AttachedClientHosts::GetInstance()->Lookup(
+ agent_host_.get(), GetExtension()->id());
if (!client_host_) {
FormatErrorMessage(keys::kNotAttachedError);
@@ -665,7 +665,7 @@ bool DebuggerAttachFunction::RunImpl() {
}
new ExtensionDevToolsClientHost(profile(),
- agent_host_,
+ agent_host_.get(),
GetExtension()->id(),
GetExtension()->name(),
debuggee_,

Powered by Google App Engine
This is Rietveld 408576698