зеркало из https://github.com/mozilla/gecko-dev.git
Fix bug 394111. r+sr+a=bzbarsky
This commit is contained in:
Родитель
53b8e27607
Коммит
d647423c6d
|
@ -1647,12 +1647,13 @@ static void
|
||||||
MoveChildrenTo(nsFrameManager* aFrameManager,
|
MoveChildrenTo(nsFrameManager* aFrameManager,
|
||||||
nsIFrame* aNewParent,
|
nsIFrame* aNewParent,
|
||||||
nsIFrame* aFrameList,
|
nsIFrame* aFrameList,
|
||||||
|
nsIFrame* aFrameListEnd,
|
||||||
nsFrameConstructorState* aState,
|
nsFrameConstructorState* aState,
|
||||||
nsFrameConstructorState* aOuterState)
|
nsFrameConstructorState* aOuterState)
|
||||||
{
|
{
|
||||||
PRBool setHasChildWithView = PR_FALSE;
|
PRBool setHasChildWithView = PR_FALSE;
|
||||||
|
|
||||||
while (aFrameList) {
|
while (aFrameList && aFrameList != aFrameListEnd) {
|
||||||
if (!setHasChildWithView
|
if (!setHasChildWithView
|
||||||
&& (aFrameList->GetStateBits() & (NS_FRAME_HAS_VIEW | NS_FRAME_HAS_CHILD_WITH_VIEW))) {
|
&& (aFrameList->GetStateBits() & (NS_FRAME_HAS_VIEW | NS_FRAME_HAS_CHILD_WITH_VIEW))) {
|
||||||
setHasChildWithView = PR_TRUE;
|
setHasChildWithView = PR_TRUE;
|
||||||
|
@ -12465,7 +12466,8 @@ nsCSSFrameConstructor::ConstructInline(nsFrameConstructorState& aState,
|
||||||
// parent block of the inline, but its parent pointer will be the anonymous
|
// parent block of the inline, but its parent pointer will be the anonymous
|
||||||
// block we create... AdjustFloatParentPtrs() deals with this by moving the
|
// block we create... AdjustFloatParentPtrs() deals with this by moving the
|
||||||
// float from the outer state |aState| to the inner |state|.
|
// float from the outer state |aState| to the inner |state|.
|
||||||
MoveChildrenTo(state.mFrameManager, blockFrame, list2, &state, &aState);
|
MoveChildrenTo(state.mFrameManager, blockFrame, list2, nsnull, &state,
|
||||||
|
&aState);
|
||||||
|
|
||||||
// list3's frames belong to another inline frame
|
// list3's frames belong to another inline frame
|
||||||
nsIFrame* inlineFrame = nsnull;
|
nsIFrame* inlineFrame = nsnull;
|
||||||
|
@ -12553,7 +12555,8 @@ nsCSSFrameConstructor::MoveFramesToEndOfIBSplit(nsFrameConstructorState& aState,
|
||||||
}
|
}
|
||||||
|
|
||||||
// Reparent (cheaply) the frames in list3
|
// Reparent (cheaply) the frames in list3
|
||||||
if (!inlineFrame->GetFirstChild(nsnull) &&
|
nsIFrame* existingFirstChild = inlineFrame->GetFirstChild(nsnull);
|
||||||
|
if (!existingFirstChild &&
|
||||||
(inlineFrame->GetStateBits() & NS_FRAME_FIRST_REFLOW)) {
|
(inlineFrame->GetStateBits() & NS_FRAME_FIRST_REFLOW)) {
|
||||||
inlineFrame->SetInitialChildList(nsnull, aFramesToMove);
|
inlineFrame->SetInitialChildList(nsnull, aFramesToMove);
|
||||||
} else {
|
} else {
|
||||||
|
@ -12561,7 +12564,7 @@ nsCSSFrameConstructor::MoveFramesToEndOfIBSplit(nsFrameConstructorState& aState,
|
||||||
}
|
}
|
||||||
nsFrameConstructorState* startState = aTargetState ? &aState : nsnull;
|
nsFrameConstructorState* startState = aTargetState ? &aState : nsnull;
|
||||||
MoveChildrenTo(aState.mFrameManager, inlineFrame, aFramesToMove,
|
MoveChildrenTo(aState.mFrameManager, inlineFrame, aFramesToMove,
|
||||||
aTargetState, startState);
|
existingFirstChild, aTargetState, startState);
|
||||||
SetFrameIsSpecial(inlineFrame, nsnull);
|
SetFrameIsSpecial(inlineFrame, nsnull);
|
||||||
return inlineFrame;
|
return inlineFrame;
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,18 @@
|
||||||
|
<html>
|
||||||
|
<head>
|
||||||
|
<script>
|
||||||
|
function boom()
|
||||||
|
{
|
||||||
|
var k = document.getElementById("k");
|
||||||
|
k.appendChild(document.createTextNode(" "));
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
</head>
|
||||||
|
|
||||||
|
<body onload="boom();">
|
||||||
|
|
||||||
|
<span><span id="k"><div></div></span><span style="float: right;"></span></span>
|
||||||
|
|
||||||
|
</body>
|
||||||
|
|
||||||
|
</html>
|
|
@ -375,3 +375,4 @@ random-if(MOZ_WIDGET_TOOLKIT=="cocoa") == 379316-2.html 379316-2-ref.html # bug
|
||||||
== 393671-1.html 393671-1-ref.html
|
== 393671-1.html 393671-1-ref.html
|
||||||
== 393671-2.html 393671-2-ref.html
|
== 393671-2.html 393671-2-ref.html
|
||||||
== 393671-3.html 393671-3-ref.html
|
== 393671-3.html 393671-3-ref.html
|
||||||
|
== 394111-1.html about:blank # Really an assertion test rather than a rendering test
|
||||||
|
|
Загрузка…
Ссылка в новой задаче