diff --git a/Libraries/LibWeb/Bindings/OptionConstructor.cpp b/Libraries/LibWeb/Bindings/OptionConstructor.cpp index 3d5482f884f..601f1f4475f 100644 --- a/Libraries/LibWeb/Bindings/OptionConstructor.cpp +++ b/Libraries/LibWeb/Bindings/OptionConstructor.cpp @@ -77,7 +77,7 @@ JS::ThrowCompletionOr> OptionConstructor::construct } // 6. If selected is true, then set option's selectedness to true; otherwise set its selectedness to false (even if defaultSelected is true). - option_element->m_selected = vm.argument(3).to_boolean(); + option_element->set_selected_internal(vm.argument(3).to_boolean()); // 7. Return option. return option_element; diff --git a/Libraries/LibWeb/HTML/HTMLOptGroupElement.cpp b/Libraries/LibWeb/HTML/HTMLOptGroupElement.cpp index 64b568c51fd..18677ba557b 100644 --- a/Libraries/LibWeb/HTML/HTMLOptGroupElement.cpp +++ b/Libraries/LibWeb/HTML/HTMLOptGroupElement.cpp @@ -7,6 +7,7 @@ #include #include #include +#include namespace Web::HTML { @@ -25,4 +26,24 @@ void HTMLOptGroupElement::initialize(JS::Realm& realm) WEB_SET_PROTOTYPE_FOR_INTERFACE(HTMLOptGroupElement); } +void HTMLOptGroupElement::inserted() +{ + Base::inserted(); + + // AD-HOC: We update the selectedness of our needs to be updated when is removed \ No newline at end of file +Result Test Name MessagePass