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

Unified Diff: Source/core/rendering/RenderThemeChromiumSkia.cpp

Issue 21430003: Implement interfaces in PaintInfo and make it a class. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@getterPaintInfo01
Patch Set: Second try Created 7 years, 5 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: Source/core/rendering/RenderThemeChromiumSkia.cpp
diff --git a/Source/core/rendering/RenderThemeChromiumSkia.cpp b/Source/core/rendering/RenderThemeChromiumSkia.cpp
index ee4f442258ee6e9583db8753c60f7cdd02a9cbd6..5cf16458b84bd041c7a319ee13971afe6413ef13 100644
--- a/Source/core/rendering/RenderThemeChromiumSkia.cpp
+++ b/Source/core/rendering/RenderThemeChromiumSkia.cpp
@@ -245,7 +245,7 @@ bool RenderThemeChromiumSkia::paintSearchFieldCancelButton(RenderObject* cancelB
static Image* cancelImage = Image::loadPlatformResource("searchCancel").leakRef();
static Image* cancelPressedImage = Image::loadPlatformResource("searchCancelPressed").leakRef();
- paintInfo.context->drawImage(isPressed(cancelButtonObject) ? cancelPressedImage : cancelImage, paintingRect);
+ paintInfo.getContext()->drawImage(isPressed(cancelButtonObject) ? cancelPressedImage : cancelImage, paintingRect);
return false;
}
@@ -287,7 +287,7 @@ bool RenderThemeChromiumSkia::paintSearchFieldResultsDecoration(RenderObject* ma
IntRect paintingRect = convertToPaintingRect(inputRenderBox, magnifierObject, magnifierRect, r);
static Image* magnifierImage = Image::loadPlatformResource("searchMagnifier").leakRef();
- paintInfo.context->drawImage(magnifierImage, paintingRect);
+ paintInfo.getContext()->drawImage(magnifierImage, paintingRect);
return false;
}
@@ -471,16 +471,16 @@ RenderThemeChromiumSkia::DirectionFlippingScope::DirectionFlippingScope(RenderOb
{
if (!m_needsFlipping)
return;
- m_paintInfo.context->save();
- m_paintInfo.context->translate(2 * rect.x() + rect.width(), 0);
- m_paintInfo.context->scale(FloatSize(-1, 1));
+ m_paintInfo.getContext()->save();
+ m_paintInfo.getContext()->translate(2 * rect.x() + rect.width(), 0);
+ m_paintInfo.getContext()->scale(FloatSize(-1, 1));
}
RenderThemeChromiumSkia::DirectionFlippingScope::~DirectionFlippingScope()
{
if (!m_needsFlipping)
return;
- m_paintInfo.context->restore();
+ m_paintInfo.getContext()->restore();
}
} // namespace WebCore

Powered by Google App Engine
This is Rietveld 408576698