Bug 72846 - Implement CSS border image properties in CSSStyleApplyProperty.
: Implement CSS border image properties in CSSStyleApplyProperty.
Status: RESOLVED FIXED
Product: WebKit
Classification: Unclassified
Component: CSS
: 528+ (Nightly build)
: Unspecified Unspecified
: P2 Normal
Assigned To: Luke Macpherson
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-11-20 20:17 PST by Luke Macpherson
Modified: 2011-11-28 02:05 PST (History)
4 users (show)

See Also:


Attachments
Patch (7.46 KB, patch)
2011-11-20 21:02 PST, Luke Macpherson
no flags Details | Formatted Diff | Diff
Patch (7.45 KB, patch)
2011-11-27 15:33 PST, Luke Macpherson
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Luke Macpherson 2011-11-20 20:17:16 PST
Implement CSS border image properties in CSSStyleApplyProperty.
Comment 1 Luke Macpherson 2011-11-20 21:02:32 PST
Created attachment 116024 [details]
Patch
Comment 2 Andreas Kling 2011-11-27 05:34:02 PST
Comment on attachment 116024 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=116024&action=review

> Source/WebCore/css/CSSStyleApplyProperty.cpp:580
> +          void (CSSStyleSelector::*mapNinePieceImage)(CSSPropertyID, CSSValue*, NinePieceImage&)>

This doesn't need to be a template argument, we can just call mapNinePieceImage() directly.

> Source/WebCore/css/CSSStyleApplyProperty.cpp:587
> +        if (borderImageType)
> +            image.setMaskDefaults();

This check should be "if (borderImageType == Mask)" for readability.
Comment 3 Luke Macpherson 2011-11-27 15:06:56 PST
Comment on attachment 116024 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=116024&action=review

>> Source/WebCore/css/CSSStyleApplyProperty.cpp:580
>> +          void (CSSStyleSelector::*mapNinePieceImage)(CSSPropertyID, CSSValue*, NinePieceImage&)>
> 
> This doesn't need to be a template argument, we can just call mapNinePieceImage() directly.

The reason is that mapNinePieceImage is private, and I both don't want to make it public, and don't want to make all the ApplyProperty* classes friends (because they too have no externally visible interfaces). Passing in the pointer seemed like the best solution here.

>> Source/WebCore/css/CSSStyleApplyProperty.cpp:587
>> +            image.setMaskDefaults();
> 
> This check should be "if (borderImageType == Mask)" for readability.

Will do.
Comment 4 Luke Macpherson 2011-11-27 15:33:47 PST
Created attachment 116683 [details]
Patch
Comment 5 Andreas Kling 2011-11-27 16:44:20 PST
Comment on attachment 116683 [details]
Patch

Duh, I didn't notice that mapNinePieceImage() is private.
r=me
Comment 6 WebKit Review Bot 2011-11-28 02:05:45 PST
Comment on attachment 116683 [details]
Patch

Clearing flags on attachment: 116683

Committed r101238: <http://trac.webkit.org/changeset/101238>
Comment 7 WebKit Review Bot 2011-11-28 02:05:51 PST
All reviewed patches have been landed.  Closing bug.