mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-06-01 16:02:53 +00:00
LibWeb/CSS: Qualify uses of LibURL
To prepare for introducing a CSS::URL type, we need to qualify any use of LibURL as `::URL::foo` instead of `URL::foo` so the compiler doesn't get confused. Many of these uses will be replaced, but I don't want to mix this in with what will likely already be a large change.
This commit is contained in:
parent
da1ff1ba40
commit
c82f4b46a2
Notes:
github-actions[bot]
2025-04-09 17:48:07 +00:00
Author: https://github.com/AtkinsSJ
Commit: c82f4b46a2
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/4285
Reviewed-by: https://github.com/tcl3 ✅
24 changed files with 77 additions and 76 deletions
|
@ -27,12 +27,13 @@ struct CSSStyleSheetInit {
|
|||
bool disabled { false };
|
||||
};
|
||||
|
||||
// https://drafts.csswg.org/cssom-1/#cssstylesheet
|
||||
class CSSStyleSheet final : public StyleSheet {
|
||||
WEB_PLATFORM_OBJECT(CSSStyleSheet, StyleSheet);
|
||||
GC_DECLARE_ALLOCATOR(CSSStyleSheet);
|
||||
|
||||
public:
|
||||
[[nodiscard]] static GC::Ref<CSSStyleSheet> create(JS::Realm&, CSSRuleList&, MediaList&, Optional<URL::URL> location);
|
||||
[[nodiscard]] static GC::Ref<CSSStyleSheet> create(JS::Realm&, CSSRuleList&, MediaList&, Optional<::URL::URL> location);
|
||||
static WebIDL::ExceptionOr<GC::Ref<CSSStyleSheet>> construct_impl(JS::Realm&, Optional<CSSStyleSheetInit> const& options = {});
|
||||
|
||||
virtual ~CSSStyleSheet() override = default;
|
||||
|
@ -74,8 +75,8 @@ public:
|
|||
|
||||
Vector<GC::Ref<CSSImportRule>> const& import_rules() const { return m_import_rules; }
|
||||
|
||||
Optional<URL::URL> base_url() const { return m_base_url; }
|
||||
void set_base_url(Optional<URL::URL> base_url) { m_base_url = move(base_url); }
|
||||
Optional<::URL::URL> base_url() const { return m_base_url; }
|
||||
void set_base_url(Optional<::URL::URL> base_url) { m_base_url = move(base_url); }
|
||||
|
||||
bool constructed() const { return m_constructed; }
|
||||
|
||||
|
@ -94,7 +95,7 @@ public:
|
|||
bool has_associated_font_loader(FontLoader& font_loader) const;
|
||||
|
||||
private:
|
||||
CSSStyleSheet(JS::Realm&, CSSRuleList&, MediaList&, Optional<URL::URL> location);
|
||||
CSSStyleSheet(JS::Realm&, CSSRuleList&, MediaList&, Optional<::URL::URL> location);
|
||||
|
||||
virtual void initialize(JS::Realm&) override;
|
||||
virtual void visit_edges(Cell::Visitor&) override;
|
||||
|
@ -113,7 +114,7 @@ private:
|
|||
|
||||
GC::Ptr<CSSRule> m_owner_css_rule;
|
||||
|
||||
Optional<URL::URL> m_base_url;
|
||||
Optional<::URL::URL> m_base_url;
|
||||
GC::Ptr<DOM::Document const> m_constructor_document;
|
||||
HashTable<GC::Ptr<DOM::Node>> m_owning_documents_or_shadow_roots;
|
||||
bool m_constructed { false };
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue