Chromium Code Reviews| Index: third_party/WebKit/Source/core/paint/NinePieceImagePainter.cpp |
| diff --git a/third_party/WebKit/Source/core/paint/NinePieceImagePainter.cpp b/third_party/WebKit/Source/core/paint/NinePieceImagePainter.cpp |
| index 338b82cc71477d547df5f69dc73423c06ca45afa..51d82366c8513042c31c0e23ca7ca5ee4d94cca8 100644 |
| --- a/third_party/WebKit/Source/core/paint/NinePieceImagePainter.cpp |
| +++ b/third_party/WebKit/Source/core/paint/NinePieceImagePainter.cpp |
| @@ -49,13 +49,15 @@ bool NinePieceImagePainter::paint(GraphicsContext& graphicsContext, const Layout |
| rectWithOutsets.expand(style.imageOutsets(ninePieceImage)); |
| LayoutRect borderImageRect = rectWithOutsets; |
| - IntSize imageSize = roundedIntSize(styleImage->imageSize(m_layoutObject, 1, borderImageRect.size())); |
| + LayoutSize defaultObjectSize = borderImageRect.size(); |
| + defaultObjectSize.scale(1 / style.effectiveZoom()); |
| + IntSize imageSize = roundedIntSize(styleImage->imageSize(m_layoutObject, 1, defaultObjectSize)); |
| IntRectOutsets borderWidths(style.borderTopWidth(), style.borderRightWidth(), |
| style.borderBottomWidth(), style.borderLeftWidth()); |
| NinePieceImageGrid grid(ninePieceImage, imageSize, pixelSnappedIntRect(borderImageRect), borderWidths); |
| - RefPtr<Image> image = styleImage->image(m_layoutObject, imageSize, style.effectiveZoom()); |
| + RefPtr<Image> image = styleImage->image(m_layoutObject, imageSize, 1); |
|
fs
2016/03/22 14:07:23
Maybe add a comment (or two) about why the zoom/sc
davve
2016/03/22 14:29:00
I added two lines to the follow-up documentation p
|
| InterpolationQuality interpolationQuality = BoxPainter::chooseInterpolationQuality(m_layoutObject, image.get(), 0, rectWithOutsets.size()); |
| InterpolationQuality previousInterpolationQuality = graphicsContext.imageInterpolationQuality(); |