mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-11 10:18:15 +09:00
LibWeb: Rename CSS::FontFace to CSS::ParsedFontFace
This implementation detail of CSSFontFaceRule is hogging the name of a Web API from CSS Font Loading Module Level 3.
This commit is contained in:
parent
3f113e728f
commit
3a5eabc43b
Notes:
sideshowbarker
2024-07-16 21:42:29 +09:00
Author: https://github.com/ADKaster
Commit: 3a5eabc43b
Pull-request: https://github.com/SerenityOS/serenity/pull/24255
Issue: https://github.com/SerenityOS/serenity/issues/22014
8 changed files with 23 additions and 23 deletions
|
@ -16,12 +16,12 @@ namespace Web::CSS {
|
|||
|
||||
JS_DEFINE_ALLOCATOR(CSSFontFaceRule);
|
||||
|
||||
JS::NonnullGCPtr<CSSFontFaceRule> CSSFontFaceRule::create(JS::Realm& realm, FontFace&& font_face)
|
||||
JS::NonnullGCPtr<CSSFontFaceRule> CSSFontFaceRule::create(JS::Realm& realm, ParsedFontFace&& font_face)
|
||||
{
|
||||
return realm.heap().allocate<CSSFontFaceRule>(realm, realm, move(font_face));
|
||||
}
|
||||
|
||||
CSSFontFaceRule::CSSFontFaceRule(JS::Realm& realm, FontFace&& font_face)
|
||||
CSSFontFaceRule::CSSFontFaceRule(JS::Realm& realm, ParsedFontFace&& font_face)
|
||||
: CSSRule(realm)
|
||||
, m_font_face(move(font_face))
|
||||
{
|
||||
|
@ -35,7 +35,7 @@ void CSSFontFaceRule::initialize(JS::Realm& realm)
|
|||
|
||||
CSSStyleDeclaration* CSSFontFaceRule::style()
|
||||
{
|
||||
// FIXME: Return a CSSStyleDeclaration subclass that directs changes to the FontFace.
|
||||
// FIXME: Return a CSSStyleDeclaration subclass that directs changes to the ParsedFontFace.
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
@ -63,7 +63,7 @@ String CSSFontFaceRule::serialized() const
|
|||
builder.append(" src: "sv);
|
||||
|
||||
// 2. The result of invoking serialize a comma-separated list on performing serialize a URL or serialize a LOCAL for each source on the source list.
|
||||
serialize_a_comma_separated_list(builder, m_font_face.sources(), [&](StringBuilder& builder, FontFace::Source source) -> void {
|
||||
serialize_a_comma_separated_list(builder, m_font_face.sources(), [&](StringBuilder& builder, ParsedFontFace::Source source) -> void {
|
||||
if (source.local_or_url.has<URL::URL>()) {
|
||||
serialize_a_url(builder, MUST(source.local_or_url.get<URL::URL>().to_string()));
|
||||
} else {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue