diff options
author | Bruno de Oliveira Abinader <bruno.d@partner.samsung.com> | 2013-11-29 10:47:30 -0400 |
---|---|---|
committer | Bruno de Oliveira Abinader <bruno.d@partner.samsung.com> | 2013-12-03 14:36:31 -0400 |
commit | ac45d70a4ace71380358fdec918e1c4438ae2e43 (patch) | |
tree | dbe38879889fd0e53886b87c26b9c69d66cb1a27 /src/components/main/layout/construct.rs | |
parent | a0c6075b4d766da8f0414405f9e1f76c8c90acc4 (diff) | |
download | servo-ac45d70a4ace71380358fdec918e1c4438ae2e43.tar.gz servo-ac45d70a4ace71380358fdec918e1c4438ae2e43.zip |
Remove 'FloatFlow'
Removes 'FloatFlow' in favor of FloatBlockFlow, which is cointained
inside BlockFlow in a 'has-a' relationship. This avoids a bunch of
duplicated code.
This patch is for:
https://github.com/mozilla/servo/issues/1281
Diffstat (limited to 'src/components/main/layout/construct.rs')
-rw-r--r-- | src/components/main/layout/construct.rs | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/components/main/layout/construct.rs b/src/components/main/layout/construct.rs index ea4f70af101..9341727e227 100644 --- a/src/components/main/layout/construct.rs +++ b/src/components/main/layout/construct.rs @@ -25,7 +25,6 @@ use layout::block::BlockFlow; use layout::box::{GenericRenderBox, ImageRenderBox, RenderBox, RenderBoxBase}; use layout::box::{UnscannedTextRenderBox}; use layout::context::LayoutContext; -use layout::float::FloatFlow; use layout::float_context::FloatType; use layout::flow::{Flow, FlowData, MutableFlowUtils}; use layout::inline::InlineFlow; @@ -360,13 +359,13 @@ impl<'self> FlowConstructor<'self> { flow } - /// Builds the flow for a node with `float: {left|right}`. This yields a `FloatFlow` with a - /// `BlockFlow` underneath it. + /// Builds the flow for a node with `float: {left|right}`. This yields a float `BlockFlow` with + /// a `BlockFlow` underneath it. fn build_flow_for_floated_block(&self, node: AbstractNode<LayoutView>, float_type: FloatType) -> ~Flow: { let base = FlowData::new(self.next_flow_id(), node); let box = self.build_box_for_node(node); - let mut flow = ~FloatFlow::from_box(base, float_type, box) as ~Flow:; + let mut flow = ~BlockFlow::float_from_box(base, float_type, box) as ~Flow:; self.build_children_of_block_flow(&mut flow, node); flow } |