diff options
Diffstat (limited to 'src/components/script/dom/clientrect.rs')
-rw-r--r-- | src/components/script/dom/clientrect.rs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/components/script/dom/clientrect.rs b/src/components/script/dom/clientrect.rs index 5c1de65851a..a0ad4a96dc1 100644 --- a/src/components/script/dom/clientrect.rs +++ b/src/components/script/dom/clientrect.rs @@ -10,7 +10,6 @@ use js::jsapi::{JSObject, JSContext, JSVal}; use js::glue::RUST_OBJECT_TO_JSVAL; use std::cast; -use std::f32; pub struct ClientRect { wrapper: WrapperCache, @@ -54,11 +53,11 @@ impl ClientRect { } pub fn Width(&self) -> f32 { - f32::abs(self.right - self.left) + (self.right - self.left).abs() } pub fn Height(&self) -> f32 { - f32::abs(self.bottom - self.top) + (self.bottom - self.top).abs() } } |