Derive Clone for ChildFrameTree instead of implementing it manually.

This commit is contained in:
Cameron Zwarich 2014-05-27 18:05:00 -07:00
parent 65d91e3950
commit c29d1b5ccc

View file

@ -58,6 +58,7 @@ struct FrameTree {
pub children: RefCell<Vec<ChildFrameTree>>,
}
#[deriving(Clone)]
struct ChildFrameTree {
frame_tree: Rc<FrameTree>,
/// Clipping rect representing the size and position, in page coordinates, of the visible
@ -65,15 +66,6 @@ struct ChildFrameTree {
pub rect: Option<Rect<f32>>,
}
impl Clone for ChildFrameTree {
fn clone(&self) -> ChildFrameTree {
ChildFrameTree {
frame_tree: self.frame_tree.clone(),
rect: self.rect.clone(),
}
}
}
pub struct SendableFrameTree {
pub pipeline: CompositionPipeline,
pub children: Vec<SendableChildFrameTree>,