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

Unified Diff: chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.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/ui/cocoa/location_bar/location_bar_view_mac.h
diff --git a/chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h b/chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h
index 3290143ded04497fda12f3616ea93223a6365492..bba88ff95a2eb6e3f8e53dee141b3e20fdbdfd5e 100644
--- a/chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h
+++ b/chrome/browser/ui/cocoa/location_bar/location_bar_view_mac.h
@@ -13,6 +13,7 @@
#include "base/memory/scoped_ptr.h"
#include "base/memory/scoped_vector.h"
#include "base/memory/weak_ptr.h"
+#include "base/prefs/public/pref_observer.h"
#include "chrome/browser/api/prefs/pref_member.h"
#include "chrome/browser/extensions/image_loading_tracker.h"
#include "chrome/browser/ui/browser.h"
@@ -45,7 +46,8 @@ class ZoomDecoration;
class LocationBarViewMac : public LocationBar,
public LocationBarTesting,
public OmniboxEditController,
- public content::NotificationObserver {
+ public content::NotificationObserver,
+ public PrefObserver {
public:
LocationBarViewMac(AutocompleteTextField* field,
CommandUpdater* command_updater,
@@ -181,6 +183,10 @@ class LocationBarViewMac : public LocationBar,
const content::NotificationSource& source,
const content::NotificationDetails& details) OVERRIDE;
+ // PrefObserver:
+ virtual void OnPreferenceChanged(PrefServiceBase* service,
+ const std::string& pref_name) OVERRIDE;
+
Browser* browser() const { return browser_; }
private:

Powered by Google App Engine
This is Rietveld 408576698