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

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Jun 27 05:28:21 PDT 2011


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





--- Comment #3 from SravanKumar <sravan.ken at gmail.com>  2011-06-27 05:28:21 PST ---
Hi,

In the course of understanding "isChecked" and "checked" functions, following was the analysis made. 

1.In "isChecked", "m_inputType->isCheckable()" method seems to be redundant, since this will get executed only if "checked" is true.

2.And this is true only when a checkbox or radio button is selected. In which case both "isChecked" and "checked" are true since "m_inputType->isCheckable()" always returns true.(please correct me if i am wrong with an example use-case)

So, based of this observation i think it is better to 

1. Remove "m_inputType->isCheckable()" from "isChecked" method.
2. Return only "m_isChecked" from "isChecked" method.
3. Remove "checked" definition and declaration.
4. Replace all "checked" calls with "isChecked".


Please let me know if i missed out some thing.

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