aboutsummaryrefslogtreecommitdiffstats
path: root/src/components/script/dom/htmliframeelement.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/components/script/dom/htmliframeelement.rs')
-rw-r--r--src/components/script/dom/htmliframeelement.rs14
1 files changed, 2 insertions, 12 deletions
diff --git a/src/components/script/dom/htmliframeelement.rs b/src/components/script/dom/htmliframeelement.rs
index 73172cb0ad8..7f39cfa58d8 100644
--- a/src/components/script/dom/htmliframeelement.rs
+++ b/src/components/script/dom/htmliframeelement.rs
@@ -9,15 +9,11 @@ use dom::element::HTMLIframeElementTypeId;
use dom::htmlelement::HTMLElement;
use dom::node::{AbstractNode, Node, ScriptView};
use dom::windowproxy::WindowProxy;
-use geom::size::Size2D;
-use geom::rect::Rect;
+use extra::url::Url;
+use geom::rect::Rect;
use servo_msg::constellation_msg::{ConstellationChan, FrameRectMsg, PipelineId, SubpageId};
-
use std::ascii::StrAsciiExt;
-use std::comm::ChanOne;
-use extra::url::Url;
-use std::util::replace;
enum SandboxAllowance {
AllowNothing = 0x00,
@@ -39,17 +35,11 @@ pub struct HTMLIFrameElement {
struct IFrameSize {
pipeline_id: PipelineId,
subpage_id: SubpageId,
- future_chan: Option<ChanOne<Size2D<uint>>>,
constellation_chan: ConstellationChan,
}
impl IFrameSize {
pub fn set_rect(&mut self, rect: Rect<f32>) {
- let future_chan = replace(&mut self.future_chan, None);
- do future_chan.map |future_chan| {
- let Size2D { width, height } = rect.size;
- future_chan.send(Size2D(width as uint, height as uint));
- };
self.constellation_chan.send(FrameRectMsg(self.pipeline_id, self.subpage_id, rect));
}
}