LibWeb: Move ariaActiveDescendantElement to ARIAMixin

Not an issue right now, but all IDL types that include the ARIA mixin
will need this.
This commit is contained in:
Timothy Flynn 2025-04-24 11:22:52 -04:00 committed by Tim Ledbetter
commit 0289df9357
Notes: github-actions[bot] 2025-04-25 00:21:29 +00:00
4 changed files with 20 additions and 9 deletions

View file

@ -105,8 +105,8 @@ void Element::visit_edges(Cell::Visitor& visitor)
Base::visit_edges(visitor);
SlottableMixin::visit_edges(visitor);
Animatable::visit_edges(visitor);
ARIAMixin::visit_edges(visitor);
visitor.visit(m_aria_active_descendant_element);
visitor.visit(m_attributes);
visitor.visit(m_inline_style);
visitor.visit(m_class_list);
@ -3607,7 +3607,7 @@ void Element::attribute_changed(FlyString const& local_name, Optional<String> co
} else if (local_name == ARIA::AttributeNames::aria_active_descendant) {
// https://html.spec.whatwg.org/multipage/common-dom-interfaces.html#reflecting-content-attributes-in-idl-attributes:concept-element-attributes-change-ext
// Set element's explicitly set attr-element to null.
m_aria_active_descendant_element = nullptr;
set_aria_active_descendant_element({});
}
}