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

Unified Diff: ash/wm/panel_frame_view.cc

Issue 9703034: ash/wm: Use gfx::Canvas::FillRect to draw the separator line instead of relying in DrawLine. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/panel_frame_view.cc
diff --git a/ash/wm/panel_frame_view.cc b/ash/wm/panel_frame_view.cc
index 5fe67bc732840d9d3ce5873bb8da57b61f4ba0d7..0fc122746af9ffc9ecea004d621b30bc1cc1b70a 100644
--- a/ash/wm/panel_frame_view.cc
+++ b/ash/wm/panel_frame_view.cc
@@ -22,6 +22,7 @@ namespace {
const int kClientViewPaddingLeft = 0;
const int kClientViewPaddingRight = 0;
const int kClientViewPaddingBottom = 0;
+const int kSeparatorWidth = 1;
const SkColor kCaptionColor = SK_ColorGRAY;
const SkColor kCaptionIconDivisorColor = SkColorSetARGB(0xFF, 0x55, 0x55, 0x55);
}
@@ -90,11 +91,9 @@ class PanelCaption : public views::View,
// Overridden from views::View:
virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE {
canvas->FillRect(GetLocalBounds(), kCaptionColor);
- gfx::Rect close_button_bounds = close_button_->bounds();
- canvas->DrawLine(
- gfx::Point(close_button_bounds.x(), close_button_bounds.y()),
- gfx::Point(close_button_bounds.x(), close_button_bounds.bottom()),
- kCaptionIconDivisorColor);
+ gfx::Rect bounds(close_button_->bounds());
+ canvas->FillRect(gfx::Rect(bounds.x(), bounds.y(), kSeparatorWidth,
+ bounds.bottom()), kCaptionIconDivisorColor);
Peter Kasting 2012/03/14 20:23:09 Shouldn't this be bounds.height()? Actually a cle
tfarina 2012/03/14 20:36:37 Done.
}
virtual void Layout() OVERRIDE {
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698