- landed fix for <bugzilla.opendarwin.org/show_bug.cgi?id=3677>
Safari fail to access a second time an element whose content was dynamically modified.
- patch by Anders Carlsson <andersca@mac.com>.
Reviewed by mjs + darin.
Test cases added:
* layout-tests/fast/dom/ids/duplicate-ids-expected.txt: Added.
* layout-tests/fast/dom/ids/duplicate-ids.html: Added.
* khtml/xml/dom_docimpl.cpp:
(DocumentImpl::getElementById):
If no element in the id dict can be found and we know that there's
at least one other element with the same id around, then traverse the document
and insert the new element in the id table.
(DocumentImpl::addElementById):
(DocumentImpl::removeElementById):
Increment and decrement the id count accordingly.
* khtml/xml/dom_docimpl.h:
Add QDict for id counts. Make element QDict mutable.
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@9764
268f45cc-cd09-0410-ab3c-
d52691b4dbfc