[webkit-reviews] review granted: [Bug 101860] RenderStyle: Pack Color members tighter in substructures. : [Attachment 173515] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Nov 12 02:10:36 PST 2012


Antti Koivisto <koivisto at iki.fi> has granted Andreas Kling <kling at webkit.org>'s
request for review:
Bug 101860: RenderStyle: Pack Color members tighter in substructures.
https://bugs.webkit.org/show_bug.cgi?id=101860

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

------- Additional Comments from Antti Koivisto <koivisto at iki.fi>
View in context: https://bugs.webkit.org/attachment.cgi?id=173515&action=review


> Source/WebCore/rendering/style/RenderStyle.cpp:978
>  Color RenderStyle::color() const { return inherited->color; }
>  Color RenderStyle::visitedLinkColor() const { return
inherited->visitedLinkColor; }
> -void RenderStyle::setColor(const Color& v) { SET_VAR(inherited, color, v) };

> -void RenderStyle::setVisitedLinkColor(const Color& v) { SET_VAR(inherited,
visitedLinkColor, v) }
> +void RenderStyle::setColor(const Color& v) { SET_VAR(inherited, color,
v.rgb()); }
> +void RenderStyle::setVisitedLinkColor(const Color& v) { SET_VAR(inherited,
visitedLinkColor, v.rgb()); }

Should these just take/return RGB32s? It would be good if the interface would
make it clear what is being saved. 

At least there should be ASSERT(c.isValid()).


More information about the webkit-reviews mailing list