
This commit introduces a WEB_SET_PROTOTYPE_FOR_INTERFACE macro that caches the interface name in a local static FlyString. This means that we only pay for FlyString-from-literal lookup once per browser lifetime instead of every time the interface is instantiated.
34 lines
732 B
C++
34 lines
732 B
C++
/*
|
|
* Copyright (c) 2022, Andreas Kling <kling@serenityos.org>
|
|
*
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
*/
|
|
|
|
#include <LibWeb/Bindings/Intrinsics.h>
|
|
#include <LibWeb/SVG/SVGClipPathElement.h>
|
|
|
|
namespace Web::SVG {
|
|
|
|
JS_DEFINE_ALLOCATOR(SVGClipPathElement);
|
|
|
|
SVGClipPathElement::SVGClipPathElement(DOM::Document& document, DOM::QualifiedName qualified_name)
|
|
: SVGElement(document, move(qualified_name))
|
|
{
|
|
}
|
|
|
|
SVGClipPathElement::~SVGClipPathElement()
|
|
{
|
|
}
|
|
|
|
void SVGClipPathElement::initialize(JS::Realm& realm)
|
|
{
|
|
Base::initialize(realm);
|
|
WEB_SET_PROTOTYPE_FOR_INTERFACE(SVGClipPathElement);
|
|
}
|
|
|
|
JS::GCPtr<Layout::Node> SVGClipPathElement::create_layout_node(NonnullRefPtr<CSS::StyleProperties>)
|
|
{
|
|
return nullptr;
|
|
}
|
|
|
|
}
|