Fill in XR frame/pose/view implementations

This commit is contained in:
Manish Goregaokar 2018-12-21 15:20:51 -08:00
parent 7e043a33f1
commit 28dff81dbf
12 changed files with 152 additions and 38 deletions

View file

@ -22,12 +22,20 @@ impl XRViewport {
fn new_inherited(x: u32, y: u32, width: u32, height: u32) -> XRViewport {
XRViewport {
reflector_: Reflector::new(),
x, y, width, height
x,
y,
width,
height,
}
}
pub fn new(global: &GlobalScope,
x: u32, y: u32, width: u32, height: u32) -> DomRoot<XRViewport> {
pub fn new(
global: &GlobalScope,
x: u32,
y: u32,
width: u32,
height: u32,
) -> DomRoot<XRViewport> {
reflect_dom_object(
Box::new(XRViewport::new_inherited(x, y, width, height)),
global,
@ -56,4 +64,4 @@ impl XRViewportMethods for XRViewport {
fn Height(&self) -> i32 {
self.height as i32
}
}
}