diff options
author | Clark Gaebel <cgaebel@mozilla.com> | 2014-10-17 13:23:42 -0700 |
---|---|---|
committer | Clark Gaebel <cgaebel@mozilla.com> | 2014-10-20 11:13:31 -0700 |
commit | 81bd3cbd9d2e8da5bd7dd281e083e218d928c202 (patch) | |
tree | ca0c3c5290188beae7e813553c37418abbffa134 /components/layout/construct.rs | |
parent | 852378209badb936e8929c31501cb8cabeea6bc5 (diff) | |
download | servo-81bd3cbd9d2e8da5bd7dd281e083e218d928c202.tar.gz servo-81bd3cbd9d2e8da5bd7dd281e083e218d928c202.zip |
Fixes the table_percentage_width_a.html reftest with incremental reflow turned on.
Diffstat (limited to 'components/layout/construct.rs')
-rw-r--r-- | components/layout/construct.rs | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/components/layout/construct.rs b/components/layout/construct.rs index 5ebafbaba6b..c69d04d1d49 100644 --- a/components/layout/construct.rs +++ b/components/layout/construct.rs @@ -10,12 +10,6 @@ //! intermediate data that goes with a DOM node and hasn't found its "home" yet-maybe it's a box, //! maybe it's an absolute or fixed position thing that hasn't found its containing block yet. //! Construction items bubble up the tree from children to parents until they find their homes. -//! -//! TODO(pcwalton): There is no incremental reflow yet. This scheme requires that nodes either have -//! weak references to flows or that there be some mechanism to efficiently (O(1) time) "blow -//! apart" a flow tree and have the flows migrate "home" to their respective DOM nodes while we -//! perform flow tree construction. The precise mechanism for this will take some experimentation -//! to get right. #![deny(unsafe_block)] @@ -85,11 +79,11 @@ pub enum ConstructionResult { impl ConstructionResult { pub fn swap_out(&mut self) -> ConstructionResult { - if opts::get().incremental_layout { - return (*self).clone(); + if opts::get().nonincremental_layout { + return mem::replace(self, NoConstructionResult) } - mem::replace(self, NoConstructionResult) + (*self).clone() } pub fn debug_id(&self) -> uint { |