mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Recalc quotes and counters before reflow. Bug 377216, r+sr=dbaron
This commit is contained in:
parent
e6d41ebe8b
commit
357c10a896
@ -10180,24 +10180,30 @@ nsCSSFrameConstructor::EndUpdate()
|
||||
// This is the end of our last update. Before we decrement
|
||||
// mUpdateCount, recalc quotes and counters as needed.
|
||||
|
||||
if (mQuotesDirty) {
|
||||
mQuotesDirty = PR_FALSE;
|
||||
mQuoteList.RecalcAll();
|
||||
}
|
||||
|
||||
if (mCountersDirty) {
|
||||
mCountersDirty = PR_FALSE;
|
||||
mCounterManager.RecalcAll();
|
||||
}
|
||||
|
||||
NS_ASSERTION(!mQuotesDirty, "Quotes updates will be lost");
|
||||
NS_ASSERTION(!mCountersDirty, "Counter updates will be lost");
|
||||
RecalcQuotesAndCounters();
|
||||
NS_ASSERTION(mUpdateCount == 1, "Odd update count");
|
||||
}
|
||||
|
||||
--mUpdateCount;
|
||||
}
|
||||
|
||||
void
|
||||
nsCSSFrameConstructor::RecalcQuotesAndCounters()
|
||||
{
|
||||
if (mQuotesDirty) {
|
||||
mQuotesDirty = PR_FALSE;
|
||||
mQuoteList.RecalcAll();
|
||||
}
|
||||
|
||||
if (mCountersDirty) {
|
||||
mCountersDirty = PR_FALSE;
|
||||
mCounterManager.RecalcAll();
|
||||
}
|
||||
|
||||
NS_ASSERTION(!mQuotesDirty, "Quotes updates will be lost");
|
||||
NS_ASSERTION(!mCountersDirty, "Counter updates will be lost");
|
||||
}
|
||||
|
||||
void
|
||||
nsCSSFrameConstructor::WillDestroyFrameTree()
|
||||
{
|
||||
|
@ -133,6 +133,7 @@ public:
|
||||
|
||||
void BeginUpdate() { ++mUpdateCount; }
|
||||
void EndUpdate();
|
||||
void RecalcQuotesAndCounters();
|
||||
|
||||
void WillDestroyFrameTree();
|
||||
|
||||
|
@ -4602,6 +4602,7 @@ PresShell::FlushPendingNotifications(mozFlushType aType)
|
||||
}
|
||||
|
||||
if (aType & Flush_OnlyReflow) {
|
||||
mFrameConstructor->RecalcQuotesAndCounters();
|
||||
ProcessReflowCommands(PR_FALSE);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user