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

Unified Diff: ui/native_theme/native_theme_aurawin.cc

Issue 148223015: Tweaks for scrollbar insets (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 11 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: ui/native_theme/native_theme_aurawin.cc
diff --git a/ui/native_theme/native_theme_aurawin.cc b/ui/native_theme/native_theme_aurawin.cc
index 82aae3d32d16da00964b8da535c31ffb6fa653d1..83dc3c3b818c6978d2aab86b742f7bb9433bf9d6 100644
--- a/ui/native_theme/native_theme_aurawin.cc
+++ b/ui/native_theme/native_theme_aurawin.cc
@@ -109,13 +109,6 @@ void NativeThemeAuraWin::PaintArrowButton(
scrollbar_arrow_button_painters_),
gc, rect);
- // The arrow is slightly offset to better balance with the thumb.
- gfx::Rect arrow_rect(rect);
- if (direction == kScrollbarDownArrow || direction == kScrollbarUpArrow)
- arrow_rect.Offset(1, 0);
- else
- arrow_rect.Offset(0, 1);
-
// Aura-win uses slightly different arrow colors.
SkColor arrow_color = GetArrowColor(state);
switch (state) {
@@ -128,7 +121,7 @@ void NativeThemeAuraWin::PaintArrowButton(
default:
break;
}
- PaintArrow(gc, arrow_rect, direction, arrow_color);
+ PaintArrow(gc, rect, direction, arrow_color);
}
void NativeThemeAuraWin::PaintScrollbarTrack(
@@ -148,9 +141,9 @@ void NativeThemeAuraWin::PaintScrollbarThumb(SkCanvas* sk_canvas,
const gfx::Rect& rect) const {
gfx::Rect thumb_rect(rect);
if (part == NativeTheme::kScrollbarVerticalThumb)
- thumb_rect.Inset(3, 0, 1, 0);
+ thumb_rect.Inset(2, 0, 2, 0);
else
- thumb_rect.Inset(0, 3, 0, 1);
+ thumb_rect.Inset(0, 2, 0, 2);
PaintPainter(GetOrCreatePainter(
kScrollbarThumbImages, state, scrollbar_thumb_painters_),
sk_canvas, thumb_rect);
« 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