[Webkit-unassigned] [Bug 54476] HTMLInputElement has two similarly named methods: "checked" and "isChecked"

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Wed Jul 6 05:41:50 PDT 2011


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





--- Comment #7 from Dominic Cooney <dominicc at chromium.org>  2011-07-06 05:41:50 PST ---
(From update of attachment 99805)
View in context: https://bugs.webkit.org/attachment.cgi?id=99805&action=review

I am not a reviewer, but I have some thoughts on how your patch could be improved.

> Source/WebCore/ChangeLog:3
> +        https://bugs.webkit.org/show_bug.cgi?id=54476

You should swap this line and the next one.

> Source/WebCore/ChangeLog:8
> +        Removed isChecked() from HTMLInputElement class

This doesn’t add much that isn’t in the summary, so consider removing it.

> Source/WebCore/ChangeLog:19
> +        * html/HTMLInputElement.h:

If you wanted to you could put commentary like what is losing what method briefly after the : here (same line)

> Source/WebCore/css/CSSStyleSelector.cpp:-2922
> -                if (inputElement && inputElement->isChecked() && !inputElement->isIndeterminate())

Have you considered cases like an input element that is a checked checkbox, which is then changed to something not checkable like a textbox? Is m_checked reset? Do rules using the ::checked pseudoclass still apply? They should not. It might almost be worth verifying your expectation with a layout test.

> Source/WebCore/html/HTMLInputElement.h:129
>      // isChecked is used by the rendering tree/CSS while checked() is used by JS to determine checked state

This comment probably needs to be updated…

-- 
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