diff options
author | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-09-18 03:47:18 +0000 |
---|---|---|
committer | ben@chromium.org <ben@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-09-18 03:47:18 +0000 |
commit | cdf17d96522d7103c696f11efcb7d31345a980c6 (patch) | |
tree | 432456ed31c23c567e2658d2754ae9fc0a51840e | |
parent | 3dd099178f7a16b3eb0ef8c63574a2f281cf3bc5 (diff) | |
download | chromium_src-cdf17d96522d7103c696f11efcb7d31345a980c6.zip chromium_src-cdf17d96522d7103c696f11efcb7d31345a980c6.tar.gz chromium_src-cdf17d96522d7103c696f11efcb7d31345a980c6.tar.bz2 |
Add some padding between the right edge of the new tab button and the left edge of the window controls.
http://crbug.com/2451
Review URL: http://codereview.chromium.org/3130
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@2355 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/views/frame/opaque_non_client_view.cc | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/chrome/browser/views/frame/opaque_non_client_view.cc b/chrome/browser/views/frame/opaque_non_client_view.cc index b85186b..e50ba90 100644 --- a/chrome/browser/views/frame/opaque_non_client_view.cc +++ b/chrome/browser/views/frame/opaque_non_client_view.cc @@ -343,6 +343,9 @@ static const int kOTRAvatarIconMargin = 9; // The distance from the top of the window of the OTR avatar icon when the // window is maximized. static const int kNoTitleOTRZoomedTopSpacing = 3; +// Horizontal distance between the right edge of the new tab icon and the left +// edge of the window minimize icon when the window is maximized. +static const int kNewTabIconWindowControlsSpacing = 10; /////////////////////////////////////////////////////////////////////////////// // OpaqueNonClientView, public: @@ -457,8 +460,10 @@ gfx::Rect OpaqueNonClientView::GetWindowBoundsForClientBounds( gfx::Rect OpaqueNonClientView::GetBoundsForTabStrip(TabStrip* tabstrip) { int tabstrip_height = tabstrip->GetPreferredHeight(); int tabstrip_x = otr_avatar_bounds_.right(); - return gfx::Rect(tabstrip_x, 0, minimize_button_->x() - tabstrip_x, - tabstrip_height); + int tabstrip_width = minimize_button_->x() - tabstrip_x; + if (frame_->IsMaximized()) + tabstrip_width -= kNewTabIconWindowControlsSpacing; + return gfx::Rect(tabstrip_x, 0, tabstrip_width, tabstrip_height); } void OpaqueNonClientView::UpdateWindowIcon() { |