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

Unified Diff: chrome/browser/protector/protector_service.h

Issue 9620010: Added Protector backup for Preferences. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Whitespace. Created 8 years, 9 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/protector/protector_service.h
diff --git a/chrome/browser/protector/protector_service.h b/chrome/browser/protector/protector_service.h
index efb78430cd7993f293bab0a956804f1ffb8e2f05..7040177f3ed0f5587d4a184793f2e61eff90db45 100644
--- a/chrome/browser/protector/protector_service.h
+++ b/chrome/browser/protector/protector_service.h
@@ -11,6 +11,7 @@
#include "base/basictypes.h"
#include "base/compiler_specific.h"
#include "base/memory/linked_ptr.h"
+#include "base/memory/scoped_ptr.h"
#include "base/message_loop_helpers.h"
#include "chrome/browser/profiles/profile_keyed_service.h"
#include "chrome/browser/protector/base_setting_change.h"
@@ -23,6 +24,7 @@ class TemplateURLService;
namespace protector {
+class ProtectedPrefsWatcher;
class SettingsChangeGlobalError;
// Presents a SettingChange to user and handles possible user actions.
@@ -65,7 +67,8 @@ class ProtectorService : public ProfileKeyedService,
private:
friend class ProtectorServiceTest;
- // Pair of error and corresponding change instance.
+ // Pair of error and corresponding change instance. linked_ptr is used because
+ // Item instances are stored in a std::vector and must be copyable.
struct Item {
Item();
~Item();
@@ -113,6 +116,9 @@ class ProtectorService : public ProfileKeyedService,
// Profile which settings we are protecting.
Profile* profile_;
+ // Observes changes to protected prefs and updates the backup.
+ scoped_ptr<ProtectedPrefsWatcher> prefs_watcher_;
+
DISALLOW_COPY_AND_ASSIGN(ProtectorService);
};

Powered by Google App Engine
This is Rietveld 408576698