mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Remove WebVR
This commit is contained in:
parent
d8781c1054
commit
c611e46381
74 changed files with 97 additions and 3178 deletions
|
@ -167,7 +167,6 @@ use time::{at_utc, get_time, precise_time_ns, Timespec};
|
|||
use url::Position;
|
||||
use webrender_api::units::LayoutPixel;
|
||||
use webrender_api::DocumentId;
|
||||
use webvr_traits::{WebVREvent, WebVRMsg};
|
||||
|
||||
pub type ImageCacheMsg = (PipelineId, PendingImageResponse);
|
||||
|
||||
|
@ -630,9 +629,6 @@ pub struct ScriptThread {
|
|||
/// A handle to the WebGL thread
|
||||
webgl_chan: Option<WebGLPipeline>,
|
||||
|
||||
/// A handle to the webvr thread, if available
|
||||
webvr_chan: Option<IpcSender<WebVRMsg>>,
|
||||
|
||||
/// The WebXR device registry
|
||||
webxr_registry: webxr_api::Registry,
|
||||
|
||||
|
@ -1338,7 +1334,6 @@ impl ScriptThread {
|
|||
layout_to_constellation_chan: state.layout_to_constellation_chan,
|
||||
|
||||
webgl_chan: state.webgl_chan,
|
||||
webvr_chan: state.webvr_chan,
|
||||
webxr_registry: state.webxr_registry,
|
||||
|
||||
worklet_thread_pool: Default::default(),
|
||||
|
@ -1660,7 +1655,6 @@ impl ScriptThread {
|
|||
},
|
||||
ScriptThreadEventCategory::EnterFullscreen => ScriptHangAnnotation::EnterFullscreen,
|
||||
ScriptThreadEventCategory::ExitFullscreen => ScriptHangAnnotation::ExitFullscreen,
|
||||
ScriptThreadEventCategory::WebVREvent => ScriptHangAnnotation::WebVREvent,
|
||||
ScriptThreadEventCategory::PerformanceTimelineTask => {
|
||||
ScriptHangAnnotation::PerformanceTimelineTask
|
||||
},
|
||||
|
@ -1710,7 +1704,6 @@ impl ScriptThread {
|
|||
DispatchStorageEvent(id, ..) => Some(id),
|
||||
ReportCSSError(id, ..) => Some(id),
|
||||
Reload(id, ..) => Some(id),
|
||||
WebVREvents(id, ..) => Some(id),
|
||||
PaintMetric(..) => None,
|
||||
ExitFullScreen(id, ..) => Some(id),
|
||||
MediaSessionAction(..) => None,
|
||||
|
@ -1771,7 +1764,6 @@ impl ScriptThread {
|
|||
ScriptThreadEventCategory::SetViewport => ProfilerCategory::ScriptSetViewport,
|
||||
ScriptThreadEventCategory::TimerEvent => ProfilerCategory::ScriptTimerEvent,
|
||||
ScriptThreadEventCategory::WebSocketEvent => ProfilerCategory::ScriptWebSocketEvent,
|
||||
ScriptThreadEventCategory::WebVREvent => ProfilerCategory::ScriptWebVREvent,
|
||||
ScriptThreadEventCategory::WorkerEvent => ProfilerCategory::ScriptWorkerEvent,
|
||||
ScriptThreadEventCategory::WorkletEvent => ProfilerCategory::ScriptWorkletEvent,
|
||||
ScriptThreadEventCategory::ServiceWorkerEvent => {
|
||||
|
@ -1930,9 +1922,6 @@ impl ScriptThread {
|
|||
ConstellationControlMsg::ExitPipeline(pipeline_id, discard_browsing_context) => {
|
||||
self.handle_exit_pipeline_msg(pipeline_id, discard_browsing_context)
|
||||
},
|
||||
ConstellationControlMsg::WebVREvents(pipeline_id, events) => {
|
||||
self.handle_webvr_events(pipeline_id, events)
|
||||
},
|
||||
ConstellationControlMsg::PaintMetric(pipeline_id, metric_type, metric_value) => {
|
||||
self.handle_paint_metric(pipeline_id, metric_type, metric_value)
|
||||
},
|
||||
|
@ -3210,7 +3199,6 @@ impl ScriptThread {
|
|||
incomplete.navigation_start,
|
||||
incomplete.navigation_start_precise,
|
||||
self.webgl_chan.as_ref().map(|chan| chan.channel()),
|
||||
self.webvr_chan.clone(),
|
||||
self.webxr_registry.clone(),
|
||||
self.microtask_queue.clone(),
|
||||
self.webrender_document,
|
||||
|
@ -3876,14 +3864,6 @@ impl ScriptThread {
|
|||
}
|
||||
}
|
||||
|
||||
fn handle_webvr_events(&self, pipeline_id: PipelineId, events: Vec<WebVREvent>) {
|
||||
let window = self.documents.borrow().find_window(pipeline_id);
|
||||
if let Some(window) = window {
|
||||
let xr = window.Navigator().Xr();
|
||||
xr.handle_webvr_events(events);
|
||||
}
|
||||
}
|
||||
|
||||
fn handle_paint_metric(
|
||||
&self,
|
||||
pipeline_id: PipelineId,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue