mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-24 02:09:28 +00:00
LibGC+Everywhere: Factor out a LibGC from LibJS
Resulting in a massive rename across almost everywhere! Alongside the namespace change, we now have the following names: * JS::NonnullGCPtr -> GC::Ref * JS::GCPtr -> GC::Ptr * JS::HeapFunction -> GC::Function * JS::CellImpl -> GC::Cell * JS::Handle -> GC::Root
This commit is contained in:
committed by
Andreas Kling
parent
ce23efc5f6
commit
f87041bf3a
@@ -41,7 +41,7 @@
|
||||
|
||||
namespace Web::HTML {
|
||||
|
||||
JS_DEFINE_ALLOCATOR(HTMLElement);
|
||||
GC_DEFINE_ALLOCATOR(HTMLElement);
|
||||
|
||||
HTMLElement::HTMLElement(DOM::Document& document, DOM::QualifiedName qualified_name)
|
||||
: Element(document, move(qualified_name))
|
||||
@@ -207,7 +207,7 @@ WebIDL::ExceptionOr<void> HTMLElement::set_outer_text(String const& value)
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/dom.html#rendered-text-fragment
|
||||
JS::NonnullGCPtr<DOM::DocumentFragment> HTMLElement::rendered_text_fragment(StringView input)
|
||||
GC::Ref<DOM::DocumentFragment> HTMLElement::rendered_text_fragment(StringView input)
|
||||
{
|
||||
// 1. Let fragment be a new DocumentFragment whose node document is document.
|
||||
// Instead of creating a DocumentFragment the nodes are appended directly.
|
||||
@@ -411,7 +411,7 @@ String HTMLElement::outer_text()
|
||||
}
|
||||
|
||||
// https://www.w3.org/TR/cssom-view-1/#dom-htmlelement-offsetparent
|
||||
JS::GCPtr<DOM::Element> HTMLElement::offset_parent() const
|
||||
GC::Ptr<DOM::Element> HTMLElement::offset_parent() const
|
||||
{
|
||||
const_cast<DOM::Document&>(document()).update_layout();
|
||||
|
||||
@@ -672,7 +672,7 @@ bool HTMLElement::fire_a_synthetic_pointer_event(FlyString const& type, DOM::Ele
|
||||
}
|
||||
|
||||
// https://html.spec.whatwg.org/multipage/forms.html#dom-lfe-labels-dev
|
||||
JS::GCPtr<DOM::NodeList> HTMLElement::labels()
|
||||
GC::Ptr<DOM::NodeList> HTMLElement::labels()
|
||||
{
|
||||
// Labelable elements and all input elements have a live NodeList object associated with them that represents the list of label elements, in tree order,
|
||||
// whose labeled control is the element in question. The labels IDL attribute of labelable elements that are not form-associated custom elements,
|
||||
@@ -841,7 +841,7 @@ TokenizedFeature::NoOpener HTMLElement::get_an_elements_noopener(StringView targ
|
||||
return TokenizedFeature::NoOpener::No;
|
||||
}
|
||||
|
||||
WebIDL::ExceptionOr<JS::NonnullGCPtr<ElementInternals>> HTMLElement::attach_internals()
|
||||
WebIDL::ExceptionOr<GC::Ref<ElementInternals>> HTMLElement::attach_internals()
|
||||
{
|
||||
// 1. If this's is value is not null, then throw a "NotSupportedError" DOMException.
|
||||
if (is_value().has_value())
|
||||
|
||||
Reference in New Issue
Block a user