LibWeb: Make CSS::ComputedProperties GC-allocated

This commit is contained in:
Andreas Kling
2024-12-20 16:35:12 +01:00
committed by Andreas Kling
parent c1cad8fa0e
commit 74469a0c1f
138 changed files with 337 additions and 339 deletions

View File

@@ -49,15 +49,15 @@ void SVGStopElement::apply_presentational_hints(GC::Ref<CSS::CascadedProperties>
Gfx::Color SVGStopElement::stop_color() const
{
if (auto css_values = computed_css_values(); css_values.has_value())
return css_values->stop_color();
if (auto computed_properties = this->computed_properties())
return computed_properties->stop_color();
return Color::Black;
}
float SVGStopElement::stop_opacity() const
{
if (auto css_values = computed_css_values(); css_values.has_value())
return css_values->stop_opacity();
if (auto computed_properties = this->computed_properties())
return computed_properties->stop_opacity();
return 1;
}