Bug 96108: Inline ElementAt(), add SafeElementAt(), voidarray usage fixes,

assertions for bad voidarray indexes.  r=jst, sr=waterson
This commit is contained in:
rjesup@wgate.com
2001-12-21 01:10:07 +00:00
parent 8351054a0a
commit 33e3e06f9e
65 changed files with 1058 additions and 625 deletions

View File

@@ -3764,18 +3764,20 @@ PresShell::CancelAllReflowCommands()
PRInt32 i;
for (i = 0; i < n; i++) {
rc = NS_STATIC_CAST(nsHTMLReflowCommand*, mReflowCommands.ElementAt(0));
mReflowCommands.RemoveElementAt(0);
ReflowCommandRemoved(rc);
delete rc;
}
NS_ASSERTION(n == mReflowCommands.Count(),"reflow command list changed during cancel!");
mReflowCommands.Clear();
n = mTimeoutReflowCommands.Count();
for (i = 0; i < n; i++) {
rc = NS_STATIC_CAST(nsHTMLReflowCommand*, mTimeoutReflowCommands.ElementAt(0));
mTimeoutReflowCommands.RemoveElementAt(0);
ReflowCommandRemoved(rc);
delete rc;
}
NS_ASSERTION(n == mTimeoutReflowCommands.Count(),"timeout reflow command list changed during cancel!");
mTimeoutReflowCommands.Clear();
DoneRemovingReflowCommands();