diff --git a/components/style/gecko/pseudo_element.rs b/components/style/gecko/pseudo_element.rs index 0a3d4647e00..8da1c2832ca 100644 --- a/components/style/gecko/pseudo_element.rs +++ b/components/style/gecko/pseudo_element.rs @@ -160,12 +160,11 @@ impl PseudoElement { /// Whether this pseudo-element should actually exist if it has /// the given styles. - pub fn should_exist(&self, style: &ComputedValues) -> bool - { - let display = style.get_box().clone_display(); - if display == display::T::none { + pub fn should_exist(&self, style: &ComputedValues) -> bool { + if style.get_box().clone_display() == display::T::none { return false; } + if self.is_before_or_after() && style.ineffective_content_property() { return false; }