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

Side by Side Diff: content/browser/plugin_service_impl.cc

Issue 1308823002: Move Singleton and related structs to namespace base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: ToT Created 5 years, 3 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 (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 #include "content/browser/plugin_service_impl.h" 5 #include "content/browser/plugin_service_impl.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
145 for (RenderProcessHost::iterator it = RenderProcessHost::AllHostsIterator(); 145 for (RenderProcessHost::iterator it = RenderProcessHost::AllHostsIterator();
146 !it.IsAtEnd(); it.Advance()) { 146 !it.IsAtEnd(); it.Advance()) {
147 RenderProcessHost* host = it.GetCurrentValue(); 147 RenderProcessHost* host = it.GetCurrentValue();
148 if (!browser_context || host->GetBrowserContext() == browser_context) 148 if (!browser_context || host->GetBrowserContext() == browser_context)
149 host->Send(new ViewMsg_PurgePluginListCache(reload_pages)); 149 host->Send(new ViewMsg_PurgePluginListCache(reload_pages));
150 } 150 }
151 } 151 }
152 152
153 // static 153 // static
154 PluginServiceImpl* PluginServiceImpl::GetInstance() { 154 PluginServiceImpl* PluginServiceImpl::GetInstance() {
155 return Singleton<PluginServiceImpl>::get(); 155 return base::Singleton<PluginServiceImpl>::get();
156 } 156 }
157 157
158 PluginServiceImpl::PluginServiceImpl() 158 PluginServiceImpl::PluginServiceImpl()
159 : npapi_plugins_enabled_(false), filter_(NULL) { 159 : npapi_plugins_enabled_(false), filter_(NULL) {
160 // Collect the total number of browser processes (which create 160 // Collect the total number of browser processes (which create
161 // PluginServiceImpl objects, to be precise). The number is used to normalize 161 // PluginServiceImpl objects, to be precise). The number is used to normalize
162 // the number of processes which start at least one NPAPI/PPAPI Flash process. 162 // the number of processes which start at least one NPAPI/PPAPI Flash process.
163 static bool counted = false; 163 static bool counted = false;
164 if (!counted) { 164 if (!counted) {
165 counted = true; 165 counted = true;
(...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after
866 #endif 866 #endif
867 867
868 bool PluginServiceImpl::PpapiDevChannelSupported( 868 bool PluginServiceImpl::PpapiDevChannelSupported(
869 BrowserContext* browser_context, 869 BrowserContext* browser_context,
870 const GURL& document_url) { 870 const GURL& document_url) {
871 return GetContentClient()->browser()->IsPluginAllowedToUseDevChannelAPIs( 871 return GetContentClient()->browser()->IsPluginAllowedToUseDevChannelAPIs(
872 browser_context, document_url); 872 browser_context, document_url);
873 } 873 }
874 874
875 } // namespace content 875 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/plugin_service_impl.h ('k') | content/browser/power_profiler/power_profiler_service.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698