| 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_FRAME_BROWSER_NON_CLIENT_FRAME_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_NON_CLIENT_FRAME_VIEW_H_ |
| 6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_NON_CLIENT_FRAME_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_NON_CLIENT_FRAME_VIEW_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "ui/views/window/non_client_view.h" | 10 #include "ui/views/window/non_client_view.h" |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 // Returns the y coordinate within the window at which the tab strip begins. | 28 // Returns the y coordinate within the window at which the tab strip begins. |
| 29 // If |as_restored| is true, this is calculated as if we were in restored mode | 29 // If |as_restored| is true, this is calculated as if we were in restored mode |
| 30 // regardless of the current mode. This is used to correctly align theme | 30 // regardless of the current mode. This is used to correctly align theme |
| 31 // images. | 31 // images. |
| 32 virtual int GetHorizontalTabStripVerticalOffset( | 32 virtual int GetHorizontalTabStripVerticalOffset( |
| 33 bool force_restored) const = 0; | 33 bool force_restored) const = 0; |
| 34 | 34 |
| 35 // Updates the throbber. | 35 // Updates the throbber. |
| 36 virtual void UpdateThrobber(bool running) = 0; | 36 virtual void UpdateThrobber(bool running) = 0; |
| 37 | 37 |
| 38 #if defined(OS_WIN) | 38 // Overriden from views::View. |
| 39 // Overriden from views::View. For some reason just the do-nothing override | |
| 40 // causes view's gtk version to crash. TODO(cpu): remove ifdef when | |
| 41 // views:gtk is gone. | |
| 42 virtual void VisibilityChanged(views::View* starting_from, | 39 virtual void VisibilityChanged(views::View* starting_from, |
| 43 bool is_visible) OVERRIDE; | 40 bool is_visible) OVERRIDE; |
| 44 #endif | |
| 45 | 41 |
| 46 protected: | 42 protected: |
| 47 BrowserView* browser_view() const { return browser_view_; } | 43 BrowserView* browser_view() const { return browser_view_; } |
| 48 BrowserFrame* frame() const { return frame_; } | 44 BrowserFrame* frame() const { return frame_; } |
| 49 | 45 |
| 50 // Updates the title and icon of the avatar button. | 46 // Updates the title and icon of the avatar button. |
| 51 void UpdateAvatarInfo(); | 47 void UpdateAvatarInfo(); |
| 52 | 48 |
| 53 private: | 49 private: |
| 54 // The frame that hosts this view. | 50 // The frame that hosts this view. |
| 55 BrowserFrame* frame_; | 51 BrowserFrame* frame_; |
| 56 | 52 |
| 57 // The BrowserView hosted within this View. | 53 // The BrowserView hosted within this View. |
| 58 BrowserView* browser_view_; | 54 BrowserView* browser_view_; |
| 59 | 55 |
| 60 // Menu button that displays that either the incognito icon or the profile | 56 // Menu button that displays that either the incognito icon or the profile |
| 61 // icon. May be NULL for some frame styles. | 57 // icon. May be NULL for some frame styles. |
| 62 scoped_ptr<AvatarMenuButton> avatar_button_; | 58 scoped_ptr<AvatarMenuButton> avatar_button_; |
| 63 }; | 59 }; |
| 64 | 60 |
| 65 namespace browser { | 61 namespace browser { |
| 66 | 62 |
| 67 // Provided by a browser_non_client_frame_view_factory_*.cc implementation | 63 // Provided by a browser_non_client_frame_view_factory_*.cc implementation |
| 68 BrowserNonClientFrameView* CreateBrowserNonClientFrameView( | 64 BrowserNonClientFrameView* CreateBrowserNonClientFrameView( |
| 69 BrowserFrame* frame, BrowserView* browser_view); | 65 BrowserFrame* frame, BrowserView* browser_view); |
| 70 | 66 |
| 71 } // browser | 67 } // browser |
| 72 | 68 |
| 73 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_NON_CLIENT_FRAME_VIEW_H_ | 69 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_NON_CLIENT_FRAME_VIEW_H_ |
| OLD | NEW |