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

Unified Diff: chrome/browser/ui/views/frame/glass_browser_frame_view.h

Issue 1869163003: Refactored GlassBrowserFrameView and BrowserDesktopTreeHostWin. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 side-by-side diff with in-line comments
Download patch
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 f14ba9dfa546e2920d12e20d0b89514ab10f6b7b..79fc58e4e9a450c55f6a037082e60ffa973baa19 100644
--- a/chrome/browser/ui/views/frame/glass_browser_frame_view.h
+++ b/chrome/browser/ui/views/frame/glass_browser_frame_view.h
@@ -52,30 +52,38 @@ class GlassBrowserFrameView : public BrowserNonClientFrameView {
bool DoesIntersectRect(const views::View* target,
const gfx::Rect& rect) const override;
- // Returns the thickness of the border that makes up the window left, right,
- // and bottom frame edges. This does not include any client edge.
- int FrameBorderThickness() const;
-
- // Returns the height of the window top frame edge. If |restored| is true,
- // this is calculated as if the window was restored, regardless of its current
- // state.
- int FrameTopBorderHeight(bool restored) const;
-
- // Returns the thickness of the entire nonclient left, right, and bottom
- // borders, including both the window frame and any client edge. If |restored|
- // is true, this is calculated as if the window was restored, regardless of
- // its current state.
- int NonClientBorderThickness(bool restored) const;
-
- // Returns the height of the entire nonclient top border, including the window
- // frame, any title area, and any connected client edge. If |restored| is
- // true, this is calculated as if the window was restored, regardless of its
- // current state.
- int NonClientTopBorderHeight(bool restored) const;
+ // Returns the thickness of the window border for the left, right, and bottom
+ // edges of the frame. On Windows 10 this is a mostly-transparent handle that
+ // allows you to resize the window.
+ int NonClientBorderThickness() const;
+
+ // Returns the thickness of the window border for the top edge of the frame,
+ // which is sometimes different than ::NonClientBorderThickness. Does not
ananta 2016/04/11 21:12:11 Please change to NonClientBorderThickness()
Bret 2016/04/11 23:44:47 Done.
+ // include the titlebar/tabstrip area. If |restored| is true, this is
+ // calculated as if the window was restored, regardless of its current state.
+ int NonClientTopBorderThickness(bool restored) const;
+
+ // Returns the thickness of the border around the client area that separates
+ // it from the non-client area. If |restored| is true, this is calculated as
+ // if the window was restored, regardless of its current state.
+ int ClientBorderThickness(bool restored) const;
+
+ // Returns the height of the entire nonclient top border, from the edge of the
+ // window to the top of the tabs. If |restored| is true, this is calculated as
+ // if the window was restored, regardless of its current state.
+ int NonClientTopHeight(bool restored) const;
// Returns whether the toolbar is currently visible.
bool IsToolbarVisible() const;
+ // Returns whether we should use the special layout for when the caption
+ // buttons are drawn at the top-right corner in RTL mode.
+ bool RTLSpecialLayout() const;
ananta 2016/04/11 21:12:11 Do we need this function?. It just calls into the
Bret 2016/04/11 23:44:47 I'm adding this to make it clear why we're branchi
+
+ // Returns the y coordinate for an element that's aligned as far towards the
+ // top of the window as it should be allowed to draw.
+ int WindowTopY() const;
+
// Paint various sub-components of this view.
void PaintToolbarBackground(gfx::Canvas* canvas) const;
void PaintClientEdge(gfx::Canvas* canvas) const;
@@ -88,7 +96,7 @@ class GlassBrowserFrameView : public BrowserNonClientFrameView {
// Layout various sub-components of this view.
void LayoutIncognitoIcon();
- void LayoutNewStyleAvatar();
+ void LayoutAvatar();
void LayoutClientView();
// Returns the insets of the client area. If |restored| is true, this is

Powered by Google App Engine
This is Rietveld 408576698