2020-08-17 15:14:30 -03:00
|
|
|
/*
|
2021-09-05 21:07:11 -03:00
|
|
|
* Copyright (c) 2020-2021, Luke Wilde <lukew@serenityos.org>
|
2020-08-17 15:14:30 -03:00
|
|
|
*
|
2021-04-22 05:24:48 -03:00
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
2020-08-17 15:14:30 -03:00
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#include <LibWeb/DOM/DocumentFragment.h>
|
2021-09-05 21:07:11 -03:00
|
|
|
#include <LibWeb/DOM/Window.h>
|
2020-08-17 15:14:30 -03:00
|
|
|
|
|
|
|
|
namespace Web::DOM {
|
|
|
|
|
|
|
|
|
|
DocumentFragment::DocumentFragment(Document& document)
|
|
|
|
|
: ParentNode(document, NodeType::DOCUMENT_FRAGMENT_NODE)
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
DocumentFragment::~DocumentFragment()
|
|
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
2021-09-05 21:07:11 -03:00
|
|
|
// https://dom.spec.whatwg.org/#dom-documentfragment-documentfragment
|
|
|
|
|
NonnullRefPtr<DocumentFragment> DocumentFragment::create_with_global_object(Bindings::WindowObject& window)
|
|
|
|
|
{
|
2021-09-09 08:55:31 -03:00
|
|
|
return make_ref_counted<DocumentFragment>(window.impl().associated_document());
|
2021-09-05 21:07:11 -03:00
|
|
|
}
|
|
|
|
|
|
2020-08-17 15:14:30 -03:00
|
|
|
}
|