[webkit-reviews] review granted: [Bug 126541] Margin tiles are not repainted when background color changes : [Attachment 220683] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Jan 8 20:45:52 PST 2014


Simon Fraser (smfr) <simon.fraser at apple.com> has granted Beth Dakin
<bdakin at apple.com>'s request for review:
Bug 126541: Margin tiles are not repainted when background color changes
https://bugs.webkit.org/show_bug.cgi?id=126541

Attachment 220683: Patch
https://bugs.webkit.org/attachment.cgi?id=220683&action=review

------- Additional Comments from Simon Fraser (smfr) <simon.fraser at apple.com>
View in context: https://bugs.webkit.org/attachment.cgi?id=220683&action=review


> Source/WebCore/platform/graphics/ca/mac/TileController.mm:1085
> +void TileController::inflateRectForMargin(FloatRect& rect) const
> +{
> +    rect.move(-leftMarginWidth(), -topMarginHeight());
> +    rect.expand(leftMarginWidth() + rightMarginWidth(), topMarginHeight() +
bottomMarginHeight());
> +}

Rather than add margins to some arbitrary rect, maybe just have it return its
size with margins, since the caller is already just passing in the same rect as
the TileController size.

> Source/WebCore/rendering/RenderLayerBacking.cpp:2090
> +	   FloatRect rectToRepaint = FloatRect(FloatPoint(0, 0),
m_graphicsLayer->size());
> +	   tiledBacking()->inflateRectForMargin(rectToRepaint);

Null-check here.


More information about the webkit-reviews mailing list