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

Unified Diff: ui/native_theme/native_theme_base.cc

Issue 2426793002: Aura overlay scrollbars adjust color for dark backgrounds (Closed)
Patch Set: update Created 4 years, 2 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: ui/native_theme/native_theme_base.cc
diff --git a/ui/native_theme/native_theme_base.cc b/ui/native_theme/native_theme_base.cc
index 54881fe67754302c3d025a0a8288c78e8f692443..c6085cd0fab5025e2258733a653397043bad1c19 100644
--- a/ui/native_theme/native_theme_base.cc
+++ b/ui/native_theme/native_theme_base.cc
@@ -161,7 +161,8 @@ void NativeThemeBase::PaintStateTransition(SkCanvas* canvas,
State startState,
State endState,
double progress,
- const gfx::Rect& rect) const {
+ const gfx::Rect& rect,
+ ScrollbarOverlayStyle style) const {
if (rect.IsEmpty())
return;
@@ -171,7 +172,7 @@ void NativeThemeBase::PaintStateTransition(SkCanvas* canvas,
case kScrollbarHorizontalThumb:
case kScrollbarVerticalThumb:
PaintScrollbarThumbStateTransition(canvas, part, startState, endState,
- progress, rect);
+ progress, rect, style);
break;
default:
NOTREACHED() << "Does not support state transition for this part:"
@@ -227,7 +228,7 @@ void NativeThemeBase::Paint(SkCanvas* canvas,
break;
case kScrollbarHorizontalThumb:
case kScrollbarVerticalThumb:
- PaintScrollbarThumb(canvas, part, state, rect);
+ PaintScrollbarThumb(canvas, part, state, rect, extra.scrollbar_style);
break;
case kScrollbarHorizontalTrack:
case kScrollbarVerticalTrack:
@@ -436,7 +437,8 @@ void NativeThemeBase::PaintScrollbarTrack(SkCanvas* canvas,
void NativeThemeBase::PaintScrollbarThumb(SkCanvas* canvas,
Part part,
State state,
- const gfx::Rect& rect) const {
+ const gfx::Rect& rect,
+ ScrollbarOverlayStyle style) const {
const bool hovered = state == kHovered;
const int midx = rect.x() + rect.width() / 2;
const int midy = rect.y() + rect.height() / 2;
« third_party/WebKit/public/platform/WebThemeEngine.h ('K') | « ui/native_theme/native_theme_base.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698