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

Unified Diff: chrome/browser/extensions/settings/settings_frontend.h

Issue 9284013: Extension Storage API: expose storage quota information to extensions, via: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: comments Created 8 years, 11 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/settings/settings_frontend.h
diff --git a/chrome/browser/extensions/settings/settings_frontend.h b/chrome/browser/extensions/settings/settings_frontend.h
index e007b9fc07e3fc5f13d4a9b338e40fe90d30e18c..5202d2966922bffe6120b53069a4a70f1d59d9b5 100644
--- a/chrome/browser/extensions/settings/settings_frontend.h
+++ b/chrome/browser/extensions/settings/settings_frontend.h
@@ -16,6 +16,7 @@
#include "chrome/browser/extensions/settings/settings_leveldb_storage.h"
#include "chrome/browser/extensions/settings/settings_namespace.h"
#include "chrome/browser/extensions/settings/settings_observer.h"
+#include "chrome/browser/extensions/settings/settings_storage_quota_enforcer.h"
#include "chrome/browser/sync/api/syncable_service.h"
class Profile;
@@ -29,9 +30,15 @@ class SettingsStorage;
// All public methods must be called on the UI thread.
class SettingsFrontend {
public:
- // Creates with the default factory. Ownership of |profile| not taken.
+ // Quota limits for sync and local. Make these public for tests.
+ static const SettingsStorageQuotaEnforcer::Limits kSyncQuota;
+ static const SettingsStorageQuotaEnforcer::Limits kLocalQuota;
+
+ // Creates with the default factory. Ownership of |profile| not taken.
static SettingsFrontend* Create(Profile* profile);
+ // Creates with a specific factory |storage_factory| (presumably for tests).
+ // Ownership of |profile| not taken.
static SettingsFrontend* Create(
const scoped_refptr<SettingsStorageFactory>& storage_factory,
// Owership NOT taken.

Powered by Google App Engine
This is Rietveld 408576698