summaryrefslogtreecommitdiffstats
path: root/chrome/browser
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/browser')
-rw-r--r--chrome/browser/about_flags.cc12
-rw-r--r--chrome/browser/background_page_tracker.cc2
-rw-r--r--chrome/browser/background_page_tracker.h2
-rw-r--r--chrome/browser/browser_about_handler.cc8
-rw-r--r--chrome/browser/browser_main.cc5
-rw-r--r--chrome/browser/browser_process_impl.cc6
-rw-r--r--chrome/browser/browser_shutdown.cc2
-rw-r--r--chrome/browser/cert_store.cc2
-rw-r--r--chrome/browser/cert_store.h2
-rw-r--r--chrome/browser/certificate_viewer.cc2
-rw-r--r--chrome/browser/chrome_plugin_browsing_context.cc2
-rw-r--r--chrome/browser/chrome_plugin_browsing_context.h2
-rw-r--r--chrome/browser/chrome_plugin_host.cc6
-rw-r--r--chrome/browser/chromeos/gview_request_interceptor.cc2
-rw-r--r--chrome/browser/chromeos/gview_request_interceptor.h2
-rw-r--r--chrome/browser/chromeos/gview_request_interceptor_unittest.cc2
-rw-r--r--chrome/browser/dom_ui/conflicts_ui.cc4
-rw-r--r--chrome/browser/dom_ui/plugins_ui.cc4
-rw-r--r--chrome/browser/enumerate_modules_model_win.cc5
-rw-r--r--chrome/browser/enumerate_modules_model_win.h4
-rw-r--r--chrome/browser/extensions/extension_bookmarks_module.cc2
-rw-r--r--chrome/browser/extensions/extension_bookmarks_module.h2
-rw-r--r--chrome/browser/extensions/extension_function_dispatcher.cc12
-rw-r--r--chrome/browser/extensions/extension_host.cc6
-rw-r--r--chrome/browser/extensions/extensions_service.cc2
-rw-r--r--chrome/browser/gpu_process_host.cc2
-rw-r--r--chrome/browser/gpu_process_host_ui_shim.cc2
-rw-r--r--chrome/browser/gpu_process_host_ui_shim.h2
-rw-r--r--chrome/browser/metrics/metrics_log.cc10
-rw-r--r--chrome/browser/net/metadata_url_request.cc2
-rw-r--r--chrome/browser/page_info_model.cc2
-rw-r--r--chrome/browser/parsers/metadata_parser_manager.cc11
-rw-r--r--chrome/browser/parsers/metadata_parser_manager.h2
-rw-r--r--chrome/browser/plugin_process_host.cc5
-rw-r--r--chrome/browser/plugin_service.cc2
-rw-r--r--chrome/browser/plugin_updater.cc6
-rw-r--r--chrome/browser/plugin_updater.h2
-rw-r--r--chrome/browser/printing/cloud_print/cloud_print_proxy_service.cc8
-rw-r--r--chrome/browser/remoting/remoting_setup_flow.cc2
-rw-r--r--chrome/browser/renderer_host/browser_render_process_host.cc3
-rw-r--r--chrome/browser/renderer_host/resource_dispatcher_host.cc10
-rw-r--r--chrome/browser/renderer_host/resource_message_filter.cc2
-rw-r--r--chrome/browser/service/service_process_control_browsertest.cc10
-rw-r--r--chrome/browser/service/service_process_control_manager.cc2
-rw-r--r--chrome/browser/service/service_process_control_manager.h2
-rw-r--r--chrome/browser/ssl/ssl_blocking_page.cc2
-rw-r--r--chrome/browser/ssl/ssl_error_info.cc2
-rw-r--r--chrome/browser/ui/browser_init.cc2
-rw-r--r--chrome/browser/ui/cocoa/about_ipc_controller.mm9
-rw-r--r--chrome/browser/ui/cocoa/page_info_bubble_controller.mm2
-rw-r--r--chrome/browser/ui/toolbar/toolbar_model.cc4
-rw-r--r--chrome/browser/ui/toolbar/wrench_menu_model.cc14
-rw-r--r--chrome/browser/ui/views/about_ipc_dialog.cc4
-rw-r--r--chrome/browser/ui/views/accessible_pane_view.cc2
-rw-r--r--chrome/browser/ui/views/frame/browser_view.cc4
-rw-r--r--chrome/browser/ui/views/html_dialog_view_browsertest.cc10
-rw-r--r--chrome/browser/ui/views/page_info_bubble_view.cc2
-rw-r--r--chrome/browser/ui/views/tab_contents/tab_contents_view_gtk.cc8
-rw-r--r--chrome/browser/ui/views/tab_contents/tab_contents_view_win.cc8
-rw-r--r--chrome/browser/ui/views/toolbar_view.cc8
60 files changed, 139 insertions, 129 deletions
diff --git a/chrome/browser/about_flags.cc b/chrome/browser/about_flags.cc
index 15d9cb2..b87f4217a 100644
--- a/chrome/browser/about_flags.cc
+++ b/chrome/browser/about_flags.cc
@@ -305,7 +305,7 @@ class FlagsState {
void reset();
// Returns the singleton instance of this class
- static FlagsState* instance() {
+ static FlagsState* GetInstance() {
return Singleton<FlagsState>::get();
}
@@ -467,7 +467,7 @@ Value* CreateChoiceData(const Experiment& experiment,
} // namespace
void ConvertFlagsToSwitches(PrefService* prefs, CommandLine* command_line) {
- FlagsState::instance()->ConvertFlagsToSwitches(prefs, command_line);
+ FlagsState::GetInstance()->ConvertFlagsToSwitches(prefs, command_line);
}
ListValue* GetFlagsExperimentsData(PrefService* prefs) {
@@ -504,17 +504,17 @@ ListValue* GetFlagsExperimentsData(PrefService* prefs) {
}
bool IsRestartNeededToCommitChanges() {
- return FlagsState::instance()->IsRestartNeededToCommitChanges();
+ return FlagsState::GetInstance()->IsRestartNeededToCommitChanges();
}
void SetExperimentEnabled(
PrefService* prefs, const std::string& internal_name, bool enable) {
- FlagsState::instance()->SetExperimentEnabled(prefs, internal_name, enable);
+ FlagsState::GetInstance()->SetExperimentEnabled(prefs, internal_name, enable);
}
void RemoveFlagsSwitches(
std::map<std::string, CommandLine::StringType>* switch_list) {
- FlagsState::instance()->RemoveFlagsSwitches(switch_list);
+ FlagsState::GetInstance()->RemoveFlagsSwitches(switch_list);
}
int GetCurrentPlatform() {
@@ -683,7 +683,7 @@ namespace testing {
const char kMultiSeparator[] = "@";
void ClearState() {
- FlagsState::instance()->reset();
+ FlagsState::GetInstance()->reset();
}
void SetExperiments(const Experiment* e, size_t count) {
diff --git a/chrome/browser/background_page_tracker.cc b/chrome/browser/background_page_tracker.cc
index 0cd2a4c..75fe3c9b 100644
--- a/chrome/browser/background_page_tracker.cc
+++ b/chrome/browser/background_page_tracker.cc
@@ -42,7 +42,7 @@ void BackgroundPageTracker::RegisterPrefs(PrefService* prefs) {
}
// static
-BackgroundPageTracker* BackgroundPageTracker::GetSingleton() {
+BackgroundPageTracker* BackgroundPageTracker::GetInstance() {
return Singleton<BackgroundPageTracker>::get();
}
diff --git a/chrome/browser/background_page_tracker.h b/chrome/browser/background_page_tracker.h
index 2b3b90c..e66c961 100644
--- a/chrome/browser/background_page_tracker.h
+++ b/chrome/browser/background_page_tracker.h
@@ -27,7 +27,7 @@ class BackgroundPageTracker : public NotificationObserver {
static void RegisterPrefs(PrefService* prefs);
// Convenience routine which gets the singleton object.
- static BackgroundPageTracker* GetSingleton();
+ static BackgroundPageTracker* GetInstance();
// Returns the number of background apps/extensions currently loaded.
int GetBackgroundPageCount();
diff --git a/chrome/browser/browser_about_handler.cc b/chrome/browser/browser_about_handler.cc
index d37a100..d76163c 100644
--- a/chrome/browser/browser_about_handler.cc
+++ b/chrome/browser/browser_about_handler.cc
@@ -764,14 +764,14 @@ void DxDiagNodeToHTML(std::string* output, const DxDiagNode& node) {
}
std::string AboutGpu() {
- const GPUInfo& gpu_info = GpuProcessHostUIShim::Get()->gpu_info();
+ const GPUInfo& gpu_info = GpuProcessHostUIShim::GetInstance()->gpu_info();
std::string html;
html.append("<html><head><title>About GPU</title></head>\n");
if (gpu_info.progress() != GPUInfo::kComplete) {
- GpuProcessHostUIShim::Get()->CollectGraphicsInfoAsynchronously();
+ GpuProcessHostUIShim::GetInstance()->CollectGraphicsInfoAsynchronously();
// If it's not fully initialized yet, set a timeout to reload the page.
html.append("<body onload=\"setTimeout('window.location.reload(true)',");
@@ -1166,11 +1166,11 @@ bool WillHandleBrowserAboutURL(GURL* url, Profile* profile) {
// Handle URLs to wreck the gpu process.
if (LowerCaseEqualsASCII(url->spec(), chrome::kAboutGpuCrashURL)) {
- GpuProcessHostUIShim::Get()->SendAboutGpuCrash();
+ GpuProcessHostUIShim::GetInstance()->SendAboutGpuCrash();
return true;
}
if (LowerCaseEqualsASCII(url->spec(), chrome::kAboutGpuHangURL)) {
- GpuProcessHostUIShim::Get()->SendAboutGpuHang();
+ GpuProcessHostUIShim::GetInstance()->SendAboutGpuHang();
return true;
}
diff --git a/chrome/browser/browser_main.cc b/chrome/browser/browser_main.cc
index 82c2ac2..d5b6d7f 100644
--- a/chrome/browser/browser_main.cc
+++ b/chrome/browser/browser_main.cc
@@ -1598,8 +1598,9 @@ int BrowserMain(const MainFunctionParams& parameters) {
// TODO(hclam): Need to check for cloud print proxy too.
if (parsed_command_line.HasSwitch(switches::kEnableRemoting)) {
if (user_prefs->GetBoolean(prefs::kRemotingHasSetupCompleted)) {
- ServiceProcessControl* control = ServiceProcessControlManager::instance()
- ->GetProcessControl(profile);
+ ServiceProcessControl* control =
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(
+ profile);
control->Launch(NULL, NULL);
}
}
diff --git a/chrome/browser/browser_process_impl.cc b/chrome/browser/browser_process_impl.cc
index ea52797..53d44d8 100644
--- a/chrome/browser/browser_process_impl.cc
+++ b/chrome/browser/browser_process_impl.cc
@@ -657,7 +657,7 @@ void BrowserProcessImpl::CreateLocalState() {
// in the plugin blacklist.
local_state_->RegisterListPref(prefs::kPluginsPluginsBlacklist);
pref_change_registrar_.Add(prefs::kPluginsPluginsBlacklist,
- PluginUpdater::GetPluginUpdater());
+ PluginUpdater::GetInstance());
// Initialize and set up notifications for the printing enabled
// preference.
@@ -764,9 +764,9 @@ DISABLE_RUNNABLE_METHOD_REFCOUNT(BrowserProcessImpl);
void BrowserProcessImpl::SetIPCLoggingEnabled(bool enable) {
// First enable myself.
if (enable)
- IPC::Logging::current()->Enable();
+ IPC::Logging::GetInstance()->Enable();
else
- IPC::Logging::current()->Disable();
+ IPC::Logging::GetInstance()->Disable();
// Now tell subprocesses. Messages to ChildProcess-derived
// processes must be done on the IO thread.
diff --git a/chrome/browser/browser_shutdown.cc b/chrome/browser/browser_shutdown.cc
index e136ef8..d115cf5 100644
--- a/chrome/browser/browser_shutdown.cc
+++ b/chrome/browser/browser_shutdown.cc
@@ -121,7 +121,7 @@ void Shutdown() {
NewRunnableFunction(&ChromePluginLib::UnloadAllPlugins));
// Shutdown all IPC channels to service processes.
- ServiceProcessControlManager::instance()->Shutdown();
+ ServiceProcessControlManager::GetInstance()->Shutdown();
// WARNING: During logoff/shutdown (WM_ENDSESSION) we may not have enough
// time to get here. If you have something that *must* happen on end session,
diff --git a/chrome/browser/cert_store.cc b/chrome/browser/cert_store.cc
index 8c2d021..30ef867 100644
--- a/chrome/browser/cert_store.cc
+++ b/chrome/browser/cert_store.cc
@@ -24,7 +24,7 @@ struct MatchSecond {
};
// static
-CertStore* CertStore::GetSharedInstance() {
+CertStore* CertStore::GetInstance() {
return Singleton<CertStore>::get();
}
diff --git a/chrome/browser/cert_store.h b/chrome/browser/cert_store.h
index fc17501..0af7ef4 100644
--- a/chrome/browser/cert_store.h
+++ b/chrome/browser/cert_store.h
@@ -27,7 +27,7 @@
class CertStore : public NotificationObserver {
public:
// Returns the singleton instance of the CertStore.
- static CertStore* GetSharedInstance();
+ static CertStore* GetInstance();
// Stores the specified cert and returns the id associated with it. The cert
// is associated to the specified RenderProcessHost.
diff --git a/chrome/browser/certificate_viewer.cc b/chrome/browser/certificate_viewer.cc
index 677c81f..73cc4d5c 100644
--- a/chrome/browser/certificate_viewer.cc
+++ b/chrome/browser/certificate_viewer.cc
@@ -8,7 +8,7 @@
void ShowCertificateViewerByID(gfx::NativeWindow parent, int cert_id) {
scoped_refptr<net::X509Certificate> cert;
- CertStore::GetSharedInstance()->RetrieveCert(cert_id, &cert);
+ CertStore::GetInstance()->RetrieveCert(cert_id, &cert);
if (!cert.get()) {
// The certificate was not found. Could be that the renderer crashed before
// we displayed the page info.
diff --git a/chrome/browser/chrome_plugin_browsing_context.cc b/chrome/browser/chrome_plugin_browsing_context.cc
index 34fe815..3ff4729 100644
--- a/chrome/browser/chrome_plugin_browsing_context.cc
+++ b/chrome/browser/chrome_plugin_browsing_context.cc
@@ -9,7 +9,7 @@
#include "chrome/browser/browser_thread.h"
#include "chrome/common/notification_service.h"
-CPBrowsingContextManager* CPBrowsingContextManager::Instance() {
+CPBrowsingContextManager* CPBrowsingContextManager::GetInstance() {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::IO));
return Singleton<CPBrowsingContextManager>::get();
}
diff --git a/chrome/browser/chrome_plugin_browsing_context.h b/chrome/browser/chrome_plugin_browsing_context.h
index ef31262..45d24f3 100644
--- a/chrome/browser/chrome_plugin_browsing_context.h
+++ b/chrome/browser/chrome_plugin_browsing_context.h
@@ -23,7 +23,7 @@ class URLRequestContext;
// Note: This class should be used on the IO thread only.
class CPBrowsingContextManager : public NotificationObserver {
public:
- static CPBrowsingContextManager* Instance();
+ static CPBrowsingContextManager* GetInstance();
// Note: don't call these directly - use Instance() above. They are public
// so Singleton can access them.
diff --git a/chrome/browser/chrome_plugin_host.cc b/chrome/browser/chrome_plugin_host.cc
index 9248036..b339b46 100644
--- a/chrome/browser/chrome_plugin_host.cc
+++ b/chrome/browser/chrome_plugin_host.cc
@@ -109,7 +109,7 @@ class PluginRequestInterceptor
return NULL;
CPBrowsingContext context =
- CPBrowsingContextManager::Instance()->Lookup(request->context());
+ CPBrowsingContextManager::GetInstance()->Lookup(request->context());
scoped_ptr<ScopableCPRequest> cprequest(
new ScopableCPRequest(request->url().spec().c_str(),
request->method().c_str(),
@@ -156,7 +156,7 @@ class PluginRequestHandler : public PluginHelper,
: PluginHelper(plugin), cprequest_(cprequest), user_buffer_(NULL) {
cprequest_->data = this; // see FromCPRequest().
- URLRequestContext* context = CPBrowsingContextManager::Instance()->
+ URLRequestContext* context = CPBrowsingContextManager::GetInstance()->
ToURLRequestContext(cprequest_->context);
// TODO(mpcomplete): remove fallback case when Gears support is prevalent.
if (!context)
@@ -386,7 +386,7 @@ void STDCALL CPB_SetKeepProcessAlive(CPID id, CPBool keep_alive) {
CPError STDCALL CPB_GetCookies(CPID id, CPBrowsingContext bcontext,
const char* url, char** cookies) {
CHECK(ChromePluginLib::IsPluginThread());
- URLRequestContext* context = CPBrowsingContextManager::Instance()->
+ URLRequestContext* context = CPBrowsingContextManager::GetInstance()->
ToURLRequestContext(bcontext);
// TODO(mpcomplete): remove fallback case when Gears support is prevalent.
if (!context) {
diff --git a/chrome/browser/chromeos/gview_request_interceptor.cc b/chrome/browser/chromeos/gview_request_interceptor.cc
index 69f97b2a..f656a8d 100644
--- a/chrome/browser/chromeos/gview_request_interceptor.cc
+++ b/chrome/browser/chromeos/gview_request_interceptor.cc
@@ -81,7 +81,7 @@ net::URLRequestJob* GViewRequestInterceptor::MaybeInterceptResponse(
}
net::URLRequest::Interceptor*
-GViewRequestInterceptor::GetGViewRequestInterceptor() {
+GViewRequestInterceptor::GetInstance() {
return Singleton<GViewRequestInterceptor>::get();
}
diff --git a/chrome/browser/chromeos/gview_request_interceptor.h b/chrome/browser/chromeos/gview_request_interceptor.h
index a8b8250..0a1691b 100644
--- a/chrome/browser/chromeos/gview_request_interceptor.h
+++ b/chrome/browser/chromeos/gview_request_interceptor.h
@@ -32,7 +32,7 @@ class GViewRequestInterceptor : public net::URLRequest::Interceptor {
virtual net::URLRequestJob* MaybeInterceptResponse(net::URLRequest* request);
// Singleton accessor.
- static net::URLRequest::Interceptor* GetGViewRequestInterceptor();
+ static net::URLRequest::Interceptor* GetInstance();
private:
friend struct DefaultSingletonTraits<GViewRequestInterceptor>;
diff --git a/chrome/browser/chromeos/gview_request_interceptor_unittest.cc b/chrome/browser/chromeos/gview_request_interceptor_unittest.cc
index ac72746..ef66061 100644
--- a/chrome/browser/chromeos/gview_request_interceptor_unittest.cc
+++ b/chrome/browser/chromeos/gview_request_interceptor_unittest.cc
@@ -51,7 +51,7 @@ class GViewRequestInterceptorTest : public testing::Test {
virtual void SetUp() {
net::URLRequest::RegisterProtocolFactory("http",
&GViewRequestInterceptorTest::Factory);
- interceptor_ = GViewRequestInterceptor::GetGViewRequestInterceptor();
+ interceptor_ = GViewRequestInterceptor::GetInstance();
ASSERT_TRUE(PathService::Get(chrome::FILE_PDF_PLUGIN, &pdf_path_));
}
diff --git a/chrome/browser/dom_ui/conflicts_ui.cc b/chrome/browser/dom_ui/conflicts_ui.cc
index 8e2bcae..ed51f21 100644
--- a/chrome/browser/dom_ui/conflicts_ui.cc
+++ b/chrome/browser/dom_ui/conflicts_ui.cc
@@ -142,11 +142,11 @@ void ConflictsDOMHandler::HandleRequestModuleList(const ListValue* args) {
// This request is handled asynchronously. See Observe for when we reply back.
registrar_.Add(this, NotificationType::MODULE_LIST_ENUMERATED,
NotificationService::AllSources());
- EnumerateModulesModel::GetSingleton()->ScanNow();
+ EnumerateModulesModel::GetInstance()->ScanNow();
}
void ConflictsDOMHandler::SendModuleList() {
- EnumerateModulesModel* loaded_modules = EnumerateModulesModel::GetSingleton();
+ EnumerateModulesModel* loaded_modules = EnumerateModulesModel::GetInstance();
ListValue* list = loaded_modules->GetModuleList();
DictionaryValue results;
results.Set("moduleList", list);
diff --git a/chrome/browser/dom_ui/plugins_ui.cc b/chrome/browser/dom_ui/plugins_ui.cc
index 62564bd..6746fdd 100644
--- a/chrome/browser/dom_ui/plugins_ui.cc
+++ b/chrome/browser/dom_ui/plugins_ui.cc
@@ -214,7 +214,7 @@ void PluginsDOMHandler::HandleEnablePluginMessage(const ListValue* args) {
return;
bool enable = enable_str == "true";
- PluginUpdater* plugin_updater = PluginUpdater::GetPluginUpdater();
+ PluginUpdater* plugin_updater = PluginUpdater::GetInstance();
if (is_group_str == "true") {
string16 group_name;
if (!args->GetString(0, &group_name))
@@ -262,7 +262,7 @@ void PluginsDOMHandler::Observe(NotificationType type,
void PluginsDOMHandler::LoadPluginsOnFileThread(ListWrapper* wrapper,
Task* task) {
- wrapper->list = PluginUpdater::GetPluginUpdater()->GetPluginGroupsData();
+ wrapper->list = PluginUpdater::GetInstance()->GetPluginGroupsData();
BrowserThread::PostTask(BrowserThread::UI, FROM_HERE, task);
BrowserThread::PostTask(
BrowserThread::UI,
diff --git a/chrome/browser/enumerate_modules_model_win.cc b/chrome/browser/enumerate_modules_model_win.cc
index b521b6c..24ded4e 100644
--- a/chrome/browser/enumerate_modules_model_win.cc
+++ b/chrome/browser/enumerate_modules_model_win.cc
@@ -672,6 +672,11 @@ string16 ModuleEnumerator::GetSubjectNameFromDigitalSignature(
// ----------------------------------------------------------------------------
+// static
+EnumerateModulesModel* EnumerateModulesModel::GetInstance() {
+ return Singleton<EnumerateModulesModel>::get();
+}
+
void EnumerateModulesModel::ScanNow() {
if (scanning_)
return; // A scan is already in progress.
diff --git a/chrome/browser/enumerate_modules_model_win.h b/chrome/browser/enumerate_modules_model_win.h
index 9000a6c..a4479c4 100644
--- a/chrome/browser/enumerate_modules_model_win.h
+++ b/chrome/browser/enumerate_modules_model_win.h
@@ -218,9 +218,7 @@ class ModuleEnumerator : public base::RefCountedThreadSafe<ModuleEnumerator> {
// notification.
class EnumerateModulesModel {
public:
- static EnumerateModulesModel* GetSingleton() {
- return Singleton<EnumerateModulesModel>::get();
- }
+ static EnumerateModulesModel* GetInstance();
// Returns the number of suspected bad modules found in the last scan.
// Returns 0 if no scan has taken place yet.
diff --git a/chrome/browser/extensions/extension_bookmarks_module.cc b/chrome/browser/extensions/extension_bookmarks_module.cc
index c67482a..180a5bb 100644
--- a/chrome/browser/extensions/extension_bookmarks_module.cc
+++ b/chrome/browser/extensions/extension_bookmarks_module.cc
@@ -75,7 +75,7 @@ void BookmarksFunction::Observe(NotificationType type,
}
// static
-ExtensionBookmarkEventRouter* ExtensionBookmarkEventRouter::GetSingleton() {
+ExtensionBookmarkEventRouter* ExtensionBookmarkEventRouter::GetInstance() {
return Singleton<ExtensionBookmarkEventRouter>::get();
}
diff --git a/chrome/browser/extensions/extension_bookmarks_module.h b/chrome/browser/extensions/extension_bookmarks_module.h
index 10fe373..21b9ad8 100644
--- a/chrome/browser/extensions/extension_bookmarks_module.h
+++ b/chrome/browser/extensions/extension_bookmarks_module.h
@@ -21,7 +21,7 @@
// the extension system.
class ExtensionBookmarkEventRouter : public BookmarkModelObserver {
public:
- static ExtensionBookmarkEventRouter* GetSingleton();
+ static ExtensionBookmarkEventRouter* GetInstance();
virtual ~ExtensionBookmarkEventRouter();
// Call this for each model to observe. Safe to call multiple times per
diff --git a/chrome/browser/extensions/extension_function_dispatcher.cc b/chrome/browser/extensions/extension_function_dispatcher.cc
index ec4b9d5..9d9654c 100644
--- a/chrome/browser/extensions/extension_function_dispatcher.cc
+++ b/chrome/browser/extensions/extension_function_dispatcher.cc
@@ -75,7 +75,7 @@ ExtensionFunction* NewExtensionFunction() {
// create instances of them.
class FactoryRegistry {
public:
- static FactoryRegistry* instance();
+ static FactoryRegistry* GetInstance();
FactoryRegistry() { ResetFunctions(); }
// Resets all functions to their default values.
@@ -102,7 +102,7 @@ class FactoryRegistry {
FactoryMap factories_;
};
-FactoryRegistry* FactoryRegistry::instance() {
+FactoryRegistry* FactoryRegistry::GetInstance() {
return Singleton<FactoryRegistry>::get();
}
@@ -325,16 +325,16 @@ ExtensionFunction* FactoryRegistry::NewFunction(const std::string& name) {
void ExtensionFunctionDispatcher::GetAllFunctionNames(
std::vector<std::string>* names) {
- FactoryRegistry::instance()->GetAllNames(names);
+ FactoryRegistry::GetInstance()->GetAllNames(names);
}
bool ExtensionFunctionDispatcher::OverrideFunction(
const std::string& name, ExtensionFunctionFactory factory) {
- return FactoryRegistry::instance()->OverrideFunction(name, factory);
+ return FactoryRegistry::GetInstance()->OverrideFunction(name, factory);
}
void ExtensionFunctionDispatcher::ResetFunctions() {
- FactoryRegistry::instance()->ResetFunctions();
+ FactoryRegistry::GetInstance()->ResetFunctions();
}
ExtensionFunctionDispatcher* ExtensionFunctionDispatcher::Create(
@@ -444,7 +444,7 @@ Browser* ExtensionFunctionDispatcher::GetCurrentBrowser(
void ExtensionFunctionDispatcher::HandleRequest(
const ViewHostMsg_DomMessage_Params& params) {
scoped_refptr<ExtensionFunction> function(
- FactoryRegistry::instance()->NewFunction(params.name));
+ FactoryRegistry::GetInstance()->NewFunction(params.name));
function->set_dispatcher_peer(peer_);
function->set_profile(profile_);
function->set_extension_id(extension_id());
diff --git a/chrome/browser/extensions/extension_host.cc b/chrome/browser/extensions/extension_host.cc
index f052573..2d99c88 100644
--- a/chrome/browser/extensions/extension_host.cc
+++ b/chrome/browser/extensions/extension_host.cc
@@ -66,7 +66,7 @@ bool ExtensionHost::enable_dom_automation_ = false;
// ExtensionHosts, to avoid blocking the UI.
class ExtensionHost::ProcessCreationQueue {
public:
- static ProcessCreationQueue* get() {
+ static ProcessCreationQueue* GetInstance() {
return Singleton<ProcessCreationQueue>::get();
}
@@ -155,7 +155,7 @@ ExtensionHost::~ExtensionHost() {
NotificationType::EXTENSION_HOST_DESTROYED,
Source<Profile>(profile_),
Details<ExtensionHost>(this));
- ProcessCreationQueue::get()->Remove(this);
+ ProcessCreationQueue::GetInstance()->Remove(this);
render_view_host_->Shutdown(); // deletes render_view_host
}
@@ -197,7 +197,7 @@ void ExtensionHost::CreateRenderViewSoon(RenderWidgetHostView* host_view) {
// to defer.
CreateRenderViewNow();
} else {
- ProcessCreationQueue::get()->CreateSoon(this);
+ ProcessCreationQueue::GetInstance()->CreateSoon(this);
}
}
diff --git a/chrome/browser/extensions/extensions_service.cc b/chrome/browser/extensions/extensions_service.cc
index 73955fc..e807637 100644
--- a/chrome/browser/extensions/extensions_service.cc
+++ b/chrome/browser/extensions/extensions_service.cc
@@ -612,7 +612,7 @@ void ExtensionsService::InitEventRouters() {
ExtensionHistoryEventRouter::GetInstance()->ObserveProfile(profile_);
ExtensionAccessibilityEventRouter::GetInstance()->ObserveProfile(profile_);
ExtensionBrowserEventRouter::GetInstance()->Init(profile_);
- ExtensionBookmarkEventRouter::GetSingleton()->Observe(
+ ExtensionBookmarkEventRouter::GetInstance()->Observe(
profile_->GetBookmarkModel());
ExtensionCookiesEventRouter::GetInstance()->Init();
ExtensionManagementEventRouter::GetInstance()->Init();
diff --git a/chrome/browser/gpu_process_host.cc b/chrome/browser/gpu_process_host.cc
index b9d1103..8626fde 100644
--- a/chrome/browser/gpu_process_host.cc
+++ b/chrome/browser/gpu_process_host.cc
@@ -52,7 +52,7 @@ class RouteOnUIThreadTask : public Task {
private:
void Run() {
- GpuProcessHostUIShim::Get()->OnMessageReceived(msg_);
+ GpuProcessHostUIShim::GetInstance()->OnMessageReceived(msg_);
}
IPC::Message msg_;
};
diff --git a/chrome/browser/gpu_process_host_ui_shim.cc b/chrome/browser/gpu_process_host_ui_shim.cc
index d8257a8..f864634 100644
--- a/chrome/browser/gpu_process_host_ui_shim.cc
+++ b/chrome/browser/gpu_process_host_ui_shim.cc
@@ -34,7 +34,7 @@ GpuProcessHostUIShim::~GpuProcessHostUIShim() {
}
// static
-GpuProcessHostUIShim* GpuProcessHostUIShim::Get() {
+GpuProcessHostUIShim* GpuProcessHostUIShim::GetInstance() {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
return Singleton<GpuProcessHostUIShim>::get();
}
diff --git a/chrome/browser/gpu_process_host_ui_shim.h b/chrome/browser/gpu_process_host_ui_shim.h
index eda33d2..8b09067 100644
--- a/chrome/browser/gpu_process_host_ui_shim.h
+++ b/chrome/browser/gpu_process_host_ui_shim.h
@@ -23,7 +23,7 @@ class GpuProcessHostUIShim : public IPC::Channel::Sender,
public NonThreadSafe {
public:
// Getter for the singleton. This will return NULL on failure.
- static GpuProcessHostUIShim* Get();
+ static GpuProcessHostUIShim* GetInstance();
int32 GetNextRoutingId();
diff --git a/chrome/browser/metrics/metrics_log.cc b/chrome/browser/metrics/metrics_log.cc
index e21f075..d0a1f01 100644
--- a/chrome/browser/metrics/metrics_log.cc
+++ b/chrome/browser/metrics/metrics_log.cc
@@ -300,10 +300,12 @@ void MetricsLog::RecordEnvironment(
{
OPEN_ELEMENT_FOR_SCOPE("gpu");
- WriteIntAttribute("vendorid",
- GpuProcessHostUIShim::Get()->gpu_info().vendor_id());
- WriteIntAttribute("deviceid",
- GpuProcessHostUIShim::Get()->gpu_info().device_id());
+ WriteIntAttribute(
+ "vendorid",
+ GpuProcessHostUIShim::GetInstance()->gpu_info().vendor_id());
+ WriteIntAttribute(
+ "deviceid",
+ GpuProcessHostUIShim::GetInstance()->gpu_info().device_id());
}
{
diff --git a/chrome/browser/net/metadata_url_request.cc b/chrome/browser/net/metadata_url_request.cc
index 375e664..9d990c5 100644
--- a/chrome/browser/net/metadata_url_request.cc
+++ b/chrome/browser/net/metadata_url_request.cc
@@ -75,7 +75,7 @@ bool MetadataRequestHandler::ReadRawData(net::IOBuffer* buf, int buf_size,
return false;
}
if (!parsed) {
- MetadataParserManager* manager = MetadataParserManager::Get();
+ MetadataParserManager* manager = MetadataParserManager::GetInstance();
scoped_ptr<MetadataParser> parser(manager->GetParserForFile(path));
if (parser != NULL) {
result_ = "{\n";
diff --git a/chrome/browser/page_info_model.cc b/chrome/browser/page_info_model.cc
index 7ceb3fd..cba7dd3 100644
--- a/chrome/browser/page_info_model.cc
+++ b/chrome/browser/page_info_model.cc
@@ -59,7 +59,7 @@ PageInfoModel::PageInfoModel(Profile* profile,
int status_with_warnings_removed = ssl.cert_status() & ~cert_warnings;
if (ssl.cert_id() &&
- CertStore::GetSharedInstance()->RetrieveCert(ssl.cert_id(), &cert) &&
+ CertStore::GetInstance()->RetrieveCert(ssl.cert_id(), &cert) &&
!net::IsCertStatusError(status_with_warnings_removed)) {
// No error found so far, check cert_status warnings.
int cert_status = ssl.cert_status();
diff --git a/chrome/browser/parsers/metadata_parser_manager.cc b/chrome/browser/parsers/metadata_parser_manager.cc
index f428fa3..9d5d12c 100644
--- a/chrome/browser/parsers/metadata_parser_manager.cc
+++ b/chrome/browser/parsers/metadata_parser_manager.cc
@@ -15,12 +15,11 @@
static const int kAmountToRead = 256;
// Gets the singleton
-MetadataParserManager* MetadataParserManager::Get() {
- // Uses the LeakySingletonTrait because cleanup is optional.
- return
- Singleton<MetadataParserManager,
- LeakySingletonTraits<MetadataParserManager> >::get();
- }
+MetadataParserManager* MetadataParserManager::GetInstance() {
+ // Uses the LeakySingletonTrait because cleanup is optional.
+ return Singleton<MetadataParserManager,
+ LeakySingletonTraits<MetadataParserManager> >::get();
+}
bool MetadataParserManager::RegisterParserFactory(
MetadataParserFactory* parser) {
diff --git a/chrome/browser/parsers/metadata_parser_manager.h b/chrome/browser/parsers/metadata_parser_manager.h
index 67d7d51..ed922e3 100644
--- a/chrome/browser/parsers/metadata_parser_manager.h
+++ b/chrome/browser/parsers/metadata_parser_manager.h
@@ -22,7 +22,7 @@ class MetadataParserManager {
~MetadataParserManager();
// Gets the singleton
- static MetadataParserManager* Get();
+ static MetadataParserManager* GetInstance();
// Adds a new Parser to the manager, when requests come in for a parser
// the manager will loop through the list of parsers, and query each.
diff --git a/chrome/browser/plugin_process_host.cc b/chrome/browser/plugin_process_host.cc
index c6ee524..ce10aa0 100644
--- a/chrome/browser/plugin_process_host.cc
+++ b/chrome/browser/plugin_process_host.cc
@@ -348,7 +348,7 @@ void PluginProcessHost::OpenChannelToPlugin(Client* client) {
void PluginProcessHost::OnGetCookies(uint32 request_context,
const GURL& url,
std::string* cookies) {
- URLRequestContext* context = CPBrowsingContextManager::Instance()->
+ URLRequestContext* context = CPBrowsingContextManager::GetInstance()->
ToURLRequestContext(request_context);
// TODO(mpcomplete): remove fallback case when Gears support is prevalent.
if (!context)
@@ -398,7 +398,8 @@ void PluginProcessHost::OnResolveProxyCompleted(IPC::Message* reply_msg,
URLRequestContext* PluginProcessHost::GetRequestContext(
uint32 request_id,
const ViewHostMsg_Resource_Request& request_data) {
- return CPBrowsingContextManager::Instance()->ToURLRequestContext(request_id);
+ return CPBrowsingContextManager::GetInstance()->ToURLRequestContext(
+ request_id);
}
void PluginProcessHost::RequestPluginChannel(Client* client) {
diff --git a/chrome/browser/plugin_service.cc b/chrome/browser/plugin_service.cc
index fd52a1c..83c188c 100644
--- a/chrome/browser/plugin_service.cc
+++ b/chrome/browser/plugin_service.cc
@@ -65,7 +65,7 @@ void PluginService::InitGlobalInstance(Profile* profile) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
// We first group the plugins and then figure out which groups to disable.
- PluginUpdater::GetPluginUpdater()->DisablePluginGroupsFromPrefs(profile);
+ PluginUpdater::GetInstance()->DisablePluginGroupsFromPrefs(profile);
if (CommandLine::ForCurrentProcess()->HasSwitch(
switches::kDisableOutdatedPlugins)) {
diff --git a/chrome/browser/plugin_updater.cc b/chrome/browser/plugin_updater.cc
index 4eff704..63e5bb6 100644
--- a/chrome/browser/plugin_updater.cc
+++ b/chrome/browser/plugin_updater.cc
@@ -292,14 +292,14 @@ void PluginUpdater::NotifyPluginStatusChanged() {
}
void PluginUpdater::OnNotifyPluginStatusChanged() {
- GetPluginUpdater()->notify_pending_ = false;
+ GetInstance()->notify_pending_ = false;
NotificationService::current()->Notify(
NotificationType::PLUGIN_ENABLE_STATUS_CHANGED,
- Source<PluginUpdater>(GetPluginUpdater()),
+ Source<PluginUpdater>(GetInstance()),
NotificationService::NoDetails());
}
/*static*/
-PluginUpdater* PluginUpdater::GetPluginUpdater() {
+PluginUpdater* PluginUpdater::GetInstance() {
return Singleton<PluginUpdater>::get();
}
diff --git a/chrome/browser/plugin_updater.h b/chrome/browser/plugin_updater.h
index ecdd1d5..5264334 100644
--- a/chrome/browser/plugin_updater.h
+++ b/chrome/browser/plugin_updater.h
@@ -45,7 +45,7 @@ class PluginUpdater : public NotificationObserver {
const NotificationSource& source,
const NotificationDetails& details);
- static PluginUpdater* GetPluginUpdater();
+ static PluginUpdater* GetInstance();
private:
PluginUpdater();
diff --git a/chrome/browser/printing/cloud_print/cloud_print_proxy_service.cc b/chrome/browser/printing/cloud_print/cloud_print_proxy_service.cc
index b40119a..cafad5a 100644
--- a/chrome/browser/printing/cloud_print/cloud_print_proxy_service.cc
+++ b/chrome/browser/printing/cloud_print/cloud_print_proxy_service.cc
@@ -141,7 +141,7 @@ void CloudPrintProxyService::OnDialogClosed() {
void CloudPrintProxyService::RefreshCloudPrintProxyStatus() {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
ServiceProcessControl* process_control =
- ServiceProcessControlManager::instance()->GetProcessControl(profile_);
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(profile_);
DCHECK(process_control->is_connected());
Callback2<bool, std::string>::Type* callback =
NewCallback(this, &CloudPrintProxyService::StatusCallback);
@@ -152,7 +152,7 @@ void CloudPrintProxyService::RefreshCloudPrintProxyStatus() {
void CloudPrintProxyService::EnableCloudPrintProxy(const std::string& lsid,
const std::string& email) {
ServiceProcessControl* process_control =
- ServiceProcessControlManager::instance()->GetProcessControl(profile_);
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(profile_);
DCHECK(process_control->is_connected());
process_control->Send(new ServiceMsg_EnableCloudPrintProxy(lsid));
// Assume the IPC worked.
@@ -161,7 +161,7 @@ void CloudPrintProxyService::EnableCloudPrintProxy(const std::string& lsid,
void CloudPrintProxyService::DisableCloudPrintProxy() {
ServiceProcessControl* process_control =
- ServiceProcessControlManager::instance()->GetProcessControl(profile_);
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(profile_);
DCHECK(process_control->is_connected());
process_control->Send(new ServiceMsg_DisableCloudPrintProxy);
// Assume the IPC worked.
@@ -175,7 +175,7 @@ void CloudPrintProxyService::StatusCallback(bool enabled, std::string email) {
bool CloudPrintProxyService::InvokeServiceTask(Task* task) {
ServiceProcessControl* process_control =
- ServiceProcessControlManager::instance()->GetProcessControl(profile_);
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(profile_);
DCHECK(process_control);
if (process_control)
process_control->Launch(task, NULL);
diff --git a/chrome/browser/remoting/remoting_setup_flow.cc b/chrome/browser/remoting/remoting_setup_flow.cc
index a517be3..6255c50 100644
--- a/chrome/browser/remoting/remoting_setup_flow.cc
+++ b/chrome/browser/remoting/remoting_setup_flow.cc
@@ -209,7 +209,7 @@ void RemotingSetupFlow::OnIssueAuthTokenSuccess(const std::string& service,
// If we have already connected to the service process then submit the tokens
// to it to register the host.
process_control_ =
- ServiceProcessControlManager::instance()->GetProcessControl(profile_);
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(profile_);
if (process_control_->is_connected()) {
// TODO(hclam): Need to figure out what to do when the service process is
diff --git a/chrome/browser/renderer_host/browser_render_process_host.cc b/chrome/browser/renderer_host/browser_render_process_host.cc
index 5af2e6f..7e85058 100644
--- a/chrome/browser/renderer_host/browser_render_process_host.cc
+++ b/chrome/browser/renderer_host/browser_render_process_host.cc
@@ -940,7 +940,8 @@ void BrowserRenderProcessHost::OnMessageReceived(const IPC::Message& msg) {
void BrowserRenderProcessHost::OnChannelConnected(int32 peer_pid) {
#if defined(IPC_MESSAGE_LOG_ENABLED)
- Send(new ViewMsg_SetIPCLoggingEnabled(IPC::Logging::current()->Enabled()));
+ Send(new ViewMsg_SetIPCLoggingEnabled(
+ IPC::Logging::GetInstance()->Enabled()));
#endif
}
diff --git a/chrome/browser/renderer_host/resource_dispatcher_host.cc b/chrome/browser/renderer_host/resource_dispatcher_host.cc
index 4e6ecab..9a4953e 100644
--- a/chrome/browser/renderer_host/resource_dispatcher_host.cc
+++ b/chrome/browser/renderer_host/resource_dispatcher_host.cc
@@ -1161,8 +1161,8 @@ bool ResourceDispatcherHost::CompleteResponseStarted(net::URLRequest* request) {
if (request->ssl_info().cert) {
int cert_id =
- CertStore::GetSharedInstance()->StoreCert(request->ssl_info().cert,
- info->child_id());
+ CertStore::GetInstance()->StoreCert(request->ssl_info().cert,
+ info->child_id());
response->response_head.security_info =
SSLManager::SerializeSecurityInfo(
cert_id, request->ssl_info().cert_status,
@@ -1500,7 +1500,7 @@ void ResourceDispatcherHost::OnResponseCompleted(net::URLRequest* request) {
std::string security_info;
const net::SSLInfo& ssl_info = request->ssl_info();
if (ssl_info.cert != NULL) {
- int cert_id = CertStore::GetSharedInstance()->StoreCert(ssl_info.cert,
+ int cert_id = CertStore::GetInstance()->StoreCert(ssl_info.cert,
info->child_id());
security_info = SSLManager::SerializeSecurityInfo(
cert_id, ssl_info.cert_status, ssl_info.security_bits,
@@ -1595,8 +1595,8 @@ net::URLRequest* ResourceDispatcherHost::GetURLRequest(
static int GetCertID(net::URLRequest* request, int child_id) {
if (request->ssl_info().cert) {
- return CertStore::GetSharedInstance()->StoreCert(request->ssl_info().cert,
- child_id);
+ return CertStore::GetInstance()->StoreCert(request->ssl_info().cert,
+ child_id);
}
// If there is no SSL info attached to this request, we must either be a non
// secure request, or the request has been canceled or failed (before the SSL
diff --git a/chrome/browser/renderer_host/resource_message_filter.cc b/chrome/browser/renderer_host/resource_message_filter.cc
index d356f78..a745d91f 100644
--- a/chrome/browser/renderer_host/resource_message_filter.cc
+++ b/chrome/browser/renderer_host/resource_message_filter.cc
@@ -1094,7 +1094,7 @@ void ResourceMessageFilter::OnCheckNotificationPermission(
void ResourceMessageFilter::OnGetCPBrowsingContext(uint32* context) {
// Always allocate a new context when a plugin requests one, since it needs to
// be unique for that plugin instance.
- *context = CPBrowsingContextManager::Instance()->Allocate(
+ *context = CPBrowsingContextManager::GetInstance()->Allocate(
request_context_->GetURLRequestContext());
}
diff --git a/chrome/browser/service/service_process_control_browsertest.cc b/chrome/browser/service/service_process_control_browsertest.cc
index ca47f9e..8cf596c 100644
--- a/chrome/browser/service/service_process_control_browsertest.cc
+++ b/chrome/browser/service/service_process_control_browsertest.cc
@@ -23,13 +23,13 @@ class ServiceProcessControlBrowserTest
base::CloseProcessHandle(service_process_handle_);
service_process_handle_ = base::kNullProcessHandle;
// Delete all instances of ServiceProcessControl.
- ServiceProcessControlManager::instance()->Shutdown();
+ ServiceProcessControlManager::GetInstance()->Shutdown();
}
protected:
void LaunchServiceProcessControl() {
ServiceProcessControl* process =
- ServiceProcessControlManager::instance()->GetProcessControl(
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(
browser()->profile());
process_ = process;
@@ -55,7 +55,7 @@ class ServiceProcessControlBrowserTest
void Disconnect() {
// This will delete all instances of ServiceProcessControl and close the IPC
// connections.
- ServiceProcessControlManager::instance()->Shutdown();
+ ServiceProcessControlManager::GetInstance()->Shutdown();
process_ = NULL;
}
@@ -140,7 +140,7 @@ static void DecrementUntilZero(int* count) {
// get invoked.
IN_PROC_BROWSER_TEST_F(ServiceProcessControlBrowserTest, MultipleLaunchTasks) {
ServiceProcessControl* process =
- ServiceProcessControlManager::instance()->GetProcessControl(
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(
browser()->profile());
int launch_count = 5;
for (int i = 0; i < launch_count; i++) {
@@ -159,7 +159,7 @@ IN_PROC_BROWSER_TEST_F(ServiceProcessControlBrowserTest, MultipleLaunchTasks) {
// Make sure using the same task for success and failure tasks works.
IN_PROC_BROWSER_TEST_F(ServiceProcessControlBrowserTest, SameLaunchTask) {
ServiceProcessControl* process =
- ServiceProcessControlManager::instance()->GetProcessControl(
+ ServiceProcessControlManager::GetInstance()->GetProcessControl(
browser()->profile());
int launch_count = 5;
for (int i = 0; i < launch_count; i++) {
diff --git a/chrome/browser/service/service_process_control_manager.cc b/chrome/browser/service/service_process_control_manager.cc
index bf2dd77..cb405fe 100644
--- a/chrome/browser/service/service_process_control_manager.cc
+++ b/chrome/browser/service/service_process_control_manager.cc
@@ -42,6 +42,6 @@ void ServiceProcessControlManager::Shutdown() {
}
// static
-ServiceProcessControlManager* ServiceProcessControlManager::instance() {
+ServiceProcessControlManager* ServiceProcessControlManager::GetInstance() {
return Singleton<ServiceProcessControlManager>::get();
}
diff --git a/chrome/browser/service/service_process_control_manager.h b/chrome/browser/service/service_process_control_manager.h
index a57c43e..a27ec03 100644
--- a/chrome/browser/service/service_process_control_manager.h
+++ b/chrome/browser/service/service_process_control_manager.h
@@ -32,7 +32,7 @@ class ServiceProcessControlManager {
void Shutdown();
// Return the instance of ServiceProcessControlManager.
- static ServiceProcessControlManager* instance();
+ static ServiceProcessControlManager* GetInstance();
private:
ServiceProcessControlList process_control_list_;
diff --git a/chrome/browser/ssl/ssl_blocking_page.cc b/chrome/browser/ssl/ssl_blocking_page.cc
index 45bca07..b2bf6a1 100644
--- a/chrome/browser/ssl/ssl_blocking_page.cc
+++ b/chrome/browser/ssl/ssl_blocking_page.cc
@@ -103,7 +103,7 @@ std::string SSLBlockingPage::GetHTMLContents() {
void SSLBlockingPage::UpdateEntry(NavigationEntry* entry) {
const net::SSLInfo& ssl_info = handler_->ssl_info();
- int cert_id = CertStore::GetSharedInstance()->StoreCert(
+ int cert_id = CertStore::GetInstance()->StoreCert(
ssl_info.cert, tab()->render_view_host()->process()->id());
entry->ssl().set_security_style(SECURITY_STYLE_AUTHENTICATION_BROKEN);
diff --git a/chrome/browser/ssl/ssl_error_info.cc b/chrome/browser/ssl/ssl_error_info.cc
index 674a64b..b10e212 100644
--- a/chrome/browser/ssl/ssl_error_info.cc
+++ b/chrome/browser/ssl/ssl_error_info.cc
@@ -253,7 +253,7 @@ int SSLErrorInfo::GetErrorsForCertStatus(int cert_id,
if (cert_status & kErrorFlags[i]) {
count++;
if (!cert.get()) {
- bool r = CertStore::GetSharedInstance()->RetrieveCert(cert_id, &cert);
+ bool r = CertStore::GetInstance()->RetrieveCert(cert_id, &cert);
DCHECK(r);
}
if (errors)
diff --git a/chrome/browser/ui/browser_init.cc b/chrome/browser/ui/browser_init.cc
index 8249ecb0d..8c3f4ea 100644
--- a/chrome/browser/ui/browser_init.cc
+++ b/chrome/browser/ui/browser_init.cc
@@ -432,7 +432,7 @@ bool BrowserInit::LaunchBrowser(const CommandLine& command_line,
// of compatible documents (PDF, etc) to the GView document viewer.
const CommandLine& parsed_command_line = *CommandLine::ForCurrentProcess();
if (parsed_command_line.HasSwitch(switches::kEnableGView)) {
- chromeos::GViewRequestInterceptor::GetGViewRequestInterceptor();
+ chromeos::GViewRequestInterceptor::GetInstance();
}
if (process_startup) {
// TODO(dhg): Try to make this just USBMountObserver::Get()->set_profile
diff --git a/chrome/browser/ui/cocoa/about_ipc_controller.mm b/chrome/browser/ui/cocoa/about_ipc_controller.mm
index df6ae24..f7f7c31 100644
--- a/chrome/browser/ui/cocoa/about_ipc_controller.mm
+++ b/chrome/browser/ui/cocoa/about_ipc_controller.mm
@@ -102,7 +102,7 @@ AboutIPCController* gSharedController = nil;
gSharedController = nil;
if (g_browser_process)
g_browser_process->SetIPCLoggingEnabled(false); // just in case...
- IPC::Logging::current()->SetConsumer(NULL);
+ IPC::Logging::GetInstance()->SetConsumer(NULL);
[super dealloc];
}
@@ -113,7 +113,7 @@ AboutIPCController* gSharedController = nil;
// We are now able to display information, so let'er rip.
bridge_.reset(new AboutIPCBridge(self));
- IPC::Logging::current()->SetConsumer(bridge_.get());
+ IPC::Logging::GetInstance()->SetConsumer(bridge_.get());
}
// Delegate callback. Closing the window means there is no more need
@@ -123,14 +123,15 @@ AboutIPCController* gSharedController = nil;
}
- (void)updateVisibleRunState {
- if (IPC::Logging::current()->Enabled())
+ if (IPC::Logging::GetInstance()->Enabled())
[startStopButton_ setTitle:@"Stop"];
else
[startStopButton_ setTitle:@"Start"];
}
- (IBAction)startStop:(id)sender {
- g_browser_process->SetIPCLoggingEnabled(!IPC::Logging::current()->Enabled());
+ g_browser_process->SetIPCLoggingEnabled(
+ !IPC::Logging::GetInstance()->Enabled());
[self updateVisibleRunState];
}
diff --git a/chrome/browser/ui/cocoa/page_info_bubble_controller.mm b/chrome/browser/ui/cocoa/page_info_bubble_controller.mm
index 1e3bc94..e0a13f6 100644
--- a/chrome/browser/ui/cocoa/page_info_bubble_controller.mm
+++ b/chrome/browser/ui/cocoa/page_info_bubble_controller.mm
@@ -376,7 +376,7 @@ void ShowPageInfoBubble(gfx::NativeWindow parent,
// By default, assume that we don't have certificate information to show.
scoped_refptr<net::X509Certificate> cert;
- CertStore::GetSharedInstance()->RetrieveCert(certID_, &cert);
+ CertStore::GetInstance()->RetrieveCert(certID_, &cert);
// Don't bother showing certificates if there isn't one. Gears runs
// with no OS root certificate.
diff --git a/chrome/browser/ui/toolbar/toolbar_model.cc b/chrome/browser/ui/toolbar/toolbar_model.cc
index 024c272..5a6a97c 100644
--- a/chrome/browser/ui/toolbar/toolbar_model.cc
+++ b/chrome/browser/ui/toolbar/toolbar_model.cc
@@ -88,7 +88,7 @@ ToolbarModel::SecurityLevel ToolbarModel::GetSecurityLevel() const {
return SECURITY_WARNING;
}
if ((ssl.cert_status() & net::CERT_STATUS_IS_EV) &&
- CertStore::GetSharedInstance()->RetrieveCert(ssl.cert_id(), NULL))
+ CertStore::GetInstance()->RetrieveCert(ssl.cert_id(), NULL))
return EV_SECURE;
return SECURE;
@@ -115,7 +115,7 @@ std::wstring ToolbarModel::GetEVCertName() const {
scoped_refptr<net::X509Certificate> cert;
// Note: Navigation controller and active entry are guaranteed non-NULL or
// the security level would be NONE.
- CertStore::GetSharedInstance()->RetrieveCert(
+ CertStore::GetInstance()->RetrieveCert(
GetNavigationController()->GetActiveEntry()->ssl().cert_id(), &cert);
return SSLManager::GetEVCertName(*cert);
}
diff --git a/chrome/browser/ui/toolbar/wrench_menu_model.cc b/chrome/browser/ui/toolbar/wrench_menu_model.cc
index 7eb2309..0efd669 100644
--- a/chrome/browser/ui/toolbar/wrench_menu_model.cc
+++ b/chrome/browser/ui/toolbar/wrench_menu_model.cc
@@ -62,7 +62,7 @@ const float kMenuBadgeFontSize = 12.0;
namespace {
SkBitmap GetBackgroundPageIcon() {
string16 pages = base::FormatNumber(
- BackgroundPageTracker::GetSingleton()->GetBackgroundPageCount());
+ BackgroundPageTracker::GetInstance()->GetBackgroundPageCount());
return badge_util::DrawBadgeIconOverlay(
*ResourceBundle::GetSharedInstance().GetBitmapNamed(IDR_BACKGROUND_MENU),
kMenuBadgeFontSize,
@@ -261,7 +261,7 @@ string16 WrenchMenuModel::GetLabelForCommandId(int command_id) const {
#endif
case IDC_VIEW_BACKGROUND_PAGES: {
string16 num_background_pages = base::FormatNumber(
- BackgroundPageTracker::GetSingleton()->GetBackgroundPageCount());
+ BackgroundPageTracker::GetInstance()->GetBackgroundPageCount());
return l10n_util::GetStringFUTF16(IDS_VIEW_BACKGROUND_PAGES,
num_background_pages);
}
@@ -306,13 +306,13 @@ bool WrenchMenuModel::IsCommandIdVisible(int command_id) const {
} else if (command_id == IDC_VIEW_INCOMPATIBILITIES) {
#if defined(OS_WIN)
EnumerateModulesModel* loaded_modules =
- EnumerateModulesModel::GetSingleton();
+ EnumerateModulesModel::GetInstance();
return loaded_modules->confirmed_bad_modules_detected() > 0;
#else
return false;
#endif
} else if (command_id == IDC_VIEW_BACKGROUND_PAGES) {
- BackgroundPageTracker* tracker = BackgroundPageTracker::GetSingleton();
+ BackgroundPageTracker* tracker = BackgroundPageTracker::GetInstance();
return tracker->GetBackgroundPageCount() > 0;
}
return true;
@@ -351,7 +351,7 @@ void WrenchMenuModel::Observe(NotificationType type,
const NotificationDetails& details) {
switch (type.value) {
case NotificationType::BACKGROUND_PAGE_TRACKER_CHANGED: {
- int num_pages = BackgroundPageTracker::GetSingleton()->
+ int num_pages = BackgroundPageTracker::GetInstance()->
GetUnacknowledgedBackgroundPageCount();
if (num_pages > 0) {
SetIcon(GetIndexOfCommandId(IDC_VIEW_BACKGROUND_PAGES),
@@ -466,7 +466,7 @@ void WrenchMenuModel::Build() {
IDS_ABOUT, product_name));
}
string16 num_background_pages = base::FormatNumber(
- BackgroundPageTracker::GetSingleton()->GetBackgroundPageCount());
+ BackgroundPageTracker::GetInstance()->GetBackgroundPageCount());
AddItem(IDC_VIEW_BACKGROUND_PAGES, l10n_util::GetStringFUTF16(
IDS_VIEW_BACKGROUND_PAGES, num_background_pages));
AddItem(IDC_UPGRADE_DIALOG, l10n_util::GetStringFUTF16(
@@ -484,7 +484,7 @@ void WrenchMenuModel::Build() {
// Add an icon to the View Background Pages item if there are unacknowledged
// pages.
- if (BackgroundPageTracker::GetSingleton()->
+ if (BackgroundPageTracker::GetInstance()->
GetUnacknowledgedBackgroundPageCount() > 0) {
SetIcon(GetIndexOfCommandId(IDC_VIEW_BACKGROUND_PAGES),
GetBackgroundPageIcon());
diff --git a/chrome/browser/ui/views/about_ipc_dialog.cc b/chrome/browser/ui/views/about_ipc_dialog.cc
index b61f83c..3e5d5d6 100644
--- a/chrome/browser/ui/views/about_ipc_dialog.cc
+++ b/chrome/browser/ui/views/about_ipc_dialog.cc
@@ -203,12 +203,12 @@ AboutIPCDialog::AboutIPCDialog()
table_(NULL),
tracking_(false) {
SetupControls();
- IPC::Logging::current()->SetConsumer(this);
+ IPC::Logging::GetInstance()->SetConsumer(this);
}
AboutIPCDialog::~AboutIPCDialog() {
active_dialog = NULL;
- IPC::Logging::current()->SetConsumer(NULL);
+ IPC::Logging::GetInstance()->SetConsumer(NULL);
}
// static
diff --git a/chrome/browser/ui/views/accessible_pane_view.cc b/chrome/browser/ui/views/accessible_pane_view.cc
index fa8a478..1e07d1d 100644
--- a/chrome/browser/ui/views/accessible_pane_view.cc
+++ b/chrome/browser/ui/views/accessible_pane_view.cc
@@ -107,7 +107,7 @@ void AccessiblePaneView::LocationBarSelectAll() {
}
void AccessiblePaneView::RestoreLastFocusedView() {
- views::ViewStorage* view_storage = views::ViewStorage::GetSharedInstance();
+ views::ViewStorage* view_storage = views::ViewStorage::GetInstance();
views::View* last_focused_view =
view_storage->RetrieveView(last_focused_view_storage_id_);
if (last_focused_view) {
diff --git a/chrome/browser/ui/views/frame/browser_view.cc b/chrome/browser/ui/views/frame/browser_view.cc
index 4cbd7e2..b970b16 100644
--- a/chrome/browser/ui/views/frame/browser_view.cc
+++ b/chrome/browser/ui/views/frame/browser_view.cc
@@ -425,7 +425,7 @@ void BrowserView::SetShowState(int state) {
BrowserView::BrowserView(Browser* browser)
: views::ClientView(NULL, NULL),
last_focused_view_storage_id_(
- views::ViewStorage::GetSharedInstance()->CreateStorageID()),
+ views::ViewStorage::GetInstance()->CreateStorageID()),
frame_(NULL),
browser_(browser),
active_bookmark_bar_(NULL),
@@ -983,7 +983,7 @@ void BrowserView::RotatePaneFocus(bool forwards) {
}
void BrowserView::SaveFocusedView() {
- views::ViewStorage* view_storage = views::ViewStorage::GetSharedInstance();
+ views::ViewStorage* view_storage = views::ViewStorage::GetInstance();
if (view_storage->RetrieveView(last_focused_view_storage_id_))
view_storage->RemoveView(last_focused_view_storage_id_);
views::View* focused_view = GetRootView()->GetFocusedView();
diff --git a/chrome/browser/ui/views/html_dialog_view_browsertest.cc b/chrome/browser/ui/views/html_dialog_view_browsertest.cc
index baacb95..e79712b 100644
--- a/chrome/browser/ui/views/html_dialog_view_browsertest.cc
+++ b/chrome/browser/ui/views/html_dialog_view_browsertest.cc
@@ -73,7 +73,7 @@ class HtmlDialogBrowserTest : public InProcessBrowserTest {
public:
WindowChangedObserver() {}
- static WindowChangedObserver* Get() {
+ static WindowChangedObserver* GetInstance() {
return Singleton<WindowChangedObserver>::get();
}
@@ -95,7 +95,7 @@ class HtmlDialogBrowserTest : public InProcessBrowserTest {
public:
WindowChangedObserver() {}
- static WindowChangedObserver* Get() {
+ static WindowChangedObserver* GetInstance() {
return Singleton<WindowChangedObserver>::get();
}
@@ -136,7 +136,8 @@ IN_PROC_BROWSER_TEST_F(HtmlDialogBrowserTest, MAYBE_SizeWindow) {
html_view->InitDialog();
html_view->window()->Show();
- MessageLoopForUI::current()->AddObserver(WindowChangedObserver::Get());
+ MessageLoopForUI::current()->AddObserver(
+ WindowChangedObserver::GetInstance());
gfx::Rect bounds;
html_view->GetWidget()->GetBounds(&bounds, false);
@@ -202,5 +203,6 @@ IN_PROC_BROWSER_TEST_F(HtmlDialogBrowserTest, MAYBE_SizeWindow) {
EXPECT_LT(0, actual_bounds.width());
EXPECT_LT(0, actual_bounds.height());
- MessageLoopForUI::current()->RemoveObserver(WindowChangedObserver::Get());
+ MessageLoopForUI::current()->RemoveObserver(
+ WindowChangedObserver::GetInstance());
}
diff --git a/chrome/browser/ui/views/page_info_bubble_view.cc b/chrome/browser/ui/views/page_info_bubble_view.cc
index 0dbd950..073c6f7 100644
--- a/chrome/browser/ui/views/page_info_bubble_view.cc
+++ b/chrome/browser/ui/views/page_info_bubble_view.cc
@@ -96,7 +96,7 @@ PageInfoBubbleView::PageInfoBubbleView(gfx::NativeWindow parent_window,
animation_start_height_(0) {
if (cert_id_ > 0) {
scoped_refptr<net::X509Certificate> cert;
- CertStore::GetSharedInstance()->RetrieveCert(cert_id_, &cert);
+ CertStore::GetInstance()->RetrieveCert(cert_id_, &cert);
// When running with fake certificate (Chrome Frame) or Gears in offline
// mode, we have no os certificate, so there is no cert to show. Don't
// bother showing the cert info link in that case.
diff --git a/chrome/browser/ui/views/tab_contents/tab_contents_view_gtk.cc b/chrome/browser/ui/views/tab_contents/tab_contents_view_gtk.cc
index d090259..c911c4d 100644
--- a/chrome/browser/ui/views/tab_contents/tab_contents_view_gtk.cc
+++ b/chrome/browser/ui/views/tab_contents/tab_contents_view_gtk.cc
@@ -106,7 +106,7 @@ TabContentsViewGtk::TabContentsViewGtk(TabContents* tab_contents)
ignore_next_char_event_(false) {
drag_source_.reset(new TabContentsDragSource(this));
last_focused_view_storage_id_ =
- views::ViewStorage::GetSharedInstance()->CreateStorageID();
+ views::ViewStorage::GetInstance()->CreateStorageID();
}
TabContentsViewGtk::~TabContentsViewGtk() {
@@ -114,7 +114,7 @@ TabContentsViewGtk::~TabContentsViewGtk() {
//
// It is possible the view went away before us, so we only do this if the
// view is registered.
- views::ViewStorage* view_storage = views::ViewStorage::GetSharedInstance();
+ views::ViewStorage* view_storage = views::ViewStorage::GetInstance();
if (view_storage->RetrieveView(last_focused_view_storage_id_) != NULL)
view_storage->RemoveView(last_focused_view_storage_id_);
@@ -277,7 +277,7 @@ void TabContentsViewGtk::SetInitialFocus() {
}
void TabContentsViewGtk::StoreFocus() {
- views::ViewStorage* view_storage = views::ViewStorage::GetSharedInstance();
+ views::ViewStorage* view_storage = views::ViewStorage::GetInstance();
if (view_storage->RetrieveView(last_focused_view_storage_id_) != NULL)
view_storage->RemoveView(last_focused_view_storage_id_);
@@ -294,7 +294,7 @@ void TabContentsViewGtk::StoreFocus() {
}
void TabContentsViewGtk::RestoreFocus() {
- views::ViewStorage* view_storage = views::ViewStorage::GetSharedInstance();
+ views::ViewStorage* view_storage = views::ViewStorage::GetInstance();
views::View* last_focused_view =
view_storage->RetrieveView(last_focused_view_storage_id_);
if (!last_focused_view) {
diff --git a/chrome/browser/ui/views/tab_contents/tab_contents_view_win.cc b/chrome/browser/ui/views/tab_contents/tab_contents_view_win.cc
index 4aec5c2..164fd92 100644
--- a/chrome/browser/ui/views/tab_contents/tab_contents_view_win.cc
+++ b/chrome/browser/ui/views/tab_contents/tab_contents_view_win.cc
@@ -41,7 +41,7 @@ TabContentsViewWin::TabContentsViewWin(TabContents* tab_contents)
close_tab_after_drag_ends_(false),
sad_tab_(NULL) {
last_focused_view_storage_id_ =
- views::ViewStorage::GetSharedInstance()->CreateStorageID();
+ views::ViewStorage::GetInstance()->CreateStorageID();
}
TabContentsViewWin::~TabContentsViewWin() {
@@ -49,7 +49,7 @@ TabContentsViewWin::~TabContentsViewWin() {
//
// It is possible the view went away before us, so we only do this if the
// view is registered.
- views::ViewStorage* view_storage = views::ViewStorage::GetSharedInstance();
+ views::ViewStorage* view_storage = views::ViewStorage::GetInstance();
if (view_storage->RetrieveView(last_focused_view_storage_id_) != NULL)
view_storage->RemoveView(last_focused_view_storage_id_);
}
@@ -213,7 +213,7 @@ void TabContentsViewWin::SetInitialFocus() {
}
void TabContentsViewWin::StoreFocus() {
- views::ViewStorage* view_storage = views::ViewStorage::GetSharedInstance();
+ views::ViewStorage* view_storage = views::ViewStorage::GetInstance();
if (view_storage->RetrieveView(last_focused_view_storage_id_) != NULL)
view_storage->RemoveView(last_focused_view_storage_id_);
@@ -243,7 +243,7 @@ void TabContentsViewWin::StoreFocus() {
}
void TabContentsViewWin::RestoreFocus() {
- views::ViewStorage* view_storage = views::ViewStorage::GetSharedInstance();
+ views::ViewStorage* view_storage = views::ViewStorage::GetInstance();
views::View* last_focused_view =
view_storage->RetrieveView(last_focused_view_storage_id_);
diff --git a/chrome/browser/ui/views/toolbar_view.cc b/chrome/browser/ui/views/toolbar_view.cc
index 73a4be3..7044ec2 100644
--- a/chrome/browser/ui/views/toolbar_view.cc
+++ b/chrome/browser/ui/views/toolbar_view.cc
@@ -355,7 +355,7 @@ cleanup:
destroyed_flag_ = NULL;
// Stop showing the background app badge also.
- BackgroundPageTracker::GetSingleton()->AcknowledgeBackgroundPages();
+ BackgroundPageTracker::GetInstance()->AcknowledgeBackgroundPages();
}
////////////////////////////////////////////////////////////////////////////////
@@ -633,13 +633,13 @@ bool ToolbarView::IsUpgradeRecommended() {
}
bool ToolbarView::ShouldShowBackgroundPageBadge() {
- return BackgroundPageTracker::GetSingleton()->
+ return BackgroundPageTracker::GetInstance()->
GetUnacknowledgedBackgroundPageCount() > 0;
}
bool ToolbarView::ShouldShowIncompatibilityWarning() {
#if defined(OS_WIN)
- EnumerateModulesModel* loaded_modules = EnumerateModulesModel::GetSingleton();
+ EnumerateModulesModel* loaded_modules = EnumerateModulesModel::GetInstance();
return loaded_modules->confirmed_bad_modules_detected() > 0;
#else
return false;
@@ -761,7 +761,7 @@ SkBitmap ToolbarView::GetBackgroundPageBadge() {
ThemeProvider* tp = GetThemeProvider();
SkBitmap* badge = tp->GetBitmapNamed(IDR_BACKGROUND_BADGE);
string16 badge_text = base::FormatNumber(
- BackgroundPageTracker::GetSingleton()->GetBackgroundPageCount());
+ BackgroundPageTracker::GetInstance()->GetBackgroundPageCount());
return badge_util::DrawBadgeIconOverlay(
*badge,
kBadgeTextFontSize,