aboutsummaryrefslogtreecommitdiffstats
path: root/components/layout/construct.rs
diff options
context:
space:
mode:
authorThiago Pontes <github@thiago.me>2016-11-25 15:51:53 -0500
committerThiago Pontes <github@thiago.me>2016-11-30 11:43:14 -0500
commit206f4ea5b83dcd7cfdab20b9fb67387ce66f1880 (patch)
tree8b46c3bcee582449edd07f41367a0afc192bc42e /components/layout/construct.rs
parent7be32770b18854af11acdbf3ec229b2a5d763a61 (diff)
downloadservo-206f4ea5b83dcd7cfdab20b9fb67387ce66f1880.tar.gz
servo-206f4ea5b83dcd7cfdab20b9fb67387ce66f1880.zip
use Either type for UrlOrNone
fix test-tidy errors fix style unit test use the Parse trait instead of ParseWithContext fix stylo test and geckolib build move all specified url parse code to parse trait and remove refs to unused type
Diffstat (limited to 'components/layout/construct.rs')
-rw-r--r--components/layout/construct.rs7
1 files changed, 4 insertions, 3 deletions
diff --git a/components/layout/construct.rs b/components/layout/construct.rs
index 453c68dcae1..f3309b97b75 100644
--- a/components/layout/construct.rs
+++ b/components/layout/construct.rs
@@ -45,7 +45,7 @@ use std::marker::PhantomData;
use std::mem;
use std::sync::Arc;
use std::sync::atomic::Ordering;
-use style::computed_values::{caption_side, display, empty_cells, float, list_style_image, list_style_position};
+use style::computed_values::{caption_side, display, empty_cells, float, list_style_position};
use style::computed_values::content::ContentItem;
use style::computed_values::position;
use style::context::SharedStyleContext;
@@ -54,6 +54,7 @@ use style::properties::{self, ServoComputedValues};
use style::selector_parser::{PseudoElement, RestyleDamage};
use style::servo::restyle_damage::{BUBBLE_ISIZES, RECONSTRUCT_FLOW};
use style::stylist::Stylist;
+use style::values::Either;
use table::TableFlow;
use table_caption::TableCaptionFlow;
use table_cell::TableCellFlow;
@@ -1205,13 +1206,13 @@ impl<'a, ConcreteThreadSafeLayoutNode: ThreadSafeLayoutNode>
-> ConstructionResult {
let flotation = FloatKind::from_property(flotation);
let marker_fragments = match node.style(self.style_context()).get_list().list_style_image {
- list_style_image::T::Url(ref url_value) => {
+ Either::First(ref url_value) => {
let image_info = box ImageFragmentInfo::new(node,
url_value.url().map(|u| u.clone()),
&self.layout_context.shared);
vec![Fragment::new(node, SpecificFragmentInfo::Image(image_info), self.layout_context)]
}
- list_style_image::T::None => {
+ Either::Second(_none) => {
match ListStyleTypeContent::from_list_style_type(node.style(self.style_context())
.get_list()
.list_style_type) {