зеркало из https://github.com/mozilla/gecko-dev.git
Checkin for AlexSavulov@netscape.com: fixes problem of block inside of a NOWRAP block causing incorrect sizing. b=93363, r=peterl sr=attinasi
This commit is contained in:
Родитель
5b2088b904
Коммит
1e1e22c2a3
|
@ -4118,7 +4118,17 @@ nsBlockFrame::PostPlaceLine(nsBlockReflowState& aState,
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update xmost
|
// Update xmost
|
||||||
nscoord xmost = aLine->mBounds.XMost();
|
nscoord xmost;
|
||||||
|
if(aLine->IsBlock() && aState.GetFlag(BRS_NOWRAP)) {
|
||||||
|
// since the nowrap blocks tend to be as wide as their widest element or
|
||||||
|
// sequel of elements that can't be wrapped anymore (see patch for bug 80817)
|
||||||
|
// let them set xmost to be the width of the widest element of the reflowed line
|
||||||
|
// (patches bug 93363 and other NOWRAP dups)
|
||||||
|
xmost = aMaxElementSize.width;
|
||||||
|
} else {
|
||||||
|
xmost = aLine->mBounds.XMost();
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
if (CRAZY_WIDTH(xmost)) {
|
if (CRAZY_WIDTH(xmost)) {
|
||||||
ListTag(stdout);
|
ListTag(stdout);
|
||||||
|
|
|
@ -4118,7 +4118,17 @@ nsBlockFrame::PostPlaceLine(nsBlockReflowState& aState,
|
||||||
}
|
}
|
||||||
|
|
||||||
// Update xmost
|
// Update xmost
|
||||||
nscoord xmost = aLine->mBounds.XMost();
|
nscoord xmost;
|
||||||
|
if(aLine->IsBlock() && aState.GetFlag(BRS_NOWRAP)) {
|
||||||
|
// since the nowrap blocks tend to be as wide as their widest element or
|
||||||
|
// sequel of elements that can't be wrapped anymore (see patch for bug 80817)
|
||||||
|
// let them set xmost to be the width of the widest element of the reflowed line
|
||||||
|
// (patches bug 93363 and other NOWRAP dups)
|
||||||
|
xmost = aMaxElementSize.width;
|
||||||
|
} else {
|
||||||
|
xmost = aLine->mBounds.XMost();
|
||||||
|
}
|
||||||
|
|
||||||
#ifdef DEBUG
|
#ifdef DEBUG
|
||||||
if (CRAZY_WIDTH(xmost)) {
|
if (CRAZY_WIDTH(xmost)) {
|
||||||
ListTag(stdout);
|
ListTag(stdout);
|
||||||
|
|
Загрузка…
Ссылка в новой задаче