diff options
author | Matt Brubeck <mbrubeck@limpet.net> | 2017-05-15 14:19:19 -0700 |
---|---|---|
committer | Matt Brubeck <mbrubeck@limpet.net> | 2017-05-16 12:55:14 -0700 |
commit | e34cf4fba03e5eb005a2ac36e61b7606b0aca1af (patch) | |
tree | 0d4acc0747381fba10445553146f9a5fc0ea4531 /components/layout/block.rs | |
parent | f87e362059f77bd7887cec0e8dd19df546538855 (diff) | |
download | servo-e34cf4fba03e5eb005a2ac36e61b7606b0aca1af.tar.gz servo-e34cf4fba03e5eb005a2ac36e61b7606b0aca1af.zip |
Fix containing block size for absolute root element
Fixes #16248.
Diffstat (limited to 'components/layout/block.rs')
-rw-r--r-- | components/layout/block.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/components/layout/block.rs b/components/layout/block.rs index 5e30c6f08ee..4da24dfebd0 100644 --- a/components/layout/block.rs +++ b/components/layout/block.rs @@ -657,7 +657,7 @@ impl BlockFlow { pub fn containing_block_size(&self, viewport_size: &Size2D<Au>, descendant: OpaqueFlow) -> LogicalSize<Au> { debug_assert!(self.base.flags.contains(IS_ABSOLUTELY_POSITIONED)); - if self.is_fixed() { + if self.is_fixed() || self.is_root() { // Initial containing block is the CB for the root LogicalSize::from_physical(self.base.writing_mode, *viewport_size) } else { |