Implement Calc for LengthOrPercentageOrAuto

This commit is contained in:
David Zbarsky 2015-08-11 21:08:05 -04:00
parent 9556141e57
commit cb4d878169
7 changed files with 44 additions and 0 deletions

View file

@ -267,11 +267,13 @@ impl Flow for TableFlow {
self.column_intrinsic_inline_sizes.push(ColumnIntrinsicInlineSize {
minimum_length: match *specified_inline_size {
LengthOrPercentageOrAuto::Auto |
LengthOrPercentageOrAuto::Calc(_) |
LengthOrPercentageOrAuto::Percentage(_) => Au(0),
LengthOrPercentageOrAuto::Length(length) => length,
},
percentage: match *specified_inline_size {
LengthOrPercentageOrAuto::Auto |
LengthOrPercentageOrAuto::Calc(_) |
LengthOrPercentageOrAuto::Length(_) => 0.0,
LengthOrPercentageOrAuto::Percentage(percentage) => percentage,
},