mirror of
https://github.com/servo/servo.git
synced 2025-06-11 01:50:10 +00:00
script: Fix a few load related bugs.
This is what was making me hit the new test failures. So turns out that when the DOMContentLoaded event is fired we fired no messages to the constellation, but we fired the DOMLoad message from the DocumentProgressHandler, effectively after having dispatched the Load message from script thread. This also fixes the possibility of a subframe navigation not blocking the load event of the parent document, for example.
This commit is contained in:
parent
d81fe27b11
commit
e6958d3947
4 changed files with 22 additions and 14 deletions
|
@ -1193,8 +1193,6 @@ impl ScriptThread {
|
|||
// https://html.spec.whatwg.org/multipage/#the-end step 7
|
||||
let handler = box DocumentProgressHandler::new(Trusted::new(doc));
|
||||
self.dom_manipulation_task_source.queue(handler, GlobalRef::Window(doc.window())).unwrap();
|
||||
|
||||
self.constellation_chan.send(ConstellationMsg::LoadComplete(pipeline)).unwrap();
|
||||
}
|
||||
|
||||
fn collect_reports(&self, reports_chan: ReportsChan) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue