mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-05-28 22:12:56 +00:00
LibWeb: Rename CSSColor
to ColorFunctionStyleValue
This gives a better idea of what the class represents.
This commit is contained in:
parent
972547635f
commit
02d34dd021
Notes:
github-actions[bot]
2025-04-09 11:12:46 +00:00
Author: https://github.com/tcl3
Commit: 02d34dd021
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4245
Reviewed-by: https://github.com/AtkinsSJ ✅
5 changed files with 17 additions and 17 deletions
|
@ -23,7 +23,6 @@
|
|||
#include <LibWeb/CSS/StyleValues/BackgroundRepeatStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/BackgroundSizeStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/BasicShapeStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/CSSColor.h>
|
||||
#include <LibWeb/CSS/StyleValues/CSSColorValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/CSSHSL.h>
|
||||
#include <LibWeb/CSS/StyleValues/CSSHWB.h>
|
||||
|
@ -32,6 +31,7 @@
|
|||
#include <LibWeb/CSS/StyleValues/CSSLabLike.h>
|
||||
#include <LibWeb/CSS/StyleValues/CSSLightDark.h>
|
||||
#include <LibWeb/CSS/StyleValues/CSSRGB.h>
|
||||
#include <LibWeb/CSS/StyleValues/ColorFunctionStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/ConicGradientStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/CounterDefinitionsStyleValue.h>
|
||||
#include <LibWeb/CSS/StyleValues/CounterStyleValue.h>
|
||||
|
@ -1654,7 +1654,7 @@ RefPtr<CSSStyleValue> Parser::parse_color_function(TokenStream<ComponentValue>&
|
|||
|
||||
auto const& maybe_color_space = inner_tokens.consume_a_token();
|
||||
inner_tokens.discard_whitespace();
|
||||
if (!any_of(CSSColor::s_supported_color_space, [&](auto supported) { return maybe_color_space.is_ident(supported); }))
|
||||
if (!any_of(ColorFunctionStyleValue::s_supported_color_space, [&](auto supported) { return maybe_color_space.is_ident(supported); }))
|
||||
return {};
|
||||
|
||||
auto const& color_space = maybe_color_space.token().ident();
|
||||
|
@ -1685,7 +1685,7 @@ RefPtr<CSSStyleValue> Parser::parse_color_function(TokenStream<ComponentValue>&
|
|||
alpha = NumberStyleValue::create(1);
|
||||
|
||||
transaction.commit();
|
||||
return CSSColor::create(color_space.to_ascii_lowercase(),
|
||||
return ColorFunctionStyleValue::create(color_space.to_ascii_lowercase(),
|
||||
c1.release_nonnull(),
|
||||
c2.release_nonnull(),
|
||||
c3.release_nonnull(),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue