LibWeb: Convert HTMLCollection to use IDL special operations

This commit is contained in:
Luke Wilde 2021-09-26 15:14:37 +01:00 committed by Andreas Kling
commit 37347cbcb6
Notes: sideshowbarker 2024-07-18 03:25:51 +09:00
6 changed files with 72 additions and 42 deletions

View file

@ -42,10 +42,13 @@ public:
~HTMLCollection();
size_t length();
Element* item(size_t index);
Element* named_item(FlyString const& name);
Element* item(size_t index) const;
Element* named_item(FlyString const& name) const;
Vector<NonnullRefPtr<Element>> collect_matching_elements();
Vector<NonnullRefPtr<Element>> collect_matching_elements() const;
Vector<String> supported_property_names() const;
bool is_supported_property_index(u32) const;
protected:
HTMLCollection(ParentNode& root, Function<bool(Element const&)> filter);