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

Unified Diff: chrome/browser/net/net_pref_observer.h

Issue 11345008: Remove content::NotificationObserver dependency from most Prefs code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Merge to head for commit Created 8 years, 1 month 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 | « chrome/browser/net/http_server_properties_manager.cc ('k') | chrome/browser/net/net_pref_observer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/net/net_pref_observer.h
diff --git a/chrome/browser/net/net_pref_observer.h b/chrome/browser/net/net_pref_observer.h
index 5f3157e08064f8c00f4b9a5b0541cbdb900297d3..1d2f5772cbf5adf9ab29aa5da4e0f06c6fbfc2a6 100644
--- a/chrome/browser/net/net_pref_observer.h
+++ b/chrome/browser/net/net_pref_observer.h
@@ -6,8 +6,8 @@
#define CHROME_BROWSER_NET_NET_PREF_OBSERVER_H_
#include "base/basictypes.h"
+#include "base/prefs/public/pref_observer.h"
#include "chrome/browser/api/prefs/pref_member.h"
-#include "content/public/browser/notification_observer.h"
namespace chrome_browser_net {
class Predictor;
@@ -22,7 +22,7 @@ class PrefService;
// Monitors network-related preferences for changes and applies them.
// The supplied PrefService must outlive this NetPrefObserver.
// Must be used only on the UI thread.
-class NetPrefObserver : public content::NotificationObserver {
+class NetPrefObserver : public PrefObserver {
public:
// |prefs| must be non-NULL and |*prefs| must outlive this.
// |prerender_manager| may be NULL. If not, |*prerender_manager| must
@@ -32,10 +32,9 @@ class NetPrefObserver : public content::NotificationObserver {
chrome_browser_net::Predictor* predictor);
virtual ~NetPrefObserver();
- // content::NotificationObserver
- virtual void Observe(int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) OVERRIDE;
+ // PrefObserver
+ virtual void OnPreferenceChanged(PrefServiceBase* service,
+ const std::string& pref_name) OVERRIDE;
static void RegisterPrefs(PrefService* prefs);
« no previous file with comments | « chrome/browser/net/http_server_properties_manager.cc ('k') | chrome/browser/net/net_pref_observer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698