aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/devtools.rs
diff options
context:
space:
mode:
Diffstat (limited to 'components/script/devtools.rs')
-rw-r--r--components/script/devtools.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/components/script/devtools.rs b/components/script/devtools.rs
index 0e892f32e6a..2356a4896f9 100644
--- a/components/script/devtools.rs
+++ b/components/script/devtools.rs
@@ -102,8 +102,8 @@ pub fn handle_get_layout(page: &Rc<Page>,
let node = find_node_by_unique_id(&*page, pipeline, node_id);
let elem = ElementCast::to_ref(node.r()).expect("should be getting layout of element");
let rect = elem.GetBoundingClientRect();
- let width = *rect.r().Width();
- let height = *rect.r().Height();
+ let width = rect.Width() as f32;
+ let height = rect.Height() as f32;
reply.send(ComputedNodeLayout { width: width, height: height }).unwrap();
}