| OLD | NEW |
| 1 // Copyright 2012 The Chromium Authors. All rights reserved. | 1 // Copyright 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef CHROME_BROWSER_UI_BROWSER_INSTANT_CONTROLLER_H_ | 5 #ifndef CHROME_BROWSER_UI_BROWSER_INSTANT_CONTROLLER_H_ |
| 6 #define CHROME_BROWSER_UI_BROWSER_INSTANT_CONTROLLER_H_ | 6 #define CHROME_BROWSER_UI_BROWSER_INSTANT_CONTROLLER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 106 void SetOmniboxBounds(const gfx::Rect& bounds); | 106 void SetOmniboxBounds(const gfx::Rect& bounds); |
| 107 | 107 |
| 108 private: | 108 private: |
| 109 // Sets the value of |instant_| based on value from profile. Invoked | 109 // Sets the value of |instant_| based on value from profile. Invoked |
| 110 // on pref change. | 110 // on pref change. |
| 111 void ResetInstant(const std::string& pref_name); | 111 void ResetInstant(const std::string& pref_name); |
| 112 | 112 |
| 113 // Overridden from search::SearchModelObserver: | 113 // Overridden from search::SearchModelObserver: |
| 114 virtual void ModeChanged(const search::Mode& old_mode, | 114 virtual void ModeChanged(const search::Mode& old_mode, |
| 115 const search::Mode& new_mode) OVERRIDE; | 115 const search::Mode& new_mode) OVERRIDE; |
| 116 virtual void TopBarsVisibilityChanged(const search::Mode& mode, |
| 117 bool visible) OVERRIDE {} |
| 116 | 118 |
| 117 // content::NotificationObserver implementation. | 119 // content::NotificationObserver implementation. |
| 118 virtual void Observe(int type, | 120 virtual void Observe(int type, |
| 119 const content::NotificationSource& source, | 121 const content::NotificationSource& source, |
| 120 const content::NotificationDetails& details) OVERRIDE; | 122 const content::NotificationDetails& details) OVERRIDE; |
| 121 | 123 |
| 122 // Helper for handling theme change. | 124 // Helper for handling theme change. |
| 123 void OnThemeChanged(ThemeService* theme_service); | 125 void OnThemeChanged(ThemeService* theme_service); |
| 124 | 126 |
| 125 // Replaces the contents at tab |index| with |new_contents| and deletes the | 127 // Replaces the contents at tab |index| with |new_contents| and deletes the |
| (...skipping 13 matching lines...) Expand all Loading... |
| 139 PrefChangeRegistrar profile_pref_registrar_; | 141 PrefChangeRegistrar profile_pref_registrar_; |
| 140 | 142 |
| 141 content::NotificationRegistrar registrar_; | 143 content::NotificationRegistrar registrar_; |
| 142 | 144 |
| 143 DISALLOW_COPY_AND_ASSIGN(BrowserInstantController); | 145 DISALLOW_COPY_AND_ASSIGN(BrowserInstantController); |
| 144 }; | 146 }; |
| 145 | 147 |
| 146 } // namespace chrome | 148 } // namespace chrome |
| 147 | 149 |
| 148 #endif // CHROME_BROWSER_UI_BROWSER_INSTANT_CONTROLLER_H_ | 150 #endif // CHROME_BROWSER_UI_BROWSER_INSTANT_CONTROLLER_H_ |
| OLD | NEW |