aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/script/dom/clientrect.rs
diff options
context:
space:
mode:
authorManish Goregaokar <manishsmail@gmail.com>2014-08-08 23:46:29 +0530
committerManish Goregaokar <manishsmail@gmail.com>2014-08-09 01:04:12 +0530
commitdeed48a759e3fea529fbf779cdb38bf2e9eaeea8 (patch)
treeccea34457e42bd07993d0e5bd4903cf5600fb826 /src/components/script/dom/clientrect.rs
parent70e70fd1d9da87bc0a832734b137f2c326641c4e (diff)
downloadservo-deed48a759e3fea529fbf779cdb38bf2e9eaeea8.tar.gz
servo-deed48a759e3fea529fbf779cdb38bf2e9eaeea8.zip
Remove unused windows/globals
Diffstat (limited to 'src/components/script/dom/clientrect.rs')
-rw-r--r--src/components/script/dom/clientrect.rs9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/components/script/dom/clientrect.rs b/src/components/script/dom/clientrect.rs
index b80d6a8853b..3d1af37fb9f 100644
--- a/src/components/script/dom/clientrect.rs
+++ b/src/components/script/dom/clientrect.rs
@@ -5,7 +5,7 @@
use dom::bindings::codegen::Bindings::ClientRectBinding;
use dom::bindings::codegen::Bindings::ClientRectBinding::ClientRectMethods;
use dom::bindings::global::Window;
-use dom::bindings::js::{JS, JSRef, Temporary};
+use dom::bindings::js::{JSRef, Temporary};
use dom::bindings::utils::{Reflectable, Reflector, reflect_dom_object};
use dom::window::Window;
use servo_util::geometry::Au;
@@ -17,12 +17,10 @@ pub struct ClientRect {
bottom: f32,
left: f32,
right: f32,
- window: JS<Window>,
}
impl ClientRect {
- pub fn new_inherited(window: &JSRef<Window>,
- top: Au, bottom: Au,
+ pub fn new_inherited(top: Au, bottom: Au,
left: Au, right: Au) -> ClientRect {
ClientRect {
top: top.to_nearest_px() as f32,
@@ -30,14 +28,13 @@ impl ClientRect {
left: left.to_nearest_px() as f32,
right: right.to_nearest_px() as f32,
reflector_: Reflector::new(),
- window: JS::from_rooted(window),
}
}
pub fn new(window: &JSRef<Window>,
top: Au, bottom: Au,
left: Au, right: Au) -> Temporary<ClientRect> {
- let rect = ClientRect::new_inherited(window, top, bottom, left, right);
+ let rect = ClientRect::new_inherited(top, bottom, left, right);
reflect_dom_object(box rect, &Window(*window), ClientRectBinding::Wrap)
}
}