mirror of
https://github.com/servo/servo.git
synced 2025-07-24 15:50:21 +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) {
|
fn unbind_from_tree(&self, context: &UnbindContext) {
|
||||||
self.super_type().unwrap().unbind_from_tree(context);
|
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 node = self.upcast::<Node>();
|
||||||
let el = self.upcast::<Element>();
|
let el = self.upcast::<Element>();
|
||||||
if node.GetParentNode().is_some() {
|
if node.GetParentNode().is_some() {
|
||||||
|
|
|
@ -1,5 +0,0 @@
|
||||||
[select-ask-for-reset.html]
|
|
||||||
type: testharness
|
|
||||||
[ask for reset on node remove, non multiple.]
|
|
||||||
expected: FAIL
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue