mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 385823 - Let us call NotifyPercentHeight even when computed height is already set, because it'll be set on imageFrames. r+sr=dbaron, a=beltzner
This commit is contained in:
parent
6c93fa8fe6
commit
bfeb48e02e
@ -3160,14 +3160,11 @@ nsFrame::DidReflow(nsPresContext* aPresContext,
|
||||
NS_FRAME_HAS_DIRTY_CHILDREN);
|
||||
}
|
||||
|
||||
// Notify the percent height observer if there is a percent height
|
||||
// but no computed height. The observer may be able to initiate
|
||||
// another reflow with a computed height. This happens in the case
|
||||
// where a table cell has no computed height but can fabricate one
|
||||
// when the cell height is known.
|
||||
// Notify the percent height observer if there is a percent height.
|
||||
// The observer may be able to initiate another reflow with a computed
|
||||
// height. This happens in the case where a table cell has no computed
|
||||
// height but can fabricate one when the cell height is known.
|
||||
if (aReflowState && aReflowState->mPercentHeightObserver &&
|
||||
((NS_UNCONSTRAINEDSIZE == aReflowState->ComputedHeight()) || // no computed height
|
||||
(0 == aReflowState->ComputedHeight())) &&
|
||||
(eStyleUnit_Percent == aReflowState->mStylePosition->mHeight.GetUnit())) {
|
||||
|
||||
nsIFrame* prevInFlow = GetPrevInFlow();
|
||||
|
@ -835,10 +835,16 @@ NS_METHOD nsTableCellFrame::Reflow(nsPresContext* aPresContext,
|
||||
|
||||
nsHTMLReflowState kidReflowState(aPresContext, aReflowState, firstKid,
|
||||
availSize);
|
||||
// mIPercentHeightObserver is for children of cells in quirks mode,
|
||||
// but only those than are tables in standards mode. NeedsToObserve
|
||||
// will determine how far this is propagated to descendants.
|
||||
kidReflowState.mPercentHeightObserver = this;
|
||||
|
||||
// Don't be a percent height observer if we're in the middle of
|
||||
// special-height reflow, in case we get an accidental NotifyPercentHeight()
|
||||
// call (which we shouldn't honor during special-height reflow)
|
||||
if (!aReflowState.mFlags.mSpecialHeightReflow) {
|
||||
// mPercentHeightObserver is for children of cells in quirks mode,
|
||||
// but only those than are tables in standards mode. NeedsToObserve
|
||||
// will determine how far this is propagated to descendants.
|
||||
kidReflowState.mPercentHeightObserver = this;
|
||||
}
|
||||
// Don't propagate special height reflow state to our kids
|
||||
kidReflowState.mFlags.mSpecialHeightReflow = PR_FALSE;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user