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

Unified Diff: chrome/browser/translate/translate_manager.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/translate/translate_manager.h
diff --git a/chrome/browser/translate/translate_manager.h b/chrome/browser/translate/translate_manager.h
index 93eca3a9c3a159878205d70415857cb7e6cb2d2d..eeb5675b6f8f89c82bc303d22ad1659b1eb12e8e 100644
--- a/chrome/browser/translate/translate_manager.h
+++ b/chrome/browser/translate/translate_manager.h
@@ -15,6 +15,7 @@
#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/prefs/public/pref_change_registrar.h"
+#include "base/prefs/public/pref_observer.h"
#include "base/time.h"
#include "chrome/common/translate_errors.h"
#include "content/public/browser/notification_observer.h"
@@ -41,6 +42,7 @@ class URLFetcher;
// It is a singleton.
class TranslateManager : public content::NotificationObserver,
+ public PrefObserver,
public net::URLFetcherDelegate {
public:
// Returns the singleton instance.
@@ -82,6 +84,10 @@ class TranslateManager : public content::NotificationObserver,
const content::NotificationSource& source,
const content::NotificationDetails& details) OVERRIDE;
+ // PrefObserver implementation:
+ virtual void OnPreferenceChanged(PrefServiceBase* service,
+ const std::string& pref_name) OVERRIDE;
+
// net::URLFetcherDelegate implementation:
virtual void OnURLFetchComplete(const net::URLFetcher* source) OVERRIDE;

Powered by Google App Engine
This is Rietveld 408576698