[Webkit-unassigned] [Bug 82728] Split remaining CSSRules into internal and CSSOM types

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Apr 2 07:48:36 PDT 2012


https://bugs.webkit.org/show_bug.cgi?id=82728


Andreas Kling <kling at webkit.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #135091|review?                     |review+
               Flag|                            |




--- Comment #23 from Andreas Kling <kling at webkit.org>  2012-04-02 07:48:36 PST ---
(From update of attachment 135091)
View in context: https://bugs.webkit.org/attachment.cgi?id=135091&action=review

Love it.
Would be nice to get EWS input though.

> Source/WebCore/ChangeLog:27
> +        StyleRuleBase is refounted. 

Typo, refcounted.

> Source/WebCore/css/CSSImportRule.h:57
>      // to avoid adding a vptr to CSSImportRule.

This comment should be updated to say StyleRuleImport.

> Source/WebCore/css/CSSMediaRule.cpp:45
> +    for (unsigned i = 0; i < m_childRuleCSSOMWrappers.size(); ++i) {

Official Antti Coding Style dictates that size() should be kept in a separate variable.

> Source/WebCore/css/CSSMediaRule.h:58
> +    mutable Vector<RefPtr<CSSRule> > m_childRuleCSSOMWrappers;

This would be more memory-efficient as OwnPtr<Vector<RefPtr<CSSRule>>> as CSSOM wrappers are rarely constructed.

> Source/WebCore/css/CSSStyleSheet.cpp:493
> +     for (unsigned i = 0; i < m_importRules.size(); ++i) {

Antti Coding Style!

> Source/WebCore/css/CSSStyleSheet.h:69
> +    virtual CSSStyleSheet* parentStyleSheet() const;

OVERRIDE.

> Source/WebCore/css/StyleRule.h:83
> +    signed m_sourceLine : 28;

We should make this unsigned at some point, the default value is 0, and there is no need for negative values AFAICT.

> Source/WebCore/css/WebKitCSSKeyframesRule.cpp:74
> +    for (unsigned i = 0; i < m_keyframes.size(); ++i) {

Antti Coding Style!

> Source/WebCore/css/WebKitCSSKeyframesRule.h:56
> +    String name() const { return m_name; }    
> +    void setName(const String& name) { m_name = AtomicString(name); }

These should probably pass AtomicString around rather than String.

> Source/WebCore/css/WebKitCSSRegionRule.cpp:49
> +    for (unsigned i = 0; i < m_childRuleCSSOMWrappers.size(); ++i) {

Antti Coding Style.

-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.



More information about the webkit-unassigned mailing list