From 4d80cfb4049ad44be89afd1b7ed98c7431bb9295 Mon Sep 17 00:00:00 2001 From: Simon Sapin Date: Tue, 6 May 2014 18:40:01 +0100 Subject: [PATCH] Fix computed value of 'display' when no declaration applies. --- src/components/style/properties.rs.mako | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/components/style/properties.rs.mako b/src/components/style/properties.rs.mako index bb2de3571a4..83b70567717 100644 --- a/src/components/style/properties.rs.mako +++ b/src/components/style/properties.rs.mako @@ -1888,6 +1888,11 @@ pub fn cascade(applicable_declarations: &[MatchedProperty], % endfor } + if !seen.get_display() { + let box_ = style_Box.get_mut(); + box_.display = longhands::display::to_computed_value(box_.display, &context); + } + (ComputedValues { % for style_struct in STYLE_STRUCTS: ${style_struct.name}: style_${style_struct.name},