Bug 423269: Don't add scriptblockers around StartUpdate/EndUpdate batches as script is likely to execute at the last EndUpdate. Also for now, restore full functionality to scripts running while there are scriptblockers. r/sr=bz a=beltzner
git-svn-id: svn://10.0.0.236/trunk@250470 18797224-902f-48f8-a5cc-f745e15eee43
This commit is contained in:
@@ -500,19 +500,17 @@ nsGenericDOMDataNode::SetTextInternal(PRUint32 aOffset, PRUint32 aCount,
|
||||
if (haveMutationListeners) {
|
||||
mozAutoRemovableBlockerRemover blockerRemover;
|
||||
|
||||
if (nsContentUtils::IsSafeToRunScript()) {
|
||||
nsMutationEvent mutation(PR_TRUE, NS_MUTATION_CHARACTERDATAMODIFIED);
|
||||
nsMutationEvent mutation(PR_TRUE, NS_MUTATION_CHARACTERDATAMODIFIED);
|
||||
|
||||
mutation.mPrevAttrValue = oldValue;
|
||||
if (aLength > 0) {
|
||||
nsAutoString val;
|
||||
mText.AppendTo(val);
|
||||
mutation.mNewAttrValue = do_GetAtom(val);
|
||||
}
|
||||
|
||||
mozAutoSubtreeModified subtree(GetOwnerDoc(), this);
|
||||
nsEventDispatcher::Dispatch(this, nsnull, &mutation);
|
||||
mutation.mPrevAttrValue = oldValue;
|
||||
if (aLength > 0) {
|
||||
nsAutoString val;
|
||||
mText.AppendTo(val);
|
||||
mutation.mNewAttrValue = do_GetAtom(val);
|
||||
}
|
||||
|
||||
mozAutoSubtreeModified subtree(GetOwnerDoc(), this);
|
||||
nsEventDispatcher::Dispatch(this, nsnull, &mutation);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user