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

Side by Side Diff: content/browser/devtools/service_worker_devtools_manager.cc

Issue 2654993006: Show service worker navigation preload requests in DevTools Network tab. (Closed)
Patch Set: incorporated pfeldman's comment Created 3 years, 11 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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/devtools/service_worker_devtools_manager.h" 5 #include "content/browser/devtools/service_worker_devtools_manager.h"
6 6
7 #include "content/browser/devtools/devtools_agent_host_impl.h" 7 #include "content/browser/devtools/devtools_agent_host_impl.h"
8 #include "content/browser/devtools/service_worker_devtools_agent_host.h" 8 #include "content/browser/devtools/service_worker_devtools_agent_host.h"
9 #include "content/public/browser/browser_thread.h" 9 #include "content/public/browser/browser_thread.h"
10 #include "content/public/browser/render_process_host.h" 10 #include "content/public/browser/render_process_host.h"
(...skipping 30 matching lines...) Expand all
41 const ServiceWorkerIdentifier& other) const { 41 const ServiceWorkerIdentifier& other) const {
42 return context_ == other.context_ && version_id_ == other.version_id_; 42 return context_ == other.context_ && version_id_ == other.version_id_;
43 } 43 }
44 44
45 // static 45 // static
46 ServiceWorkerDevToolsManager* ServiceWorkerDevToolsManager::GetInstance() { 46 ServiceWorkerDevToolsManager* ServiceWorkerDevToolsManager::GetInstance() {
47 DCHECK_CURRENTLY_ON(BrowserThread::UI); 47 DCHECK_CURRENTLY_ON(BrowserThread::UI);
48 return base::Singleton<ServiceWorkerDevToolsManager>::get(); 48 return base::Singleton<ServiceWorkerDevToolsManager>::get();
49 } 49 }
50 50
51 DevToolsAgentHostImpl* 51 ServiceWorkerDevToolsAgentHost*
52 ServiceWorkerDevToolsManager::GetDevToolsAgentHostForWorker( 52 ServiceWorkerDevToolsManager::GetDevToolsAgentHostForWorker(
53 int worker_process_id, 53 int worker_process_id,
54 int worker_route_id) { 54 int worker_route_id) {
55 AgentHostMap::iterator it = workers_.find( 55 AgentHostMap::iterator it = workers_.find(
56 WorkerId(worker_process_id, worker_route_id)); 56 WorkerId(worker_process_id, worker_route_id));
57 return it == workers_.end() ? NULL : it->second; 57 return it == workers_.end() ? NULL : it->second;
58 } 58 }
59 59
60 void ServiceWorkerDevToolsManager::AddAllAgentHosts( 60 void ServiceWorkerDevToolsManager::AddAllAgentHosts(
61 ServiceWorkerDevToolsAgentHost::List* result) { 61 ServiceWorkerDevToolsAgentHost::List* result) {
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
196 break; 196 break;
197 } 197 }
198 return it; 198 return it;
199 } 199 }
200 200
201 void ServiceWorkerDevToolsManager::ResetForTesting() { 201 void ServiceWorkerDevToolsManager::ResetForTesting() {
202 workers_.clear(); 202 workers_.clear();
203 } 203 }
204 204
205 } // namespace content 205 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/devtools/service_worker_devtools_manager.h ('k') | content/browser/loader/resource_dispatcher_host_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698