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

Unified Diff: chrome/browser/extensions/api/storage/managed_value_store_cache.cc

Issue 102493002: Use schemas bundled in extensions to convert policies loaded on Windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 7 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | components/policy/core/common/configuration_policy_provider_test.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/extensions/api/storage/managed_value_store_cache.cc
diff --git a/chrome/browser/extensions/api/storage/managed_value_store_cache.cc b/chrome/browser/extensions/api/storage/managed_value_store_cache.cc
index 770c330ce8860f7bcd5fffae6f2a8a96ca074f53..47ad4127e6895d593fc1c9aac8cc2c1e7215a8f2 100644
--- a/chrome/browser/extensions/api/storage/managed_value_store_cache.cc
+++ b/chrome/browser/extensions/api/storage/managed_value_store_cache.cc
@@ -52,6 +52,13 @@ namespace {
const char kLoadSchemasBackgroundTaskTokenName[] =
"load_managed_storage_schemas_token";
+// The Legacy Browser Support was the first user of the policy-for-extensions
+// API, and relied on behavior that will be phased out. If this extension is
+// present then its policies will be loaded in a special way.
+// TODO(joaodasilva): remove this for M35. http://crbug.com/325349
+const char kLegacyBrowserSupportExtensionId[] =
+ "heildphpnddilhkemkielfhnkaagiabh";
+
} // namespace
// This helper observes initialization of all the installed extensions and
@@ -173,13 +180,8 @@ bool ManagedValueStoreCache::ExtensionTracker::UsesManagedStorage(
if (extension->manifest()->HasPath(manifest_keys::kStorageManagedSchema))
return true;
- // TODO(joaodasilva): also load extensions that use the storage API for now,
- // to support the Legacy Browser Support extension. Remove this.
- // http://crbug.com/240704
- if (extension->HasAPIPermission(APIPermission::kStorage))
- return true;
-
- return false;
+ // TODO(joaodasilva): remove this by M35.
+ return extension->id() == kLegacyBrowserSupportExtensionId;
}
// static
« no previous file with comments | « no previous file | components/policy/core/common/configuration_policy_provider_test.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698