Perform a microtask checkpoint after executing classic scripts and callbacks.

This commit is contained in:
Josh Matthews 2017-01-12 12:53:53 -05:00
parent 32d4f84a30
commit b5d2bd757b
7 changed files with 49 additions and 25 deletions

View file

@ -567,6 +567,13 @@ impl ScriptThreadFactory for ScriptThread {
}
impl ScriptThread {
pub fn invoke_perform_a_microtask_checkpoint() {
SCRIPT_THREAD_ROOT.with(|root| {
let script_thread = unsafe { &*root.get().unwrap() };
script_thread.perform_a_microtask_checkpoint()
})
}
pub fn page_headers_available(id: &PipelineId, metadata: Option<Metadata>)
-> Option<Root<ServoParser>> {
SCRIPT_THREAD_ROOT.with(|root| {