mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
rename of page_fetch_complete and handle_page_fetch_complete
rename align
This commit is contained in:
parent
fc1e74c550
commit
71104c8619
2 changed files with 8 additions and 8 deletions
|
@ -94,7 +94,7 @@ impl AsyncResponseListener for ParserContext {
|
||||||
Err(_) => None,
|
Err(_) => None,
|
||||||
};
|
};
|
||||||
let content_type = metadata.clone().and_then(|meta| meta.content_type);
|
let content_type = metadata.clone().and_then(|meta| meta.content_type);
|
||||||
let parser = match ScriptThread::page_fetch_complete(&self.id,
|
let parser = match ScriptThread::page_headers_available(&self.id,
|
||||||
self.subpage.as_ref(),
|
self.subpage.as_ref(),
|
||||||
metadata) {
|
metadata) {
|
||||||
Some(parser) => parser,
|
Some(parser) => parser,
|
||||||
|
|
|
@ -477,11 +477,11 @@ pub unsafe extern "C" fn shadow_check_callback(_cx: *mut JSContext,
|
||||||
}
|
}
|
||||||
|
|
||||||
impl ScriptThread {
|
impl ScriptThread {
|
||||||
pub fn page_fetch_complete(id: &PipelineId, subpage: Option<&SubpageId>, metadata: Option<Metadata>)
|
pub fn page_headers_available(id: &PipelineId, subpage: Option<&SubpageId>, metadata: Option<Metadata>)
|
||||||
-> Option<ParserRoot> {
|
-> Option<ParserRoot> {
|
||||||
SCRIPT_THREAD_ROOT.with(|root| {
|
SCRIPT_THREAD_ROOT.with(|root| {
|
||||||
let script_thread = unsafe { &*root.borrow().unwrap() };
|
let script_thread = unsafe { &*root.borrow().unwrap() };
|
||||||
script_thread.handle_page_fetch_complete(id, subpage, metadata)
|
script_thread.handle_page_headers_available(id, subpage, metadata)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1298,7 +1298,7 @@ impl ScriptThread {
|
||||||
|
|
||||||
/// We have received notification that the response associated with a load has completed.
|
/// We have received notification that the response associated with a load has completed.
|
||||||
/// Kick off the document and frame tree creation process using the result.
|
/// Kick off the document and frame tree creation process using the result.
|
||||||
fn handle_page_fetch_complete(&self, id: &PipelineId, subpage: Option<&SubpageId>,
|
fn handle_page_headers_available(&self, id: &PipelineId, subpage: Option<&SubpageId>,
|
||||||
metadata: Option<Metadata>) -> Option<ParserRoot> {
|
metadata: Option<Metadata>) -> Option<ParserRoot> {
|
||||||
let idx = self.incomplete_loads.borrow().iter().position(|load| {
|
let idx = self.incomplete_loads.borrow().iter().position(|load| {
|
||||||
load.pipeline_id == *id && load.parent_info.as_ref().map(|info| &info.1) == subpage
|
load.pipeline_id == *id && load.parent_info.as_ref().map(|info| &info.1) == subpage
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue