mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Bug 1374233 - Part 6: Add PositiveInteger and PositiveIntegerOrAuto for column-count.
column-count should be a positive integer or auto. MozReview-Commit-ID: 9LFvrYo8De5
This commit is contained in:
parent
190cd5b952
commit
9d69cb2866
7 changed files with 49 additions and 9 deletions
|
@ -107,11 +107,11 @@ impl Flow for MulticolFlow {
|
|||
column_count =
|
||||
max(1, (content_inline_size + column_gap).0 / (column_width.0 + column_gap).0);
|
||||
if let Either::First(specified_column_count) = column_style.column_count {
|
||||
column_count = min(column_count, specified_column_count as i32);
|
||||
column_count = min(column_count, specified_column_count.0 as i32);
|
||||
}
|
||||
} else {
|
||||
column_count = match column_style.column_count {
|
||||
Either::First(n) => n,
|
||||
Either::First(n) => n.0,
|
||||
_ => unreachable!(),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue