mirror of
https://github.com/servo/servo.git
synced 2025-10-05 11:09:22 +01:00
Async XHR GET with basic response header support
This commit is contained in:
parent
90a0bcfa78
commit
533fab46f9
8 changed files with 253 additions and 51 deletions
|
@ -21,6 +21,7 @@ use dom::eventtarget::{EventTarget, EventTargetHelpers};
|
|||
use dom::node;
|
||||
use dom::node::{Node, NodeHelpers};
|
||||
use dom::window::{TimerId, Window, WindowHelpers};
|
||||
use dom::xmlhttprequest::{TrustedXHRAddress, XMLHttpRequest, XHRProgress};
|
||||
use html::hubbub_html_parser::HtmlParserResult;
|
||||
use html::hubbub_html_parser::{HtmlDiscoveredStyle, HtmlDiscoveredScript};
|
||||
use html::hubbub_html_parser;
|
||||
|
@ -88,6 +89,8 @@ pub enum ScriptMsg {
|
|||
ExitPipelineMsg(PipelineId),
|
||||
/// Notifies the script that a window associated with a particular pipeline should be closed.
|
||||
ExitWindowMsg(PipelineId),
|
||||
/// Notifies the script of progress on a fetch
|
||||
XHRProgressMsg(TrustedXHRAddress, XHRProgress)
|
||||
}
|
||||
|
||||
pub struct NewLayoutInfo {
|
||||
|
@ -773,6 +776,7 @@ impl ScriptTask {
|
|||
ExitPipelineMsg(id) => if self.handle_exit_pipeline_msg(id) { return false },
|
||||
ExitWindowMsg(id) => self.handle_exit_window_msg(id),
|
||||
ResizeMsg(..) => fail!("should have handled ResizeMsg already"),
|
||||
XHRProgressMsg(addr, progress) => XMLHttpRequest::handle_xhr_progress(addr, progress),
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue