mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Ask for reset when option is removed.
This commit is contained in:
parent
941653da65
commit
12afd837a0
2 changed files with 6 additions and 5 deletions
|
@ -210,6 +210,12 @@ impl VirtualMethods for HTMLOptionElement {
|
|||
fn unbind_from_tree(&self, context: &UnbindContext) {
|
||||
self.super_type().unwrap().unbind_from_tree(context);
|
||||
|
||||
if let Some(select) = context.parent.inclusive_ancestors()
|
||||
.filter_map(Root::downcast::<HTMLSelectElement>)
|
||||
.next() {
|
||||
select.ask_for_reset();
|
||||
}
|
||||
|
||||
let node = self.upcast::<Node>();
|
||||
let el = self.upcast::<Element>();
|
||||
if node.GetParentNode().is_some() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue