diff options
author | Kunal Mohan <kunalmohan99@gmail.com> | 2020-01-24 13:29:09 +0530 |
---|---|---|
committer | Kunal Mohan <kunalmohan99@gmail.com> | 2020-01-24 20:52:36 +0530 |
commit | 5a3e1b8e6903c825e50597a218532d417f1dfef9 (patch) | |
tree | 50770b139f2e9968f7c15de246f222936975722f /components/script/script_thread.rs | |
parent | be409233fdf8d3578e0529ec150a3697788ba4c8 (diff) | |
download | servo-5a3e1b8e6903c825e50597a218532d417f1dfef9.tar.gz servo-5a3e1b8e6903c825e50597a218532d417f1dfef9.zip |
rename compartment to realm
Diffstat (limited to 'components/script/script_thread.rs')
-rw-r--r-- | components/script/script_thread.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/components/script/script_thread.rs b/components/script/script_thread.rs index 9ce99c26441..bcc7b10f8c7 100644 --- a/components/script/script_thread.rs +++ b/components/script/script_thread.rs @@ -17,7 +17,6 @@ //! a page runs its course and the script thread returns to processing events in the main event //! loop. -use crate::compartments::enter_realm; use crate::devtools; use crate::document_loader::DocumentLoader; use crate::dom::bindings::cell::DomRefCell; @@ -69,6 +68,7 @@ use crate::dom::worklet::WorkletThreadPool; use crate::dom::workletglobalscope::WorkletGlobalScopeInit; use crate::fetch::FetchCanceller; use crate::microtask::{Microtask, MicrotaskQueue}; +use crate::realms::enter_realm; use crate::script_runtime::{get_reports, new_rt_and_cx, JSContext, Runtime, ScriptPort}; use crate::script_runtime::{CommonScriptMsg, ScriptChan, ScriptThreadEventCategory}; use crate::serviceworkerjob::{Job, JobQueue}; @@ -701,7 +701,7 @@ pub struct ScriptThread { /// In the event of thread panic, all data on the stack runs its destructor. However, there /// are no reachable, owning pointers to the DOM memory, so it never gets freed by default /// when the script thread fails. The ScriptMemoryFailsafe uses the destructor bomb pattern -/// to forcibly tear down the JS compartments for pages associated with the failing ScriptThread. +/// to forcibly tear down the JS realms for pages associated with the failing ScriptThread. struct ScriptMemoryFailsafe<'a> { owner: Option<&'a ScriptThread>, } @@ -2264,7 +2264,7 @@ impl ScriptThread { warn!("resize sent to nonexistent pipeline"); } - // exit_fullscreen creates a new JS promise object, so we need to have entered a compartment + // exit_fullscreen creates a new JS promise object, so we need to have entered a realm fn handle_exit_fullscreen(&self, id: PipelineId) { let document = self.documents.borrow().find_document(id); if let Some(document) = document { |