dymokomi/luce-browser-engine
Source of release 0.6.1
0.6.1 / src / web / html / html_menu_element.lucb
#==============================================================================================
#
# html_menu_element - HTML::HTMLMenuElement: <menu>
#
# DESCRIPTION:
# Port of LibWeb/HTML/HTMLMenuElement.cpp (lines 1-28) and HTMLMenuElement.h: the
# constructor (which moves the mixin tables to HTMLMenuElement's, as C++'s vptrs move),
# initialize and the inline overrides.
#
#==============================================================================================
## Ported from HTMLMenuElement.cpp:15 Web::HTML::HTMLMenuElement::HTMLMenuElement.
pub func html_menu_element_construct(this: HtmlMenuElement*, document: DomDocument*, qualified_name: DomQualifiedName):
html_element_construct(this.html_element(), document, qualified_name)
# The vptrs of the mixin bases move to HTMLMenuElement's tables.
let element = this.html_element()
element.element.slottable_mixin.vtable = &html_menu_element_slottable_mixin_vtable
element.element.aria_mixin.vtable = &html_menu_element_aria_mixin_vtable
element.element.animatable.vtable = &html_menu_element_animatable_vtable
element.global_event_handlers.vtable = &html_menu_element_global_event_handlers_vtable
element.form_associated_element.vtable = &html_menu_element_form_associated_element_vtable
## Ported from HTMLMenuElement.cpp:22 Web::HTML::HTMLMenuElement::initialize (override).
pub func html_menu_element_initialize_impl(base: JsCell*, realm: Realm*):
web_set_prototype_for_interface(base, realm, BindInterfaceName.html_menu_element)
html_element_initialize_impl(base, realm)
## Ported from HTMLMenuElement.h:22 Web::HTML::HTMLMenuElement::default_role (override).
pub func html_menu_element_default_role_impl(base: AriaMixin*) -> AriaRole?:
return AriaRole.list
## Ported from HTMLMenuElement.h:24 Web::HTML::HTMLMenuElement::is_html_menu_element (override).
pub func html_menu_element_is_html_menu_element_impl(base: DomNode*) -> bool:
return true