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

Unified Diff: chrome/common/pref_store.h

Issue 5915004: Introduce incognito preference settings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fixed whitespaces in mac files Created 9 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/common/pref_store.h
diff --git a/chrome/common/pref_store.h b/chrome/common/pref_store.h
index 35818a0aa039ac617453c393bcfdf44b62f183c5..819a76441a68be8ed002ce7eb48540efa0e67415 100644
--- a/chrome/common/pref_store.h
+++ b/chrome/common/pref_store.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -9,6 +9,7 @@
#include <string>
#include "base/basictypes.h"
+#include "base/ref_counted.h"
class Value;
@@ -19,7 +20,7 @@ class Value;
// CommandLinePrefStore, which bridges command line options to preferences and
// ConfigurationPolicyPrefStore, which is used for hooking up configuration
// policy with the preference subsystem.
-class PrefStore {
+class PrefStore : public base::RefCounted<PrefStore> {
public:
// Observer interface for monitoring PrefStore.
class Observer {
@@ -43,7 +44,6 @@ class PrefStore {
};
PrefStore() {}
- virtual ~PrefStore() {}
// Add and remove observers.
virtual void AddObserver(Observer* observer) {}
@@ -57,6 +57,11 @@ class PrefStore {
// |result| value remains with the PrefStore.
virtual ReadResult GetValue(const std::string& key, Value** result) const = 0;
+ protected:
+ friend class base::RefCounted<PrefStore>;
+ virtual ~PrefStore() {}
+
+ private:
DISALLOW_COPY_AND_ASSIGN(PrefStore);
};

Powered by Google App Engine
This is Rietveld 408576698