LibWeb/CSS: Remove unused checks for calculated dimension types

These are a remnant of when Length itself could hold a pointer to a
CalculatedStyleValue. That hasn't been the case for a long time now.
This commit is contained in:
Sam Atkins 2024-09-18 17:17:58 +01:00 committed by Sam Atkins
parent 9b79081a06
commit 35cb6badc2
Notes: github-actions[bot] 2024-09-18 19:39:42 +00:00

View file

@ -56,11 +56,7 @@ public:
bool contains_percentage() const
{
return m_value.visit(
[&](T const& t) {
if constexpr (requires { t.is_calculated(); }) {
if (t.is_calculated())
return t.calculated_style_value()->contains_percentage();
}
[&](T const&) {
return false;
},
[&](Percentage const&) {
@ -99,11 +95,6 @@ public:
{
return m_value.visit(
[&](T const& t) {
if constexpr (requires { t.is_calculated(); }) {
if (t.is_calculated())
return T::resolve_calculated(t.calculated_style_value(), layout_node, reference_value);
}
return t;
},
[&](Percentage const& percentage) {
@ -118,11 +109,6 @@ public:
{
return m_value.visit(
[&](T const& t) {
if constexpr (requires { t.is_calculated(); }) {
if (t.is_calculated())
return T::resolve_calculated(t.calculated_style_value(), layout_node, reference_value);
}
return t;
},
[&](Percentage const& percentage) {