[Webkit-unassigned] [Bug 48821] Let HTMLObjectElement be a form associated element

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Dec 2 02:20:38 PST 2010


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





--- Comment #24 from Kent Tamura <tkent at chromium.org>  2010-12-02 02:20:37 PST ---
(From update of attachment 75250)
View in context: https://bugs.webkit.org/attachment.cgi?id=75250&action=review

>>> WebCore/html/FormAssociatedElement.h:62
>>> +    void setReadOnly(bool value) { m_readOnly = value; }
>> 
>> Do we need them in FormAssociatedElement?
>> <object> doesn't have such properties.
> 
> Actually they are not required for <object>, but these flags are bit fields and would be stored into the same place(byte) of validation related bit fields so I thought it might be better putting these flags in FormAssociatedElement for memory consuming. Would it be better keeping these in HTMLFormControlElement?

IMO, it's ok to split these flags into two classes.
BTW, do we really need to put validation members to FormAssociatedElement? <object> needs to have a ValidityState object, but other validation flags should be constant in <object>.

>>> WebCore/html/HTMLObjectElement.cpp:502
>>> +    return serviceType.isNull() ? emptyAtom : serviceType;
>> 
>> This function returns an address of a temporal object on the stack.
>> Anyway, is returning m_serviceType correct?  m_serviceType is not compatible with other form control types, It's a MIME type. Do we need formControlType() in FormAssociatedElement?
> 
> Thank you for warning. Removed temporal object and added a member variables for it. As for the return value, HTML5 spec says the type attribute must be a valid MIME type (http://dev.w3.org/html5/spec/the-iframe-element.html#attr-object-type). That's why I tried to return m_serviceType here.

Do we need formControlType() in FormAssociatedElement?  I think we can remove type() and formControlType() from FormAssociatedElement.  We had better minimize the number of methods of FormAssociatedElement.

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