mirror of
https://github.com/servo/servo.git
synced 2025-08-05 05:30:08 +01:00
Expose webxr registry to window
This commit is contained in:
parent
305312e93b
commit
5f69a9e66a
2 changed files with 10 additions and 0 deletions
|
@ -266,6 +266,9 @@ pub struct Window {
|
||||||
#[ignore_malloc_size_of = "channels are hard"]
|
#[ignore_malloc_size_of = "channels are hard"]
|
||||||
webvr_chan: Option<IpcSender<WebVRMsg>>,
|
webvr_chan: Option<IpcSender<WebVRMsg>>,
|
||||||
|
|
||||||
|
#[ignore_malloc_size_of = "defined in webxr"]
|
||||||
|
webxr_registry: webxr_api::Registry,
|
||||||
|
|
||||||
/// A map for storing the previous permission state read results.
|
/// A map for storing the previous permission state read results.
|
||||||
permission_state_invocation_results: DomRefCell<HashMap<String, PermissionState>>,
|
permission_state_invocation_results: DomRefCell<HashMap<String, PermissionState>>,
|
||||||
|
|
||||||
|
@ -436,6 +439,10 @@ impl Window {
|
||||||
self.webvr_chan.clone()
|
self.webvr_chan.clone()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn webxr_registry(&self) -> &webxr_api::Registry {
|
||||||
|
&self.webxr_registry
|
||||||
|
}
|
||||||
|
|
||||||
fn new_paint_worklet(&self) -> DomRoot<Worklet> {
|
fn new_paint_worklet(&self) -> DomRoot<Worklet> {
|
||||||
debug!("Creating new paint worklet.");
|
debug!("Creating new paint worklet.");
|
||||||
Worklet::new(self, WorkletGlobalScopeType::Paint)
|
Worklet::new(self, WorkletGlobalScopeType::Paint)
|
||||||
|
@ -2072,6 +2079,7 @@ impl Window {
|
||||||
navigation_start_precise: u64,
|
navigation_start_precise: u64,
|
||||||
webgl_chan: Option<WebGLChan>,
|
webgl_chan: Option<WebGLChan>,
|
||||||
webvr_chan: Option<IpcSender<WebVRMsg>>,
|
webvr_chan: Option<IpcSender<WebVRMsg>>,
|
||||||
|
webxr_registry: webxr_api::Registry,
|
||||||
microtask_queue: Rc<MicrotaskQueue>,
|
microtask_queue: Rc<MicrotaskQueue>,
|
||||||
webrender_document: DocumentId,
|
webrender_document: DocumentId,
|
||||||
webrender_api_sender: RenderApiSender,
|
webrender_api_sender: RenderApiSender,
|
||||||
|
@ -2149,6 +2157,7 @@ impl Window {
|
||||||
test_runner: Default::default(),
|
test_runner: Default::default(),
|
||||||
webgl_chan,
|
webgl_chan,
|
||||||
webvr_chan,
|
webvr_chan,
|
||||||
|
webxr_registry,
|
||||||
permission_state_invocation_results: Default::default(),
|
permission_state_invocation_results: Default::default(),
|
||||||
pending_layout_images: Default::default(),
|
pending_layout_images: Default::default(),
|
||||||
unminified_js_dir: Default::default(),
|
unminified_js_dir: Default::default(),
|
||||||
|
|
|
@ -2975,6 +2975,7 @@ impl ScriptThread {
|
||||||
incomplete.navigation_start_precise,
|
incomplete.navigation_start_precise,
|
||||||
self.webgl_chan.as_ref().map(|chan| chan.channel()),
|
self.webgl_chan.as_ref().map(|chan| chan.channel()),
|
||||||
self.webvr_chan.clone(),
|
self.webvr_chan.clone(),
|
||||||
|
self.webxr_registry.clone(),
|
||||||
self.microtask_queue.clone(),
|
self.microtask_queue.clone(),
|
||||||
self.webrender_document,
|
self.webrender_document,
|
||||||
self.webrender_api_sender.clone(),
|
self.webrender_api_sender.clone(),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue