[webkit-dev] CSSGroupingRule and a bit of refactoring?

Antti Koivisto koivisto at iki.fi
Thu Dec 13 14:12:06 PST 2012


We already have internal type corresponding to the new
CSSGroupingRule, StyleRuleBlock. Technically refactoring the CSSOM like
this would be fairly trivial.

It is not clear to me what value this new type adds though. In JS you don't
really care if types have a common base as long as they share similar
looking interface. Are there some concrete use cases?


  antti


On Thu, Dec 13, 2012 at 3:41 AM, Pablo Flouret <pablof at motorola.com> wrote:

> Hello webkit folk,
>
> I'm working on having @supports behave like a proper CSSSupportsRule [1].
>
> In the css3-conditional spec, CSSSupportsRule inherits from a
> CSSGroupingRule (CSSMediaRule does as well):
> http://dev.w3.org/csswg/css3-conditional/#the-cssgroupingrule-interface.
>
> I'm wondering if it's a good idea, as a first step, to do a bit of
> refactoring and rip the stuff that's now in CSSGroupingRule from
> CSSMediaRule (cssRules/insertRule/deleteRule), and have the supports
> and media rules inherit from it.
>
> Incidentally, i see at least WebKitCSSKeyframesRule and
> WebKitCSSRegionRule also having similar but not quite identical
> re-implementations of these functions, but i guess whether these ones
> should also inherit from CSSGroupingRule might be a question for the
> standards mailing lists first (in any case, they would potentially
> benefit from such a refactoring).
>
> Opinions / advice / potential problems?
>
> Thanks!
>
> [1] http://wkbug.com/104822
>
> --
> pablo flouret
> motorola | webkit / browser team
> _______________________________________________
> webkit-dev mailing list
> webkit-dev at lists.webkit.org
> http://lists.webkit.org/mailman/listinfo/webkit-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-dev/attachments/20121214/a10cdf12/attachment.html>


More information about the webkit-dev mailing list