2024-03-31 14:54:00 +01:00
|
|
|
/*
|
|
|
|
|
* Copyright (c) 2024, MacDue <macdue@dueutil.tech>
|
2025-11-05 15:20:53 +01:00
|
|
|
* Copyright (c) 2025, Jelle Raaijmakers <jelle@ladybird.org>
|
2024-03-31 14:54:00 +01:00
|
|
|
*
|
|
|
|
|
* SPDX-License-Identifier: BSD-2-Clause
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#include <LibWeb/Bindings/Intrinsics.h>
|
2024-04-27 12:09:58 +12:00
|
|
|
#include <LibWeb/Bindings/SVGTransformListPrototype.h>
|
2024-03-31 14:54:00 +01:00
|
|
|
#include <LibWeb/SVG/SVGTransformList.h>
|
|
|
|
|
#include <LibWeb/WebIDL/ExceptionOr.h>
|
|
|
|
|
|
|
|
|
|
namespace Web::SVG {
|
|
|
|
|
|
2024-11-15 04:01:23 +13:00
|
|
|
GC_DEFINE_ALLOCATOR(SVGTransformList);
|
2024-03-31 14:54:00 +01:00
|
|
|
|
2025-11-05 15:20:53 +01:00
|
|
|
GC::Ref<SVGTransformList> SVGTransformList::create(JS::Realm& realm, Vector<GC::Ref<SVGTransform>> items, ReadOnlyList read_only)
|
2024-03-31 14:54:00 +01:00
|
|
|
{
|
2025-11-05 15:20:53 +01:00
|
|
|
return realm.create<SVGTransformList>(realm, move(items), read_only);
|
2024-03-31 14:54:00 +01:00
|
|
|
}
|
|
|
|
|
|
2025-11-05 15:20:53 +01:00
|
|
|
GC::Ref<SVGTransformList> SVGTransformList::create(JS::Realm& realm, ReadOnlyList read_only)
|
2024-06-02 12:48:35 +01:00
|
|
|
{
|
2025-11-05 15:20:53 +01:00
|
|
|
return realm.create<SVGTransformList>(realm, read_only);
|
2024-06-02 12:48:35 +01:00
|
|
|
}
|
|
|
|
|
|
2025-11-05 15:20:53 +01:00
|
|
|
SVGTransformList::SVGTransformList(JS::Realm& realm, Vector<GC::Ref<SVGTransform>> items, ReadOnlyList read_only)
|
|
|
|
|
: Bindings::PlatformObject(realm)
|
|
|
|
|
, SVGList(realm, move(items), read_only)
|
2024-03-31 14:54:00 +01:00
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
2025-11-05 15:20:53 +01:00
|
|
|
SVGTransformList::SVGTransformList(JS::Realm& realm, ReadOnlyList read_only)
|
|
|
|
|
: Bindings::PlatformObject(realm)
|
|
|
|
|
, SVGList(realm, read_only)
|
2024-03-31 14:54:00 +01:00
|
|
|
{
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
void SVGTransformList::initialize(JS::Realm& realm)
|
|
|
|
|
{
|
|
|
|
|
WEB_SET_PROTOTYPE_FOR_INTERFACE(SVGTransformList);
|
2025-04-20 16:22:57 +02:00
|
|
|
Base::initialize(realm);
|
2024-03-31 14:54:00 +01:00
|
|
|
}
|
|
|
|
|
|
2025-11-05 15:20:53 +01:00
|
|
|
void SVGTransformList::visit_edges(Visitor& visitor)
|
2024-03-31 14:54:00 +01:00
|
|
|
{
|
|
|
|
|
Base::visit_edges(visitor);
|
2025-11-05 15:20:53 +01:00
|
|
|
SVGList::visit_edges(visitor);
|
2024-03-31 14:54:00 +01:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|