mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Auto merge of #7265 - tafia:tidy-use, r=Ms2ger
Add alphabetical order check for use statements close #7112 <!-- Reviewable:start --> [<img src="https://reviewable.io/review_button.png" height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/7265) <!-- Reviewable:end -->
This commit is contained in:
commit
a5fbb2f2a6
270 changed files with 919 additions and 933 deletions
|
@ -31,14 +31,14 @@ use context::LayoutContext;
|
|||
use display_list_builder::{BlockFlowDisplayListBuilding, BorderPaintingMode};
|
||||
use display_list_builder::{FragmentDisplayListBuilding};
|
||||
use floats::{ClearType, FloatKind, Floats, PlacementInfo};
|
||||
use flow::{self, AbsolutePositionInfo, BaseFlow, ForceNonfloatedFlag, FlowClass, Flow};
|
||||
use flow::{ImmutableFlowUtils, MutableFlowUtils, OpaqueFlow, PreorderFlowTraversal};
|
||||
use flow::{PostorderFlowTraversal, mut_base};
|
||||
use flow::{BLOCK_POSITION_IS_STATIC, HAS_LEFT_FLOATED_DESCENDANTS, HAS_RIGHT_FLOATED_DESCENDANTS};
|
||||
use flow::{IMPACTED_BY_LEFT_FLOATS, IMPACTED_BY_RIGHT_FLOATS, INLINE_POSITION_IS_STATIC};
|
||||
use flow::{LAYERS_NEEDED_FOR_DESCENDANTS, NEEDS_LAYER};
|
||||
use flow::{IS_ABSOLUTELY_POSITIONED};
|
||||
use flow::{CLEARS_LEFT, CLEARS_RIGHT};
|
||||
use flow::{IMPACTED_BY_LEFT_FLOATS, IMPACTED_BY_RIGHT_FLOATS, INLINE_POSITION_IS_STATIC};
|
||||
use flow::{IS_ABSOLUTELY_POSITIONED};
|
||||
use flow::{ImmutableFlowUtils, MutableFlowUtils, OpaqueFlow, PreorderFlowTraversal};
|
||||
use flow::{LAYERS_NEEDED_FOR_DESCENDANTS, NEEDS_LAYER};
|
||||
use flow::{PostorderFlowTraversal, mut_base};
|
||||
use flow::{self, AbsolutePositionInfo, BaseFlow, ForceNonfloatedFlag, FlowClass, Flow};
|
||||
use fragment::{CoordinateSystem, Fragment, FragmentBorderBoxIterator, SpecificFragmentInfo};
|
||||
use incremental::{REFLOW, REFLOW_OUT_OF_FLOW};
|
||||
use layout_debug;
|
||||
|
@ -56,8 +56,8 @@ use std::sync::Arc;
|
|||
use style::computed_values::{border_collapse, box_sizing, display, float, overflow_x, overflow_y};
|
||||
use style::computed_values::{transform, transform_style, position, text_align};
|
||||
use style::properties::ComputedValues;
|
||||
use style::values::computed::{LengthOrPercentage, LengthOrPercentageOrAuto};
|
||||
use style::values::computed::{LengthOrNone, LengthOrPercentageOrNone};
|
||||
use style::values::computed::{LengthOrPercentage, LengthOrPercentageOrAuto};
|
||||
use util::geometry::{Au, MAX_AU, MAX_RECT};
|
||||
use util::logical_geometry::{LogicalPoint, LogicalRect, LogicalSize, WritingMode};
|
||||
use util::opts;
|
||||
|
|
|
@ -17,11 +17,11 @@ use block::BlockFlow;
|
|||
use context::LayoutContext;
|
||||
use data::{HAS_NEWLY_CONSTRUCTED_FLOW, LayoutDataWrapper};
|
||||
use floats::FloatKind;
|
||||
use flow::{self, AbsoluteDescendants, Flow, ImmutableFlowUtils, IS_ABSOLUTELY_POSITIONED};
|
||||
use flow::{MutableFlowUtils, MutableOwnedFlowUtils};
|
||||
use flow::{self, AbsoluteDescendants, Flow, ImmutableFlowUtils, IS_ABSOLUTELY_POSITIONED};
|
||||
use flow_ref::FlowRef;
|
||||
use fragment::{Fragment, GeneratedContentInfo, IframeFragmentInfo};
|
||||
use fragment::{CanvasFragmentInfo, ImageFragmentInfo, InlineAbsoluteFragmentInfo};
|
||||
use fragment::{Fragment, GeneratedContentInfo, IframeFragmentInfo};
|
||||
use fragment::{InlineAbsoluteHypotheticalFragmentInfo, TableColumnFragmentInfo};
|
||||
use fragment::{InlineBlockFragmentInfo, SpecificFragmentInfo, UnscannedTextFragmentInfo};
|
||||
use fragment::{WhitespaceStrippingResult};
|
||||
|
@ -1729,8 +1729,8 @@ pub fn strip_ignorable_whitespace_from_end(this: &mut LinkedList<Fragment>) {
|
|||
/// If the 'unicode-bidi' property has a value other than 'normal', return the bidi control codes
|
||||
/// to inject before and after the text content of the element.
|
||||
fn bidi_control_chars(style: &Arc<ComputedValues>) -> Option<(&'static str, &'static str)> {
|
||||
use style::computed_values::unicode_bidi::T::*;
|
||||
use style::computed_values::direction::T::*;
|
||||
use style::computed_values::unicode_bidi::T::*;
|
||||
|
||||
let unicode_bidi = style.get_text().unicode_bidi;
|
||||
let direction = style.get_inheritedbox().direction;
|
||||
|
|
|
@ -9,13 +9,13 @@
|
|||
use css::matching::{ApplicableDeclarationsCache, StyleSharingCandidateCache};
|
||||
|
||||
use canvas_traits::CanvasMsg;
|
||||
use msg::compositor_msg::LayerId;
|
||||
use fnv::FnvHasher;
|
||||
use euclid::{Rect, Size2D};
|
||||
use fnv::FnvHasher;
|
||||
use gfx::display_list::OpaqueNode;
|
||||
use gfx::font_cache_task::FontCacheTask;
|
||||
use gfx::font_context::FontContext;
|
||||
use ipc_channel::ipc::{self, IpcSender};
|
||||
use msg::compositor_msg::LayerId;
|
||||
use msg::constellation_msg::ConstellationChan;
|
||||
use net_traits::image::base::Image;
|
||||
use net_traits::image_cache_task::{ImageCacheChan, ImageCacheTask, ImageResponse, ImageState};
|
||||
|
|
|
@ -16,11 +16,11 @@ use wrapper::{LayoutElement, LayoutNode};
|
|||
use script::dom::characterdata::CharacterDataTypeId;
|
||||
use script::dom::node::NodeTypeId;
|
||||
use script::layout_interface::Animation;
|
||||
use selectors::{Element};
|
||||
use selectors::bloom::BloomFilter;
|
||||
use selectors::matching::{CommonStyleAffectingAttributeMode, CommonStyleAffectingAttributes};
|
||||
use selectors::matching::{common_style_affecting_attributes, rare_style_affecting_attributes};
|
||||
use selectors::parser::PseudoElement;
|
||||
use selectors::{Element};
|
||||
use std::borrow::ToOwned;
|
||||
use std::hash::{Hash, Hasher};
|
||||
use std::mem;
|
||||
|
|
|
@ -22,9 +22,8 @@ use model::{self, MaybeAuto, ToGfxMatrix};
|
|||
use table_cell::CollapsedBordersForCell;
|
||||
|
||||
use canvas_traits::{CanvasMsg, FromLayoutMsg};
|
||||
use euclid::{Point2D, Point3D, Rect, Size2D, SideOffsets2D};
|
||||
use euclid::Matrix4;
|
||||
use gfx_traits::color;
|
||||
use euclid::{Point2D, Point3D, Rect, Size2D, SideOffsets2D};
|
||||
use gfx::display_list::{BLUR_INFLATION_FACTOR, BaseDisplayItem, BorderDisplayItem};
|
||||
use gfx::display_list::{BorderRadii, BoxShadowClipMode, BoxShadowDisplayItem, ClippingRegion};
|
||||
use gfx::display_list::{DisplayItem, DisplayList, DisplayItemMetadata};
|
||||
|
@ -33,17 +32,18 @@ use gfx::display_list::{GradientStop, ImageDisplayItem, LineDisplayItem};
|
|||
use gfx::display_list::{OpaqueNode, SolidColorDisplayItem};
|
||||
use gfx::display_list::{StackingContext, TextDisplayItem, TextOrientation};
|
||||
use gfx::paint_task::{PaintLayer, THREAD_TINT_COLORS};
|
||||
use gfx_traits::color;
|
||||
use ipc_channel::ipc::{self, IpcSharedMemory};
|
||||
use msg::compositor_msg::{ScrollPolicy, LayerId};
|
||||
use msg::constellation_msg::ConstellationChan;
|
||||
use msg::constellation_msg::Msg as ConstellationMsg;
|
||||
use net_traits::image_cache_task::UsePlaceholder;
|
||||
use net_traits::image::base::{Image, PixelFormat};
|
||||
use net_traits::image_cache_task::UsePlaceholder;
|
||||
use std::cmp;
|
||||
use std::default::Default;
|
||||
use std::f32;
|
||||
use std::sync::Arc;
|
||||
use std::sync::mpsc::channel;
|
||||
use std::f32;
|
||||
use style::computed_values::filter::Filter;
|
||||
use style::computed_values::{background_attachment, background_clip, background_origin};
|
||||
use style::computed_values::{background_repeat, background_size};
|
||||
|
|
|
@ -2,14 +2,14 @@
|
|||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||
|
||||
use std::cmp::{max, min};
|
||||
use std::fmt;
|
||||
use std::i32;
|
||||
use style::computed_values::float;
|
||||
use util::geometry::Au;
|
||||
use util::logical_geometry::WritingMode;
|
||||
use util::logical_geometry::{LogicalRect, LogicalSize};
|
||||
use util::persistent_list::PersistentList;
|
||||
use std::cmp::{max, min};
|
||||
use std::i32;
|
||||
use std::fmt;
|
||||
use style::computed_values::float;
|
||||
|
||||
/// The kind of float: left or right.
|
||||
#[derive(Clone, RustcEncodable, Debug, Copy)]
|
||||
|
|
|
@ -35,6 +35,7 @@ use fragment::{Fragment, FragmentBorderBoxIterator, SpecificFragmentInfo};
|
|||
use incremental::{self, RECONSTRUCT_FLOW, REFLOW, REFLOW_OUT_OF_FLOW, RestyleDamage};
|
||||
use inline::InlineFlow;
|
||||
use model::{CollapsibleMargins, IntrinsicISizes, MarginCollapseInfo};
|
||||
use multicol::MulticolFlow;
|
||||
use parallel::FlowParallelInfo;
|
||||
use table::{ColumnComputedInlineSize, ColumnIntrinsicInlineSize, TableFlow};
|
||||
use table_caption::TableCaptionFlow;
|
||||
|
@ -43,7 +44,6 @@ use table_colgroup::TableColGroupFlow;
|
|||
use table_row::TableRowFlow;
|
||||
use table_rowgroup::TableRowGroupFlow;
|
||||
use table_wrapper::TableWrapperFlow;
|
||||
use multicol::MulticolFlow;
|
||||
use wrapper::{PseudoElementType, ThreadSafeLayoutNode};
|
||||
|
||||
use euclid::{Point2D, Rect, Size2D};
|
||||
|
|
|
@ -10,8 +10,8 @@
|
|||
|
||||
#![allow(unsafe_code)]
|
||||
|
||||
use flow::{Flow, BaseFlow};
|
||||
use flow;
|
||||
use flow::{Flow, BaseFlow};
|
||||
|
||||
use std::mem;
|
||||
use std::ops::{Deref, DerefMut};
|
||||
|
|
|
@ -20,10 +20,10 @@ use text;
|
|||
use wrapper::{PseudoElementType, ThreadSafeLayoutNode};
|
||||
|
||||
use euclid::{Point2D, Rect, Size2D};
|
||||
use gfx;
|
||||
use gfx::display_list::{BLUR_INFLATION_FACTOR, OpaqueNode};
|
||||
use gfx::text::glyph::CharIndex;
|
||||
use gfx::text::text_run::{TextRun, TextRunSlice};
|
||||
use gfx;
|
||||
use ipc_channel::ipc::IpcSender;
|
||||
use msg::constellation_msg::{ConstellationChan, Msg, PipelineId, SubpageId};
|
||||
use net_traits::image::base::Image;
|
||||
|
@ -44,11 +44,11 @@ use style::values::computed::{LengthOrPercentage, LengthOrPercentageOrAuto};
|
|||
use style::values::computed::{LengthOrPercentageOrNone};
|
||||
use text::TextRunScanner;
|
||||
use url::Url;
|
||||
use util;
|
||||
use util::geometry::{Au, ZERO_POINT};
|
||||
use util::logical_geometry::{LogicalRect, LogicalSize, LogicalMargin, WritingMode};
|
||||
use util::range::*;
|
||||
use util::str::{is_whitespace, slice_chars};
|
||||
use util;
|
||||
|
||||
/// Fragments (`struct Fragment`) are the leaves of the layout tree. They cannot position
|
||||
/// themselves. In general, fragments do not have a simple correspondence with CSS fragments in the
|
||||
|
|
|
@ -9,8 +9,8 @@
|
|||
//! as possible.
|
||||
|
||||
use context::LayoutContext;
|
||||
use flow::{self, AFFECTS_COUNTERS, Flow, HAS_COUNTER_AFFECTING_CHILDREN, ImmutableFlowUtils};
|
||||
use flow::{InorderFlowTraversal};
|
||||
use flow::{self, AFFECTS_COUNTERS, Flow, HAS_COUNTER_AFFECTING_CHILDREN, ImmutableFlowUtils};
|
||||
use fragment::{Fragment, GeneratedContentInfo, SpecificFragmentInfo, UnscannedTextFragmentInfo};
|
||||
use incremental::{self, RESOLVE_GENERATED_CONTENT};
|
||||
use smallvec::SmallVec;
|
||||
|
|
|
@ -8,8 +8,8 @@ use block::{AbsoluteAssignBSizesTraversal, AbsoluteStoreOverflowTraversal};
|
|||
use context::LayoutContext;
|
||||
use display_list_builder::{FragmentDisplayListBuilding, InlineFlowDisplayListBuilding};
|
||||
use floats::{FloatKind, Floats, PlacementInfo};
|
||||
use flow::{self, BaseFlow, FlowClass, Flow, ForceNonfloatedFlag, IS_ABSOLUTELY_POSITIONED};
|
||||
use flow::{MutableFlowUtils, OpaqueFlow};
|
||||
use flow::{self, BaseFlow, FlowClass, Flow, ForceNonfloatedFlag, IS_ABSOLUTELY_POSITIONED};
|
||||
use fragment::{CoordinateSystem, Fragment, FragmentBorderBoxIterator, SpecificFragmentInfo};
|
||||
use incremental::{REFLOW, REFLOW_OUT_OF_FLOW, RESOLVE_GENERATED_CONTENT};
|
||||
use layout_debug;
|
||||
|
@ -24,17 +24,17 @@ use gfx::font_context::FontContext;
|
|||
use std::cmp::max;
|
||||
use std::collections::VecDeque;
|
||||
use std::fmt;
|
||||
use std::isize;
|
||||
use std::mem;
|
||||
use std::sync::Arc;
|
||||
use std::isize;
|
||||
use style::computed_values::{display, overflow_x, position, text_align, text_justify};
|
||||
use style::computed_values::{text_overflow, vertical_align, white_space};
|
||||
use style::properties::ComputedValues;
|
||||
use unicode_bidi;
|
||||
use util;
|
||||
use util::geometry::{Au, MAX_AU, ZERO_RECT};
|
||||
use util::logical_geometry::{LogicalRect, LogicalSize, WritingMode};
|
||||
use util::range::{Range, RangeIndex};
|
||||
use util;
|
||||
|
||||
// From gfxFontConstants.h in Firefox
|
||||
static FONT_SUBSCRIPT_OFFSET_RATIO: f32 = 0.20;
|
||||
|
|
|
@ -7,14 +7,14 @@
|
|||
|
||||
#![macro_use]
|
||||
|
||||
use flow_ref::FlowRef;
|
||||
use flow;
|
||||
use flow_ref::FlowRef;
|
||||
use rustc_serialize::json;
|
||||
|
||||
use std::borrow::ToOwned;
|
||||
use std::cell::RefCell;
|
||||
use std::io::Write;
|
||||
use std::fs::File;
|
||||
use std::io::Write;
|
||||
use std::sync::atomic::{AtomicUsize, Ordering, ATOMIC_USIZE_INIT};
|
||||
|
||||
thread_local!(static STATE_KEY: RefCell<Option<State>> = RefCell::new(None));
|
||||
|
|
|
@ -29,17 +29,17 @@ use azure::azure::AzColor;
|
|||
use canvas_traits::CanvasMsg;
|
||||
use encoding::EncodingRef;
|
||||
use encoding::all::UTF_8;
|
||||
use fnv::FnvHasher;
|
||||
use euclid::Matrix4;
|
||||
use euclid::point::Point2D;
|
||||
use euclid::rect::Rect;
|
||||
use euclid::scale_factor::ScaleFactor;
|
||||
use euclid::size::Size2D;
|
||||
use gfx_traits::color;
|
||||
use gfx::display_list::{ClippingRegion, DisplayList, OpaqueNode};
|
||||
use fnv::FnvHasher;
|
||||
use gfx::display_list::StackingContext;
|
||||
use gfx::display_list::{ClippingRegion, DisplayList, OpaqueNode};
|
||||
use gfx::font_cache_task::FontCacheTask;
|
||||
use gfx::paint_task::{LayoutToPaintMsg, PaintLayer};
|
||||
use gfx_traits::color;
|
||||
use ipc_channel::ipc::{self, IpcReceiver, IpcSender};
|
||||
use ipc_channel::router::ROUTER;
|
||||
use layout_traits::LayoutTaskFactory;
|
||||
|
@ -47,19 +47,19 @@ use log;
|
|||
use msg::compositor_msg::{Epoch, ScrollPolicy, LayerId};
|
||||
use msg::constellation_msg::Msg as ConstellationMsg;
|
||||
use msg::constellation_msg::{ConstellationChan, Failure, PipelineExitType, PipelineId};
|
||||
use profile_traits::mem::{self, Report, ReportKind, ReportsChan};
|
||||
use profile_traits::time::{self, ProfilerMetadata, profile};
|
||||
use profile_traits::time::{TimerMetadataFrameType, TimerMetadataReflowType};
|
||||
use net_traits::{load_bytes_iter, PendingAsyncLoad};
|
||||
use net_traits::image_cache_task::{ImageCacheTask, ImageCacheResult, ImageCacheChan};
|
||||
use net_traits::{load_bytes_iter, PendingAsyncLoad};
|
||||
use profile_traits::mem::{self, Report, ReportKind, ReportsChan};
|
||||
use profile_traits::time::{TimerMetadataFrameType, TimerMetadataReflowType};
|
||||
use profile_traits::time::{self, ProfilerMetadata, profile};
|
||||
use script::dom::bindings::js::LayoutJS;
|
||||
use script::dom::node::{LayoutData, Node};
|
||||
use script::layout_interface::Animation;
|
||||
use script::layout_interface::{LayoutChan, LayoutRPC, OffsetParentResponse};
|
||||
use script::layout_interface::{NewLayoutTaskInfo, Msg, Reflow, ReflowGoal, ReflowQueryType};
|
||||
use script::layout_interface::{ScriptLayoutChan, ScriptReflow, TrustedNodeAddress};
|
||||
use script_traits::{ConstellationControlMsg, LayoutControlMsg, OpaqueScriptLayoutChannel};
|
||||
use script_traits::StylesheetLoadResponder;
|
||||
use script_traits::{ConstellationControlMsg, LayoutControlMsg, OpaqueScriptLayoutChannel};
|
||||
use selectors::parser::PseudoElement;
|
||||
use serde_json;
|
||||
use std::borrow::ToOwned;
|
||||
|
@ -73,8 +73,8 @@ use std::sync::{Arc, Mutex, MutexGuard};
|
|||
use string_cache::Atom;
|
||||
use style::computed_values::{self, filter, mix_blend_mode};
|
||||
use style::media_queries::{MediaType, MediaQueryList, Device};
|
||||
use style::properties::style_structs;
|
||||
use style::properties::longhands::{display, position};
|
||||
use style::properties::style_structs;
|
||||
use style::selector_matching::Stylist;
|
||||
use style::stylesheets::{Origin, Stylesheet, CSSRuleIteratorExt};
|
||||
use url::Url;
|
||||
|
|
|
@ -20,12 +20,12 @@ use text;
|
|||
|
||||
use euclid::{Point2D, Rect};
|
||||
use gfx::display_list::DisplayList;
|
||||
use std::sync::Arc;
|
||||
use style::computed_values::{list_style_type, position};
|
||||
use style::properties::ComputedValues;
|
||||
use util::geometry::Au;
|
||||
use util::logical_geometry::LogicalSize;
|
||||
use util::opts;
|
||||
use style::properties::ComputedValues;
|
||||
use style::computed_values::{list_style_type, position};
|
||||
use std::sync::Arc;
|
||||
|
||||
/// A block with the CSS `display` property equal to `list-item`.
|
||||
#[derive(Debug)]
|
||||
|
|
|
@ -13,11 +13,11 @@ use flow::{FlowClass, Flow, OpaqueFlow};
|
|||
use fragment::{Fragment, FragmentBorderBoxIterator};
|
||||
|
||||
use euclid::{Point2D, Rect};
|
||||
use std::fmt;
|
||||
use std::sync::Arc;
|
||||
use style::properties::ComputedValues;
|
||||
use util::geometry::Au;
|
||||
use util::logical_geometry::LogicalSize;
|
||||
use std::fmt;
|
||||
use style::properties::ComputedValues;
|
||||
use std::sync::Arc;
|
||||
|
||||
pub struct MulticolFlow {
|
||||
pub block_flow: BlockFlow,
|
||||
|
|
|
@ -9,16 +9,16 @@
|
|||
#![allow(unsafe_code)]
|
||||
|
||||
use context::{LayoutContext, SharedLayoutContext};
|
||||
use flow::{Flow, MutableFlowUtils, PreorderFlowTraversal, PostorderFlowTraversal};
|
||||
use flow;
|
||||
use flow::{Flow, MutableFlowUtils, PreorderFlowTraversal, PostorderFlowTraversal};
|
||||
use flow_ref::FlowRef;
|
||||
use traversal::{PreorderDomTraversal, PostorderDomTraversal};
|
||||
use traversal::PostorderNodeMutTraversal;
|
||||
use traversal::{BubbleISizes, AssignISizes, AssignBSizesAndStoreOverflow};
|
||||
use traversal::{ComputeAbsolutePositions, BuildDisplayList};
|
||||
use traversal::{PreorderDomTraversal, PostorderDomTraversal};
|
||||
use traversal::{RecalcStyleForNode, ConstructFlows};
|
||||
use wrapper::{layout_node_to_unsafe_layout_node, layout_node_from_unsafe_layout_node, LayoutNode};
|
||||
use wrapper::UnsafeLayoutNode;
|
||||
use wrapper::{layout_node_to_unsafe_layout_node, layout_node_from_unsafe_layout_node, LayoutNode};
|
||||
|
||||
use profile_traits::time::{self, ProfilerMetadata, profile};
|
||||
use std::mem;
|
||||
|
|
|
@ -11,8 +11,8 @@ use euclid::rect::Rect;
|
|||
use flow_ref::FlowRef;
|
||||
use fragment::{Fragment, FragmentBorderBoxIterator};
|
||||
use gfx::display_list::{DisplayItemMetadata, OpaqueNode};
|
||||
use msg::constellation_msg::Msg as ConstellationMsg;
|
||||
use msg::constellation_msg::ConstellationChan;
|
||||
use msg::constellation_msg::Msg as ConstellationMsg;
|
||||
use opaque_node::OpaqueNodeMethods;
|
||||
use script::layout_interface::{ContentBoxResponse, ContentBoxesResponse, NodeGeometryResponse};
|
||||
use script::layout_interface::{HitTestResponse, LayoutRPC, MouseOverResponse, OffsetParentResponse};
|
||||
|
@ -20,8 +20,8 @@ use script::layout_interface::{ResolvedStyleResponse, ScriptLayoutChan, TrustedN
|
|||
use sequential;
|
||||
|
||||
use std::sync::{Arc, Mutex};
|
||||
use util::geometry::Au;
|
||||
use util::cursor::Cursor;
|
||||
use util::geometry::Au;
|
||||
use util::logical_geometry::WritingMode;
|
||||
|
||||
pub struct LayoutRPCImpl(pub Arc<Mutex<LayoutTaskData>>);
|
||||
|
|
|
@ -5,16 +5,16 @@
|
|||
//! Implements sequential traversals over the DOM and flow trees.
|
||||
|
||||
use context::{LayoutContext, SharedLayoutContext};
|
||||
use flow::{self, Flow, ImmutableFlowUtils, InorderFlowTraversal, MutableFlowUtils};
|
||||
use flow::{PostorderFlowTraversal, PreorderFlowTraversal};
|
||||
use flow::{self, Flow, ImmutableFlowUtils, InorderFlowTraversal, MutableFlowUtils};
|
||||
use flow_ref::FlowRef;
|
||||
use fragment::FragmentBorderBoxIterator;
|
||||
use generated_content::ResolveGeneratedContent;
|
||||
use traversal::{PreorderDomTraversal, PostorderDomTraversal};
|
||||
use traversal::PostorderNodeMutTraversal;
|
||||
use traversal::{BubbleISizes, RecalcStyleForNode, ConstructFlows};
|
||||
use traversal::{AssignBSizesAndStoreOverflow, AssignISizes};
|
||||
use traversal::{BubbleISizes, RecalcStyleForNode, ConstructFlows};
|
||||
use traversal::{ComputeAbsolutePositions, BuildDisplayList};
|
||||
use traversal::{PreorderDomTraversal, PostorderDomTraversal};
|
||||
use wrapper::LayoutNode;
|
||||
|
||||
use euclid::point::Point2D;
|
||||
|
|
|
@ -6,18 +6,18 @@
|
|||
|
||||
#![deny(unsafe_code)]
|
||||
|
||||
use block::{self, BlockFlow, CandidateBSizeIterator, ISizeAndMarginsComputer};
|
||||
use block::{ISizeConstraintInput, ISizeConstraintSolution};
|
||||
use block::{self, BlockFlow, CandidateBSizeIterator, ISizeAndMarginsComputer};
|
||||
use context::LayoutContext;
|
||||
use display_list_builder::{BlockFlowDisplayListBuilding, BorderPaintingMode};
|
||||
use flow::{self, Flow, FlowClass, IMPACTED_BY_LEFT_FLOATS, IMPACTED_BY_RIGHT_FLOATS};
|
||||
use flow::{ImmutableFlowUtils, OpaqueFlow};
|
||||
use flow::{self, Flow, FlowClass, IMPACTED_BY_LEFT_FLOATS, IMPACTED_BY_RIGHT_FLOATS};
|
||||
use fragment::{Fragment, FragmentBorderBoxIterator};
|
||||
use incremental::{REFLOW, REFLOW_OUT_OF_FLOW};
|
||||
use layout_debug;
|
||||
use model::{IntrinsicISizes, IntrinsicISizesContribution, MaybeAuto};
|
||||
use table_row::{self, CellIntrinsicInlineSize, CollapsedBorder, CollapsedBorderProvenance};
|
||||
use table_row::{TableRowFlow};
|
||||
use table_row::{self, CellIntrinsicInlineSize, CollapsedBorder, CollapsedBorderProvenance};
|
||||
use table_wrapper::TableLayout;
|
||||
|
||||
use euclid::{Point2D, Rect};
|
||||
|
|
|
@ -12,11 +12,11 @@ use flow::{FlowClass, Flow, OpaqueFlow};
|
|||
use fragment::{Fragment, FragmentBorderBoxIterator};
|
||||
|
||||
use euclid::{Point2D, Rect};
|
||||
use std::fmt;
|
||||
use std::sync::Arc;
|
||||
use style::properties::ComputedValues;
|
||||
use util::geometry::Au;
|
||||
use util::logical_geometry::LogicalSize;
|
||||
use std::fmt;
|
||||
use style::properties::ComputedValues;
|
||||
use std::sync::Arc;
|
||||
|
||||
/// A table formatting context.
|
||||
pub struct TableCaptionFlow {
|
||||
|
|
|
@ -11,8 +11,8 @@ use context::LayoutContext;
|
|||
use display_list_builder::{BlockFlowDisplayListBuilding, BorderPaintingMode};
|
||||
use flow::{Flow, FlowClass, OpaqueFlow};
|
||||
use fragment::{Fragment, FragmentBorderBoxIterator};
|
||||
use model::MaybeAuto;
|
||||
use layout_debug;
|
||||
use model::MaybeAuto;
|
||||
use table::InternalTable;
|
||||
use table_row::{CollapsedBorder, CollapsedBorderProvenance};
|
||||
use wrapper::ThreadSafeLayoutNode;
|
||||
|
|
|
@ -12,12 +12,12 @@ use fragment::{Fragment, FragmentBorderBoxIterator, SpecificFragmentInfo};
|
|||
use layout_debug;
|
||||
|
||||
use euclid::{Point2D, Rect};
|
||||
use util::geometry::{Au, ZERO_RECT};
|
||||
use std::cmp::max;
|
||||
use std::fmt;
|
||||
use style::values::computed::LengthOrPercentageOrAuto;
|
||||
use style::properties::ComputedValues;
|
||||
use std::sync::Arc;
|
||||
use style::properties::ComputedValues;
|
||||
use style::values::computed::LengthOrPercentageOrAuto;
|
||||
use util::geometry::{Au, ZERO_RECT};
|
||||
use util::logical_geometry::LogicalSize;
|
||||
|
||||
/// A table formatting context.
|
||||
|
|
|
@ -13,9 +13,9 @@ use flow::{self, FlowClass, Flow, ImmutableFlowUtils, OpaqueFlow};
|
|||
use flow_list::MutFlowListIterator;
|
||||
use fragment::{Fragment, FragmentBorderBoxIterator};
|
||||
use layout_debug;
|
||||
use model::MaybeAuto;
|
||||
use table::{ColumnComputedInlineSize, ColumnIntrinsicInlineSize, InternalTable, VecExt};
|
||||
use table_cell::{CollapsedBordersForCell, TableCellFlow};
|
||||
use model::MaybeAuto;
|
||||
|
||||
use cssparser::{Color, RGBA};
|
||||
use euclid::{Point2D, Rect};
|
||||
|
|
|
@ -25,8 +25,6 @@ use table::{ColumnComputedInlineSize, ColumnIntrinsicInlineSize};
|
|||
use table_row;
|
||||
|
||||
use euclid::{Point2D, Rect};
|
||||
use util::geometry::Au;
|
||||
use util::logical_geometry::LogicalSize;
|
||||
use std::cmp::{max, min};
|
||||
use std::fmt;
|
||||
use std::ops::Add;
|
||||
|
@ -35,6 +33,8 @@ use style::computed_values::{border_collapse, table_layout};
|
|||
use style::properties::ComputedValues;
|
||||
use style::values::CSSFloat;
|
||||
use style::values::computed::LengthOrPercentageOrAuto;
|
||||
use util::geometry::Au;
|
||||
use util::logical_geometry::LogicalSize;
|
||||
|
||||
#[derive(Copy, Clone, RustcEncodable, Debug)]
|
||||
pub enum TableLayout {
|
||||
|
|
|
@ -4,15 +4,15 @@
|
|||
|
||||
//! Traversals over the DOM and flow trees, running the layout computations.
|
||||
|
||||
use css::matching::{ApplicableDeclarations, MatchMethods, StyleSharingResult};
|
||||
use construct::FlowConstructor;
|
||||
use context::LayoutContext;
|
||||
use flow::{self, Flow};
|
||||
use css::matching::{ApplicableDeclarations, MatchMethods, StyleSharingResult};
|
||||
use flow::{PreorderFlowTraversal, PostorderFlowTraversal};
|
||||
use flow::{self, Flow};
|
||||
use incremental::{self, BUBBLE_ISIZES, REFLOW, REFLOW_OUT_OF_FLOW, RestyleDamage};
|
||||
use script::layout_interface::ReflowGoal;
|
||||
use wrapper::{layout_node_to_unsafe_layout_node, LayoutNode};
|
||||
use wrapper::{ThreadSafeLayoutNode, UnsafeLayoutNode};
|
||||
use wrapper::{layout_node_to_unsafe_layout_node, LayoutNode};
|
||||
|
||||
use selectors::bloom::BloomFilter;
|
||||
use util::opts;
|
||||
|
|
|
@ -32,12 +32,13 @@
|
|||
|
||||
use canvas_traits::CanvasMsg;
|
||||
use context::SharedLayoutContext;
|
||||
use incremental::RestyleDamage;
|
||||
use data::{LayoutDataFlags, LayoutDataWrapper, PrivateLayoutData};
|
||||
use incremental::RestyleDamage;
|
||||
use opaque_node::OpaqueNodeMethods;
|
||||
|
||||
use gfx::display_list::OpaqueNode;
|
||||
use ipc_channel::ipc::IpcSender;
|
||||
use msg::constellation_msg::{PipelineId, SubpageId};
|
||||
use script::dom::attr::AttrValue;
|
||||
use script::dom::bindings::codegen::InheritTypes::{CharacterDataCast, ElementCast};
|
||||
use script::dom::bindings::codegen::InheritTypes::{HTMLIFrameElementCast, HTMLCanvasElementCast};
|
||||
|
@ -47,18 +48,18 @@ use script::dom::bindings::js::LayoutJS;
|
|||
use script::dom::characterdata::{CharacterDataTypeId, LayoutCharacterDataHelpers};
|
||||
use script::dom::element::{Element, ElementTypeId};
|
||||
use script::dom::element::{LayoutElementHelpers, RawLayoutElementHelpers};
|
||||
use script::dom::htmlelement::HTMLElementTypeId;
|
||||
use script::dom::htmlcanvaselement::LayoutHTMLCanvasElementHelpers;
|
||||
use script::dom::htmlelement::HTMLElementTypeId;
|
||||
use script::dom::htmlimageelement::LayoutHTMLImageElementHelpers;
|
||||
use script::dom::htmlinputelement::{HTMLInputElement, LayoutHTMLInputElementHelpers};
|
||||
use script::dom::htmltextareaelement::LayoutHTMLTextAreaElementHelpers;
|
||||
use script::dom::node::{Node, NodeTypeId};
|
||||
use script::dom::node::{LayoutNodeHelpers, SharedLayoutData};
|
||||
use script::dom::node::{HAS_CHANGED, IS_DIRTY, HAS_DIRTY_SIBLINGS, HAS_DIRTY_DESCENDANTS};
|
||||
use script::dom::node::{LayoutNodeHelpers, SharedLayoutData};
|
||||
use script::dom::node::{Node, NodeTypeId};
|
||||
use script::dom::text::Text;
|
||||
use selectors::matching::DeclarationBlock;
|
||||
use selectors::parser::{NamespaceConstraint, AttrSelector};
|
||||
use smallvec::VecLike;
|
||||
use msg::constellation_msg::{PipelineId, SubpageId};
|
||||
use util::str::is_whitespace;
|
||||
use std::borrow::ToOwned;
|
||||
use std::cell::{Ref, RefMut};
|
||||
use std::marker::PhantomData;
|
||||
|
@ -67,13 +68,12 @@ use std::sync::Arc;
|
|||
use string_cache::{Atom, Namespace};
|
||||
use style::computed_values::content::ContentItem;
|
||||
use style::computed_values::{content, display, white_space};
|
||||
use selectors::matching::DeclarationBlock;
|
||||
use selectors::parser::{NamespaceConstraint, AttrSelector};
|
||||
use style::legacy::UnsignedIntegerAttribute;
|
||||
use style::node::TElementAttributes;
|
||||
use style::properties::{PropertyDeclaration, PropertyDeclarationBlock};
|
||||
use style::properties::ComputedValues;
|
||||
use style::properties::{PropertyDeclaration, PropertyDeclarationBlock};
|
||||
use url::Url;
|
||||
use util::str::is_whitespace;
|
||||
|
||||
/// A wrapper so that layout can access only the methods that it should have access to. Layout must
|
||||
/// only ever see these and must never see instances of `LayoutJS`.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue