The code to look for an ancestor form element is duplicated in three different places
authorrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 29 Aug 2013 01:35:21 +0000 (01:35 +0000)
committerrniwa@webkit.org <rniwa@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 29 Aug 2013 01:35:21 +0000 (01:35 +0000)
commitc6577b448f6f8bb9017b69fb544f4f1f8d33bf76
treecd83143b11c09c3502bb8db9bf868175242608fd
parent22995006e3a2997497b29b9045f4f2cba81fe20c
The code to look for an ancestor form element is duplicated in three different places
https://bugs.webkit.org/show_bug.cgi?id=120391

Reviewed by Darin Adler.

Unduplicated the code by putting a single implementation in HTMLFormElement.cpp.

* WebCore.order:
* html/FormAssociatedElement.cpp:
(WebCore::FormAssociatedElement::findAssociatedForm):
(WebCore::FormAssociatedElement::formAttributeChanged):
* html/HTMLElement.cpp:
(WebCore::HTMLElement::virtualForm):
* html/HTMLElement.h:
* html/HTMLFormControlElement.cpp:
(WebCore::HTMLFormControlElement::HTMLFormControlElement):
* html/HTMLFormElement.cpp:
(WebCore::HTMLFormElement::findClosestFormAncestor):
* html/HTMLFormElement.h:
* html/HTMLImageElement.cpp:
(WebCore::HTMLImageElement::insertedInto):
* html/HTMLObjectElement.cpp:
(WebCore::HTMLObjectElement::HTMLObjectElement):
* html/parser/HTMLTreeBuilder.cpp:
(WebCore::HTMLTreeBuilder::HTMLTreeBuilder):

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@154801 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Source/WebCore/ChangeLog
Source/WebCore/WebCore.order
Source/WebCore/html/FormAssociatedElement.cpp
Source/WebCore/html/HTMLElement.cpp
Source/WebCore/html/HTMLElement.h
Source/WebCore/html/HTMLFormControlElement.cpp
Source/WebCore/html/HTMLFormElement.cpp
Source/WebCore/html/HTMLFormElement.h
Source/WebCore/html/HTMLImageElement.cpp
Source/WebCore/html/HTMLObjectElement.cpp
Source/WebCore/html/parser/HTMLTreeBuilder.cpp