mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Remove "fire a simple event" concept, refactor event firing API.
"fire a simple event" concept was removed in https://github.com/whatwg/html/pull/1933.
This commit is contained in:
parent
5b4cc9568d
commit
c3b279a4c3
15 changed files with 58 additions and 52 deletions
|
@ -849,12 +849,8 @@ impl HTMLInputElement {
|
|||
let filelist = FileList::new(&window, files);
|
||||
self.filelist.set(Some(&filelist));
|
||||
|
||||
target.fire_event("input",
|
||||
EventBubbles::Bubbles,
|
||||
EventCancelable::NotCancelable);
|
||||
target.fire_event("change",
|
||||
EventBubbles::Bubbles,
|
||||
EventCancelable::NotCancelable);
|
||||
target.fire_bubbling_event("input");
|
||||
target.fire_bubbling_event("change");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -1290,12 +1286,8 @@ impl Activatable for HTMLInputElement {
|
|||
// https://html.spec.whatwg.org/multipage/#radio-button-state-(type=radio):activation-behavior
|
||||
// Check if document owner is fully active
|
||||
let target = self.upcast::<EventTarget>();
|
||||
target.fire_event("input",
|
||||
EventBubbles::Bubbles,
|
||||
EventCancelable::NotCancelable);
|
||||
target.fire_event("change",
|
||||
EventBubbles::Bubbles,
|
||||
EventCancelable::NotCancelable);
|
||||
target.fire_bubbling_event("input");
|
||||
target.fire_bubbling_event("change");
|
||||
},
|
||||
InputType::InputFile => self.select_files(None),
|
||||
_ => ()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue