[webkit-changes] cvs commit: WebCore/khtml/xml dom_docimpl.cpp
dom_docimpl.h dom_nodeimpl.cpp
Timothy
thatcher at opensource.apple.com
Fri Nov 18 18:47:14 PST 2005
thatcher 05/11/18 18:47:14
Modified: . Tag: Safari-1-3-branch ChangeLog
khtml/xml Tag: Safari-1-3-branch dom_docimpl.cpp
dom_docimpl.h dom_nodeimpl.cpp
Log:
Merged fix from TOT to Safari-1-3-branch
2005-11-18 David Harrison <harrison at apple.com>
Reviewed by Tim Hatcher.
http://bugzilla.opendarwin.org/show_bug.cgi?id=5774
Failed assertion `!eventDispatchForbidden()' in dom_nodeimpl.cpp:892
Tests added: None, becaause it keeps some existing ones from crashing.
* khtml/xml/dom_nodeimpl.cpp:
(DOM::ContainerNodeImpl::insertBefore):
(DOM::ContainerNodeImpl::replaceChild):
(DOM::ContainerNodeImpl::removeChild):
(DOM::ContainerNodeImpl::appendChild):
(DOM::ContainerNodeImpl::addChild):
Call enableEventDispatch() sooner, when basic dom mods are done.
Revision Changes Path
No revision
No revision
1.335.2.33 +21 -0 WebCore/ChangeLog
Index: ChangeLog
===================================================================
RCS file: /cvs/root/WebCore/ChangeLog,v
retrieving revision 1.335.2.32
retrieving revision 1.335.2.33
diff -u -r1.335.2.32 -r1.335.2.33
--- ChangeLog 19 Nov 2005 00:19:41 -0000 1.335.2.32
+++ ChangeLog 19 Nov 2005 02:47:06 -0000 1.335.2.33
@@ -2,6 +2,27 @@
Merged fix from TOT to Safari-1-3-branch
+ 2005-11-18 David Harrison <harrison at apple.com>
+
+ Reviewed by Tim Hatcher.
+
+ http://bugzilla.opendarwin.org/show_bug.cgi?id=5774
+ Failed assertion `!eventDispatchForbidden()' in dom_nodeimpl.cpp:892
+
+ Tests added: None, becaause it keeps some existing ones from crashing.
+
+ * khtml/xml/dom_nodeimpl.cpp:
+ (DOM::ContainerNodeImpl::insertBefore):
+ (DOM::ContainerNodeImpl::replaceChild):
+ (DOM::ContainerNodeImpl::removeChild):
+ (DOM::ContainerNodeImpl::appendChild):
+ (DOM::ContainerNodeImpl::addChild):
+ Call enableEventDispatch() sooner, when basic dom mods are done.
+
+2005-11-18 Timothy Hatcher <timothy at apple.com>
+
+ Merged fix from TOT to Safari-1-3-branch
+
2005-11-16 Adele Peterson <adele at apple.com>
Reviewed by Dave Harrson.
No revision
No revision
1.211.4.13 +0 -1 WebCore/khtml/xml/dom_docimpl.cpp
Index: dom_docimpl.cpp
===================================================================
RCS file: /cvs/root/WebCore/khtml/xml/dom_docimpl.cpp,v
retrieving revision 1.211.4.12
retrieving revision 1.211.4.13
diff -u -r1.211.4.12 -r1.211.4.13
--- dom_docimpl.cpp 18 Nov 2005 23:39:00 -0000 1.211.4.12
+++ dom_docimpl.cpp 19 Nov 2005 02:47:11 -0000 1.211.4.13
@@ -363,7 +363,6 @@
resetVisitedLinkColor();
resetActiveLinkColor();
- m_eventDispatchForbidden = 0;
m_processingLoadEvent = false;
m_startTime.restart();
m_overMinimumLayoutThreshold = false;
1.104.4.10 +0 -1 WebCore/khtml/xml/dom_docimpl.h
Index: dom_docimpl.h
===================================================================
RCS file: /cvs/root/WebCore/khtml/xml/dom_docimpl.h,v
retrieving revision 1.104.4.9
retrieving revision 1.104.4.10
diff -u -r1.104.4.9 -r1.104.4.10
--- dom_docimpl.h 18 Nov 2005 23:39:01 -0000 1.104.4.9
+++ dom_docimpl.h 19 Nov 2005 02:47:11 -0000 1.104.4.10
@@ -695,7 +695,6 @@
KWQAccObjectCache* m_accCache;
#endif
- int m_eventDispatchForbidden;
QPtrList<HTMLImageLoader> m_imageLoadEventDispatchSoonList;
QPtrList<HTMLImageLoader> m_imageLoadEventDispatchingList;
int m_imageLoadEventTimer;
1.140.6.7 +12 -24 WebCore/khtml/xml/dom_nodeimpl.cpp
Index: dom_nodeimpl.cpp
===================================================================
RCS file: /cvs/root/WebCore/khtml/xml/dom_nodeimpl.cpp,v
retrieving revision 1.140.6.6
retrieving revision 1.140.6.7
diff -u -r1.140.6.6 -r1.140.6.7
--- dom_nodeimpl.cpp 19 Nov 2005 00:19:44 -0000 1.140.6.6
+++ dom_nodeimpl.cpp 19 Nov 2005 02:47:12 -0000 1.140.6.7
@@ -1701,12 +1701,12 @@
child->setParent(this);
child->setPreviousSibling(prev);
child->setNextSibling(refChild);
+ allowEventDispatch();
// Add child to the rendering tree
// ### should we detach() it first if it's already attached?
if (attached() && !child->attached())
child->attach();
- allowEventDispatch();
// Dispatch the mutation events
dispatchChildInsertedEvents(child,exceptioncode);
@@ -1763,9 +1763,8 @@
if (exceptioncode)
return 0;
- forbidEventDispatch();
-
// Add child in the correct position
+ forbidEventDispatch();
if (prev) prev->setNextSibling(child);
if (next) next->setPreviousSibling(child);
if(!prev) _first = child;
@@ -1773,12 +1772,12 @@
child->setParent(this);
child->setPreviousSibling(prev);
child->setNextSibling(next);
+ allowEventDispatch();
// Add child to the rendering tree
// ### should we detach() it first if it's already attached?
if (attached() && !child->attached())
child->attach();
- allowEventDispatch();
// Dispatch the mutation events
dispatchChildInsertedEvents(child,exceptioncode);
@@ -1867,10 +1866,10 @@
oldChild->setNextSibling(0);
oldChild->setParent(0);
- getDocument()->setDocumentChanged(true);
-
allowEventDispatch();
+ getDocument()->setDocumentChanged(true);
+
// Dispatch post-removal mutation events
dispatchSubtreeModifiedEvent();
@@ -1957,26 +1956,22 @@
return 0;
}
- forbidEventDispatch();
-
// Append child to the end of the list
+ forbidEventDispatch();
child->setParent(this);
-
- if(_last)
- {
+ if (_last) {
child->setPreviousSibling(_last);
_last->setNextSibling(child);
_last = child;
} else
_first = _last = child;
+ allowEventDispatch();
// Add child to the rendering tree
// ### should we detach() it first if it's already attached?
if (attached() && !child->attached())
child->attach();
- allowEventDispatch();
-
// Dispatch the mutation events
dispatchChildInsertedEvents(child,exceptioncode);
@@ -2056,27 +2051,20 @@
return 0;
}
- forbidEventDispatch();
-
// just add it...
+ forbidEventDispatch();
newChild->setParent(this);
-
- if(_last)
- {
+ if(_last) {
newChild->setPreviousSibling(_last);
_last->setNextSibling(newChild);
_last = newChild;
- }
- else
- {
+ } else
_first = _last = newChild;
- }
+ allowEventDispatch();
if (inDocument())
newChild->insertedIntoDocument();
childrenChanged();
-
- allowEventDispatch();
if(newChild->nodeType() == Node::ELEMENT_NODE)
return newChild;
More information about the webkit-changes
mailing list