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

Side by Side Diff: content/browser/debugger/devtools_manager.cc

Issue 7480028: Removal of Profile from content part 2. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 4 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/browser/debugger/devtools_manager.h" 5 #include "content/browser/debugger/devtools_manager.h"
6 6
7 #include <vector> 7 #include <vector>
8 8
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "chrome/browser/browser_process.h" 10 #include "chrome/browser/browser_process.h"
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 if (it->second.first == host) { 116 if (it->second.first == host) {
117 orphan_client_hosts_.erase(it->first); 117 orphan_client_hosts_.erase(it->first);
118 return; 118 return;
119 } 119 }
120 } 120 }
121 return; 121 return;
122 } 122 }
123 123
124 NotificationService::current()->Notify( 124 NotificationService::current()->Notify(
125 content::NOTIFICATION_DEVTOOLS_WINDOW_CLOSING, 125 content::NOTIFICATION_DEVTOOLS_WINDOW_CLOSING,
126 Source<Profile>(inspected_rvh->site_instance()->GetProcess()->profile()), 126 Source<content::BrowserContext>(
127 inspected_rvh->site_instance()->GetProcess()->browser_context()),
127 Details<RenderViewHost>(inspected_rvh)); 128 Details<RenderViewHost>(inspected_rvh));
128 129
129 UnbindClientHost(inspected_rvh, host); 130 UnbindClientHost(inspected_rvh, host);
130 } 131 }
131 132
132 void DevToolsManager::Observe(int type, 133 void DevToolsManager::Observe(int type,
133 const NotificationSource& source, 134 const NotificationSource& source,
134 const NotificationDetails& details) { 135 const NotificationDetails& details) {
135 DCHECK(type == content::NOTIFICATION_RENDER_VIEW_HOST_DELETED); 136 DCHECK(type == content::NOTIFICATION_RENDER_VIEW_HOST_DELETED);
136 UnregisterDevToolsClientHostFor(Source<RenderViewHost>(source).ptr()); 137 UnregisterDevToolsClientHostFor(Source<RenderViewHost>(source).ptr());
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after
291 for (InspectedRvhToClientHostMap::iterator it = 292 for (InspectedRvhToClientHostMap::iterator it =
292 inspected_rvh_to_client_host_.begin(); 293 inspected_rvh_to_client_host_.begin();
293 it != inspected_rvh_to_client_host_.end(); ++it) { 294 it != inspected_rvh_to_client_host_.end(); ++it) {
294 rhvs.push_back(it->first); 295 rhvs.push_back(it->first);
295 } 296 }
296 for (std::vector<RenderViewHost*>::iterator it = rhvs.begin(); 297 for (std::vector<RenderViewHost*>::iterator it = rhvs.begin();
297 it != rhvs.end(); ++it) { 298 it != rhvs.end(); ++it) {
298 UnregisterDevToolsClientHostFor(*it); 299 UnregisterDevToolsClientHostFor(*it);
299 } 300 }
300 } 301 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698