mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-08 10:44:56 +00:00
Bug 1113216 - Avoid assertions/crashes by treating enumerated block-size values as auto, pending proper implementation of all the values. r=dbaron
This commit is contained in:
parent
e2f83ce0e3
commit
8699f8544e
@ -1396,6 +1396,16 @@ public:
|
|||||||
nsStyleUnit unit = aCoord.GetUnit();
|
nsStyleUnit unit = aCoord.GetUnit();
|
||||||
return unit == eStyleUnit_Auto || // only for 'height'
|
return unit == eStyleUnit_Auto || // only for 'height'
|
||||||
unit == eStyleUnit_None || // only for 'max-height'
|
unit == eStyleUnit_None || // only for 'max-height'
|
||||||
|
// The enumerated values were originally aimed at inline-size
|
||||||
|
// (or width, as it was before logicalization). For now, let them
|
||||||
|
// return true here, so that we don't call ComputeBSizeValue with
|
||||||
|
// value types that it doesn't understand. (See bug 1113216.)
|
||||||
|
//
|
||||||
|
// FIXME (bug 567039, bug 527285)
|
||||||
|
// This isn't correct for the 'fill' value or for the 'min-*' or
|
||||||
|
// 'max-*' properties, which need to be handled differently by
|
||||||
|
// the callers of IsAutoBSize().
|
||||||
|
unit == eStyleUnit_Enumerated ||
|
||||||
(aCBBSize == nscoord_MAX && aCoord.HasPercent());
|
(aCBBSize == nscoord_MAX && aCoord.HasPercent());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -355,9 +355,9 @@ nsFieldSetFrame::Reflow(nsPresContext* aPresContext,
|
|||||||
DO_GLOBAL_REFLOW_COUNT("nsFieldSetFrame");
|
DO_GLOBAL_REFLOW_COUNT("nsFieldSetFrame");
|
||||||
DISPLAY_REFLOW(aPresContext, this, aReflowState, aDesiredSize, aStatus);
|
DISPLAY_REFLOW(aPresContext, this, aReflowState, aDesiredSize, aStatus);
|
||||||
|
|
||||||
NS_PRECONDITION(aReflowState.ComputedWidth() != NS_INTRINSICSIZE,
|
NS_PRECONDITION(aReflowState.ComputedISize() != NS_INTRINSICSIZE,
|
||||||
"Should have a precomputed width!");
|
"Should have a precomputed inline-size!");
|
||||||
|
|
||||||
// Initialize OUT parameter
|
// Initialize OUT parameter
|
||||||
aStatus = NS_FRAME_COMPLETE;
|
aStatus = NS_FRAME_COMPLETE;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user