Chromium Code Reviews| Index: chrome/browser/ui/toolbar/toolbar_actions_bar.h |
| diff --git a/chrome/browser/ui/toolbar/toolbar_actions_bar.h b/chrome/browser/ui/toolbar/toolbar_actions_bar.h |
| index 2e78ef387ce2eea9ee5504ecc69c2f9f54453679..d00e3d985d868e01f74db2776a579130365a88af 100644 |
| --- a/chrome/browser/ui/toolbar/toolbar_actions_bar.h |
| +++ b/chrome/browser/ui/toolbar/toolbar_actions_bar.h |
| @@ -101,9 +101,23 @@ class ToolbarActionsBar : public ToolbarActionsModel::Observer { |
| // Returns the number of icons that can fit within the given width. |
| size_t WidthToIconCount(int width) const; |
| - // Returns the number of icons that should be displayed. |
| + // Returns the number of icons that should be displayed if space allows. |
| size_t GetIconCount() const; |
| + // Returns the starting index (inclusive) for displayable icons. |
| + size_t GetStartIndexInBounds() const; |
| + |
| + // Returns the ending index (exclusive) for displayable icons. |
| + size_t GetEndIndexInBounds() const; |
| + |
| + // Returns true if an overflow container is necessary to display any other |
| + // icons. This is different than ToolbarActionsModel::all_icons_visible() |
| + // because the ToolbarActionsBar (which represents the UI for a specific |
| + // window) might be unable to display all the icons that the model (which |
| + // represents the underlying model of *all* windows) is set to, such as in |
|
Peter Kasting
2015/09/17 00:18:04
So does this mean that if all windows are equally
Devlin
2015/09/17 17:00:27
I've cleared up this comment, and added some bette
Peter Kasting
2015/09/17 19:59:53
Yeah, these help.
|
| + // the case of a very narrow window. |
|
Peter Kasting
2015/09/17 00:18:04
This comment helps, but it might be necessary to i
Devlin
2015/09/17 17:00:27
See above.
|
| + bool NeedsOverflow() const; |
| + |
| // Returns the frame (bounds) that the specified index should have, taking |
| // into account if this is the main or overflow bar. If this is the overflow |
| // bar and the index should not be displayed (i.e., it is shown on the main |