Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(721)

Side by Side Diff: chrome/browser/ui/views/frame/opaque_browser_frame_view.h

Issue 6692001: Add in DOMBrowserView and Frame related classes (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_OPAQUE_BROWSER_FRAME_VIEW_H_ 5 #ifndef CHROME_BROWSER_UI_VIEWS_FRAME_OPAQUE_BROWSER_FRAME_VIEW_H_
6 #define CHROME_BROWSER_UI_VIEWS_FRAME_OPAQUE_BROWSER_FRAME_VIEW_H_ 6 #define CHROME_BROWSER_UI_VIEWS_FRAME_OPAQUE_BROWSER_FRAME_VIEW_H_
7 #pragma once 7 #pragma once
8 8
9 #include "chrome/browser/ui/views/frame/browser_frame.h" 9 #include "chrome/browser/ui/views/frame/browser_frame.h"
10 #include "chrome/browser/ui/views/frame/browser_non_client_frame_view.h" 10 #include "chrome/browser/ui/views/frame/browser_non_client_frame_view.h"
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
64 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE; 64 virtual void GetAccessibleState(ui::AccessibleViewState* state) OVERRIDE;
65 65
66 // Overridden from views::ButtonListener: 66 // Overridden from views::ButtonListener:
67 virtual void ButtonPressed(views::Button* sender, const views::Event& event) 67 virtual void ButtonPressed(views::Button* sender, const views::Event& event)
68 OVERRIDE; 68 OVERRIDE;
69 69
70 // Overridden from TabIconView::TabIconViewModel: 70 // Overridden from TabIconView::TabIconViewModel:
71 virtual bool ShouldTabIconViewAnimate() const OVERRIDE; 71 virtual bool ShouldTabIconViewAnimate() const OVERRIDE;
72 virtual SkBitmap GetFavIconForTabIconView() OVERRIDE; 72 virtual SkBitmap GetFavIconForTabIconView() OVERRIDE;
73 73
74 protected:
75 virtual void LayoutOTRAvatar();
76
74 private: 77 private:
75 // Returns the thickness of the border that makes up the window frame edges. 78 // Returns the thickness of the border that makes up the window frame edges.
76 // This does not include any client edge. If |restored| is true, acts as if 79 // This does not include any client edge. If |restored| is true, acts as if
77 // the window is restored regardless of the real mode. 80 // the window is restored regardless of the real mode.
78 int FrameBorderThickness(bool restored) const; 81 int FrameBorderThickness(bool restored) const;
79 82
80 // Returns the height of the top resize area. This is smaller than the frame 83 // Returns the height of the top resize area. This is smaller than the frame
81 // border height in order to increase the window draggable area. 84 // border height in order to increase the window draggable area.
82 int TopResizeHeight() const; 85 int TopResizeHeight() const;
83 86
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
115 void PaintRestoredFrameBorder(gfx::Canvas* canvas); 118 void PaintRestoredFrameBorder(gfx::Canvas* canvas);
116 void PaintMaximizedFrameBorder(gfx::Canvas* canvas); 119 void PaintMaximizedFrameBorder(gfx::Canvas* canvas);
117 void PaintTitleBar(gfx::Canvas* canvas); 120 void PaintTitleBar(gfx::Canvas* canvas);
118 void PaintToolbarBackground(gfx::Canvas* canvas); 121 void PaintToolbarBackground(gfx::Canvas* canvas);
119 void PaintOTRAvatar(gfx::Canvas* canvas); 122 void PaintOTRAvatar(gfx::Canvas* canvas);
120 void PaintRestoredClientEdge(gfx::Canvas* canvas); 123 void PaintRestoredClientEdge(gfx::Canvas* canvas);
121 124
122 // Layout various sub-components of this view. 125 // Layout various sub-components of this view.
123 void LayoutWindowControls(); 126 void LayoutWindowControls();
124 void LayoutTitleBar(); 127 void LayoutTitleBar();
125 void LayoutOTRAvatar();
126 128
127 // Returns the bounds of the client area for the specified view size. 129 // Returns the bounds of the client area for the specified view size.
128 gfx::Rect CalculateClientAreaBounds(int width, int height) const; 130 gfx::Rect CalculateClientAreaBounds(int width, int height) const;
129 131
130 // The layout rect of the title, if visible. 132 // The layout rect of the title, if visible.
131 gfx::Rect title_bounds_; 133 gfx::Rect title_bounds_;
132 134
133 // The layout rect of the OTR avatar icon, if visible. 135 // The layout rect of the OTR avatar icon, if visible.
134 gfx::Rect otr_avatar_bounds_; 136 gfx::Rect otr_avatar_bounds_;
135 137
(...skipping 12 matching lines...) Expand all
148 // The BrowserView hosted within this View. 150 // The BrowserView hosted within this View.
149 BrowserView* browser_view_; 151 BrowserView* browser_view_;
150 152
151 // The bounds of the ClientView. 153 // The bounds of the ClientView.
152 gfx::Rect client_view_bounds_; 154 gfx::Rect client_view_bounds_;
153 155
154 DISALLOW_COPY_AND_ASSIGN(OpaqueBrowserFrameView); 156 DISALLOW_COPY_AND_ASSIGN(OpaqueBrowserFrameView);
155 }; 157 };
156 158
157 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_OPAQUE_BROWSER_FRAME_VIEW_H_ 159 #endif // CHROME_BROWSER_UI_VIEWS_FRAME_OPAQUE_BROWSER_FRAME_VIEW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698