Rename Root<T> to DomRoot<T>

In a later PR, DomRoot<T> will become a type alias of Root<Dom<T>>,
where Root<T> will be able to handle all the things that need to be
rooted that have a stable traceable address that doesn't move for the
whole lifetime of the root. Stay tuned.
This commit is contained in:
Anthony Ramine 2017-09-26 01:53:40 +02:00
parent 577370746e
commit f87c2a8d76
291 changed files with 1774 additions and 1770 deletions

View file

@ -8,7 +8,7 @@ use dom::bindings::codegen::Bindings::VRFrameDataBinding::VRFrameDataMethods;
use dom::bindings::error::Fallible;
use dom::bindings::num::Finite;
use dom::bindings::reflector::{DomObject, Reflector, reflect_dom_object};
use dom::bindings::root::{Dom, Root};
use dom::bindings::root::{Dom, DomRoot};
use dom::globalscope::GlobalScope;
use dom::vrpose::VRPose;
use dom::window::Window;
@ -46,7 +46,7 @@ impl VRFrameData {
}
#[allow(unsafe_code)]
fn new(global: &GlobalScope) -> Root<VRFrameData> {
fn new(global: &GlobalScope) -> DomRoot<VRFrameData> {
let matrix = [1.0, 0.0, 0.0, 0.0,
0.0, 1.0, 0.0, 0.0,
0.0, 0.0, 1.0, 0.0,
@ -65,7 +65,7 @@ impl VRFrameData {
root
}
pub fn Constructor(window: &Window) -> Fallible<Root<VRFrameData>> {
pub fn Constructor(window: &Window) -> Fallible<DomRoot<VRFrameData>> {
Ok(VRFrameData::new(&window.global()))
}
}
@ -141,7 +141,7 @@ impl VRFrameDataMethods for VRFrameData {
}
// https://w3c.github.io/webvr/#dom-vrframedata-pose
fn Pose(&self) -> Root<VRPose> {
Root::from_ref(&*self.pose)
fn Pose(&self) -> DomRoot<VRPose> {
DomRoot::from_ref(&*self.pose)
}
}