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

Unified Diff: chrome/browser/extensions/extension_special_storage_policy.cc

Issue 1782053004: Change how the quota system computes the total poolsize for temporary storage (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/extensions/extension_special_storage_policy.cc
diff --git a/chrome/browser/extensions/extension_special_storage_policy.cc b/chrome/browser/extensions/extension_special_storage_policy.cc
index 2abb046383df60a9c9853258394bc247aae87b1c..331c9a3088fc3c223d58fd12118b0c0e783add3c 100644
--- a/chrome/browser/extensions/extension_special_storage_policy.cc
+++ b/chrome/browser/extensions/extension_special_storage_policy.cc
@@ -114,11 +114,6 @@ bool ExtensionSpecialStoragePolicy::IsStorageSessionOnly(const GURL& origin) {
return cookie_settings_->IsCookieSessionOnly(origin);
}
-bool ExtensionSpecialStoragePolicy::CanQueryDiskSize(const GURL& origin) {
- base::AutoLock locker(lock_);
- return installed_apps_.Contains(origin);
-}
-
bool ExtensionSpecialStoragePolicy::HasSessionOnlyOrigins() {
if (cookie_settings_.get() == NULL)
return false;
@@ -177,9 +172,6 @@ void ExtensionSpecialStoragePolicy::GrantRightsForExtension(
extension->is_app()) {
if (NeedsProtection(extension) && protected_apps_.Add(extension))
change_flags |= SpecialStoragePolicy::STORAGE_PROTECTED;
- // FIXME: Does GrantRightsForExtension imply |extension| is installed?
- if (extension->is_app())
- installed_apps_.Add(extension);
if (extension->permissions_data()->HasAPIPermission(
APIPermission::kUnlimitedStorage) &&
@@ -225,9 +217,6 @@ void ExtensionSpecialStoragePolicy::RevokeRightsForExtension(
if (NeedsProtection(extension) && protected_apps_.Remove(extension))
change_flags |= SpecialStoragePolicy::STORAGE_PROTECTED;
- if (extension->is_app())
- installed_apps_.Remove(extension);
-
if (extension->permissions_data()->HasAPIPermission(
APIPermission::kUnlimitedStorage) &&
unlimited_extensions_.Remove(extension))
@@ -251,7 +240,6 @@ void ExtensionSpecialStoragePolicy::RevokeRightsForAllExtensions() {
{
base::AutoLock locker(lock_);
protected_apps_.Clear();
- installed_apps_.Clear();
unlimited_extensions_.Clear();
file_handler_extensions_.Clear();
isolated_extensions_.Clear();

Powered by Google App Engine
This is Rietveld 408576698