mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Auto merge of #14246 - emilio:servo-url, r=SimonSapin
Urlmageddon <!-- Please describe your changes on the following line: --> Still needs a bunch of code in net to be converted in order to get more advantage of this for images and stuff, but meanwhile this should help quite a bit with #13778. Still wanted to get this in. r? @SimonSapin <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/14246) <!-- Reviewable:end -->
This commit is contained in:
commit
22aebdf5d4
161 changed files with 1044 additions and 718 deletions
|
@ -34,6 +34,7 @@ use script_runtime::{ScriptThreadEventCategory, PromiseJobQueue, EnqueuedPromise
|
|||
use script_thread::{Runnable, RunnableWrapper};
|
||||
use script_traits::{TimerEvent, TimerEventId};
|
||||
use script_traits::WorkerGlobalScopeInit;
|
||||
use servo_url::ServoUrl;
|
||||
use std::default::Default;
|
||||
use std::panic;
|
||||
use std::rc::Rc;
|
||||
|
@ -43,7 +44,6 @@ use std::sync::mpsc::Receiver;
|
|||
use task_source::file_reading::FileReadingTaskSource;
|
||||
use task_source::networking::NetworkingTaskSource;
|
||||
use timers::{IsInterval, TimerCallback};
|
||||
use url::Url;
|
||||
|
||||
pub fn prepare_workerscope_init(global: &GlobalScope,
|
||||
devtools_sender: Option<IpcSender<DevtoolScriptControlMsg>>) -> WorkerGlobalScopeInit {
|
||||
|
@ -68,7 +68,7 @@ pub struct WorkerGlobalScope {
|
|||
globalscope: GlobalScope,
|
||||
|
||||
worker_id: WorkerId,
|
||||
worker_url: Url,
|
||||
worker_url: ServoUrl,
|
||||
#[ignore_heap_size_of = "Arc"]
|
||||
closing: Option<Arc<AtomicBool>>,
|
||||
#[ignore_heap_size_of = "Defined in js"]
|
||||
|
@ -91,7 +91,7 @@ pub struct WorkerGlobalScope {
|
|||
|
||||
impl WorkerGlobalScope {
|
||||
pub fn new_inherited(init: WorkerGlobalScopeInit,
|
||||
worker_url: Url,
|
||||
worker_url: ServoUrl,
|
||||
runtime: Runtime,
|
||||
from_devtools_receiver: Receiver<DevtoolScriptControlMsg>,
|
||||
timer_event_chan: IpcSender<TimerEvent>,
|
||||
|
@ -144,7 +144,7 @@ impl WorkerGlobalScope {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn get_url(&self) -> &Url {
|
||||
pub fn get_url(&self) -> &ServoUrl {
|
||||
&self.worker_url
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue