| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_VIEWS_TOOLBAR_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_TOOLBAR_VIEW_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_TOOLBAR_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_TOOLBAR_VIEW_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 #include <string> |
| 10 | 11 |
| 11 #include "base/memory/scoped_ptr.h" | 12 #include "base/memory/scoped_ptr.h" |
| 12 #include "base/observer_list.h" | 13 #include "base/observer_list.h" |
| 13 #include "chrome/browser/command_updater.h" | 14 #include "chrome/browser/command_updater.h" |
| 14 #include "chrome/browser/prefs/pref_member.h" | 15 #include "chrome/browser/prefs/pref_member.h" |
| 15 #include "chrome/browser/ui/toolbar/back_forward_menu_model.h" | 16 #include "chrome/browser/ui/toolbar/back_forward_menu_model.h" |
| 16 #include "chrome/browser/ui/views/accessible_pane_view.h" | 17 #include "chrome/browser/ui/views/accessible_pane_view.h" |
| 17 #include "chrome/browser/ui/views/location_bar/location_bar_view.h" | 18 #include "chrome/browser/ui/views/location_bar/location_bar_view.h" |
| 18 #include "chrome/browser/ui/views/reload_button.h" | 19 #include "chrome/browser/ui/views/reload_button.h" |
| 19 #include "ui/base/animation/slide_animation.h" | 20 #include "ui/base/animation/slide_animation.h" |
| (...skipping 140 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 160 // Types of display mode this toolbar can have. | 161 // Types of display mode this toolbar can have. |
| 161 enum DisplayMode { | 162 enum DisplayMode { |
| 162 DISPLAYMODE_NORMAL, // Normal toolbar with buttons, etc. | 163 DISPLAYMODE_NORMAL, // Normal toolbar with buttons, etc. |
| 163 DISPLAYMODE_LOCATION // Slimline toolbar showing only compact location | 164 DISPLAYMODE_LOCATION // Slimline toolbar showing only compact location |
| 164 // bar, used for popups. | 165 // bar, used for popups. |
| 165 }; | 166 }; |
| 166 bool IsDisplayModeNormal() const { | 167 bool IsDisplayModeNormal() const { |
| 167 return display_mode_ == DISPLAYMODE_NORMAL; | 168 return display_mode_ == DISPLAYMODE_NORMAL; |
| 168 } | 169 } |
| 169 | 170 |
| 171 // Shows the critical notification bubble against the wrench menu. |
| 172 void ShowCriticalNotification(); |
| 173 |
| 170 // Updates the badge on the app menu (Wrench). | 174 // Updates the badge on the app menu (Wrench). |
| 171 void UpdateAppMenuBadge(); | 175 void UpdateAppMenuBadge(); |
| 172 | 176 |
| 173 // Gets a badge for the wrench icon corresponding to the number of | 177 // Gets a badge for the wrench icon corresponding to the number of |
| 174 // unacknowledged background pages in the system. | 178 // unacknowledged background pages in the system. |
| 175 SkBitmap GetBackgroundPageBadge(); | 179 SkBitmap GetBackgroundPageBadge(); |
| 176 | 180 |
| 177 scoped_ptr<BackForwardMenuModel> back_menu_model_; | 181 scoped_ptr<BackForwardMenuModel> back_menu_model_; |
| 178 scoped_ptr<BackForwardMenuModel> forward_menu_model_; | 182 scoped_ptr<BackForwardMenuModel> forward_menu_model_; |
| 179 | 183 |
| (...skipping 24 matching lines...) Expand all Loading... |
| 204 | 208 |
| 205 // A list of listeners to call when the menu opens. | 209 // A list of listeners to call when the menu opens. |
| 206 ObserverList<views::MenuListener> menu_listeners_; | 210 ObserverList<views::MenuListener> menu_listeners_; |
| 207 | 211 |
| 208 NotificationRegistrar registrar_; | 212 NotificationRegistrar registrar_; |
| 209 | 213 |
| 210 DISALLOW_IMPLICIT_CONSTRUCTORS(ToolbarView); | 214 DISALLOW_IMPLICIT_CONSTRUCTORS(ToolbarView); |
| 211 }; | 215 }; |
| 212 | 216 |
| 213 #endif // CHROME_BROWSER_UI_VIEWS_TOOLBAR_VIEW_H_ | 217 #endif // CHROME_BROWSER_UI_VIEWS_TOOLBAR_VIEW_H_ |
| OLD | NEW |