Simplify processing of deferred scripts

It is now done on-demand when a deferred script finished loading, and when
the page source finished loading.
This commit is contained in:
Anthony Ramine 2017-01-20 16:41:49 +01:00
parent abdb390da8
commit e9feb20775
2 changed files with 11 additions and 6 deletions

View file

@ -359,9 +359,8 @@ impl ServoParser {
window.reflow(ReflowGoal::ForDisplay, ReflowQueryType::NoQuery, ReflowReason::FirstLoad);
}
// Steps 3-12 are in other castles, namely process_deferred_scripts and finish_load.
// Steps 3-12 are in another castle, namely finish_load.
let url = self.tokenizer.borrow().url().clone();
self.document.process_deferred_scripts();
self.document.finish_load(LoadType::PageSource(url));
}
}