aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/fakexrinputcontroller.rs
diff options
context:
space:
mode:
authorManish Goregaokar <manishsmail@gmail.com>2020-01-13 15:31:31 +0530
committerManish Goregaokar <manishsmail@gmail.com>2020-01-21 15:47:30 -0800
commite0135fe7832382b01d3269f6d231477196d09b4f (patch)
tree85ec8da24d41e5f36ab900301cf0009fd66ed5f3 /components/script/dom/fakexrinputcontroller.rs
parent9c34a6585b50b7c20468060dafca717d1d363e6c (diff)
downloadservo-e0135fe7832382b01d3269f6d231477196d09b4f.tar.gz
servo-e0135fe7832382b01d3269f6d231477196d09b4f.zip
Support profiles
Diffstat (limited to 'components/script/dom/fakexrinputcontroller.rs')
-rw-r--r--components/script/dom/fakexrinputcontroller.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/components/script/dom/fakexrinputcontroller.rs b/components/script/dom/fakexrinputcontroller.rs
index 7c145a3ed20..e93d328ff29 100644
--- a/components/script/dom/fakexrinputcontroller.rs
+++ b/components/script/dom/fakexrinputcontroller.rs
@@ -12,6 +12,7 @@ use crate::dom::bindings::codegen::Bindings::XRInputSourceBinding::{
use crate::dom::bindings::error::Fallible;
use crate::dom::bindings::reflector::{reflect_dom_object, Reflector};
use crate::dom::bindings::root::DomRoot;
+use crate::dom::bindings::str::DOMString;
use crate::dom::fakexrdevice::get_origin;
use crate::dom::globalscope::GlobalScope;
use dom_struct::dom_struct;
@@ -128,4 +129,10 @@ impl FakeXRInputControllerMethods for FakeXRInputController {
};
let _ = self.send_message(MockInputMsg::SetTargetRayMode(t));
}
+
+ /// https://immersive-web.github.io/webxr-test-api/#dom-fakexrinputcontroller-setprofiles
+ fn SetProfiles(&self, profiles: Vec<DOMString>) {
+ let t = profiles.into_iter().map(String::from).collect();
+ let _ = self.send_message(MockInputMsg::SetProfiles(t));
+ }
}