| OLD | NEW |
| 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 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_VIEWS_BOOKMARK_BAR_VIEW_H_ | 5 #ifndef CHROME_BROWSER_VIEWS_BOOKMARK_BAR_VIEW_H_ |
| 6 #define CHROME_BROWSER_VIEWS_BOOKMARK_BAR_VIEW_H_ | 6 #define CHROME_BROWSER_VIEWS_BOOKMARK_BAR_VIEW_H_ |
| 7 | 7 |
| 8 #include "chrome/browser/bookmarks/bookmark_drag_data.h" | 8 #include "chrome/browser/bookmarks/bookmark_drag_data.h" |
| 9 #include "chrome/browser/bookmarks/bookmark_model.h" | 9 #include "chrome/browser/bookmarks/bookmark_model.h" |
| 10 #include "chrome/browser/extensions/extensions_service.h" |
| 10 #include "chrome/common/slide_animation.h" | 11 #include "chrome/common/slide_animation.h" |
| 11 #include "chrome/views/label.h" | 12 #include "chrome/views/label.h" |
| 12 #include "chrome/views/menu.h" | 13 #include "chrome/views/menu.h" |
| 13 #include "chrome/views/menu_button.h" | 14 #include "chrome/views/menu_button.h" |
| 14 #include "chrome/views/view.h" | 15 #include "chrome/views/view.h" |
| 15 #include "chrome/views/view_menu_delegate.h" | 16 #include "chrome/views/view_menu_delegate.h" |
| 16 | 17 |
| 17 class Browser; | 18 class Browser; |
| 18 class PageNavigator; | 19 class PageNavigator; |
| 19 class PrefService; | 20 class PrefService; |
| (...skipping 357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 377 | 378 |
| 378 // If the bookmark bubble is showing this determines which view should throb | 379 // If the bookmark bubble is showing this determines which view should throb |
| 379 // and starts it throbbing. Does nothing if bookmark bubble isn't showing. | 380 // and starts it throbbing. Does nothing if bookmark bubble isn't showing. |
| 380 void StartThrobbing(); | 381 void StartThrobbing(); |
| 381 | 382 |
| 382 // If a button is currently throbbing, it is stopped. If immediate is true | 383 // If a button is currently throbbing, it is stopped. If immediate is true |
| 383 // the throb stops immediately, otherwise it stops after a couple more | 384 // the throb stops immediately, otherwise it stops after a couple more |
| 384 // throbs. | 385 // throbs. |
| 385 void StopThrobbing(bool immediate); | 386 void StopThrobbing(bool immediate); |
| 386 | 387 |
| 388 // Add any extension toolstrips which may be requested by the given |
| 389 // extensions. Views for the toolstrips are inserted after the last bookmark |
| 390 // button. Returns true if there were any new toolstrips added. |
| 391 bool AddExtensionToolstrips(const ExtensionList* extensions); |
| 392 |
| 387 Profile* profile_; | 393 Profile* profile_; |
| 388 | 394 |
| 389 // Used for opening urls. | 395 // Used for opening urls. |
| 390 PageNavigator* page_navigator_; | 396 PageNavigator* page_navigator_; |
| 391 | 397 |
| 392 // Model providing details as to the starred entries/groups that should be | 398 // Model providing details as to the starred entries/groups that should be |
| 393 // shown. This is owned by the Profile. | 399 // shown. This is owned by the Profile. |
| 394 BookmarkModel* model_; | 400 BookmarkModel* model_; |
| 395 | 401 |
| 396 // Used to manage showing a Menu: either for the most recently bookmarked | 402 // Used to manage showing a Menu: either for the most recently bookmarked |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 429 scoped_ptr<SlideAnimation> size_animation_; | 435 scoped_ptr<SlideAnimation> size_animation_; |
| 430 | 436 |
| 431 // If the bookmark bubble is showing, this is the URL. | 437 // If the bookmark bubble is showing, this is the URL. |
| 432 GURL bubble_url_; | 438 GURL bubble_url_; |
| 433 | 439 |
| 434 // If the bookmark bubble is showing, this is the visible ancestor of the URL. | 440 // If the bookmark bubble is showing, this is the visible ancestor of the URL. |
| 435 // The visible ancestor is either the other_bookmarked_button_, | 441 // The visible ancestor is either the other_bookmarked_button_, |
| 436 // overflow_button_ or a button on the bar. | 442 // overflow_button_ or a button on the bar. |
| 437 views::BaseButton* throbbing_view_; | 443 views::BaseButton* throbbing_view_; |
| 438 | 444 |
| 445 // How many extension toolstrips we have showing in the toolbar. |
| 446 int num_extension_toolstrips_; |
| 447 |
| 439 DISALLOW_COPY_AND_ASSIGN(BookmarkBarView); | 448 DISALLOW_COPY_AND_ASSIGN(BookmarkBarView); |
| 440 }; | 449 }; |
| 441 | 450 |
| 442 #endif // CHROME_BROWSER_VIEWS_BOOKMARK_BAR_VIEW_H_ | 451 #endif // CHROME_BROWSER_VIEWS_BOOKMARK_BAR_VIEW_H_ |
| 443 | 452 |
| OLD | NEW |