зеркало из https://github.com/mozilla/gecko-dev.git
bug 30692 - skip inner table cell's block as percentage base and use cell instead. r=troy
This commit is contained in:
Родитель
f98c49b79b
Коммит
87beb13dc1
|
@ -191,6 +191,14 @@ nsHTMLReflowState::GetContainingBlockReflowState(const nsHTMLReflowState* aParen
|
|||
// reflow state...
|
||||
nsresult rv = aParentRS->frame->IsPercentageBase(isContainingBlock);
|
||||
if (NS_SUCCEEDED(rv) && isContainingBlock) {
|
||||
// a block inside a table cell needs to use the table cell
|
||||
if (aParentRS->parentReflowState) {
|
||||
nsCOMPtr<nsIAtom> fType;
|
||||
aParentRS->parentReflowState->frame->GetFrameType(getter_AddRefs(fType));
|
||||
if (nsLayoutAtoms::tableCellFrame == fType.get()) {
|
||||
aParentRS = aParentRS->parentReflowState;
|
||||
}
|
||||
}
|
||||
return aParentRS;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -191,6 +191,14 @@ nsHTMLReflowState::GetContainingBlockReflowState(const nsHTMLReflowState* aParen
|
|||
// reflow state...
|
||||
nsresult rv = aParentRS->frame->IsPercentageBase(isContainingBlock);
|
||||
if (NS_SUCCEEDED(rv) && isContainingBlock) {
|
||||
// a block inside a table cell needs to use the table cell
|
||||
if (aParentRS->parentReflowState) {
|
||||
nsCOMPtr<nsIAtom> fType;
|
||||
aParentRS->parentReflowState->frame->GetFrameType(getter_AddRefs(fType));
|
||||
if (nsLayoutAtoms::tableCellFrame == fType.get()) {
|
||||
aParentRS = aParentRS->parentReflowState;
|
||||
}
|
||||
}
|
||||
return aParentRS;
|
||||
}
|
||||
}
|
||||
|
|
Загрузка…
Ссылка в новой задаче