diff options
author | bors-servo <lbergstrom+bors@mozilla.com> | 2015-10-26 03:04:24 -0500 |
---|---|---|
committer | bors-servo <lbergstrom+bors@mozilla.com> | 2015-10-26 03:04:24 -0500 |
commit | 83b72e86693452ce9e950752743a712c29deb430 (patch) | |
tree | 13125e8b9e86cafaaa939409675f16c1624c6a8b /components/layout/construct.rs | |
parent | ec691904cc3f03e1cd6e630a7dac0fc0357d130d (diff) | |
parent | 28f9302b3808d75bba467912a11d188e0fff02f8 (diff) | |
download | servo-83b72e86693452ce9e950752743a712c29deb430.tar.gz servo-83b72e86693452ce9e950752743a712c29deb430.zip |
Auto merge of #8204 - Ms2ger:privatize-FlowConstructionUtils, r=nox
Privatize FlowConstructionUtils.
This makes it match the documentation.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/8204)
<!-- Reviewable:end -->
Diffstat (limited to 'components/layout/construct.rs')
-rw-r--r-- | components/layout/construct.rs | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/components/layout/construct.rs b/components/layout/construct.rs index ff1ff42a1d2..2ed8f286db0 100644 --- a/components/layout/construct.rs +++ b/components/layout/construct.rs @@ -1659,7 +1659,9 @@ impl<'ln> ObjectElement<'ln> for ThreadSafeLayoutNode<'ln> { } } -pub trait FlowConstructionUtils { +// This must not be public because only the layout constructor can call these +// methods. +trait FlowConstructionUtils { /// Adds a new flow as a child of this flow. Removes the flow from the given leaf set if /// it's present. fn add_new_child(&mut self, new_child: FlowRef); @@ -1675,8 +1677,6 @@ pub trait FlowConstructionUtils { impl FlowConstructionUtils for FlowRef { /// Adds a new flow as a child of this flow. Fails if this flow is marked as a leaf. - /// - /// This must not be public because only the layout constructor can do this. fn add_new_child(&mut self, mut new_child: FlowRef) { { let kid_base = flow::mut_base(flow_ref::deref_mut(&mut new_child)); @@ -1694,8 +1694,6 @@ impl FlowConstructionUtils for FlowRef { /// /// All flows must be finished at some point, or they will not have their intrinsic inline-sizes /// properly computed. (This is not, however, a memory safety problem.) - /// - /// This must not be public because only the layout constructor can do this. fn finish(&mut self) { if !opts::get().bubble_inline_sizes_separately { flow_ref::deref_mut(self).bubble_inline_sizes() |