Chromium Code Reviews| Index: chrome/browser/ui/views/frame/glass_browser_frame_view.h |
| diff --git a/chrome/browser/ui/views/frame/glass_browser_frame_view.h b/chrome/browser/ui/views/frame/glass_browser_frame_view.h |
| index 8b0ad07cd6475aa4dbbeb5512a5421fd3060b860..0a94580de11b220cf90e5c509436774652229a09 100644 |
| --- a/chrome/browser/ui/views/frame/glass_browser_frame_view.h |
| +++ b/chrome/browser/ui/views/frame/glass_browser_frame_view.h |
| @@ -13,6 +13,8 @@ |
| #include "chrome/browser/ui/views/frame/windows_10_caption_button.h" |
| #include "chrome/browser/ui/views/tab_icon_view.h" |
| #include "chrome/browser/ui/views/tab_icon_view_model.h" |
| +#include "chrome/browser/ui/views/tabs/tab_strip.h" |
| +#include "chrome/browser/ui/views/tabs/tab_strip_observer.h" |
| #include "ui/views/controls/button/button.h" |
| #include "ui/views/window/non_client_view.h" |
| @@ -20,7 +22,8 @@ class BrowserView; |
| class GlassBrowserFrameView : public BrowserNonClientFrameView, |
| public views::ButtonListener, |
| - public TabIconViewModel { |
| + public TabIconViewModel, |
| + public TabStripObserver { |
| public: |
| // Constructs a non-client view for an BrowserFrame. |
| GlassBrowserFrameView(BrowserFrame* frame, BrowserView* browser_view); |
| @@ -32,7 +35,8 @@ class GlassBrowserFrameView : public BrowserNonClientFrameView, |
| int GetThemeBackgroundXInset() const override; |
| void UpdateThrobber(bool running) override; |
| gfx::Size GetMinimumSize() const override; |
| - views::View* GetProfileSwitcherView() const override; |
| + views::MenuButton* GetProfileSwitcherButton() const override; |
| + void OnBrowserViewInitViewsComplete() override; |
| // views::NonClientFrameView: |
| gfx::Rect GetBoundsForClientView() const override; |
| @@ -73,6 +77,11 @@ class GlassBrowserFrameView : public BrowserNonClientFrameView, |
| bool DoesIntersectRect(const views::View* target, |
| const gfx::Rect& rect) const override; |
| + // TabStripObserver: |
| + void TabStripMaxXChanged(TabStrip* tab_strip) override; |
| + void TabStripDeleted(TabStrip* tab_strip) override; |
| + void TabStripRemovedTabAt(TabStrip* tab_strip, int index) override; |
| + |
| // Returns the thickness of the border around the client area (web content, |
| // toolbar, and tabs) that separates it from the frame border. If |restored| |
| // is true, this is calculated as if the window was restored, regardless of |
| @@ -189,6 +198,9 @@ class GlassBrowserFrameView : public BrowserNonClientFrameView, |
| // The index of the current frame of the throbber animation. |
| int throbber_frame_; |
| + // TabStrip, which we need to watch for changes to resize the avatar button |
|
msarda
2017/04/21 09:43:28
It is not clear what "we" means in this context:
*
emx
2017/04/24 16:23:10
Done.
|
| + TabStrip* tab_strip_; |
| + |
| static const int kThrobberIconCount = 24; |
| static HICON throbber_icons_[kThrobberIconCount]; |
| static void InitThrobberIcons(); |