OLD | NEW |
---|---|
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "chrome/common/extensions/chrome_extensions_client.h" | 5 #include "chrome/common/extensions/chrome_extensions_client.h" |
6 | 6 |
7 #include "chrome/common/chrome_version_info.h" | 7 #include "chrome/common/chrome_version_info.h" |
8 #include "chrome/common/extensions/api/generated_schemas.h" | 8 #include "chrome/common/extensions/api/generated_schemas.h" |
9 #include "chrome/common/extensions/chrome_manifest_handlers.h" | 9 #include "chrome/common/extensions/chrome_manifest_handlers.h" |
10 #include "chrome/common/extensions/extension_constants.h" | 10 #include "chrome/common/extensions/extension_constants.h" |
(...skipping 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
93 // online courses and will be needed while the online educational programs | 93 // online courses and will be needed while the online educational programs |
94 // are in place. | 94 // are in place. |
95 scripting_whitelist_.push_back("angkfkebojeancgemegoedelbnjgcgme"); | 95 scripting_whitelist_.push_back("angkfkebojeancgemegoedelbnjgcgme"); |
96 } | 96 } |
97 | 97 |
98 const PermissionMessageProvider& | 98 const PermissionMessageProvider& |
99 ChromeExtensionsClient::GetPermissionMessageProvider() const { | 99 ChromeExtensionsClient::GetPermissionMessageProvider() const { |
100 return permission_message_provider_; | 100 return permission_message_provider_; |
101 } | 101 } |
102 | 102 |
103 const std::string ChromeExtensionsClient::GetProductName() { | |
104 return "Chrome"; | |
James Cook
2014/08/25 20:58:11
I don't think you want to do this. You probably wa
Xi Han
2014/08/26 18:21:40
Done.
| |
105 } | |
106 | |
103 scoped_ptr<FeatureProvider> ChromeExtensionsClient::CreateFeatureProvider( | 107 scoped_ptr<FeatureProvider> ChromeExtensionsClient::CreateFeatureProvider( |
104 const std::string& name) const { | 108 const std::string& name) const { |
105 scoped_ptr<FeatureProvider> provider; | 109 scoped_ptr<FeatureProvider> provider; |
106 scoped_ptr<JSONFeatureProviderSource> source( | 110 scoped_ptr<JSONFeatureProviderSource> source( |
107 CreateFeatureProviderSource(name)); | 111 CreateFeatureProviderSource(name)); |
108 if (name == "api") { | 112 if (name == "api") { |
109 provider.reset(new BaseFeatureProvider(source->dictionary(), | 113 provider.reset(new BaseFeatureProvider(source->dictionary(), |
110 CreateFeature<APIFeature>)); | 114 CreateFeature<APIFeature>)); |
111 } else if (name == "manifest") { | 115 } else if (name == "manifest") { |
112 provider.reset(new BaseFeatureProvider(source->dictionary(), | 116 provider.reset(new BaseFeatureProvider(source->dictionary(), |
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
267 // Suppress fatal errors only on beta and stable channels. | 271 // Suppress fatal errors only on beta and stable channels. |
268 return GetCurrentChannel() > chrome::VersionInfo::CHANNEL_DEV; | 272 return GetCurrentChannel() > chrome::VersionInfo::CHANNEL_DEV; |
269 } | 273 } |
270 | 274 |
271 // static | 275 // static |
272 ChromeExtensionsClient* ChromeExtensionsClient::GetInstance() { | 276 ChromeExtensionsClient* ChromeExtensionsClient::GetInstance() { |
273 return g_client.Pointer(); | 277 return g_client.Pointer(); |
274 } | 278 } |
275 | 279 |
276 } // namespace extensions | 280 } // namespace extensions |
OLD | NEW |