[Webkit-unassigned] [Bug 49240] Implement formaction, formenctype, formmethod and formtarget attributes for the input tag

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Nov 9 09:39:21 PST 2010


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


Dimitri Glazkov (Google) <dglazkov at chromium.org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
  Attachment #73354|review?                     |review-
               Flag|                            |




--- Comment #3 from Dimitri Glazkov (Google) <dglazkov at chromium.org>  2010-11-09 09:39:21 PST ---
(From update of attachment 73354)
View in context: https://bugs.webkit.org/attachment.cgi?id=73354&action=review

Just  a few comments.

> LayoutTests/fast/forms/formtarget-attribute.html:8
> +                    layoutTestController.waitUntilDone();

This definitely should be a dumpAsText test.

> WebCore/html/HTMLFormElement.cpp:319
> +    if (event && event->target() && event->target()->toNode())
> +        button = static_cast<HTMLFormControlElement*>(event->target()->toNode());

This seems like a different method from obtaining the button from above (see firstSuccessfulSubmitButton logic). What's the difference?

> WebCore/html/HTMLFormElement.cpp:330
> +    if (button) {
> +        String attribute;
> +        if (!(attribute = button->formAction()).isNull())
> +            copiedAttributes.parseAction(attribute);
> +        if (!(attribute = button->formEnctype()).isNull())
> +            copiedAttributes.parseEncodingType(attribute);
> +        if (!(attribute = button->formMethod()).isNull())
> +            copiedAttributes.parseMethodType(attribute);
> +        if (!(attribute = button->formTarget()).isNull())
> +            copiedAttributes.setTarget(attribute);
> +    }

This whole thing looks like it should just live in FormSubmission::create.

> WebCore/loader/FormSubmission.cpp:121
> +void FormSubmission::Attributes::copyFrom(const Attributes& other)
> +{
> +    m_method = other.m_method;
> +    m_action = other.m_action;
> +    m_target = other.m_target;
> +    m_encodingType = other.m_encodingType;
> +    m_acceptCharset = other.m_acceptCharset;
> +}
> +

And this becomes unnecessary.

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