diff options
author | Sumit <srivassumit@gmail.com> | 2017-05-14 01:44:14 -0400 |
---|---|---|
committer | Josh Matthews <josh@joshmatthews.net> | 2017-05-15 18:15:38 -0400 |
commit | 3ca89204ffcdcabcf7bb1a343497bdae860c72b2 (patch) | |
tree | bb775040dde9f58f5ad424e39f10eda8ebbb4f1b /components/script/microtask.rs | |
parent | fa251ec96b445b9ba8439d76e05870a88c2caa0f (diff) | |
download | servo-3ca89204ffcdcabcf7bb1a343497bdae860c72b2.tar.gz servo-3ca89204ffcdcabcf7bb1a343497bdae860c72b2.zip |
Mutation Observer API
Diffstat (limited to 'components/script/microtask.rs')
-rw-r--r-- | components/script/microtask.rs | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/components/script/microtask.rs b/components/script/microtask.rs index da04d1ed6ab..7fadf111ddb 100644 --- a/components/script/microtask.rs +++ b/components/script/microtask.rs @@ -11,6 +11,7 @@ use dom::bindings::cell::DOMRefCell; use dom::bindings::codegen::Bindings::PromiseBinding::PromiseJobCallback; use dom::bindings::js::Root; use dom::globalscope::GlobalScope; +use dom::mutationobserver::MutationObserver; use msg::constellation_msg::PipelineId; use std::cell::Cell; use std::mem; @@ -28,6 +29,7 @@ pub struct MicrotaskQueue { #[derive(JSTraceable, HeapSizeOf)] pub enum Microtask { Promise(EnqueuedPromiseCallback), + NotifyMutationObservers, } /// A promise callback scheduled to run during the next microtask checkpoint (#4283). @@ -71,6 +73,9 @@ impl MicrotaskQueue { let _ = job.callback.Call_(&*target, ExceptionHandling::Report); } } + Microtask::NotifyMutationObservers => { + MutationObserver::notify_mutation_observers(); + } } } } |