Bug 709256 part 3. Skip calling PresShell::FlushPendingNotifications altogether if there might not be anything to flush. r=roc

This commit is contained in:
Boris Zbarsky
2011-12-14 23:42:15 -05:00
parent ea23d59088
commit 2df763e902
14 changed files with 155 additions and 5 deletions

View File

@@ -11703,6 +11703,11 @@ nsCSSFrameConstructor::PostRestyleEventInternal(bool aForLazyConstruction)
mObservingRefreshDriver = mPresShell->GetPresContext()->RefreshDriver()->
AddStyleFlushObserver(mPresShell);
}
// Unconditionally flag our document as needing a flush. The other
// option here would be a dedicated boolean to track whether we need
// to do so (set here and unset in ProcessPendingRestyles).
mPresShell->GetDocument()->SetNeedStyleFlush();
}
void