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

Unified Diff: chrome/browser/safe_browsing/safe_browsing_tab_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 LKGR. 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/safe_browsing/safe_browsing_tab_observer.h
diff --git a/chrome/browser/safe_browsing/safe_browsing_tab_observer.h b/chrome/browser/safe_browsing/safe_browsing_tab_observer.h
index ec97fee4cca8c037577d538873f444a2b469f724..b41ecb9c19c3a180eb91fce2fa45b72ddff43f99 100644
--- a/chrome/browser/safe_browsing/safe_browsing_tab_observer.h
+++ b/chrome/browser/safe_browsing/safe_browsing_tab_observer.h
@@ -7,7 +7,7 @@
#include "base/memory/scoped_ptr.h"
#include "base/prefs/public/pref_change_registrar.h"
-#include "content/public/browser/notification_observer.h"
+#include "base/prefs/public/pref_observer.h"
#include "content/public/browser/web_contents_user_data.h"
namespace content {
@@ -20,7 +20,7 @@ class ClientSideDetectionHost;
// Per-tab class to handle safe-browsing functionality.
class SafeBrowsingTabObserver
- : public content::NotificationObserver,
+ : public PrefObserver,
public content::WebContentsUserData<SafeBrowsingTabObserver> {
public:
virtual ~SafeBrowsingTabObserver();
@@ -29,10 +29,9 @@ class SafeBrowsingTabObserver
explicit SafeBrowsingTabObserver(content::WebContents* web_contents);
friend class content::WebContentsUserData<SafeBrowsingTabObserver>;
- // content::NotificationObserver overrides:
- virtual void Observe(int type,
- const content::NotificationSource& source,
- const content::NotificationDetails& details) OVERRIDE;
+ // PrefObserver overrides:
+ virtual void OnPreferenceChanged(PrefServiceBase* service,
+ const std::string& pref_name) OVERRIDE;
// Internal helpers ----------------------------------------------------------

Powered by Google App Engine
This is Rietveld 408576698