Rename WrapperCache to Reflector.

I think the abstraction from the raw JSObject is still probably worthwhile for
now.
This commit is contained in:
Bobby Holley 2013-10-08 20:31:24 +02:00
parent 0a0599ad9b
commit 2cbe2d7ce9
24 changed files with 81 additions and 81 deletions

View file

@ -3,7 +3,7 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
use dom::bindings::codegen::EventTargetBinding;
use dom::bindings::utils::{Reflectable, WrapperCache, BindingObject, DerivedWrapper};
use dom::bindings::utils::{Reflectable, Reflector, BindingObject, DerivedWrapper};
use script_task::page_from_context;
use js::glue::RUST_OBJECT_TO_JSVAL;
@ -12,13 +12,13 @@ use js::jsapi::{JSObject, JSContext, JSVal};
use std::cast;
pub struct EventTarget {
wrapper: WrapperCache
wrapper: Reflector
}
impl EventTarget {
pub fn new() -> ~EventTarget {
~EventTarget {
wrapper: WrapperCache::new()
wrapper: Reflector::new()
}
}
@ -28,7 +28,7 @@ impl EventTarget {
}
impl Reflectable for EventTarget {
fn get_wrappercache(&mut self) -> &mut WrapperCache {
fn get_wrappercache(&mut self) -> &mut Reflector {
unsafe { cast::transmute(&self.wrapper) }
}