| Index: third_party/WebKit/Source/platform/exported/WebScrollbarThemePainter.cpp
|
| diff --git a/third_party/WebKit/Source/platform/exported/WebScrollbarThemePainter.cpp b/third_party/WebKit/Source/platform/exported/WebScrollbarThemePainter.cpp
|
| index 8b63bbffefa025a5c11808b04db7e8dfe09f394b..91216707ad07d3b745aa795dcc6799e8e8c2d160 100644
|
| --- a/third_party/WebKit/Source/platform/exported/WebScrollbarThemePainter.cpp
|
| +++ b/third_party/WebKit/Source/platform/exported/WebScrollbarThemePainter.cpp
|
| @@ -68,6 +68,8 @@ void WebScrollbarThemePainter::paintTrackBackground(WebCanvas* canvas, const Web
|
| pictureBuilder.context().setDeviceScaleFactor(m_deviceScaleFactor);
|
| m_theme->paintTrackBackground(&pictureBuilder.context(), m_scrollbar.get(), intRect);
|
| pictureBuilder.endRecording()->playback(canvas);
|
| + if (!m_theme->shouldRepaintAllPartsOnInvalidation())
|
| + m_scrollbar->setTrackBackgroundNeedsRepaint(false);
|
| }
|
|
|
| void WebScrollbarThemePainter::paintBackTrackPart(WebCanvas* canvas, const WebRect& rect)
|
| @@ -140,6 +142,8 @@ void WebScrollbarThemePainter::paintThumb(WebCanvas* canvas, const WebRect& rect
|
| pictureBuilder.context().setDeviceScaleFactor(m_deviceScaleFactor);
|
| m_theme->paintThumb(&pictureBuilder.context(), m_scrollbar.get(), intRect);
|
| pictureBuilder.endRecording()->playback(canvas);
|
| + if (!m_theme->shouldRepaintAllPartsOnInvalidation())
|
| + m_scrollbar->setThumbNeedsRepaint(false);
|
| }
|
|
|
| WebScrollbarThemePainter::WebScrollbarThemePainter(ScrollbarTheme* theme, Scrollbar* scrollbar, float deviceScaleFactor)
|
| @@ -149,4 +153,24 @@ WebScrollbarThemePainter::WebScrollbarThemePainter(ScrollbarTheme* theme, Scroll
|
| {
|
| }
|
|
|
| +float WebScrollbarThemePainter::thumbOpacity() const
|
| +{
|
| + return m_theme->thumbOpacity(m_scrollbar.get());
|
| +}
|
| +
|
| +float WebScrollbarThemePainter::trackOpacity() const
|
| +{
|
| + return m_theme->trackOpacity(m_scrollbar.get());
|
| +}
|
| +
|
| +bool WebScrollbarThemePainter::trackBackgroundNeedsRepaint() const
|
| +{
|
| + return m_scrollbar->trackBackgroundNeedsRepaint();
|
| +}
|
| +
|
| +bool WebScrollbarThemePainter::thumbNeedsRepaint() const
|
| +{
|
| + return m_scrollbar->thumbNeedsRepaint();
|
| +}
|
| +
|
| } // namespace blink
|
|
|