mirror of
https://github.com/servo/servo.git
synced 2025-08-04 13:10:20 +01:00
layout: Avoid double negation in CellLayout::is_empty_for_empty_cells()
(#33688)
* Avoid double negation in is_empty_for_empty_cells() Signed-off-by: Taym <haddadi.taym@gmail.com> * Remove more negation Signed-off-by: Taym <haddadi.taym@gmail.com> * Fix format Signed-off-by: Taym <haddadi.taym@gmail.com> --------- Signed-off-by: Taym <haddadi.taym@gmail.com>
This commit is contained in:
parent
628ca03a80
commit
7bcc288cd9
1 changed files with 2 additions and 3 deletions
|
@ -74,11 +74,10 @@ impl CellLayout {
|
|||
|
||||
/// Whether the cell is considered empty for the purpose of the 'empty-cells' property.
|
||||
fn is_empty_for_empty_cells(&self) -> bool {
|
||||
!self
|
||||
.layout
|
||||
self.layout
|
||||
.fragments
|
||||
.iter()
|
||||
.any(|fragment| !matches!(fragment, Fragment::AbsoluteOrFixedPositioned(_)))
|
||||
.all(|fragment| matches!(fragment, Fragment::AbsoluteOrFixedPositioned(_)))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue