mirror of
https://github.com/servo/servo.git
synced 2025-08-04 21:20:23 +01:00
Finish the integration of webxr
into the Cargo workspace (#35229)
- Run `cargo fmt` on `webxr` and `webxr-api` - Fix clippy warnings in the existing `webxr` code - Integrate the new crates into the workspace - Expose `webxr` via the libservo API rather than requiring embedders to depend on it explicitly. Signed-off-by: Martin Robinson <mrobinson@igalia.com>
This commit is contained in:
parent
a4c6c205d2
commit
5466c27f6f
41 changed files with 448 additions and 649 deletions
|
@ -2,18 +2,15 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use crate::Hand;
|
||||
use crate::Input;
|
||||
use crate::JointFrame;
|
||||
use crate::Native;
|
||||
|
||||
use euclid::RigidTransform3D;
|
||||
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq, Hash)]
|
||||
use crate::{Hand, Input, JointFrame, Native};
|
||||
|
||||
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
|
||||
#[cfg_attr(feature = "ipc", derive(serde::Serialize, serde::Deserialize))]
|
||||
pub struct InputId(pub u32);
|
||||
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
#[derive(Clone, Copy, Debug)]
|
||||
#[cfg_attr(feature = "ipc", derive(serde::Serialize, serde::Deserialize))]
|
||||
pub enum Handedness {
|
||||
None,
|
||||
|
@ -21,7 +18,7 @@ pub enum Handedness {
|
|||
Right,
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug)]
|
||||
#[derive(Clone, Copy, Debug)]
|
||||
#[cfg_attr(feature = "ipc", derive(serde::Serialize, serde::Deserialize))]
|
||||
pub enum TargetRayMode {
|
||||
Gaze,
|
||||
|
@ -55,7 +52,7 @@ pub struct InputFrame {
|
|||
pub input_changed: bool,
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq)]
|
||||
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
|
||||
#[cfg_attr(feature = "ipc", derive(serde::Serialize, serde::Deserialize))]
|
||||
pub enum SelectEvent {
|
||||
/// Selection started
|
||||
|
@ -66,7 +63,7 @@ pub enum SelectEvent {
|
|||
Select,
|
||||
}
|
||||
|
||||
#[derive(Copy, Clone, Debug, PartialEq, Eq)]
|
||||
#[derive(Clone, Copy, Debug, Eq, PartialEq)]
|
||||
#[cfg_attr(feature = "ipc", derive(serde::Serialize, serde::Deserialize))]
|
||||
pub enum SelectKind {
|
||||
Select,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue