Bug 479655 part 5. Pass the relevant restyle tracker through to style reresolution. r=dbaron
This commit is contained in:
@@ -91,6 +91,7 @@
|
||||
#include "nsAutoPtr.h"
|
||||
#include "imgIRequest.h"
|
||||
#include "nsTransitionManager.h"
|
||||
#include "RestyleTracker.h"
|
||||
|
||||
#include "nsFrameManager.h"
|
||||
#ifdef ACCESSIBILITY
|
||||
@@ -961,7 +962,8 @@ nsFrameManager::ReResolveStyleContext(nsPresContext *aPresContext,
|
||||
nsIContent *aParentContent,
|
||||
nsStyleChangeList *aChangeList,
|
||||
nsChangeHint aMinChange,
|
||||
PRBool aFireAccessibilityEvents)
|
||||
PRBool aFireAccessibilityEvents,
|
||||
RestyleTracker& aRestyleTracker)
|
||||
{
|
||||
if (!NS_IsHintSubset(nsChangeHint_NeedDirtyReflow, aMinChange)) {
|
||||
// If aMinChange doesn't include nsChangeHint_NeedDirtyReflow, clear out
|
||||
@@ -1049,7 +1051,8 @@ nsFrameManager::ReResolveStyleContext(nsPresContext *aPresContext,
|
||||
// frame because it is visible or hidden withitn this frame.
|
||||
assumeDifferenceHint = ReResolveStyleContext(aPresContext, providerFrame,
|
||||
aParentContent, aChangeList,
|
||||
aMinChange, PR_FALSE);
|
||||
aMinChange, PR_FALSE,
|
||||
aRestyleTracker);
|
||||
|
||||
// The provider's new context becomes the parent context of
|
||||
// aFrame's context.
|
||||
@@ -1390,19 +1393,22 @@ nsFrameManager::ReResolveStyleContext(nsPresContext *aPresContext,
|
||||
content, aChangeList,
|
||||
NS_SubtractHint(aMinChange,
|
||||
nsChangeHint_ReflowFrame),
|
||||
fireAccessibilityEvents);
|
||||
fireAccessibilityEvents,
|
||||
aRestyleTracker);
|
||||
|
||||
// reresolve placeholder's context under the same parent
|
||||
// as the out-of-flow frame
|
||||
ReResolveStyleContext(aPresContext, child, content,
|
||||
aChangeList, aMinChange,
|
||||
fireAccessibilityEvents);
|
||||
fireAccessibilityEvents,
|
||||
aRestyleTracker);
|
||||
}
|
||||
else { // regular child frame
|
||||
if (child != resolvedChild) {
|
||||
ReResolveStyleContext(aPresContext, child, content,
|
||||
aChangeList, aMinChange,
|
||||
fireAccessibilityEvents);
|
||||
fireAccessibilityEvents,
|
||||
aRestyleTracker);
|
||||
} else {
|
||||
NOISY_TRACE_FRAME("child frame already resolved as descendant, skipping",aFrame);
|
||||
}
|
||||
@@ -1424,7 +1430,8 @@ nsFrameManager::ReResolveStyleContext(nsPresContext *aPresContext,
|
||||
void
|
||||
nsFrameManager::ComputeStyleChangeFor(nsIFrame *aFrame,
|
||||
nsStyleChangeList *aChangeList,
|
||||
nsChangeHint aMinChange)
|
||||
nsChangeHint aMinChange,
|
||||
RestyleTracker& aRestyleTracker)
|
||||
{
|
||||
if (aMinChange) {
|
||||
aChangeList->AppendChange(aFrame, aFrame->GetContent(), aMinChange);
|
||||
@@ -1449,7 +1456,8 @@ nsFrameManager::ComputeStyleChangeFor(nsIFrame *aFrame,
|
||||
// Inner loop over next-in-flows of the current frame
|
||||
nsChangeHint frameChange =
|
||||
ReResolveStyleContext(GetPresContext(), frame, nsnull,
|
||||
aChangeList, topLevelChange, PR_TRUE);
|
||||
aChangeList, topLevelChange, PR_TRUE,
|
||||
aRestyleTracker);
|
||||
NS_UpdateHint(topLevelChange, frameChange);
|
||||
|
||||
if (topLevelChange & nsChangeHint_ReconstructFrame) {
|
||||
|
||||
Reference in New Issue
Block a user