[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-commits
Subject: kdelibs/khtml/html
From: Germain Garand <germain () ebooksfrance ! com>
Date: 2005-02-03 1:38:08
Message-ID: 20050203013808.309C81BBBC () office ! kde ! org
[Download RAW message or body]
CVS commit by ggarand:
register form elements dynamically created from JS (webcore merge)
BUG: 58847
M +13 -0 html_formimpl.cpp 1.417
--- kdelibs/khtml/html/html_formimpl.cpp #1.416:1.417
@@ -811,4 +811,17 @@ void HTMLGenericFormElementImpl::attach(
}
+ // FIXME: This handles the case of a new form element being created by
+ // JavaScript and inserted inside a form. What it does not handle is
+ // a form element being moved from inside a form to outside, or from one
+ // inside one form to another. The reason this other case is hard to fix
+ // is that during parsing, we may have been passed a form that we are not
+ // inside, DOM-tree-wise. If so, it's hard for us to know when we should
+ // be removed from that form's element list.
+ if (!m_form) {
+ m_form = getForm();
+ if (m_form)
+ m_form->registerFormElement(this);
+ }
+
NodeBaseImpl::attach();
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic