OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 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_VIEWS_BOOKMARKS_BOOKMARK_BAR_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_BOOKMARKS_BOOKMARK_BAR_VIEW_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_BOOKMARKS_BOOKMARK_BAR_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_BOOKMARKS_BOOKMARK_BAR_VIEW_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 | 9 |
10 #include "base/compiler_specific.h" | 10 #include "base/compiler_specific.h" |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
94 | 94 |
95 // Sets whether the containing browser is showing an infobar. This affects | 95 // Sets whether the containing browser is showing an infobar. This affects |
96 // layout during animation. | 96 // layout during animation. |
97 void set_infobar_visible(bool infobar_visible) { | 97 void set_infobar_visible(bool infobar_visible) { |
98 infobar_visible_ = infobar_visible; | 98 infobar_visible_ = infobar_visible; |
99 } | 99 } |
100 | 100 |
101 // Changes the state of the bookmark bar. | 101 // Changes the state of the bookmark bar. |
102 void SetBookmarkBarState(BookmarkBar::State state, | 102 void SetBookmarkBarState(BookmarkBar::State state, |
103 BookmarkBar::AnimateChangeType animate_type); | 103 BookmarkBar::AnimateChangeType animate_type); |
| 104 BookmarkBar::State get_bookmark_bar_state() const { |
| 105 return bookmark_bar_state_; |
| 106 } |
104 | 107 |
105 // If |loc| is over a bookmark button the node is returned corresponding to | 108 // If |loc| is over a bookmark button the node is returned corresponding to |
106 // the button and |model_start_index| is set to 0. If a overflow button is | 109 // the button and |model_start_index| is set to 0. If a overflow button is |
107 // showing and |loc| is over the overflow button, the bookmark bar node is | 110 // showing and |loc| is over the overflow button, the bookmark bar node is |
108 // returned and |model_start_index| is set to the index of the first node | 111 // returned and |model_start_index| is set to the index of the first node |
109 // contained in the overflow menu. | 112 // contained in the overflow menu. |
110 const bookmarks::BookmarkNode* GetNodeForButtonAtModelIndex( | 113 const bookmarks::BookmarkNode* GetNodeForButtonAtModelIndex( |
111 const gfx::Point& loc, | 114 const gfx::Point& loc, |
112 int* model_start_index); | 115 int* model_start_index); |
113 | 116 |
(...skipping 348 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
462 | 465 |
463 base::ObserverList<BookmarkBarViewObserver> observers_; | 466 base::ObserverList<BookmarkBarViewObserver> observers_; |
464 | 467 |
465 // Factory used to delay showing of the drop menu. | 468 // Factory used to delay showing of the drop menu. |
466 base::WeakPtrFactory<BookmarkBarView> show_folder_method_factory_; | 469 base::WeakPtrFactory<BookmarkBarView> show_folder_method_factory_; |
467 | 470 |
468 DISALLOW_COPY_AND_ASSIGN(BookmarkBarView); | 471 DISALLOW_COPY_AND_ASSIGN(BookmarkBarView); |
469 }; | 472 }; |
470 | 473 |
471 #endif // CHROME_BROWSER_UI_VIEWS_BOOKMARKS_BOOKMARK_BAR_VIEW_H_ | 474 #endif // CHROME_BROWSER_UI_VIEWS_BOOKMARKS_BOOKMARK_BAR_VIEW_H_ |
OLD | NEW |