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

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

Issue 11345008: Remove content::NotificationObserver dependency from most Prefs code. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix PrefNotifierImpl Created 8 years, 2 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/net/chrome_url_request_context.h
diff --git a/chrome/browser/net/chrome_url_request_context.h b/chrome/browser/net/chrome_url_request_context.h
index 16fdbb9d1850b32879bce573a6c5698dc4f9c863..9d5325e25f86e6000cbb6e1fd8591cc20242071b 100644
--- a/chrome/browser/net/chrome_url_request_context.h
+++ b/chrome/browser/net/chrome_url_request_context.h
@@ -9,8 +9,7 @@
#include "base/memory/scoped_ptr.h"
#include "base/prefs/public/pref_change_registrar.h"
-#include "content/public/browser/notification_observer.h"
-#include "content/public/browser/notification_registrar.h"
+#include "base/prefs/public/pref_observer.h"
#include "net/url_request/url_request_context.h"
#include "net/url_request/url_request_context_getter.h"
#include "net/url_request/url_request_job_factory.h"
@@ -99,7 +98,7 @@ class ChromeURLRequestContext : public net::URLRequestContext {
// Most methods are expected to be called on the UI thread, except for
// the destructor and GetURLRequestContext().
class ChromeURLRequestContextGetter : public net::URLRequestContextGetter,
- public content::NotificationObserver {
+ public PrefObserver {
public:
// Constructs a ChromeURLRequestContextGetter that will use |factory| to
// create the ChromeURLRequestContext. If |profile| is non-NULL, then the
@@ -180,10 +179,9 @@ class ChromeURLRequestContextGetter : public net::URLRequestContextGetter,
// thread before the instance is deleted on the IO thread.
void CleanupOnUIThread();
- // content::NotificationObserver implementation.
- virtual void Observe(int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) OVERRIDE;
+ // PrefObserver implementation.
+ virtual void OnPreferenceChanged(PrefServiceBase* service,
+ const std::string& pref_name) OVERRIDE;
private:
// Must be called on the IO thread.

Powered by Google App Engine
This is Rietveld 408576698