HTMLFieldSetElement.h [plain text]
#ifndef HTMLFieldSetElement_h
#define HTMLFieldSetElement_h
#include "HTMLFormControlElement.h"
#include <wtf/HashSet.h>
namespace WebCore {
class FormAssociatedElement;
class HTMLCollection;
class HTMLFieldSetElement final : public HTMLFormControlElement {
public:
static Ref<HTMLFieldSetElement> create(const QualifiedName&, Document&, HTMLFormElement*);
HTMLLegendElement* legend() const;
Ref<HTMLCollection> elements();
const Vector<FormAssociatedElement*>& associatedElements() const;
unsigned length() const;
void addInvalidDescendant(const HTMLFormControlElement&);
void removeInvalidDescendant(const HTMLFormControlElement&);
private:
HTMLFieldSetElement(const QualifiedName&, Document&, HTMLFormElement*);
~HTMLFieldSetElement();
virtual bool isEnumeratable() const override { return true; }
virtual bool supportsFocus() const override;
virtual RenderPtr<RenderElement> createElementRenderer(Ref<RenderStyle>&&, const RenderTreePosition&) override;
virtual const AtomicString& formControlType() const override;
virtual bool computeWillValidate() const override { return false; }
virtual void disabledAttributeChanged() override;
virtual void disabledStateChanged() override;
virtual void childrenChanged(const ChildChange&) override;
virtual void didMoveToNewDocument(Document* oldDocument) override;
virtual bool matchesValidPseudoClass() const override;
virtual bool matchesInvalidPseudoClass() const override;
void refreshElementsIfNeeded() const;
mutable Vector<FormAssociatedElement*> m_associatedElements;
mutable uint64_t m_documentVersion;
HashSet<const HTMLFormControlElement*> m_invalidDescendants;
};
}
#endif