From 776538a6c41b4bf918ef2a9c9adb72215cf38344 Mon Sep 17 00:00:00 2001 From: MacDue Date: Thu, 15 Sep 2022 08:31:12 +0100 Subject: [PATCH] LibWeb: Add operator== to CSS::Number This will be needed for the .equals() function of the backdrop-filter style value. --- Userland/Libraries/LibWeb/CSS/Number.h | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Userland/Libraries/LibWeb/CSS/Number.h b/Userland/Libraries/LibWeb/CSS/Number.h index feb2259f3b..cebcd8653c 100644 --- a/Userland/Libraries/LibWeb/CSS/Number.h +++ b/Userland/Libraries/LibWeb/CSS/Number.h @@ -76,6 +76,11 @@ public: return String::number(m_value); } + bool operator==(Number const& other) const + { + return m_type == other.m_type && m_value == other.m_value; + } + private: float m_value { 0 }; Type m_type;