OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_FRAME_BROWSER_EXTENDER_H_ | 5 #ifndef CHROME_BROWSER_VIEWS_FRAME_BROWSER_EXTENDER_H_ |
6 #define CHROME_BROWSER_VIEWS_FRAME_BROWSER_EXTENDER_H_ | 6 #define CHROME_BROWSER_VIEWS_FRAME_BROWSER_EXTENDER_H_ |
7 | 7 |
8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
9 #include "base/gfx/rect.h" | 9 #include "base/gfx/rect.h" |
10 | 10 |
11 class BrowserView; | 11 class BrowserView; |
| 12 class Tab; |
12 | 13 |
13 namespace views { | 14 namespace views { |
14 class Window; | 15 class Window; |
15 } // namespace views | 16 } // namespace views |
16 | 17 |
17 | 18 |
18 // BrowserExtender adds chromeos specific features to BrowserView. | 19 // BrowserExtender adds chromeos specific features to BrowserView. |
19 // The factory method |Create(BrowserView*)| creates different types | 20 // The factory method |Create(BrowserView*)| creates different types |
20 // of extender depending on the type of BrowserView and target platform. | 21 // of extender depending on the type of BrowserView and target platform. |
21 // Please see chromeos_browser_extenders.cc for ChromeOS extenders, and | 22 // Please see chromeos_browser_extenders.cc for ChromeOS extenders, and |
(...skipping 29 matching lines...) Expand all Loading... |
51 // Called when the browser window is either activated or deactivated. | 52 // Called when the browser window is either activated or deactivated. |
52 virtual void ActivationChanged() = 0; | 53 virtual void ActivationChanged() = 0; |
53 | 54 |
54 // Returns true to hide the toolbar for the window, or false | 55 // Returns true to hide the toolbar for the window, or false |
55 // to use the regular logic to decide. | 56 // to use the regular logic to decide. |
56 virtual bool ShouldForceHideToolbar() = 0; | 57 virtual bool ShouldForceHideToolbar() = 0; |
57 | 58 |
58 // Toggles the visibility of CompactNavigationBar. | 59 // Toggles the visibility of CompactNavigationBar. |
59 virtual void ToggleCompactNavigationBar() = 0; | 60 virtual void ToggleCompactNavigationBar() = 0; |
60 | 61 |
| 62 // Called when a mouse entered into the |tab|. |
| 63 virtual void OnMouseEnteredToTab(Tab* tab) = 0; |
| 64 |
| 65 // Called when a mouse moved (hovered) on the |tab|. |
| 66 virtual void OnMouseMovedOnTab(Tab* tab) = 0; |
| 67 |
| 68 // Called when a mouse exited from the |tab|. |
| 69 virtual void OnMouseExitedFromTab(Tab* tab) = 0; |
| 70 |
61 // Tells if the browser can be closed. | 71 // Tells if the browser can be closed. |
62 bool can_close() const { | 72 bool can_close() const { |
63 return can_close_; | 73 return can_close_; |
64 } | 74 } |
65 | 75 |
66 // Specifies if the browser can be closed or not. This typically set | 76 // Specifies if the browser can be closed or not. This typically set |
67 // to false when the browser is being dragged. | 77 // to false when the browser is being dragged. |
68 void set_can_close(bool b) { | 78 void set_can_close(bool b) { |
69 can_close_ = b; | 79 can_close_ = b; |
70 } | 80 } |
(...skipping 12 matching lines...) Expand all Loading... |
83 // BrowserView to be extended. | 93 // BrowserView to be extended. |
84 BrowserView* browser_view_; | 94 BrowserView* browser_view_; |
85 | 95 |
86 // True if the browser can be closed. See set_can_close method for setails. | 96 // True if the browser can be closed. See set_can_close method for setails. |
87 bool can_close_; | 97 bool can_close_; |
88 | 98 |
89 DISALLOW_COPY_AND_ASSIGN(BrowserExtender); | 99 DISALLOW_COPY_AND_ASSIGN(BrowserExtender); |
90 }; | 100 }; |
91 | 101 |
92 #endif // CHROME_BROWSER_CHROMEOS_BROWSER_EXTENDER_H_ | 102 #endif // CHROME_BROWSER_CHROMEOS_BROWSER_EXTENDER_H_ |
OLD | NEW |