Bug 398144 - Make blocks that are margin-roots never consider themselves empty. [p=roc r+sr=dbaron a=blocking1.9+]

This commit is contained in:
reed@reedloden.com 2007-11-07 19:55:12 -08:00
Родитель aa4a6414ab
Коммит 9b5edcef2c
1 изменённых файлов: 6 добавлений и 0 удалений

Просмотреть файл

@ -2574,6 +2574,12 @@ IsMarginZero(nsStyleUnit aUnit, nsStyleCoord &aCoord)
/* virtual */ PRBool
nsBlockFrame::IsSelfEmpty()
{
// Blocks which are margin-roots (including inline-blocks) cannot be treated
// as empty for margin-collapsing and other purposes. They're more like
// replaced elements.
if (GetStateBits() & NS_BLOCK_MARGIN_ROOT)
return PR_FALSE;
const nsStylePosition* position = GetStylePosition();
switch (position->mMinHeight.GetUnit()) {