summaryrefslogtreecommitdiffstats
path: root/chrome/common/extensions
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/common/extensions')
-rw-r--r--chrome/common/extensions/api/extension_api.cc9
-rw-r--r--chrome/common/extensions/permissions/permissions_data.cc4
2 files changed, 5 insertions, 8 deletions
diff --git a/chrome/common/extensions/api/extension_api.cc b/chrome/common/extensions/api/extension_api.cc
index a609ac8..f28ab3c 100644
--- a/chrome/common/extensions/api/extension_api.cc
+++ b/chrome/common/extensions/api/extension_api.cc
@@ -224,12 +224,9 @@ ExtensionAPI::~ExtensionAPI() {
}
void ExtensionAPI::InitDefaultConfiguration() {
- RegisterDependencyProvider(
- "api", FeatureProvider::GetByName("api"));
- RegisterDependencyProvider(
- "manifest", FeatureProvider::GetByName("manifest"));
- RegisterDependencyProvider(
- "permission", FeatureProvider::GetByName("permission"));
+ const char* names[] = {"api", "manifest", "permission"};
+ for (size_t i = 0; i < arraysize(names); ++i)
+ RegisterDependencyProvider(names[i], FeatureProvider::GetByName(names[i]));
// Schemas to be loaded from resources.
CHECK(unloaded_schemas_.empty());
diff --git a/chrome/common/extensions/permissions/permissions_data.cc b/chrome/common/extensions/permissions/permissions_data.cc
index a05a2d8..0e8adc6 100644
--- a/chrome/common/extensions/permissions/permissions_data.cc
+++ b/chrome/common/extensions/permissions/permissions_data.cc
@@ -12,7 +12,6 @@
#include "base/strings/utf_string_conversions.h"
#include "base/values.h"
#include "chrome/common/extensions/extension.h"
-#include "chrome/common/extensions/features/base_feature_provider.h"
#include "chrome/common/extensions/permissions/api_permission_set.h"
#include "chrome/common/extensions/permissions/chrome_scheme_hosts.h"
#include "chrome/common/extensions/permissions/permission_set.h"
@@ -21,6 +20,7 @@
#include "extensions/common/constants.h"
#include "extensions/common/error_utils.h"
#include "extensions/common/features/feature.h"
+#include "extensions/common/features/feature_provider.h"
#include "extensions/common/manifest.h"
#include "extensions/common/manifest_constants.h"
#include "extensions/common/manifest_constants.h"
@@ -119,7 +119,7 @@ bool ParseHelper(Extension* extension,
// Verify feature availability of permissions.
std::vector<APIPermission::ID> to_remove;
FeatureProvider* permission_features =
- BaseFeatureProvider::GetByName("permission");
+ FeatureProvider::GetPermissionFeatures();
for (APIPermissionSet::const_iterator iter = api_permissions->begin();
iter != api_permissions->end(); ++iter) {
Feature* feature = permission_features->GetFeature(iter->name());