diff options
author | Simon Hausmann <simon.hausmann@nokia.com> | 2012-07-23 09:28:44 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@nokia.com> | 2012-07-23 09:28:44 +0200 |
commit | 815f1ed417bd26fbe2abbdf20ac5d3423b30796c (patch) | |
tree | 923c9a9e2834ccab60f5caecfb8f0ac410c1dd9e /Source/WebCore/rendering/RenderBoxModelObject.cpp | |
parent | b4ad5d9d2b96baacd0180ead50de5195ca78af2d (diff) | |
download | qtwebkit-815f1ed417bd26fbe2abbdf20ac5d3423b30796c.tar.gz |
Imported WebKit commit e65cbc5b6ac32627c797e7fc7f46eb7794410c92 (http://svn.webkit.org/repository/webkit/trunk@123308)
New snapshot with better configure tests
Diffstat (limited to 'Source/WebCore/rendering/RenderBoxModelObject.cpp')
-rw-r--r-- | Source/WebCore/rendering/RenderBoxModelObject.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/Source/WebCore/rendering/RenderBoxModelObject.cpp b/Source/WebCore/rendering/RenderBoxModelObject.cpp index 8f9b9a622..5eef3ccac 100644 --- a/Source/WebCore/rendering/RenderBoxModelObject.cpp +++ b/Source/WebCore/rendering/RenderBoxModelObject.cpp @@ -1171,13 +1171,11 @@ void RenderBoxModelObject::calculateBackgroundImageGeometry(const FillLayer* fil // its margins. Since those were added in already, we have to factor them out when computing // the background positioning area. if (isRoot()) { - positioningAreaSize = IntSize(snapSizeToPixel(toRenderBox(this)->width() - left - right, toRenderBox(this)->x()), - snapSizeToPixel(toRenderBox(this)->height() - top - bottom, toRenderBox(this)->y())); + positioningAreaSize = pixelSnappedIntSize(toRenderBox(this)->size() - LayoutSize(left + right, top + bottom), toRenderBox(this)->location()); left += marginLeft(); top += marginTop(); } else - positioningAreaSize = IntSize(snapSizeToPixel(paintRect.width() - left - right, paintRect.x()), - snapSizeToPixel(paintRect.height() - top - bottom, paintRect.y())); + positioningAreaSize = pixelSnappedIntSize(paintRect.size() - LayoutSize(left + right, top + bottom), paintRect.location()); } else { geometry.setDestRect(pixelSnappedIntRect(viewRect())); positioningAreaSize = geometry.destRect().size(); @@ -1410,7 +1408,7 @@ public: } bool hasVisibleColorAndStyle() const { return style > BHIDDEN && !isTransparent; } - bool shouldRender() const { return isPresent && hasVisibleColorAndStyle(); } + bool shouldRender() const { return isPresent && width && hasVisibleColorAndStyle(); } bool presentButInvisible() const { return usedWidth() && !hasVisibleColorAndStyle(); } bool obscuresBackgroundEdge(float scale) const { @@ -1648,6 +1646,7 @@ void RenderBoxModelObject::paintOneBorderSide(GraphicsContext* graphicsContext, BackgroundBleedAvoidance bleedAvoidance, bool includeLogicalLeftEdge, bool includeLogicalRightEdge, bool antialias, const Color* overrideColor) { const BorderEdge& edgeToRender = edges[side]; + ASSERT(edgeToRender.width); const BorderEdge& adjacentEdge1 = edges[adjacentSide1]; const BorderEdge& adjacentEdge2 = edges[adjacentSide2]; |