Chromium Code Reviews| Index: Source/core/html/HTMLElement.cpp |
| diff --git a/Source/core/html/HTMLElement.cpp b/Source/core/html/HTMLElement.cpp |
| index 5ca263f1684cdfb0a3dd08ce0c5a7660f097d34c..3c4a002180286d693c1ce30bead60f0da793a58e 100644 |
| --- a/Source/core/html/HTMLElement.cpp |
| +++ b/Source/core/html/HTMLElement.cpp |
| @@ -742,6 +742,14 @@ RenderObject* HTMLElement::createRenderer(RenderStyle* style) |
| return RenderObject::createObject(this, style); |
| } |
| +HTMLFormElement* HTMLElement::formOwner() const |
|
tkent
2013/12/10 23:19:28
This function always calls a virtual function isFo
sof
2013/12/11 07:55:03
Agreed, too much indirection here.
As suggested,
|
| +{ |
| + if (!isFormAssociatedElement()) |
| + return 0; |
| + |
| + return virtualForm(); |
| +} |
| + |
| HTMLFormElement* HTMLElement::findFormAncestor() const |
| { |
| for (ContainerNode* ancestor = parentNode(); ancestor; ancestor = ancestor->parentNode()) { |