mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Remove useless use crate_name;
imports.
A `crate_name::foo` path always works in 2018
This commit is contained in:
parent
50c840fe42
commit
9f977c5287
85 changed files with 0 additions and 115 deletions
|
@ -6,7 +6,6 @@ use std::env;
|
|||
use std::fs::File;
|
||||
use std::io::{BufRead, BufReader};
|
||||
use std::path::Path;
|
||||
use string_cache_codegen;
|
||||
|
||||
fn main() {
|
||||
let static_atoms =
|
||||
|
|
|
@ -15,11 +15,9 @@ use cssparser::RGBA;
|
|||
use euclid::{Point2D, Rect, Size2D, Transform2D, Vector2D};
|
||||
use ipc_channel::ipc::IpcSender;
|
||||
use num_traits::ToPrimitive;
|
||||
use pixels;
|
||||
use serde_bytes::ByteBuf;
|
||||
use std::mem;
|
||||
use std::sync::Arc;
|
||||
use webrender_api;
|
||||
|
||||
pub struct CanvasData<'a> {
|
||||
drawtarget: DrawTarget,
|
||||
|
|
|
@ -10,7 +10,6 @@ use ipc_channel::ipc::{self, IpcSender};
|
|||
use std::borrow::ToOwned;
|
||||
use std::collections::HashMap;
|
||||
use std::thread;
|
||||
use webrender_api;
|
||||
|
||||
pub struct CanvasPaintThread<'a> {
|
||||
canvases: HashMap<CanvasId, CanvasData<'a>>,
|
||||
|
|
|
@ -13,8 +13,6 @@ use fnv::FnvHashMap;
|
|||
use gleam::gl;
|
||||
use servo_config::prefs::PREFS;
|
||||
use std::rc::Rc;
|
||||
use webrender;
|
||||
use webrender_api;
|
||||
|
||||
/// WebGL Threading API entry point that lives in the constellation.
|
||||
pub struct WebGLThreads(WebGLSender<WebGLMsg>);
|
||||
|
|
|
@ -8,10 +8,7 @@ use euclid::Size2D;
|
|||
use fnv::FnvHashMap;
|
||||
use gleam::gl;
|
||||
use offscreen_gl_context::{GLContext, GLContextAttributes, GLLimits, NativeGLContextMethods};
|
||||
use pixels;
|
||||
use std::thread;
|
||||
use webrender;
|
||||
use webrender_api;
|
||||
|
||||
/// WebGL Threading API entry point that lives in the constellation.
|
||||
/// It allows to get a WebGLThread handle for each script pipeline.
|
||||
|
|
|
@ -8,7 +8,6 @@ use ipc_channel::ipc::{IpcBytesReceiver, IpcBytesSender, IpcSender};
|
|||
use serde_bytes::ByteBuf;
|
||||
use std::default::Default;
|
||||
use std::str::FromStr;
|
||||
use webrender_api;
|
||||
|
||||
#[derive(Clone, Debug, Deserialize, Serialize)]
|
||||
pub enum FillRule {
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
* 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 ipc_channel;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use std::io;
|
||||
|
||||
|
|
|
@ -8,7 +8,6 @@ pub mod base_channel {
|
|||
// Needed to re-export the select macro.
|
||||
pub use crossbeam_channel::*;
|
||||
|
||||
use crossbeam_channel;
|
||||
use ipc_channel::ipc::IpcReceiver;
|
||||
use ipc_channel::router::ROUTER;
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
|
|
@ -6,7 +6,6 @@ use std::env;
|
|||
use std::fs::File;
|
||||
use std::io::{Read, Write};
|
||||
use std::path::Path;
|
||||
use toml;
|
||||
|
||||
fn main() {
|
||||
let lockfile_path = Path::new(&env::var("CARGO_MANIFEST_DIR").unwrap())
|
||||
|
|
|
@ -40,7 +40,6 @@ use style_traits::cursor::CursorKind;
|
|||
use style_traits::viewport::ViewportConstraints;
|
||||
use style_traits::{CSSPixel, DevicePixel, PinchZoomFactor};
|
||||
use time::{now, precise_time_ns, precise_time_s};
|
||||
use webrender;
|
||||
use webrender_api::{self, DeviceIntPoint, DevicePoint, HitTestFlags, HitTestResult};
|
||||
use webrender_api::{LayoutVector2D, ScrollLocation};
|
||||
|
||||
|
|
|
@ -17,7 +17,6 @@ use script_traits::{AnimationState, ConstellationMsg, EventResult};
|
|||
use servo_channel::{Receiver, Sender};
|
||||
use std::fmt::{Debug, Error, Formatter};
|
||||
use style_traits::viewport::ViewportConstraints;
|
||||
use webrender;
|
||||
use webrender_api::{self, DeviceIntPoint, DeviceUintSize};
|
||||
|
||||
/// Sends messages to the compositor.
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
use crate::prefs::{self, PrefValue, PREFS};
|
||||
use euclid::TypedSize2D;
|
||||
use getopts::Options;
|
||||
use num_cpus;
|
||||
use servo_geometry::DeviceIndependentPixel;
|
||||
use servo_url::ServoUrl;
|
||||
use std::borrow::Cow;
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
use crate::basedir::default_config_dir;
|
||||
use crate::opts;
|
||||
use embedder_traits::resources::{self, Resource};
|
||||
use num_cpus;
|
||||
use serde_json::{self, Value};
|
||||
use std::borrow::ToOwned;
|
||||
use std::cmp::max;
|
||||
|
|
|
@ -110,7 +110,6 @@ use crate::session_history::{
|
|||
JointSessionHistory, NeedsToReload, SessionHistoryChange, SessionHistoryDiff,
|
||||
};
|
||||
use crate::timer_scheduler::TimerScheduler;
|
||||
use debugger;
|
||||
use devtools_traits::{ChromeToDevtoolsControlMsg, DevtoolsControlMsg};
|
||||
use embedder_traits::{EmbedderMsg, EmbedderProxy};
|
||||
use euclid::{Size2D, TypedScale, TypedSize2D};
|
||||
|
@ -164,7 +163,6 @@ use std::thread;
|
|||
use style_traits::cursor::CursorKind;
|
||||
use style_traits::viewport::ViewportConstraints;
|
||||
use style_traits::CSSPixel;
|
||||
use webrender_api;
|
||||
use webvr_traits::{WebVREvent, WebVRMsg};
|
||||
|
||||
/// Servo supports tabs (referred to as browsers), so `Constellation` needs to
|
||||
|
|
|
@ -41,7 +41,6 @@ use std::rc::Rc;
|
|||
use std::sync::Arc;
|
||||
use style_traits::CSSPixel;
|
||||
use style_traits::DevicePixel;
|
||||
use webrender_api;
|
||||
use webvr_traits::WebVRMsg;
|
||||
|
||||
/// A `Pipeline` is the constellation's view of a `Document`. Each pipeline has an
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
#[macro_use]
|
||||
extern crate log;
|
||||
|
||||
use servo_channel;
|
||||
use std::thread;
|
||||
use ws::{self, Builder, CloseCode, Handler, Handshake};
|
||||
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
extern crate proc_macro;
|
||||
|
||||
use std::str::FromStr;
|
||||
use syn;
|
||||
use synstructure::{self, decl_derive};
|
||||
|
||||
decl_derive!([DenyPublicFields] => deny_public_fields_derive);
|
||||
|
|
|
@ -16,7 +16,6 @@ use http::{header, HeaderMap};
|
|||
use hyper::{Method, StatusCode};
|
||||
use serde_json::{Map, Value};
|
||||
use std::net::TcpStream;
|
||||
use time;
|
||||
use time::Tm;
|
||||
|
||||
struct HttpRequest {
|
||||
|
|
|
@ -27,9 +27,7 @@ use std::sync::Arc;
|
|||
use style::computed_values::{font_stretch, font_style, font_variant_caps, font_weight};
|
||||
use style::properties::style_structs::Font as FontStyleStruct;
|
||||
use style::values::computed::font::SingleFontFamily;
|
||||
use time;
|
||||
use unicode_script::Script;
|
||||
use webrender_api;
|
||||
|
||||
macro_rules! ot_tag {
|
||||
($t1:expr, $t2:expr, $t3:expr, $t4:expr) => {
|
||||
|
|
|
@ -12,7 +12,6 @@ use crate::platform::font_list::for_each_variation;
|
|||
use crate::platform::font_list::system_default_family;
|
||||
use crate::platform::font_list::SANS_SERIF_FONT_FAMILY;
|
||||
use crate::platform::font_template::FontTemplateData;
|
||||
use fontsan;
|
||||
use ipc_channel::ipc::{self, IpcReceiver, IpcSender};
|
||||
use net_traits::request::{Destination, RequestInit};
|
||||
use net_traits::{fetch_async, CoreResourceThread, FetchResponseMsg};
|
||||
|
@ -25,7 +24,6 @@ use std::sync::{Arc, Mutex};
|
|||
use std::{f32, fmt, mem, thread};
|
||||
use style::font_face::{EffectiveSources, Source};
|
||||
use style::values::computed::font::FamilyName;
|
||||
use webrender_api;
|
||||
|
||||
/// A list of font templates that make up a given font family.
|
||||
pub struct FontTemplates {
|
||||
|
|
|
@ -21,7 +21,6 @@ use std::rc::Rc;
|
|||
use std::sync::atomic::{AtomicUsize, Ordering, ATOMIC_USIZE_INIT};
|
||||
use style::computed_values::font_variant_caps::T as FontVariantCaps;
|
||||
use style::properties::style_structs::Font as FontStyleStruct;
|
||||
use webrender_api;
|
||||
|
||||
static SMALL_CAPS_SCALE_FACTOR: f32 = 0.8; // Matches FireFox (see gfxFont.h)
|
||||
|
||||
|
|
|
@ -12,7 +12,6 @@ use fontconfig::fontconfig::{
|
|||
FcFontSetList, FcObjectSetCreate, FcObjectSetDestroy, FcPatternAddString,
|
||||
};
|
||||
use fontconfig::fontconfig::{FcObjectSetAdd, FcPatternGetInteger};
|
||||
use libc;
|
||||
use libc::{c_char, c_int};
|
||||
use std::ffi::CString;
|
||||
use std::ptr;
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
* 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 core_text;
|
||||
use crate::text::util::unicode_plane;
|
||||
use ucd::{Codepoint, UnicodeBlock};
|
||||
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
use app_units::Au;
|
||||
use core_graphics::data_provider::CGDataProvider;
|
||||
use core_graphics::font::CGFont;
|
||||
use core_text;
|
||||
use core_text::font::CTFont;
|
||||
use serde::de::{Error, Visitor};
|
||||
use serde::{Deserialize, Deserializer, Serialize, Serializer};
|
||||
|
|
|
@ -13,7 +13,6 @@ use crate::platform::font_template::FontTemplateData;
|
|||
use crate::platform::windows::font_context::FontContextHandle;
|
||||
use crate::platform::windows::font_list::font_from_atom;
|
||||
use crate::text::glyph::GlyphId;
|
||||
use dwrote;
|
||||
use dwrote::{Font, FontFace, FontFile};
|
||||
use dwrote::{FontStretch, FontStyle};
|
||||
use servo_atoms::Atom;
|
||||
|
@ -26,7 +25,6 @@ use style::values::computed::font::FontStyle as StyleFontStyle;
|
|||
use style::values::generics::font::FontStyle as GenericFontStyle;
|
||||
use style::values::generics::NonNegative;
|
||||
use style::values::specified::font::FontStretchKeyword;
|
||||
use truetype;
|
||||
|
||||
// 1em = 12pt = 16px, assuming 72 points per inch and 96 px per inch
|
||||
fn pt_to_px(pt: f64) -> f64 {
|
||||
|
|
|
@ -24,7 +24,6 @@ use style::values::computed::font::{
|
|||
};
|
||||
use style::values::computed::font::{FontStretch, FontWeight, SingleFontFamily};
|
||||
use style::values::generics::font::FontStyle;
|
||||
use webrender_api;
|
||||
|
||||
struct TestFontSource {
|
||||
handle: FontContextHandle,
|
||||
|
|
|
@ -14,7 +14,6 @@ use std::slice::Iter;
|
|||
use std::sync::Arc;
|
||||
use style::str::char_is_whitespace;
|
||||
use unicode_bidi as bidi;
|
||||
use webrender_api;
|
||||
use xi_unicode::LineBreakLeafIter;
|
||||
|
||||
thread_local! {
|
||||
|
|
|
@ -7,8 +7,6 @@ extern crate syn;
|
|||
#[macro_use]
|
||||
extern crate synstructure;
|
||||
|
||||
use quote;
|
||||
|
||||
decl_derive!([JSTraceable] => js_traceable_derive);
|
||||
|
||||
fn js_traceable_derive(s: synstructure::Structure) -> quote::Tokens {
|
||||
|
|
|
@ -23,7 +23,6 @@ use crate::text::TextRunScanner;
|
|||
use crate::wrapper::ThreadSafeLayoutNodeHelpers;
|
||||
use crate::ServoArc;
|
||||
use euclid::{Point2D, Rect, Size2D, Vector2D};
|
||||
use gfx;
|
||||
use gfx::text::glyph::ByteIndex;
|
||||
use gfx::text::text_run::{TextRun, TextRunSlice};
|
||||
use gfx_traits::StackingContextId;
|
||||
|
|
|
@ -15,7 +15,6 @@ use crate::flow_ref::FlowRef;
|
|||
use crate::traversal::{AssignBSizes, AssignISizes, BubbleISizes};
|
||||
use crate::traversal::{PostorderFlowTraversal, PreorderFlowTraversal};
|
||||
use profile_traits::time::{self, profile, TimerMetadata};
|
||||
use rayon;
|
||||
use servo_config::opts;
|
||||
use smallvec::SmallVec;
|
||||
use std::mem;
|
||||
|
|
|
@ -21,7 +21,6 @@ use script_traits::{ConstellationControlMsg, LayoutControlMsg};
|
|||
use servo_channel::{Receiver, Sender};
|
||||
use servo_url::ServoUrl;
|
||||
use std::sync::Arc;
|
||||
use webrender_api;
|
||||
|
||||
// A static method creating a layout thread
|
||||
// Here to remove the compositor -> layout dependency
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
use std::cell::Cell;
|
||||
use std::fmt;
|
||||
use std::num::NonZeroU32;
|
||||
use webrender_api;
|
||||
|
||||
#[derive(Clone, Copy, Debug, Deserialize, Eq, Hash, PartialEq, Serialize)]
|
||||
pub enum TraversalDirection {
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
//! Implementation of cookie creation and matching as specified by
|
||||
//! http://tools.ietf.org/html/rfc6265
|
||||
|
||||
use cookie_rs;
|
||||
use hyper_serde::{self, Serde};
|
||||
use net_traits::pub_domains::is_pub_domain;
|
||||
use net_traits::CookieSource;
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
//! Implementation of cookie storage as specified in
|
||||
//! http://tools.ietf.org/html/rfc6265
|
||||
|
||||
use cookie_rs;
|
||||
use crate::cookie::Cookie;
|
||||
use net_traits::pub_domains::reg_suffix;
|
||||
use net_traits::CookieSource;
|
||||
|
|
|
@ -5,11 +5,9 @@
|
|||
use embedder_traits::resources::{self, Resource};
|
||||
use net_traits::pub_domains::reg_suffix;
|
||||
use net_traits::IncludeSubdomains;
|
||||
use serde_json;
|
||||
use servo_url::ServoUrl;
|
||||
use std::collections::HashMap;
|
||||
use std::net::{Ipv4Addr, Ipv6Addr};
|
||||
use time;
|
||||
|
||||
#[derive(Clone, Debug, Deserialize, Serialize)]
|
||||
pub struct HstsEntry {
|
||||
|
|
|
@ -29,7 +29,6 @@ use std::ops::Bound;
|
|||
use std::sync::atomic::{AtomicBool, Ordering};
|
||||
use std::sync::Mutex;
|
||||
use std::time::SystemTime;
|
||||
use time;
|
||||
use time::{Duration, Timespec, Tm};
|
||||
|
||||
/// The key used to differentiate requests in the cache.
|
||||
|
|
|
@ -36,8 +36,6 @@ use http::uri::Authority;
|
|||
use http::{HeaderMap, Request as HyperRequest};
|
||||
use hyper::{Body, Client, Method, Response as HyperResponse, StatusCode};
|
||||
use hyper_serde::Serde;
|
||||
use log;
|
||||
use mime;
|
||||
use msg::constellation_msg::{HistoryStateId, PipelineId};
|
||||
use net_traits::quality::{quality_to_value, Quality, QualityItem};
|
||||
use net_traits::request::{CacheMode, CredentialsMode, Destination, Origin};
|
||||
|
@ -61,7 +59,6 @@ use std::time::{Duration, SystemTime};
|
|||
use time::{self, Tm};
|
||||
use tokio::prelude::{future, Future, Stream};
|
||||
use tokio::runtime::Runtime;
|
||||
use uuid;
|
||||
|
||||
lazy_static! {
|
||||
pub static ref HANDLE: Mutex<Runtime> = { Mutex::new(Runtime::new().unwrap()) };
|
||||
|
|
|
@ -9,7 +9,6 @@ use net_traits::image_cache::{CanRequestImages, ImageCache, ImageResponder};
|
|||
use net_traits::image_cache::{ImageOrMetadataAvailable, ImageResponse, ImageState};
|
||||
use net_traits::image_cache::{PendingImageId, UsePlaceholder};
|
||||
use net_traits::{FetchMetadata, FetchResponseMsg, NetworkError};
|
||||
use pixels;
|
||||
use servo_url::ServoUrl;
|
||||
use std::collections::hash_map::Entry::{Occupied, Vacant};
|
||||
use std::collections::HashMap;
|
||||
|
@ -17,7 +16,6 @@ use std::io;
|
|||
use std::mem;
|
||||
use std::sync::{Arc, Mutex};
|
||||
use std::thread;
|
||||
use webrender_api;
|
||||
|
||||
///
|
||||
/// TODO(gw): Remaining work on image cache:
|
||||
|
|
|
@ -4,7 +4,6 @@
|
|||
|
||||
//! A thread that takes a URL and streams back the binary data.
|
||||
|
||||
use cookie_rs;
|
||||
use crate::connector::{create_http_client, create_ssl_connector_builder};
|
||||
use crate::cookie;
|
||||
use crate::cookie_storage::CookieStorage;
|
||||
|
@ -33,8 +32,6 @@ use profile_traits::mem::ProfilerChan as MemProfilerChan;
|
|||
use profile_traits::mem::{Report, ReportKind, ReportsChan};
|
||||
use profile_traits::time::ProfilerChan;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use serde_json;
|
||||
use servo_allocator;
|
||||
use servo_channel::Sender;
|
||||
use servo_config::opts;
|
||||
use servo_url::ServoUrl;
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
* 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 cookie_rs;
|
||||
use net::cookie::Cookie;
|
||||
use net::cookie_storage::CookieStorage;
|
||||
use net_traits::CookieSource;
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
use net::hsts::{HstsEntry, HstsList};
|
||||
use net_traits::IncludeSubdomains;
|
||||
use std::collections::HashMap;
|
||||
use time;
|
||||
|
||||
#[test]
|
||||
fn test_hsts_entry_is_not_expired_when_it_has_no_timestamp() {
|
||||
|
|
|
@ -11,7 +11,6 @@ use net_traits::request::{Destination, Request, RequestInit};
|
|||
use net_traits::response::{Response, ResponseBody};
|
||||
use servo_url::ServoUrl;
|
||||
use std::sync::mpsc::channel;
|
||||
use time;
|
||||
|
||||
|
||||
#[test]
|
||||
|
|
|
@ -4,9 +4,7 @@
|
|||
|
||||
use ipc_channel::ipc::IpcSharedMemory;
|
||||
use piston_image::{DynamicImage, ImageFormat};
|
||||
use pixels;
|
||||
use std::fmt;
|
||||
use webrender_api;
|
||||
|
||||
#[derive(Clone, Copy, Debug, Deserialize, Eq, MallocSizeOf, PartialEq, Serialize)]
|
||||
pub enum PixelFormat {
|
||||
|
|
|
@ -7,7 +7,6 @@ use crate::FetchResponseMsg;
|
|||
use ipc_channel::ipc::IpcSender;
|
||||
use servo_url::ServoUrl;
|
||||
use std::sync::Arc;
|
||||
use webrender_api;
|
||||
|
||||
// ======================================================================
|
||||
// Aux structs and enums.
|
||||
|
|
|
@ -2,8 +2,6 @@
|
|||
* 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 net_traits;
|
||||
|
||||
#[test]
|
||||
fn test_trim_http_whitespace() {
|
||||
fn test_trim(in_: &[u8], out: &[u8]) {
|
||||
|
|
|
@ -26,7 +26,6 @@ use std::path::Path;
|
|||
use std::time::Duration;
|
||||
use std::{f64, thread, u32, u64};
|
||||
use time_crate::precise_time_ns;
|
||||
use tokio;
|
||||
use tokio::prelude::Future;
|
||||
|
||||
pub trait Formattable {
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
//! A module for writing time profiler traces out to a self contained HTML file.
|
||||
|
||||
use profile_traits::time::{ProfilerCategory, TimerMetadata};
|
||||
use serde_json;
|
||||
use std::fs;
|
||||
use std::io::{self, Write};
|
||||
use std::path;
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
* 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 bincode;
|
||||
use crate::time;
|
||||
use crate::time::ProfilerCategory;
|
||||
use crate::time::ProfilerChan;
|
||||
|
|
|
@ -8,7 +8,6 @@
|
|||
|
||||
use ipc_channel::ipc::{self, IpcSender};
|
||||
use ipc_channel::router::ROUTER;
|
||||
use serde;
|
||||
use servo_channel::Sender;
|
||||
use std::marker::Send;
|
||||
|
||||
|
|
|
@ -5,7 +5,6 @@
|
|||
use crate::energy::read_energy_uj;
|
||||
use ipc_channel::ipc::IpcSender;
|
||||
use servo_config::opts;
|
||||
use signpost;
|
||||
use time::precise_time_ns;
|
||||
|
||||
#[derive(Clone, Debug, Deserialize, Eq, Ord, PartialEq, PartialOrd, Serialize)]
|
||||
|
|
|
@ -2,8 +2,6 @@
|
|||
* 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 cmake;
|
||||
use phf_codegen;
|
||||
use phf_shared;
|
||||
use serde_json::{self, Value};
|
||||
use std::env;
|
||||
|
|
|
@ -9,7 +9,6 @@ use js::jsapi::{JSContext, JSPROP_ENUMERATE, JSPROP_PERMANENT};
|
|||
use js::jsval::{BooleanValue, DoubleValue, Int32Value, JSVal, NullValue, UInt32Value};
|
||||
use js::rust::wrappers::JS_DefineProperty;
|
||||
use js::rust::HandleObject;
|
||||
use libc;
|
||||
|
||||
/// Representation of an IDL constant.
|
||||
#[derive(Clone)]
|
||||
|
|
|
@ -40,7 +40,6 @@ use crate::dom::bindings::root::DomRoot;
|
|||
use crate::dom::bindings::str::{ByteString, DOMString, USVString};
|
||||
use crate::dom::bindings::trace::{JSTraceable, RootedTraceableBox};
|
||||
use crate::dom::bindings::utils::DOMClass;
|
||||
use js;
|
||||
use js::conversions::latin1_to_string;
|
||||
pub use js::conversions::ConversionBehavior;
|
||||
pub use js::conversions::{ConversionResult, FromJSValConvertible, ToJSValConvertible};
|
||||
|
@ -59,7 +58,6 @@ use js::jsval::{ObjectValue, StringValue, UndefinedValue};
|
|||
use js::rust::wrappers::{JS_GetProperty, JS_IsArrayObject};
|
||||
use js::rust::{get_object_class, is_dom_class, is_dom_object, maybe_wrap_value, ToString};
|
||||
use js::rust::{HandleId, HandleObject, HandleValue, MutableHandleValue};
|
||||
use libc;
|
||||
use num_traits::Float;
|
||||
use servo_config::opts;
|
||||
use std::{char, ffi, ptr, slice};
|
||||
|
|
|
@ -35,7 +35,6 @@ use js::rust::wrappers::{JS_FireOnNewGlobalObject, JS_GetPrototype};
|
|||
use js::rust::wrappers::{JS_LinkConstructorAndPrototype, JS_NewObjectWithUniqueType};
|
||||
use js::rust::{define_methods, define_properties, get_object_class};
|
||||
use js::rust::{HandleObject, HandleValue, MutableHandleObject};
|
||||
use libc;
|
||||
use std::convert::TryFrom;
|
||||
use std::ptr;
|
||||
|
||||
|
|
|
@ -8,7 +8,6 @@ use crate::dom::bindings::guard::Guard;
|
|||
use crate::dom::bindings::interface::{create_object, define_on_global_object};
|
||||
use js::jsapi::{JSClass, JSContext, JSFunctionSpec};
|
||||
use js::rust::{HandleObject, MutableHandleObject};
|
||||
use libc;
|
||||
|
||||
/// The class of a namespace object.
|
||||
#[derive(Clone, Copy)]
|
||||
|
|
|
@ -30,7 +30,6 @@ use crate::dom::bindings::trace::trace_reflector;
|
|||
use crate::dom::promise::Promise;
|
||||
use crate::task::TaskOnce;
|
||||
use js::jsapi::JSTracer;
|
||||
use libc;
|
||||
use std::cell::RefCell;
|
||||
use std::collections::hash_map::Entry::{Occupied, Vacant};
|
||||
use std::collections::hash_map::HashMap;
|
||||
|
|
|
@ -13,7 +13,6 @@ use crate::dom::bindings::inheritance::TopTypeId;
|
|||
use crate::dom::bindings::str::DOMString;
|
||||
use crate::dom::bindings::trace::trace_object;
|
||||
use crate::dom::windowproxy;
|
||||
use js;
|
||||
use js::glue::{CallJitGetterOp, CallJitMethodOp, CallJitSetterOp, IsWrapper};
|
||||
use js::glue::{GetCrossCompartmentWrapper, JS_GetReservedSlot, WrapperNew};
|
||||
use js::glue::{UnwrapObject, RUST_JSID_TO_INT, RUST_JSID_TO_STRING};
|
||||
|
@ -38,7 +37,6 @@ use js::rust::wrappers::JS_SetProperty;
|
|||
use js::rust::{get_object_class, is_dom_class, GCMethods, ToString, ToWindowProxyIfWindow};
|
||||
use js::rust::{Handle, HandleId, HandleObject, HandleValue, MutableHandleValue};
|
||||
use js::JS_CALLEE;
|
||||
use libc;
|
||||
use malloc_size_of::{MallocSizeOf, MallocSizeOfOps};
|
||||
use std::ffi::CString;
|
||||
use std::os::raw::{c_char, c_void};
|
||||
|
|
|
@ -41,7 +41,6 @@ use net_traits::image_cache::ImageOrMetadataAvailable;
|
|||
use net_traits::image_cache::ImageResponse;
|
||||
use net_traits::image_cache::ImageState;
|
||||
use net_traits::image_cache::UsePlaceholder;
|
||||
use pixels;
|
||||
use profile_traits::ipc as profiled_ipc;
|
||||
use script_traits::ScriptMsg;
|
||||
use servo_url::ServoUrl;
|
||||
|
|
|
@ -155,7 +155,6 @@ use style::shared_lock::{SharedRwLock as StyleSharedRwLock, SharedRwLockReadGuar
|
|||
use style::str::{split_html_space_chars, str_join};
|
||||
use style::stylesheet_set::DocumentStylesheetSet;
|
||||
use style::stylesheets::{CssRule, Origin, OriginSet, Stylesheet};
|
||||
use time;
|
||||
use url::percent_encoding::percent_decode;
|
||||
use url::Host;
|
||||
|
||||
|
|
|
@ -26,7 +26,6 @@ use crate::dom::node::Node;
|
|||
use crate::dom::text::Text;
|
||||
use crate::dom::xmldocument::XMLDocument;
|
||||
use dom_struct::dom_struct;
|
||||
use mime;
|
||||
use script_traits::DocumentActivity;
|
||||
|
||||
// https://dom.spec.whatwg.org/#domimplementation
|
||||
|
|
|
@ -24,7 +24,6 @@ use dom_struct::dom_struct;
|
|||
use servo_atoms::Atom;
|
||||
use std::cell::Cell;
|
||||
use std::default::Default;
|
||||
use time;
|
||||
|
||||
#[dom_struct]
|
||||
pub struct Event {
|
||||
|
|
|
@ -15,7 +15,6 @@ use crate::dom::globalscope::GlobalScope;
|
|||
use crate::dom::window::Window;
|
||||
use dom_struct::dom_struct;
|
||||
use net_traits::filemanager_thread::SelectedFile;
|
||||
use time;
|
||||
|
||||
#[dom_struct]
|
||||
pub struct File {
|
||||
|
|
|
@ -50,7 +50,6 @@ use js::rust::wrappers::Evaluate2;
|
|||
use js::rust::{get_object_class, CompileOptionsWrapper, Runtime};
|
||||
use js::rust::{HandleValue, MutableHandleValue};
|
||||
use js::{JSCLASS_IS_DOMJSCLASS, JSCLASS_IS_GLOBAL};
|
||||
use libc;
|
||||
use msg::constellation_msg::PipelineId;
|
||||
use net_traits::{CoreResourceThread, IpcSend, ResourceThreads};
|
||||
use profile_traits::{mem as profile_mem, time as profile_time};
|
||||
|
|
|
@ -22,7 +22,6 @@ use embedder_traits::EmbedderMsg;
|
|||
use html5ever::{LocalName, Prefix};
|
||||
use servo_url::ServoUrl;
|
||||
use style::attr::AttrValue;
|
||||
use time;
|
||||
|
||||
/// How long we should wait before performing the initial reflow after `<body>` is parsed, in
|
||||
/// nanoseconds.
|
||||
|
|
|
@ -41,7 +41,6 @@ use js::jsapi::JSContext;
|
|||
use js::rust::HandleValue;
|
||||
use offscreen_gl_context::GLContextAttributes;
|
||||
use profile_traits::ipc;
|
||||
use ref_filter_map;
|
||||
use script_layout_interface::{HTMLCanvasData, HTMLCanvasDataSource};
|
||||
use servo_config::prefs::PREFS;
|
||||
use std::cell::Ref;
|
||||
|
|
|
@ -49,7 +49,6 @@ use crate::textinput::{Direction, SelectionDirection, TextInput};
|
|||
use dom_struct::dom_struct;
|
||||
use embedder_traits::FilterPattern;
|
||||
use html5ever::{LocalName, Prefix};
|
||||
use mime_guess;
|
||||
use msg::constellation_msg::InputMethodType;
|
||||
use net_traits::blob_url_store::get_blob_origin;
|
||||
use net_traits::filemanager_thread::FileManagerThreadMsg;
|
||||
|
|
|
@ -13,7 +13,6 @@ use euclid::{Rect, Size2D};
|
|||
use js::jsapi::{Heap, JSContext, JSObject};
|
||||
use js::rust::Runtime;
|
||||
use js::typedarray::{CreateWith, Uint8ClampedArray};
|
||||
use pixels;
|
||||
use std::borrow::Cow;
|
||||
use std::default::Default;
|
||||
use std::ptr;
|
||||
|
|
|
@ -25,7 +25,6 @@ use dom_struct::dom_struct;
|
|||
use metrics::ToMs;
|
||||
use std::cell::Cell;
|
||||
use std::cmp::Ordering;
|
||||
use time;
|
||||
|
||||
const INVALID_ENTRY_NAMES: &'static [&'static str] = &[
|
||||
"navigationStart",
|
||||
|
|
|
@ -70,14 +70,12 @@ use js::typedarray::{TypedArray, TypedArrayElementCreator};
|
|||
use net_traits::image::base::PixelFormat;
|
||||
use net_traits::image_cache::ImageResponse;
|
||||
use offscreen_gl_context::{GLContextAttributes, GLLimits};
|
||||
use pixels;
|
||||
use script_layout_interface::HTMLCanvasDataSource;
|
||||
use serde::{Deserialize, Serialize};
|
||||
use servo_config::prefs::PREFS;
|
||||
use std::cell::Cell;
|
||||
use std::cmp;
|
||||
use std::ptr::{self, NonNull};
|
||||
use webrender_api;
|
||||
|
||||
// From the GLES 2.0.25 spec, page 85:
|
||||
//
|
||||
|
|
|
@ -92,7 +92,6 @@ use js::jsval::JSVal;
|
|||
use js::jsval::UndefinedValue;
|
||||
use js::rust::wrappers::JS_DefineProperty;
|
||||
use js::rust::HandleValue;
|
||||
use libc;
|
||||
use msg::constellation_msg::PipelineId;
|
||||
use net_traits::image_cache::{ImageCache, ImageResponder, ImageResponse};
|
||||
use net_traits::image_cache::{PendingImageId, PendingImageResponse};
|
||||
|
@ -114,7 +113,6 @@ use script_traits::{ConstellationControlMsg, DocumentState, LoadData};
|
|||
use script_traits::{ScriptMsg, ScriptToConstellationChan, ScrollState, TimerEvent, TimerEventId};
|
||||
use script_traits::{TimerSchedulerMsg, UntrustedNodeAddress, WindowSizeData, WindowSizeType};
|
||||
use selectors::attr::CaseSensitivity;
|
||||
use servo_arc;
|
||||
use servo_channel::{channel, Sender};
|
||||
use servo_config::opts;
|
||||
use servo_geometry::{f32_rect_to_au_rect, MaxRect};
|
||||
|
@ -139,7 +137,6 @@ use style::selector_parser::PseudoElement;
|
|||
use style::str::HTML_SPACE_CHARACTERS;
|
||||
use style::stylesheets::CssRuleType;
|
||||
use style_traits::{CSSPixel, DevicePixel, ParsingMode};
|
||||
use time;
|
||||
use url::Position;
|
||||
use webrender_api::{
|
||||
DeviceIntPoint, DeviceUintSize, DocumentId, ExternalScrollId, RenderApiSender,
|
||||
|
|
|
@ -51,7 +51,6 @@ use net_traits::request::RequestInit;
|
|||
use net_traits::request::RequestMode;
|
||||
use net_traits::IpcSend;
|
||||
use servo_channel::{channel, Receiver, Sender};
|
||||
use servo_rand;
|
||||
use servo_url::ImmutableOrigin;
|
||||
use servo_url::ServoUrl;
|
||||
use std::cmp::max;
|
||||
|
|
|
@ -74,7 +74,6 @@ use std::ptr::NonNull;
|
|||
use std::slice;
|
||||
use std::str::{self, FromStr};
|
||||
use std::sync::{Arc, Mutex};
|
||||
use time;
|
||||
use url::Position;
|
||||
|
||||
#[derive(Clone, Copy, Debug, JSTraceable, MallocSizeOf, PartialEq)]
|
||||
|
|
|
@ -92,7 +92,6 @@ use headers_ext::LastModified;
|
|||
use headers_ext::ReferrerPolicy as ReferrerPolicyHeader;
|
||||
use hyper_serde::Serde;
|
||||
use ipc_channel::ipc::{self, IpcSender};
|
||||
use itertools;
|
||||
use js::glue::GetWindowProxyClass;
|
||||
use js::jsapi::{JSAutoCompartment, JSContext, JS_SetWrapObjectCallbacks};
|
||||
use js::jsapi::{JSTracer, SetWindowProxyClass};
|
||||
|
|
|
@ -31,7 +31,6 @@ use servo_url::ServoUrl;
|
|||
use std::ptr::NonNull;
|
||||
use std::sync::atomic::AtomicIsize;
|
||||
use style::data::ElementData;
|
||||
use webrender_api;
|
||||
|
||||
#[repr(C)]
|
||||
pub struct StyleData {
|
||||
|
|
|
@ -4,7 +4,6 @@
|
|||
|
||||
use cssparser::SourceLocation;
|
||||
use ipc_channel::ipc::IpcSender;
|
||||
use log;
|
||||
use msg::constellation_msg::PipelineId;
|
||||
use script_traits::ConstellationControlMsg;
|
||||
use servo_url::ServoUrl;
|
||||
|
|
|
@ -23,7 +23,6 @@ use std::ops::{Index, Range, RangeFrom, RangeFull, RangeTo};
|
|||
use std::path::Path;
|
||||
use std::sync::Arc;
|
||||
use url::{Position, Url};
|
||||
use url_serde;
|
||||
|
||||
pub use url::Host;
|
||||
|
||||
|
|
|
@ -2,11 +2,9 @@
|
|||
* 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 servo_rand;
|
||||
use std::cell::RefCell;
|
||||
use std::rc::Rc;
|
||||
use url::{Host, Origin};
|
||||
use url_serde;
|
||||
use uuid::Uuid;
|
||||
|
||||
/// The origin of an URL
|
||||
|
|
|
@ -14,7 +14,6 @@ extern crate serde;
|
|||
mod keys;
|
||||
|
||||
use base64;
|
||||
use cookie;
|
||||
use crate::keys::keycodes_to_keys;
|
||||
use euclid::TypedSize2D;
|
||||
use hyper::Method;
|
||||
|
|
|
@ -2,7 +2,6 @@
|
|||
* 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 serde_json;
|
||||
use servo::compositing::windowing::{
|
||||
AnimationState, EmbedderCoordinates, MouseWindowEvent, WindowEvent, WindowMethods,
|
||||
};
|
||||
|
|
|
@ -5,15 +5,12 @@
|
|||
#[cfg(any(target_os = "android", target_os = "windows"))]
|
||||
#[allow(non_camel_case_types)]
|
||||
pub mod egl {
|
||||
use libc;
|
||||
use servo::gl::{Gl, GlesFns};
|
||||
use std::ffi::CString;
|
||||
#[cfg(not(target_os = "windows"))]
|
||||
use std::os::raw::c_void;
|
||||
use std::rc::Rc;
|
||||
#[cfg(target_os = "windows")]
|
||||
use winapi;
|
||||
#[cfg(target_os = "windows")]
|
||||
use winapi::um::libloaderapi::{GetProcAddress, LoadLibraryA};
|
||||
|
||||
#[cfg(target_os = "windows")]
|
||||
|
|
|
@ -12,7 +12,6 @@ use jni::sys::{jboolean, jfloat, jint, jstring, JNI_TRUE};
|
|||
use jni::{errors, JNIEnv, JavaVM};
|
||||
use libc::{dup2, pipe, read};
|
||||
use log::Level;
|
||||
use std;
|
||||
use std::os::raw::{c_char, c_int, c_void};
|
||||
use std::sync::{Arc, Mutex};
|
||||
use std::thread;
|
||||
|
|
|
@ -10,8 +10,6 @@ use gdi32;
|
|||
use gleam::gl;
|
||||
use glutin::{Api, ContextBuilder, GlContext, GlRequest, GlWindow};
|
||||
use keyboard_types::{Key, KeyboardEvent, KeyState};
|
||||
#[cfg(any(target_os = "linux", target_os = "macos"))]
|
||||
use osmesa_sys;
|
||||
use servo::compositing::windowing::{AnimationState, MouseWindowEvent, WindowEvent};
|
||||
use servo::compositing::windowing::{EmbedderCoordinates, WindowMethods};
|
||||
use servo::embedder_traits::EventLoopWaker;
|
||||
|
@ -34,9 +32,6 @@ use std::time;
|
|||
use super::keyutils::keyboard_event_from_winit;
|
||||
#[cfg(target_os = "windows")]
|
||||
use user32;
|
||||
#[cfg(target_os = "windows")]
|
||||
use winapi;
|
||||
use winit;
|
||||
use winit::{ElementState, Event, MouseButton, MouseScrollDelta, TouchPhase, KeyboardInput};
|
||||
use winit::dpi::{LogicalPosition, LogicalSize, PhysicalSize};
|
||||
#[cfg(target_os = "macos")]
|
||||
|
|
|
@ -10,7 +10,6 @@ use euclid::Size2D;
|
|||
use azure::azure::AzIntSize;
|
||||
use azure::azure::{AzIntSize};
|
||||
|
||||
use std;
|
||||
|
||||
mod paint_context;
|
||||
pub mod display_list;
|
||||
|
|
|
@ -7,7 +7,6 @@ use metrics::{InteractiveFlag, InteractiveMetrics};
|
|||
use metrics::{ProfilerMetadataFactory, ProgressiveWebMetric};
|
||||
use profile_traits::time::{ProfilerChan, TimerMetadata};
|
||||
use servo_url::ServoUrl;
|
||||
use time;
|
||||
|
||||
struct DummyProfilerMetadataFactory {}
|
||||
impl ProfilerMetadataFactory for DummyProfilerMetadataFactory {
|
||||
|
|
|
@ -9,7 +9,6 @@ use metrics::{PaintTimeMetrics, ProfilerMetadataFactory, ProgressiveWebMetric};
|
|||
use msg::constellation_msg::TEST_PIPELINE_ID;
|
||||
use profile_traits::time::{ProfilerChan, TimerMetadata};
|
||||
use servo_url::ServoUrl;
|
||||
use time;
|
||||
use webrender_api::{AlphaType, ColorF, ImageDisplayItem, ImageKey, ImageRendering, LayoutSize};
|
||||
|
||||
struct DummyProfilerMetadataFactory {}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue