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

Side by Side Diff: extensions/browser/extension_function_registry.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 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 "extensions/browser/extension_function_registry.h" 5 #include "extensions/browser/extension_function_registry.h"
6 6
7 #include "base/memory/singleton.h" 7 #include "base/memory/singleton.h"
8 #include "extensions/browser/extension_function.h" 8 #include "extensions/browser/extension_function.h"
9 #include "extensions/browser/extensions_browser_client.h" 9 #include "extensions/browser/extensions_browser_client.h"
10 10
11 // static 11 // static
12 ExtensionFunctionRegistry* ExtensionFunctionRegistry::GetInstance() { 12 ExtensionFunctionRegistry* ExtensionFunctionRegistry::GetInstance() {
13 return Singleton<ExtensionFunctionRegistry>::get(); 13 return base::Singleton<ExtensionFunctionRegistry>::get();
14 } 14 }
15 15
16 ExtensionFunctionRegistry::ExtensionFunctionRegistry() { 16 ExtensionFunctionRegistry::ExtensionFunctionRegistry() {
17 extensions::ExtensionsBrowserClient* client = 17 extensions::ExtensionsBrowserClient* client =
18 extensions::ExtensionsBrowserClient::Get(); 18 extensions::ExtensionsBrowserClient::Get();
19 if (client) { 19 if (client) {
20 client->RegisterExtensionFunctions(this); 20 client->RegisterExtensionFunctions(this);
21 } 21 }
22 } 22 }
23 23
(...skipping 30 matching lines...) Expand all
54 } 54 }
55 55
56 ExtensionFunctionRegistry::FactoryEntry::FactoryEntry( 56 ExtensionFunctionRegistry::FactoryEntry::FactoryEntry(
57 ExtensionFunctionFactory factory, 57 ExtensionFunctionFactory factory,
58 const char* function_name, 58 const char* function_name,
59 extensions::functions::HistogramValue histogram_value) 59 extensions::functions::HistogramValue histogram_value)
60 : factory_(factory), 60 : factory_(factory),
61 function_name_(function_name), 61 function_name_(function_name),
62 histogram_value_(histogram_value) { 62 histogram_value_(histogram_value) {
63 } 63 }
OLDNEW
« no previous file with comments | « extensions/browser/extension_function.cc ('k') | extensions/browser/extension_message_filter.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698