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_VIEW_H_ | 5 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ |
6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ | 6 #define CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
117 // Returns a Browser instance of this view. | 117 // Returns a Browser instance of this view. |
118 Browser* browser() { return browser_.get(); } | 118 Browser* browser() { return browser_.get(); } |
119 const Browser* browser() const { return browser_.get(); } | 119 const Browser* browser() const { return browser_.get(); } |
120 | 120 |
121 // Initializes (or re-initializes) the status bubble. We try to only create | 121 // Initializes (or re-initializes) the status bubble. We try to only create |
122 // the bubble once and re-use it for the life of the browser, but certain | 122 // the bubble once and re-use it for the life of the browser, but certain |
123 // events (such as changing enabling/disabling Aero on Win) can force a need | 123 // events (such as changing enabling/disabling Aero on Win) can force a need |
124 // to change some of the bubble's creation parameters. | 124 // to change some of the bubble's creation parameters. |
125 void InitStatusBubble(); | 125 void InitStatusBubble(); |
126 | 126 |
127 // Initializes the permission bubble view. This class is intended to be | |
128 // created once and then re-used for the life of the browser window. The | |
129 // bubbles it creates will be associated with a single visible tab. | |
130 void InitPermissionBubbleView(); | |
131 | |
132 // Returns the apparent bounds of the toolbar, in BrowserView coordinates. | 127 // Returns the apparent bounds of the toolbar, in BrowserView coordinates. |
133 // These differ from |toolbar_.bounds()| in that they match where the toolbar | 128 // These differ from |toolbar_.bounds()| in that they match where the toolbar |
134 // background image is drawn -- slightly outside the "true" bounds | 129 // background image is drawn -- slightly outside the "true" bounds |
135 // horizontally. Note that this returns the bounds for the toolbar area. | 130 // horizontally. Note that this returns the bounds for the toolbar area. |
136 gfx::Rect GetToolbarBounds() const; | 131 gfx::Rect GetToolbarBounds() const; |
137 | 132 |
138 // Returns the constraining bounding box that should be used to lay out the | 133 // Returns the constraining bounding box that should be used to lay out the |
139 // FindBar within. This is _not_ the size of the find bar, just the bounding | 134 // FindBar within. This is _not_ the size of the find bar, just the bounding |
140 // box it should be laid out within. The coordinate system of the returned | 135 // box it should be laid out within. The coordinate system of the returned |
141 // rect is in the coordinate system of the frame, since the FindBar is a child | 136 // rect is in the coordinate system of the frame, since the FindBar is a child |
(...skipping 515 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
657 // Tracks and stores the last focused view which is not the | 652 // Tracks and stores the last focused view which is not the |
658 // devtools_web_view_ or any of its children. Used to restore focus once | 653 // devtools_web_view_ or any of its children. Used to restore focus once |
659 // the devtools_web_view_ is hidden. | 654 // the devtools_web_view_ is hidden. |
660 scoped_ptr<views::ExternalFocusTracker> devtools_focus_tracker_; | 655 scoped_ptr<views::ExternalFocusTracker> devtools_focus_tracker_; |
661 | 656 |
662 // The Status information bubble that appears at the bottom of the window. | 657 // The Status information bubble that appears at the bottom of the window. |
663 scoped_ptr<StatusBubbleViews> status_bubble_; | 658 scoped_ptr<StatusBubbleViews> status_bubble_; |
664 | 659 |
665 // The permission bubble view is the toolkit-specific implementation of the | 660 // The permission bubble view is the toolkit-specific implementation of the |
666 // interface used by the manager to display permissions bubbles. | 661 // interface used by the manager to display permissions bubbles. |
667 scoped_ptr<PermissionBubbleViewViews> permission_bubble_view_; | 662 scoped_ptr<PermissionBubbleViewViews> permission_bubble_; |
668 | 663 |
669 // A mapping between accelerators and commands. | 664 // A mapping between accelerators and commands. |
670 std::map<ui::Accelerator, int> accelerator_table_; | 665 std::map<ui::Accelerator, int> accelerator_table_; |
671 | 666 |
672 // True if we have already been initialized. | 667 // True if we have already been initialized. |
673 bool initialized_; | 668 bool initialized_; |
674 | 669 |
675 // True when in ProcessFullscreen(). The flag is used to avoid reentrance and | 670 // True when in ProcessFullscreen(). The flag is used to avoid reentrance and |
676 // to ignore requests to layout while in ProcessFullscreen() to reduce | 671 // to ignore requests to layout while in ProcessFullscreen() to reduce |
677 // jankiness. | 672 // jankiness. |
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
715 scoped_ptr<ImmersiveModeController> immersive_mode_controller_; | 710 scoped_ptr<ImmersiveModeController> immersive_mode_controller_; |
716 | 711 |
717 scoped_ptr<WebContentsCloseHandler> web_contents_close_handler_; | 712 scoped_ptr<WebContentsCloseHandler> web_contents_close_handler_; |
718 | 713 |
719 mutable base::WeakPtrFactory<BrowserView> activate_modal_dialog_factory_; | 714 mutable base::WeakPtrFactory<BrowserView> activate_modal_dialog_factory_; |
720 | 715 |
721 DISALLOW_COPY_AND_ASSIGN(BrowserView); | 716 DISALLOW_COPY_AND_ASSIGN(BrowserView); |
722 }; | 717 }; |
723 | 718 |
724 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ | 719 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_BROWSER_VIEW_H_ |
OLD | NEW |