| Index: chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm
|
| diff --git a/chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm b/chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm
|
| index 39f326e4da0b3ffb185cd90730dac2d04c47064a..91a0fcb755549d7a6e9717c44c5c4c7b0c5fc40d 100644
|
| --- a/chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm
|
| +++ b/chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm
|
| @@ -9,7 +9,6 @@
|
| #include "base/mac/bundle_locations.h"
|
| #include "base/mac/mac_util.h"
|
| #include "base/memory/singleton.h"
|
| -#include "base/prefs/public/pref_observer.h"
|
| #include "base/string_util.h"
|
| #include "base/sys_string_conversions.h"
|
| #include "base/utf_string_conversions.h"
|
| @@ -107,8 +106,7 @@ namespace ToolbarControllerInternal {
|
| // preferences and upgrade available notifications. Bridges the notification
|
| // back to the ToolbarController.
|
| class NotificationBridge
|
| - : public content::NotificationObserver,
|
| - public PrefObserver {
|
| + : public content::NotificationObserver {
|
| public:
|
| explicit NotificationBridge(ToolbarController* controller)
|
| : controller_(controller) {
|
| @@ -132,9 +130,7 @@ class NotificationBridge
|
| }
|
| }
|
|
|
| - // Overridden from PrefObserver:
|
| - virtual void OnPreferenceChanged(PrefServiceBase* service,
|
| - const std::string& pref_name) OVERRIDE {
|
| + void OnPreferenceChanged(const std::string& pref_name) {
|
| [controller_ prefChanged:pref_name];
|
| }
|
|
|
| @@ -281,7 +277,8 @@ class NotificationBridge
|
| new ToolbarControllerInternal::NotificationBridge(self));
|
| PrefService* prefs = profile_->GetPrefs();
|
| showHomeButton_.Init(prefs::kShowHomeButton, prefs,
|
| - notificationBridge_.get());
|
| + base::Bind(&NotificationBridge::OnPreferenceChanged,
|
| + base::Unretained(notificationBridge_.get())));
|
| [self showOptionalHomeButton];
|
| [self installWrenchMenu];
|
|
|
|
|