servo: Merge #16689 - Upgrade to html5ever 0.16 (from servo:m5e); r=nox

Source-Repo: https://github.com/servo/servo
Source-Revision: 8b41c7c137c78aab208fe2991c3ec951fe5f1386

--HG--
extra : subtree_source : https%3A//hg.mozilla.org/projects/converted-servo-linear
extra : subtree_revision : 234eca73c03f9e482a94c97e49ce5a78d077123e
This commit is contained in:
Simon Sapin 2017-05-03 08:42:41 -05:00
Родитель 891449384c
Коммит fd16ec7749
104 изменённых файлов: 363 добавлений и 471 удалений

61
servo/Cargo.lock сгенерированный
Просмотреть файл

@ -1150,33 +1150,17 @@ dependencies = [
[[package]]
name = "html5ever"
version = "0.15.0"
version = "0.16.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"heapsize 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
"heapsize_derive 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever-atoms 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
"mac 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"phf 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
"phf_codegen 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
"markup5ever 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"quote 0.3.15 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.24 (registry+https://github.com/rust-lang/crates.io-index)",
"syn 0.11.11 (registry+https://github.com/rust-lang/crates.io-index)",
"tendril 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "html5ever-atoms"
version = "0.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"heapsize 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
"heapsize_derive 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"string_cache 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"string_cache_codegen 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "httparse"
version = "1.2.1"
@ -1378,7 +1362,7 @@ dependencies = [
"gfx 0.0.1",
"gfx_traits 0.0.1",
"heapsize 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever-atoms 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.16.0 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
"libc 0.2.22 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
@ -1573,6 +1557,21 @@ dependencies = [
"libc 0.2.22 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "markup5ever"
version = "0.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"heapsize 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
"heapsize_derive 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"phf 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
"phf_codegen 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.24 (registry+https://github.com/rust-lang/crates.io-index)",
"string_cache 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"string_cache_codegen 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"tendril 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
name = "matches"
version = "0.1.4"
@ -2279,8 +2278,7 @@ dependencies = [
"gfx_traits 0.0.1",
"heapsize 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
"heapsize_derive 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.15.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever-atoms 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.16.0 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper 0.10.9 (registry+https://github.com/rust-lang/crates.io-index)",
"hyper_serde 0.6.2 (registry+https://github.com/rust-lang/crates.io-index)",
"image 0.12.4 (registry+https://github.com/rust-lang/crates.io-index)",
@ -2328,7 +2326,7 @@ dependencies = [
"webrender_traits 0.36.0 (git+https://github.com/servo/webrender)",
"webvr 0.0.1",
"webvr_traits 0.0.1",
"xml5ever 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)",
"xml5ever 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
]
[[package]]
@ -2343,7 +2341,7 @@ dependencies = [
"gfx_traits 0.0.1",
"heapsize 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
"heapsize_derive 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever-atoms 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.16.0 (registry+https://github.com/rust-lang/crates.io-index)",
"ipc-channel 0.7.1 (registry+https://github.com/rust-lang/crates.io-index)",
"libc 0.2.22 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
@ -2768,7 +2766,7 @@ dependencies = [
"fnv 1.0.5 (registry+https://github.com/rust-lang/crates.io-index)",
"heapsize 0.3.9 (registry+https://github.com/rust-lang/crates.io-index)",
"heapsize_derive 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever-atoms 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.16.0 (registry+https://github.com/rust-lang/crates.io-index)",
"kernel32-sys 0.2.2 (registry+https://github.com/rust-lang/crates.io-index)",
"lazy_static 0.2.8 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
@ -2803,7 +2801,7 @@ dependencies = [
"app_units 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)",
"cssparser 0.13.1 (registry+https://github.com/rust-lang/crates.io-index)",
"euclid 0.11.3 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever-atoms 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"html5ever 0.16.0 (registry+https://github.com/rust-lang/crates.io-index)",
"parking_lot 0.3.8 (registry+https://github.com/rust-lang/crates.io-index)",
"rayon 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.24 (registry+https://github.com/rust-lang/crates.io-index)",
@ -3327,15 +3325,12 @@ dependencies = [
[[package]]
name = "xml5ever"
version = "0.5.0"
version = "0.6.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
dependencies = [
"html5ever-atoms 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)",
"log 0.3.7 (registry+https://github.com/rust-lang/crates.io-index)",
"mac 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)",
"phf 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
"phf_codegen 0.7.21 (registry+https://github.com/rust-lang/crates.io-index)",
"rustc-serialize 0.3.24 (registry+https://github.com/rust-lang/crates.io-index)",
"markup5ever 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)",
"tendril 0.2.3 (registry+https://github.com/rust-lang/crates.io-index)",
"time 0.1.37 (registry+https://github.com/rust-lang/crates.io-index)",
]
@ -3439,8 +3434,7 @@ dependencies = [
"checksum heapsize_derive 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "46f96d52fb1564059fc97b85ef6165728cc30198ab60073bf114c66c4c89bb5d"
"checksum heartbeats-simple 0.4.0 (registry+https://github.com/rust-lang/crates.io-index)" = "9ad003ce233955e9d95f2c69cde84e68302ba9ba4a673d351c9bff93c738aadc"
"checksum heartbeats-simple-sys 0.4.1 (registry+https://github.com/rust-lang/crates.io-index)" = "e1a408c0011427cc0e0049f7861c70377819aedfc006e8c901b1c70fd98fb1a4"
"checksum html5ever 0.15.0 (registry+https://github.com/rust-lang/crates.io-index)" = "89a83ad398346d1f25b21979dd79ed7b5c345796194665b34321b5551726347e"
"checksum html5ever-atoms 0.3.0 (registry+https://github.com/rust-lang/crates.io-index)" = "8e4a291981feff7291514f8219d5cd2c740d0c042d75cff248a7c00a025f9d40"
"checksum html5ever 0.16.0 (registry+https://github.com/rust-lang/crates.io-index)" = "83d2f9d3abeac56d8b4de9fd033473f6183b89ea91e635326b2807b6a14e98b9"
"checksum httparse 1.2.1 (registry+https://github.com/rust-lang/crates.io-index)" = "a6e7a63e511f9edffbab707141fbb8707d1a3098615fb2adbd5769cdfcc9b17d"
"checksum hyper 0.10.9 (registry+https://github.com/rust-lang/crates.io-index)" = "94da93321c171e26481afeebe8288757b0501901b7c5492648163d8ec4942ec5"
"checksum hyper-openssl 0.2.6 (registry+https://github.com/rust-lang/crates.io-index)" = "85a372eb692590b3fe014c196c30f9f52d4c42f58cd49dd94caeee1593c9cc37"
@ -3470,6 +3464,7 @@ dependencies = [
"checksum lzw 0.10.0 (registry+https://github.com/rust-lang/crates.io-index)" = "7d947cbb889ed21c2a84be6ffbaebf5b4e0f4340638cba0444907e38b56be084"
"checksum mac 0.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "c41e0c4fef86961ac6d6f8a82609f55f31b05e4fce149ac5710e439df7619ba4"
"checksum malloc_buf 0.0.6 (registry+https://github.com/rust-lang/crates.io-index)" = "62bb907fe88d54d8d9ce32a3cceab4218ed2f6b7d35617cafe9adf84e43919cb"
"checksum markup5ever 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a614f301a2d5583894d1915a8c6bd2c473e80fba69263a60cf2677dbc49936f8"
"checksum matches 0.1.4 (registry+https://github.com/rust-lang/crates.io-index)" = "efd7622e3022e1a6eaa602c4cea8912254e5582c9c692e9167714182244801b1"
"checksum memchr 1.0.1 (registry+https://github.com/rust-lang/crates.io-index)" = "1dbccc0e46f1ea47b9f17e6d67c5a96bd27030519c519c9c91327e31275a47b4"
"checksum metadeps 1.1.1 (registry+https://github.com/rust-lang/crates.io-index)" = "829fffe7ea1d747e23f64be972991bc516b2f1ac2ae4a3b33d8bea150c410151"
@ -3606,4 +3601,4 @@ dependencies = [
"checksum xdg 2.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a66b7c2281ebde13cf4391d70d4c7e5946c3c25e72a7b859ca8f677dcd0b0c61"
"checksum xi-unicode 0.1.0 (registry+https://github.com/rust-lang/crates.io-index)" = "12ea8eda4b1eb72f02d148402e23832d56a33f55d8c1b2d5bcdde91d79d47cb1"
"checksum xml-rs 0.3.5 (registry+https://github.com/rust-lang/crates.io-index)" = "f2b15eed12692bd59d15e98ee7f8dc8408465b992d8ddb4d1672c24865132ec7"
"checksum xml5ever 0.5.0 (registry+https://github.com/rust-lang/crates.io-index)" = "a1aae5379a4a7ffb580300bb725696ce238bec993a7bad872ec09ea00ec1c4a5"
"checksum xml5ever 0.6.0 (registry+https://github.com/rust-lang/crates.io-index)" = "b5bbbde15cfe438463d4e48dc0c752e427a29766d144e3304594ad0c5813cbf9"

Просмотреть файл

@ -20,7 +20,7 @@ fnv = "1.0"
gfx = {path = "../gfx"}
gfx_traits = {path = "../gfx_traits"}
heapsize = "0.3.0"
html5ever-atoms = "0.3"
html5ever = "0.16"
ipc-channel = "0.7"
libc = "0.2"
log = "0.3.5"

Просмотреть файл

@ -22,7 +22,7 @@ extern crate fnv;
extern crate gfx;
extern crate gfx_traits;
extern crate heapsize;
#[macro_use] extern crate html5ever_atoms;
#[macro_use] extern crate html5ever;
extern crate ipc_channel;
extern crate libc;
#[macro_use]

Просмотреть файл

@ -46,8 +46,7 @@ fnv = "1.0"
gfx_traits = {path = "../gfx_traits"}
heapsize = "0.3.6"
heapsize_derive = "0.1"
html5ever = {version = "0.15", features = ["heap_size", "unstable"]}
html5ever-atoms = {version = "0.3", features = ["heap_size"]}
html5ever = {version = "0.16", features = ["heap_size", "unstable"]}
hyper = "0.10"
hyper_serde = "0.6"
image = "0.12"
@ -88,7 +87,7 @@ time = "0.1.12"
unicode-segmentation = "1.1.0"
url = {version = "1.2", features = ["heap_size", "query_encoding"]}
uuid = {version = "0.4", features = ["v4"]}
xml5ever = {version = "0.5", features = ["unstable"]}
xml5ever = {version = "0.6", features = ["unstable"]}
webrender_traits = {git = "https://github.com/servo/webrender", features = ["ipc"]}
webvr = {path = "../webvr"}
webvr_traits = {path = "../webvr_traits"}

Просмотреть файл

@ -13,7 +13,7 @@ use dom::element::{AttributeMutation, Element};
use dom::virtualmethods::vtable_for;
use dom::window::Window;
use dom_struct::dom_struct;
use html5ever_atoms::{Prefix, LocalName, Namespace};
use html5ever::{Prefix, LocalName, Namespace};
use servo_atoms::Atom;
use std::borrow::ToOwned;
use std::cell::Ref;

Просмотреть файл

@ -4,7 +4,7 @@
//! The `ByteString` struct.
use html5ever_atoms::{LocalName, Namespace};
use html5ever::{LocalName, Namespace};
use servo_atoms::Atom;
use std::ascii::AsciiExt;
use std::borrow::{Borrow, Cow, ToOwned};

Просмотреть файл

@ -47,8 +47,8 @@ use euclid::{Matrix2D, Matrix4D, Point2D};
use euclid::length::Length as EuclidLength;
use euclid::rect::Rect;
use euclid::size::Size2D;
use html5ever::tokenizer::buffer_queue::BufferQueue;
use html5ever_atoms::{Prefix, LocalName, Namespace, QualName};
use html5ever::{Prefix, LocalName, Namespace, QualName};
use html5ever::buffer_queue::BufferQueue;
use hyper::header::Headers;
use hyper::method::Method;
use hyper::mime::Mime;

Просмотреть файл

@ -6,7 +6,7 @@
use dom::bindings::error::{Error, ErrorResult, Fallible};
use dom::bindings::str::DOMString;
use html5ever_atoms::{Prefix, LocalName, Namespace};
use html5ever::{Prefix, LocalName, Namespace};
/// Validate a qualified name. See https://dom.spec.whatwg.org/#validate for details.
pub fn validate_qualified_name(qualified_name: &str) -> ErrorResult {

Просмотреть файл

@ -77,7 +77,7 @@ use dom::htmlulistelement::HTMLUListElement;
use dom::htmlunknownelement::HTMLUnknownElement;
use dom::htmlvideoelement::HTMLVideoElement;
use dom::svgsvgelement::SVGSVGElement;
use html5ever_atoms::{Prefix, QualName};
use html5ever::QualName;
use servo_config::prefs::PREFS;
fn create_svg_element(name: QualName,
@ -274,13 +274,12 @@ fn create_html_element(name: QualName,
}
pub fn create_element(name: QualName,
prefix: Option<Prefix>,
document: &Document,
creator: ElementCreator)
-> Root<Element> {
// FIXME(ajeffrey): Convert directly from Prefix to DOMString.
let prefix = prefix.map(|p| DOMString::from(&*p));
let prefix = name.prefix.as_ref().map(|p| DOMString::from(&**p));
match name.ns {
ns!(html) => create_html_element(name, prefix, document, creator),

Просмотреть файл

@ -93,7 +93,7 @@ use dom_struct::dom_struct;
use encoding::EncodingRef;
use encoding::all::UTF_8;
use euclid::point::Point2D;
use html5ever_atoms::{LocalName, QualName};
use html5ever::{LocalName, QualName};
use hyper::header::{Header, SetCookie};
use hyper_serde::Serde;
use ipc_channel::ipc::{self, IpcSender};
@ -2733,7 +2733,7 @@ impl DocumentMethods for Document {
-> Root<HTMLCollection> {
let ns = namespace_from_domstring(maybe_ns);
let local = LocalName::from(tag_name);
let qname = QualName::new(ns, local);
let qname = QualName::new(None, ns, local);
match self.tagns_map.borrow_mut().entry(qname.clone()) {
Occupied(entry) => Root::from_ref(entry.get()),
Vacant(entry) => {
@ -2782,8 +2782,8 @@ impl DocumentMethods for Document {
ns!()
};
let name = QualName::new(ns, LocalName::from(local_name));
Ok(Element::create(name, None, self, ElementCreator::ScriptCreated))
let name = QualName::new(None, ns, LocalName::from(local_name));
Ok(Element::create(name, self, ElementCreator::ScriptCreated))
}
// https://dom.spec.whatwg.org/#dom-document-createelementns
@ -2793,8 +2793,8 @@ impl DocumentMethods for Document {
-> Fallible<Root<Element>> {
let (namespace, prefix, local_name) = try!(validate_and_extract(namespace,
&qualified_name));
let name = QualName::new(namespace, local_name);
Ok(Element::create(name, prefix, self, ElementCreator::ScriptCreated))
let name = QualName::new(prefix, namespace, local_name);
Ok(Element::create(name, self, ElementCreator::ScriptCreated))
}
// https://dom.spec.whatwg.org/#dom-document-createattribute
@ -3047,8 +3047,8 @@ impl DocumentMethods for Document {
match elem {
Some(elem) => Root::upcast::<Node>(elem),
None => {
let name = QualName::new(ns!(svg), local_name!("title"));
let elem = Element::create(name, None, self, ElementCreator::ScriptCreated);
let name = QualName::new(None, ns!(svg), local_name!("title"));
let elem = Element::create(name, self, ElementCreator::ScriptCreated);
let parent = root.upcast::<Node>();
let child = elem.upcast::<Node>();
parent.InsertBefore(child, parent.GetFirstChild().r())
@ -3064,9 +3064,8 @@ impl DocumentMethods for Document {
None => {
match self.GetHead() {
Some(head) => {
let name = QualName::new(ns!(html), local_name!("title"));
let name = QualName::new(None, ns!(html), local_name!("title"));
let elem = Element::create(name,
None,
self,
ElementCreator::ScriptCreated);
head.upcast::<Node>()

Просмотреть файл

@ -12,7 +12,7 @@ use dom::bindings::str::DOMString;
use dom::element::Element;
use dom::node::window_from_node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use servo_atoms::Atom;
use style::str::HTML_SPACE_CHARACTERS;

Просмотреть файл

@ -75,11 +75,11 @@ use dom::validation::Validatable;
use dom::virtualmethods::{VirtualMethods, vtable_for};
use dom::window::ReflowReason;
use dom_struct::dom_struct;
use html5ever::{Prefix, LocalName, Namespace, QualName};
use html5ever::serialize;
use html5ever::serialize::SerializeOpts;
use html5ever::serialize::TraversalScope;
use html5ever::serialize::TraversalScope::{ChildrenOnly, IncludeNode};
use html5ever_atoms::{Prefix, LocalName, Namespace, QualName};
use js::jsapi::{HandleValue, JSAutoCompartment};
use net_traits::request::CorsSettings;
use ref_filter_map::ref_filter_map;
@ -195,10 +195,10 @@ impl<'a> TryFrom<&'a str> for AdjacentPosition {
// Element methods
//
impl Element {
pub fn create(name: QualName, prefix: Option<Prefix>,
pub fn create(name: QualName,
document: &Document, creator: ElementCreator)
-> Root<Element> {
create_element(name, prefix, document, creator)
create_element(name, document, creator)
}
pub fn new_inherited(local_name: LocalName,
@ -1955,8 +1955,8 @@ impl ElementMethods for Element {
// Step 4.
NodeTypeId::DocumentFragment => {
let body_elem = Element::create(QualName::new(ns!(html), local_name!("body")),
None, &context_document,
let body_elem = Element::create(QualName::new(None, ns!(html), local_name!("body")),
&context_document,
ElementCreator::ScriptCreated);
Root::upcast(body_elem)
},

Просмотреть файл

@ -17,7 +17,7 @@ use dom::file::File;
use dom::globalscope::GlobalScope;
use dom::htmlformelement::{HTMLFormElement, FormDatumValue, FormDatum};
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use std::collections::HashMap;
use std::collections::hash_map::Entry::{Occupied, Vacant};
use std::iter;

Просмотреть файл

@ -25,7 +25,7 @@ use dom::node::{Node, document_from_node};
use dom::urlhelper::UrlHelper;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use net_traits::ReferrerPolicy;
use num_traits::ToPrimitive;
use script_traits::MozBrowserEvent;

Просмотреть файл

@ -12,7 +12,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::attr::AttrValue;
#[dom_struct]

Просмотреть файл

@ -20,7 +20,7 @@ use dom::node::{Node, document_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use euclid::point::Point2D;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use net_traits::ReferrerPolicy;
use std::default::Default;
use std::f32;

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlmediaelement::HTMLMediaElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLAudioElement {

Просмотреть файл

@ -14,7 +14,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::{Node, UnbindContext, document_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use servo_url::ServoUrl;
use style::attr::AttrValue;

Просмотреть файл

@ -18,7 +18,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::{Node, document_from_node, window_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use script_traits::ScriptMsg as ConstellationMsg;
use servo_url::ServoUrl;
use style::attr::AttrValue;

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLBRElement {

Просмотреть файл

@ -24,7 +24,7 @@ use dom::validation::Validatable;
use dom::validitystate::{ValidityState, ValidationFlags};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use std::cell::Cell;
use std::default::Default;
use style::element_state::*;

Просмотреть файл

@ -27,7 +27,7 @@ use dom::virtualmethods::VirtualMethods;
use dom::webglrenderingcontext::{LayoutCanvasWebGLRenderingContextHelpers, WebGLRenderingContext};
use dom_struct::dom_struct;
use euclid::size::Size2D;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use image::ColorType;
use image::png::PNGEncoder;
use ipc_channel::ipc::{self, IpcSender};

Просмотреть файл

@ -14,7 +14,7 @@ use dom::element::Element;
use dom::node::Node;
use dom::window::Window;
use dom_struct::dom_struct;
use html5ever_atoms::{LocalName, QualName};
use html5ever::{LocalName, QualName};
use servo_atoms::Atom;
use std::cell::Cell;
use style::str::split_html_space_chars;
@ -164,7 +164,7 @@ impl HTMLCollection {
maybe_ns: Option<DOMString>) -> Root<HTMLCollection> {
let local = LocalName::from(tag);
let ns = namespace_from_domstring(maybe_ns);
let qname = QualName::new(ns, local);
let qname = QualName::new(None, ns, local);
HTMLCollection::by_qual_tag_name(window, root, qname)
}

Просмотреть файл

@ -10,7 +10,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLDataElement {

Просмотреть файл

@ -14,7 +14,7 @@ use dom::htmlelement::HTMLElement;
use dom::htmloptionelement::HTMLOptionElement;
use dom::node::{Node, window_from_node};
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLDataListElement {

Просмотреть файл

@ -16,7 +16,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::{Node, window_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use script_thread::Runnable;
use std::cell::Cell;
use task_source::TaskSource;

Просмотреть файл

@ -14,7 +14,7 @@ use dom::eventtarget::EventTarget;
use dom::htmlelement::HTMLElement;
use dom::node::{Node, window_from_node};
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLDialogElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLDirectoryElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLDivElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLDListElement {

Просмотреть файл

@ -30,7 +30,7 @@ use dom::node::{document_from_node, window_from_node};
use dom::nodelist::NodeList;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use std::ascii::AsciiExt;
use std::borrow::ToOwned;
use std::default::Default;

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLEmbedElement {

Просмотреть файл

@ -18,7 +18,7 @@ use dom::node::{Node, window_from_node};
use dom::validitystate::ValidityState;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use std::default::Default;
use style::element_state::*;

Просмотреть файл

@ -14,7 +14,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use servo_atoms::Atom;
use style::attr::AttrValue;
use style::str::{HTML_SPACE_CHARACTERS, read_numbers};

Просмотреть файл

@ -45,7 +45,7 @@ use dom_struct::dom_struct;
use encoding::EncodingRef;
use encoding::all::UTF_8;
use encoding::label::encoding_from_whatwg_label;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use hyper::header::{Charset, ContentDisposition, ContentType, DispositionParam, DispositionType};
use hyper::method::Method;
use msg::constellation_msg::PipelineId;

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLFrameElement {

Просмотреть файл

@ -12,7 +12,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::{Node, document_from_node};
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLFrameSetElement {

Просмотреть файл

@ -15,7 +15,7 @@ use dom::node::{Node, document_from_node};
use dom::userscripts::load_script;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLHeadElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[derive(JSTraceable, HeapSizeOf)]
pub enum HeadingLevel {

Просмотреть файл

@ -13,7 +13,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::attr::{AttrValue, LengthOrPercentageOrAuto};
#[dom_struct]

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLHtmlElement {

Просмотреть файл

@ -36,7 +36,7 @@ use dom::node::{Node, NodeDamage, UnbindContext, document_from_node, window_from
use dom::virtualmethods::VirtualMethods;
use dom::window::{ReflowReason, Window};
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use ipc_channel::ipc;
use js::jsapi::{JSAutoCompartment, JSContext, MutableHandleValue};
use js::jsval::{NullValue, UndefinedValue};

Просмотреть файл

@ -35,7 +35,7 @@ use dom::virtualmethods::VirtualMethods;
use dom::window::Window;
use dom_struct::dom_struct;
use euclid::point::Point2D;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use ipc_channel::ipc;
use ipc_channel::router::ROUTER;
use net_traits::{FetchResponseListener, FetchMetadata, NetworkError, FetchResponseMsg};

Просмотреть файл

@ -37,7 +37,7 @@ use dom::validation::Validatable;
use dom::validitystate::ValidationFlags;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use ipc_channel::ipc::{self, IpcSender};
use mime_guess;
use net_traits::{CoreResourceMsg, IpcSend};

Просмотреть файл

@ -18,7 +18,7 @@ use dom::htmlformelement::{FormControl, FormControlElementHelpers, HTMLFormEleme
use dom::node::{document_from_node, Node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::attr::AttrValue;
#[dom_struct]

Просмотреть файл

@ -16,7 +16,7 @@ use dom::htmlformelement::{HTMLFormElement, FormControl};
use dom::node::{Node, UnbindContext};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLLegendElement {

Просмотреть файл

@ -12,7 +12,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::attr::AttrValue;
#[dom_struct]

Просмотреть файл

@ -22,7 +22,7 @@ use dom::node::{Node, UnbindContext, document_from_node, window_from_node};
use dom::stylesheet::StyleSheet as DOMStyleSheet;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use net_traits::ReferrerPolicy;
use script_layout_interface::message::Msg;
use script_traits::{MozBrowserEvent, ScriptMsg as ConstellationMsg};

Просмотреть файл

@ -11,7 +11,7 @@ use dom::htmlareaelement::HTMLAreaElement;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLMapElement {

Просмотреть файл

@ -28,7 +28,7 @@ use dom::mediaerror::MediaError;
use dom::node::{window_from_node, document_from_node, Node, UnbindContext};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use ipc_channel::ipc;
use ipc_channel::router::ROUTER;
use net_traits::{FetchResponseListener, FetchMetadata, Metadata, NetworkError};

Просмотреть файл

@ -18,7 +18,7 @@ use dom::htmlheadelement::HTMLHeadElement;
use dom::node::{Node, UnbindContext, document_from_node, window_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use servo_config::prefs::PREFS;
use std::ascii::AsciiExt;
use std::sync::atomic::AtomicBool;

Просмотреть файл

@ -11,7 +11,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom::nodelist::NodeList;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLMeterElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLModElement {

Просмотреть файл

@ -18,7 +18,7 @@ use dom::validation::Validatable;
use dom::validitystate::{ValidityState, ValidationFlags};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use net_traits::image::base::Image;
use std::default::Default;
use style::stylearc::Arc;

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLOListElement {

Просмотреть файл

@ -15,7 +15,7 @@ use dom::htmloptionelement::HTMLOptionElement;
use dom::node::Node;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::element_state::*;
#[dom_struct]

Просмотреть файл

@ -23,7 +23,7 @@ use dom::node::{Node, UnbindContext};
use dom::text::Text;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use std::cell::Cell;
use style::element_state::*;
use style::str::{split_html_space_chars, str_join};

Просмотреть файл

@ -17,7 +17,7 @@ use dom::nodelist::NodeList;
use dom::validitystate::ValidityState;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLOutputElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLParagraphElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLParamElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLPreElement {

Просмотреть файл

@ -11,7 +11,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom::nodelist::NodeList;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLProgressElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLQuoteElement {

Просмотреть файл

@ -26,7 +26,7 @@ use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use encoding::label::encoding_from_whatwg_label;
use encoding::types::{DecoderTrap, EncodingRef};
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use ipc_channel::ipc;
use ipc_channel::router::ROUTER;
use js::jsval::UndefinedValue;

Просмотреть файл

@ -31,7 +31,7 @@ use dom::validation::Validatable;
use dom::validitystate::{ValidityState, ValidationFlags};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use std::default::Default;
use std::iter;
use style::attr::AttrValue;

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLSourceElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLSpanElement {

Просмотреть файл

@ -19,7 +19,7 @@ use dom::node::{ChildrenMutation, Node, UnbindContext, document_from_node, windo
use dom::stylesheet::StyleSheet as DOMStyleSheet;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use net_traits::ReferrerPolicy;
use script_layout_interface::message::Msg;
use std::cell::Cell;

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLTableCaptionElement {

Просмотреть файл

@ -15,7 +15,7 @@ use dom::htmltablerowelement::HTMLTableRowElement;
use dom::node::Node;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::attr::{AttrValue, LengthOrPercentageOrAuto};
const DEFAULT_COLSPAN: u32 = 1;

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLTableColElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmltablecellelement::HTMLTableCellElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLTableDataCellElement {

Просмотреть файл

@ -23,7 +23,7 @@ use dom::htmltablesectionelement::HTMLTableSectionElement;
use dom::node::{Node, document_from_node, window_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use std::cell::Cell;
use style::attr::{AttrValue, LengthOrPercentageOrAuto, parse_unsigned_integer};

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmltablecellelement::HTMLTableCellElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLTableHeaderCellElement {

Просмотреть файл

@ -22,7 +22,7 @@ use dom::htmltablesectionelement::HTMLTableSectionElement;
use dom::node::{Node, window_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::attr::AttrValue;
#[derive(JSTraceable)]

Просмотреть файл

@ -17,7 +17,7 @@ use dom::htmltablerowelement::HTMLTableRowElement;
use dom::node::{Node, window_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::attr::AttrValue;
#[dom_struct]

Просмотреть файл

@ -15,7 +15,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::{CloneChildrenFlag, Node, document_from_node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLTemplateElement {

Просмотреть файл

@ -26,7 +26,7 @@ use dom::nodelist::NodeList;
use dom::validation::Validatable;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use ipc_channel::ipc::IpcSender;
use script_traits::ScriptMsg as ConstellationMsg;
use std::cell::Cell;

Просмотреть файл

@ -10,7 +10,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLTimeElement {

Просмотреть файл

@ -13,7 +13,7 @@ use dom::htmlelement::HTMLElement;
use dom::node::{ChildrenMutation, Node};
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLTitleElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLTrackElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLUListElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlelement::HTMLElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLUnknownElement {

Просмотреть файл

@ -9,7 +9,7 @@ use dom::document::Document;
use dom::htmlmediaelement::HTMLMediaElement;
use dom::node::Node;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
#[dom_struct]
pub struct HTMLVideoElement {

Просмотреть файл

@ -14,7 +14,7 @@ use dom::bindings::xmlname::namespace_from_domstring;
use dom::element::Element;
use dom::window::Window;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use std::ascii::AsciiExt;
#[dom_struct]

Просмотреть файл

@ -58,7 +58,7 @@ use euclid::point::Point2D;
use euclid::rect::Rect;
use euclid::size::Size2D;
use heapsize::{HeapSizeOf, heap_size_of};
use html5ever_atoms::{Prefix, Namespace, QualName};
use html5ever::{Prefix, Namespace, QualName};
use js::jsapi::{JSContext, JSObject, JSRuntime};
use libc::{self, c_void, uintptr_t};
use msg::constellation_msg::PipelineId;
@ -1749,11 +1749,11 @@ impl Node {
NodeTypeId::Element(..) => {
let element = node.downcast::<Element>().unwrap();
let name = QualName {
prefix: element.prefix().map(|p| Prefix::from(&**p)),
ns: element.namespace().clone(),
local: element.local_name().clone()
};
let element = Element::create(name,
element.prefix().map(|p| Prefix::from(&**p)),
&document, ElementCreator::ScriptCreated);
Root::upcast::<Node>(element)
},

Просмотреть файл

@ -5,38 +5,28 @@
#![allow(unrooted_must_root)]
use dom::bindings::codegen::Bindings::HTMLTemplateElementBinding::HTMLTemplateElementMethods;
use dom::bindings::codegen::Bindings::NodeBinding::NodeMethods;
use dom::bindings::inheritance::{Castable, CharacterDataTypeId, NodeTypeId};
use dom::bindings::js::{JS, Root};
use dom::bindings::str::DOMString;
use dom::bindings::trace::JSTraceable;
use dom::characterdata::CharacterData;
use dom::comment::Comment;
use dom::document::Document;
use dom::documenttype::DocumentType;
use dom::element::{Element, ElementCreator};
use dom::htmlformelement::{FormControlElementHelpers, HTMLFormElement};
use dom::element::Element;
use dom::htmlscriptelement::HTMLScriptElement;
use dom::htmltemplateelement::HTMLTemplateElement;
use dom::node::Node;
use dom::processinginstruction::ProcessingInstruction;
use dom::virtualmethods::vtable_for;
use html5ever::Attribute;
use dom::servoparser::Sink;
use html5ever::QualName;
use html5ever::serialize::{AttrRef, Serializable, Serializer};
use html5ever::buffer_queue::BufferQueue;
use html5ever::serialize::{AttrRef, Serialize, Serializer};
use html5ever::serialize::TraversalScope;
use html5ever::serialize::TraversalScope::{ChildrenOnly, IncludeNode};
use html5ever::tendril::StrTendril;
use html5ever::tokenizer::{Tokenizer as HtmlTokenizer, TokenizerOpts, TokenizerResult};
use html5ever::tokenizer::buffer_queue::BufferQueue;
use html5ever::tree_builder::{NodeOrText, QuirksMode};
use html5ever::tree_builder::{Tracer as HtmlTracer, TreeBuilder, TreeBuilderOpts, TreeSink};
use html5ever::tree_builder::{Tracer as HtmlTracer, TreeBuilder, TreeBuilderOpts};
use js::jsapi::JSTracer;
use servo_url::ServoUrl;
use std::ascii::AsciiExt;
use std::borrow::Cow;
use std::io::{self, Write};
use style::context::QuirksMode as ServoQuirksMode;
use std::io;
#[derive(HeapSizeOf, JSTraceable)]
#[must_root]
@ -55,6 +45,7 @@ impl Tokenizer {
base_url: url,
document: JS::from_ref(document),
current_line: 1,
script: Default::default(),
};
let options = TreeBuilderOpts {
@ -124,179 +115,18 @@ unsafe impl JSTraceable for HtmlTokenizer<TreeBuilder<JS<Node>, Sink>> {
}
}
#[derive(JSTraceable, HeapSizeOf)]
#[must_root]
struct Sink {
base_url: ServoUrl,
document: JS<Document>,
current_line: u64,
}
impl TreeSink for Sink {
type Output = Self;
fn finish(self) -> Self { self }
type Handle = JS<Node>;
fn get_document(&mut self) -> JS<Node> {
JS::from_ref(self.document.upcast())
}
fn get_template_contents(&mut self, target: JS<Node>) -> JS<Node> {
let template = target.downcast::<HTMLTemplateElement>()
.expect("tried to get template contents of non-HTMLTemplateElement in HTML parsing");
JS::from_ref(template.Content().upcast())
}
fn same_node(&self, x: JS<Node>, y: JS<Node>) -> bool {
x == y
}
fn elem_name(&self, target: JS<Node>) -> QualName {
let elem = target.downcast::<Element>()
.expect("tried to get name of non-Element in HTML parsing");
QualName {
ns: elem.namespace().clone(),
local: elem.local_name().clone(),
}
}
fn same_tree(&self, x: JS<Node>, y: JS<Node>) -> bool {
let x = x.downcast::<Element>().expect("Element node expected");
let y = y.downcast::<Element>().expect("Element node expected");
x.is_in_same_home_subtree(y)
}
fn create_element(&mut self, name: QualName, attrs: Vec<Attribute>)
-> JS<Node> {
let elem = Element::create(name, None, &*self.document,
ElementCreator::ParserCreated(self.current_line));
for attr in attrs {
elem.set_attribute_from_parser(attr.name, DOMString::from(String::from(attr.value)), None);
}
JS::from_ref(elem.upcast())
}
fn create_comment(&mut self, text: StrTendril) -> JS<Node> {
let comment = Comment::new(DOMString::from(String::from(text)), &*self.document);
JS::from_ref(comment.upcast())
}
fn has_parent_node(&self, node: JS<Node>) -> bool {
node.GetParentNode().is_some()
}
fn associate_with_form(&mut self, target: JS<Node>, form: JS<Node>) {
let node = target;
let form = Root::downcast::<HTMLFormElement>(Root::from_ref(&*form))
.expect("Owner must be a form element");
let elem = node.downcast::<Element>();
let control = elem.as_ref().and_then(|e| e.as_maybe_form_control());
if let Some(control) = control {
control.set_form_owner_from_parser(&form);
} else {
// TODO remove this code when keygen is implemented.
assert!(node.NodeName() == "KEYGEN", "Unknown form-associatable element");
}
}
fn append_before_sibling(&mut self,
sibling: JS<Node>,
new_node: NodeOrText<JS<Node>>) {
let parent = sibling.GetParentNode()
.expect("append_before_sibling called on node without parent");
super::insert(&parent, Some(&*sibling), new_node);
}
fn parse_error(&mut self, msg: Cow<'static, str>) {
debug!("Parse error: {}", msg);
}
fn set_quirks_mode(&mut self, mode: QuirksMode) {
let mode = match mode {
QuirksMode::Quirks => ServoQuirksMode::Quirks,
QuirksMode::LimitedQuirks => ServoQuirksMode::LimitedQuirks,
QuirksMode::NoQuirks => ServoQuirksMode::NoQuirks,
};
self.document.set_quirks_mode(mode);
}
fn append(&mut self, parent: JS<Node>, child: NodeOrText<JS<Node>>) {
super::insert(&parent, None, child);
}
fn append_doctype_to_document(&mut self, name: StrTendril, public_id: StrTendril,
system_id: StrTendril) {
let doc = &*self.document;
let doctype = DocumentType::new(
DOMString::from(String::from(name)), Some(DOMString::from(String::from(public_id))),
Some(DOMString::from(String::from(system_id))), doc);
doc.upcast::<Node>().AppendChild(doctype.upcast()).expect("Appending failed");
}
fn add_attrs_if_missing(&mut self, target: JS<Node>, attrs: Vec<Attribute>) {
let elem = target.downcast::<Element>()
.expect("tried to set attrs on non-Element in HTML parsing");
for attr in attrs {
elem.set_attribute_from_parser(attr.name, DOMString::from(String::from(attr.value)), None);
}
}
fn remove_from_parent(&mut self, target: JS<Node>) {
if let Some(ref parent) = target.GetParentNode() {
parent.RemoveChild(&*target).unwrap();
}
}
fn mark_script_already_started(&mut self, node: JS<Node>) {
let script = node.downcast::<HTMLScriptElement>();
script.map(|script| script.set_already_started(true));
}
fn reparent_children(&mut self, node: JS<Node>, new_parent: JS<Node>) {
while let Some(ref child) = node.GetFirstChild() {
new_parent.AppendChild(&child).unwrap();
}
}
/// https://html.spec.whatwg.org/multipage/#html-integration-point
/// Specifically, the <annotation-xml> cases.
fn is_mathml_annotation_xml_integration_point(&self, handle: JS<Node>) -> bool {
let elem = handle.downcast::<Element>().unwrap();
elem.get_attribute(&ns!(), &local_name!("encoding")).map_or(false, |attr| {
attr.value().eq_ignore_ascii_case("text/html")
|| attr.value().eq_ignore_ascii_case("application/xhtml+xml")
})
}
fn set_current_line(&mut self, line_number: u64) {
self.current_line = line_number;
}
fn pop(&mut self, node: JS<Node>) {
let node = Root::from_ref(&*node);
vtable_for(&node).pop();
}
}
impl<'a> Serializable for &'a Node {
fn serialize<'wr, Wr: Write>(&self, serializer: &mut Serializer<'wr, Wr>,
traversal_scope: TraversalScope) -> io::Result<()> {
impl<'a> Serialize for &'a Node {
fn serialize<S: Serializer>(&self, serializer: &mut S,
traversal_scope: TraversalScope) -> io::Result<()> {
let node = *self;
match (traversal_scope, node.type_id()) {
(_, NodeTypeId::Element(..)) => {
let elem = node.downcast::<Element>().unwrap();
let name = QualName::new(elem.namespace().clone(),
let name = QualName::new(None, elem.namespace().clone(),
elem.local_name().clone());
if traversal_scope == IncludeNode {
let attrs = elem.attrs().iter().map(|attr| {
let qname = QualName::new(attr.namespace().clone(),
let qname = QualName::new(None, attr.namespace().clone(),
attr.local_name().clone());
let value = attr.value().clone();
(qname, value)

Просмотреть файл

@ -6,27 +6,35 @@ use document_loader::{DocumentLoader, LoadType};
use dom::bindings::cell::DOMRefCell;
use dom::bindings::codegen::Bindings::DocumentBinding::{DocumentMethods, DocumentReadyState};
use dom::bindings::codegen::Bindings::HTMLImageElementBinding::HTMLImageElementMethods;
use dom::bindings::codegen::Bindings::HTMLTemplateElementBinding::HTMLTemplateElementMethods;
use dom::bindings::codegen::Bindings::NodeBinding::NodeMethods;
use dom::bindings::codegen::Bindings::ServoParserBinding;
use dom::bindings::inheritance::Castable;
use dom::bindings::js::{JS, Root, RootedReference};
use dom::bindings::js::{JS, MutNullableJS, Root, RootedReference};
use dom::bindings::refcounted::Trusted;
use dom::bindings::reflector::{Reflector, reflect_dom_object};
use dom::bindings::str::DOMString;
use dom::characterdata::CharacterData;
use dom::comment::Comment;
use dom::document::{Document, DocumentSource, HasBrowsingContext, IsHTMLDocument};
use dom::element::Element;
use dom::documenttype::DocumentType;
use dom::element::{Element, ElementCreator};
use dom::globalscope::GlobalScope;
use dom::htmlformelement::HTMLFormElement;
use dom::htmlformelement::{FormControlElementHelpers, HTMLFormElement};
use dom::htmlimageelement::HTMLImageElement;
use dom::htmlscriptelement::{HTMLScriptElement, ScriptResult};
use dom::htmltemplateelement::HTMLTemplateElement;
use dom::node::{Node, NodeSiblingIterator};
use dom::processinginstruction::ProcessingInstruction;
use dom::text::Text;
use dom::virtualmethods::vtable_for;
use dom_struct::dom_struct;
use encoding::all::UTF_8;
use encoding::types::{DecoderTrap, Encoding};
use html5ever::tokenizer::buffer_queue::BufferQueue;
use html5ever::tree_builder::NodeOrText;
use html5ever::{Attribute, QualName, ExpandedName};
use html5ever::buffer_queue::BufferQueue;
use html5ever::tendril::StrTendril;
use html5ever::tree_builder::{NodeOrText, TreeSink, NextParserState, QuirksMode, ElementFlags};
use hyper::header::ContentType;
use hyper::mime::{Mime, SubLevel, TopLevel};
use hyper_serde::Serde;
@ -40,8 +48,10 @@ use script_traits::DocumentActivity;
use servo_config::resource_files::read_resource_file;
use servo_url::ServoUrl;
use std::ascii::AsciiExt;
use std::borrow::Cow;
use std::cell::Cell;
use std::mem;
use style::context::QuirksMode as ServoQuirksMode;
mod html;
mod xml;
@ -671,3 +681,183 @@ fn insert(parent: &Node, reference_child: Option<&Node>, child: NodeOrText<JS<No
},
}
}
#[derive(JSTraceable, HeapSizeOf)]
#[must_root]
pub struct Sink {
base_url: ServoUrl,
document: JS<Document>,
current_line: u64,
script: MutNullableJS<HTMLScriptElement>,
}
#[allow(unrooted_must_root)] // FIXME: really?
impl TreeSink for Sink {
type Output = Self;
fn finish(self) -> Self { self }
type Handle = JS<Node>;
fn get_document(&mut self) -> JS<Node> {
JS::from_ref(self.document.upcast())
}
fn get_template_contents(&mut self, target: &JS<Node>) -> JS<Node> {
let template = target.downcast::<HTMLTemplateElement>()
.expect("tried to get template contents of non-HTMLTemplateElement in HTML parsing");
JS::from_ref(template.Content().upcast())
}
fn same_node(&self, x: &JS<Node>, y: &JS<Node>) -> bool {
x == y
}
fn elem_name<'a>(&self, target: &'a JS<Node>) -> ExpandedName<'a> {
let elem = target.downcast::<Element>()
.expect("tried to get name of non-Element in HTML parsing");
ExpandedName {
ns: elem.namespace(),
local: elem.local_name(),
}
}
fn same_tree(&self, x: &JS<Node>, y: &JS<Node>) -> bool {
let x = x.downcast::<Element>().expect("Element node expected");
let y = y.downcast::<Element>().expect("Element node expected");
x.is_in_same_home_subtree(y)
}
fn create_element(&mut self, name: QualName, attrs: Vec<Attribute>, _flags: ElementFlags)
-> JS<Node> {
let elem = Element::create(name, &*self.document,
ElementCreator::ParserCreated(self.current_line));
for attr in attrs {
elem.set_attribute_from_parser(attr.name, DOMString::from(String::from(attr.value)), None);
}
JS::from_ref(elem.upcast())
}
fn create_comment(&mut self, text: StrTendril) -> JS<Node> {
let comment = Comment::new(DOMString::from(String::from(text)), &*self.document);
JS::from_ref(comment.upcast())
}
fn create_pi(&mut self, target: StrTendril, data: StrTendril) -> JS<Node> {
let doc = &*self.document;
let pi = ProcessingInstruction::new(
DOMString::from(String::from(target)), DOMString::from(String::from(data)),
doc);
JS::from_ref(pi.upcast())
}
fn has_parent_node(&self, node: &JS<Node>) -> bool {
node.GetParentNode().is_some()
}
fn associate_with_form(&mut self, target: &JS<Node>, form: &JS<Node>) {
let node = target;
let form = Root::downcast::<HTMLFormElement>(Root::from_ref(&**form))
.expect("Owner must be a form element");
let elem = node.downcast::<Element>();
let control = elem.and_then(|e| e.as_maybe_form_control());
if let Some(control) = control {
control.set_form_owner_from_parser(&form);
} else {
// TODO remove this code when keygen is implemented.
assert!(node.NodeName() == "KEYGEN", "Unknown form-associatable element");
}
}
fn append_before_sibling(&mut self,
sibling: &JS<Node>,
new_node: NodeOrText<JS<Node>>) {
let parent = sibling.GetParentNode()
.expect("append_before_sibling called on node without parent");
insert(&parent, Some(&*sibling), new_node);
}
fn parse_error(&mut self, msg: Cow<'static, str>) {
debug!("Parse error: {}", msg);
}
fn set_quirks_mode(&mut self, mode: QuirksMode) {
let mode = match mode {
QuirksMode::Quirks => ServoQuirksMode::Quirks,
QuirksMode::LimitedQuirks => ServoQuirksMode::LimitedQuirks,
QuirksMode::NoQuirks => ServoQuirksMode::NoQuirks,
};
self.document.set_quirks_mode(mode);
}
fn append(&mut self, parent: &JS<Node>, child: NodeOrText<JS<Node>>) {
insert(&parent, None, child);
}
fn append_doctype_to_document(&mut self, name: StrTendril, public_id: StrTendril,
system_id: StrTendril) {
let doc = &*self.document;
let doctype = DocumentType::new(
DOMString::from(String::from(name)), Some(DOMString::from(String::from(public_id))),
Some(DOMString::from(String::from(system_id))), doc);
doc.upcast::<Node>().AppendChild(doctype.upcast()).expect("Appending failed");
}
fn add_attrs_if_missing(&mut self, target: &JS<Node>, attrs: Vec<Attribute>) {
let elem = target.downcast::<Element>()
.expect("tried to set attrs on non-Element in HTML parsing");
for attr in attrs {
elem.set_attribute_from_parser(attr.name, DOMString::from(String::from(attr.value)), None);
}
}
fn remove_from_parent(&mut self, target: &JS<Node>) {
if let Some(ref parent) = target.GetParentNode() {
parent.RemoveChild(&*target).unwrap();
}
}
fn mark_script_already_started(&mut self, node: &JS<Node>) {
let script = node.downcast::<HTMLScriptElement>();
script.map(|script| script.set_already_started(true));
}
fn complete_script(&mut self, node: &JS<Node>) -> NextParserState {
if let Some(script) = node.downcast() {
self.script.set(Some(script));
NextParserState::Suspend
} else {
NextParserState::Continue
}
}
fn reparent_children(&mut self, node: &JS<Node>, new_parent: &JS<Node>) {
while let Some(ref child) = node.GetFirstChild() {
new_parent.AppendChild(&child).unwrap();
}
}
/// https://html.spec.whatwg.org/multipage/#html-integration-point
/// Specifically, the <annotation-xml> cases.
fn is_mathml_annotation_xml_integration_point(&self, handle: &JS<Node>) -> bool {
let elem = handle.downcast::<Element>().unwrap();
elem.get_attribute(&ns!(), &local_name!("encoding")).map_or(false, |attr| {
attr.value().eq_ignore_ascii_case("text/html")
|| attr.value().eq_ignore_ascii_case("application/xhtml+xml")
})
}
fn set_current_line(&mut self, line_number: u64) {
self.current_line = line_number;
}
fn pop(&mut self, node: &JS<Node>) {
let node = Root::from_ref(&**node);
vtable_for(&node).pop();
}
}

Просмотреть файл

@ -4,29 +4,17 @@
#![allow(unrooted_must_root)]
use dom::bindings::codegen::Bindings::NodeBinding::NodeMethods;
use dom::bindings::inheritance::Castable;
use dom::bindings::js::{JS, MutNullableJS, Root};
use dom::bindings::str::DOMString;
use dom::bindings::js::{JS, Root};
use dom::bindings::trace::JSTraceable;
use dom::comment::Comment;
use dom::document::Document;
use dom::documenttype::DocumentType;
use dom::element::{Element, ElementCreator};
use dom::htmlscriptelement::HTMLScriptElement;
use dom::node::Node;
use dom::processinginstruction::ProcessingInstruction;
use dom::virtualmethods::vtable_for;
use html5ever::tokenizer::buffer_queue::BufferQueue;
use html5ever::tree_builder::{NodeOrText as H5eNodeOrText};
use html5ever_atoms::{Prefix, QualName};
use dom::servoparser::Sink;
use js::jsapi::JSTracer;
use servo_url::ServoUrl;
use std::borrow::Cow;
use xml5ever::tendril::StrTendril;
use xml5ever::tokenizer::{Attribute, QName, XmlTokenizer};
use xml5ever::tree_builder::{NextParserState, NodeOrText};
use xml5ever::tree_builder::{Tracer as XmlTracer, TreeSink, XmlTreeBuilder};
use xml5ever::buffer_queue::BufferQueue;
use xml5ever::tokenizer::XmlTokenizer;
use xml5ever::tree_builder::{Tracer as XmlTracer, XmlTreeBuilder};
#[derive(HeapSizeOf, JSTraceable)]
#[must_root]
@ -40,6 +28,7 @@ impl Tokenizer {
let sink = Sink {
base_url: url,
document: JS::from_ref(document),
current_line: 1,
script: Default::default(),
};
@ -86,7 +75,7 @@ unsafe impl JSTraceable for XmlTokenizer<XmlTreeBuilder<JS<Node>, Sink>> {
impl XmlTracer for Tracer {
type Handle = JS<Node>;
#[allow(unrooted_must_root)]
fn trace_handle(&self, node: JS<Node>) {
fn trace_handle(&self, node: &JS<Node>) {
unsafe { node.trace(self.0); }
}
}
@ -96,111 +85,3 @@ unsafe impl JSTraceable for XmlTokenizer<XmlTreeBuilder<JS<Node>, Sink>> {
tree_builder.sink().trace(trc);
}
}
#[derive(JSTraceable, HeapSizeOf)]
#[must_root]
struct Sink {
base_url: ServoUrl,
document: JS<Document>,
script: MutNullableJS<HTMLScriptElement>,
}
impl TreeSink for Sink {
type Output = Self;
type Handle = JS<Node>;
fn finish(self) -> Self {
self
}
fn parse_error(&mut self, msg: Cow<'static, str>) {
debug!("Parse error: {}", msg);
}
fn get_document(&mut self) -> JS<Node> {
JS::from_ref(self.document.upcast())
}
fn elem_name(&self, target: &JS<Node>) -> QName {
let elem = target.downcast::<Element>()
.expect("tried to get name of non-Element in XML parsing");
QName {
prefix: elem.prefix().map_or(namespace_prefix!(""), |p| Prefix::from(&**p)),
namespace_url: elem.namespace().clone(),
local: elem.local_name().clone(),
}
}
fn create_element(&mut self, name: QName, attrs: Vec<Attribute>)
-> JS<Node> {
let prefix = if name.prefix == namespace_prefix!("") { None } else { Some(name.prefix) };
let name = QualName {
ns: name.namespace_url,
local: name.local,
};
//TODO: Add ability to track lines to API of xml5ever
let elem = Element::create(name, prefix, &*self.document,
ElementCreator::ParserCreated(1));
for attr in attrs {
let name = QualName {
ns: attr.name.namespace_url,
local: attr.name.local,
};
elem.set_attribute_from_parser(name, DOMString::from(String::from(attr.value)), None);
}
JS::from_ref(elem.upcast())
}
fn create_comment(&mut self, text: StrTendril) -> JS<Node> {
let comment = Comment::new(DOMString::from(String::from(text)), &*self.document);
JS::from_ref(comment.upcast())
}
fn append(&mut self, parent: JS<Node>, child: NodeOrText<JS<Node>>) {
let child = match child {
NodeOrText::AppendNode(n) => H5eNodeOrText::AppendNode(n),
NodeOrText::AppendText(s) => H5eNodeOrText::AppendText(s),
};
super::insert(&*parent, None, child);
}
fn append_doctype_to_document(&mut self, name: StrTendril, public_id: StrTendril,
system_id: StrTendril) {
let doc = &*self.document;
let doctype = DocumentType::new(
DOMString::from(String::from(name)), Some(DOMString::from(String::from(public_id))),
Some(DOMString::from(String::from(system_id))), doc);
doc.upcast::<Node>().AppendChild(doctype.upcast()).expect("Appending failed");
}
fn create_pi(&mut self, target: StrTendril, data: StrTendril) -> JS<Node> {
let doc = &*self.document;
let pi = ProcessingInstruction::new(
DOMString::from(String::from(target)), DOMString::from(String::from(data)),
doc);
JS::from_ref(pi.upcast())
}
fn mark_script_already_started(&mut self, node: Self::Handle) {
let script = node.downcast::<HTMLScriptElement>();
if let Some(script) = script {
script.set_already_started(true);
}
}
fn complete_script(&mut self, node: Self::Handle) -> NextParserState {
if let Some(script) = node.downcast() {
self.script.set(Some(script));
NextParserState::Suspend
} else {
NextParserState::Continue
}
}
fn pop(&mut self, node: Self::Handle) {
let node = Root::from_ref(&*node);
vtable_for(&node).pop();
}
}

Просмотреть файл

@ -8,7 +8,7 @@ use dom::document::Document;
use dom::element::Element;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::element_state::ElementState;
#[dom_struct]

Просмотреть файл

@ -8,7 +8,7 @@ use dom::document::Document;
use dom::svgelement::SVGElement;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::element_state::ElementState;
#[dom_struct]

Просмотреть файл

@ -13,7 +13,7 @@ use dom::node::Node;
use dom::svggraphicselement::SVGGraphicsElement;
use dom::virtualmethods::VirtualMethods;
use dom_struct::dom_struct;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use script_layout_interface::SVGSVGData;
use style::attr::AttrValue;

Просмотреть файл

@ -51,7 +51,7 @@ use dom::htmltextareaelement::HTMLTextAreaElement;
use dom::htmltitleelement::HTMLTitleElement;
use dom::node::{ChildrenMutation, CloneChildrenFlag, Node, UnbindContext};
use dom::svgsvgelement::SVGSVGElement;
use html5ever_atoms::LocalName;
use html5ever::LocalName;
use style::attr::AttrValue;
/// Trait to allow DOM nodes to opt-in to overriding (or adding to) common

Просмотреть файл

@ -42,7 +42,7 @@ use dom::node::{CAN_BE_FRAGMENTED, DIRTY_ON_VIEWPORT_SIZE_CHANGE, HAS_DIRTY_DESC
use dom::node::{LayoutNodeHelpers, Node};
use dom::text::Text;
use gfx_traits::ByteIndex;
use html5ever_atoms::{LocalName, Namespace};
use html5ever::{LocalName, Namespace};
use msg::constellation_msg::PipelineId;
use range::Range;
use script_layout_interface::{HTMLCanvasData, LayoutNodeType, SVGSVGData, TrustedNodeAddress};

Просмотреть файл

@ -48,8 +48,7 @@ extern crate fnv;
extern crate gfx_traits;
extern crate heapsize;
#[macro_use] extern crate heapsize_derive;
extern crate html5ever;
#[macro_use] extern crate html5ever_atoms;
#[macro_use] extern crate html5ever;
#[macro_use]
extern crate hyper;
extern crate hyper_serde;

Просмотреть файл

@ -18,7 +18,7 @@ euclid = "0.11"
gfx_traits = {path = "../gfx_traits"}
heapsize = "0.3.0"
heapsize_derive = "0.1"
html5ever-atoms = "0.3"
html5ever = "0.16"
ipc-channel = "0.7"
libc = "0.2"
log = "0.3.5"

Просмотреть файл

@ -19,7 +19,7 @@ extern crate euclid;
extern crate gfx_traits;
extern crate heapsize;
#[macro_use] extern crate heapsize_derive;
#[macro_use] extern crate html5ever_atoms;
#[macro_use] extern crate html5ever;
extern crate ipc_channel;
extern crate libc;
#[macro_use]

Просмотреть файл

@ -10,7 +10,7 @@ use OpaqueStyleAndLayoutData;
use SVGSVGData;
use atomic_refcell::AtomicRefCell;
use gfx_traits::{ByteIndex, FragmentType, combine_id_with_fragment_type};
use html5ever_atoms::{Namespace, LocalName};
use html5ever::{Namespace, LocalName};
use msg::constellation_msg::PipelineId;
use range::Range;
use servo_url::ServoUrl;

Просмотреть файл

@ -16,7 +16,7 @@ doctest = false
gecko = ["nsstring_vendor", "rayon/unstable", "num_cpus"]
use_bindgen = ["bindgen", "regex"]
servo = ["serde/unstable", "serde", "serde_derive", "heapsize", "heapsize_derive",
"style_traits/servo", "servo_atoms", "servo_config", "html5ever-atoms",
"style_traits/servo", "servo_atoms", "servo_config", "html5ever",
"cssparser/heapsize", "cssparser/serde", "encoding", "smallvec/heapsizeof",
"rayon/unstable", "servo_url"]
testing = []
@ -35,7 +35,7 @@ euclid = "0.11"
fnv = "1.0"
heapsize = {version = "0.3.0", optional = true}
heapsize_derive = {version = "0.1", optional = true}
html5ever-atoms = {version = "0.3", optional = true}
html5ever = {version = "0.16", optional = true}
lazy_static = "0.2"
log = "0.3"
matches = "0.1"

Просмотреть файл

@ -50,7 +50,7 @@ extern crate fnv;
#[cfg(feature = "gecko")] #[macro_use] pub mod gecko_string_cache;
#[cfg(feature = "servo")] extern crate heapsize;
#[cfg(feature = "servo")] #[macro_use] extern crate heapsize_derive;
#[cfg(feature = "servo")] #[macro_use] extern crate html5ever_atoms;
#[cfg(feature = "servo")] #[macro_use] extern crate html5ever;
#[macro_use]
extern crate lazy_static;
#[macro_use]
@ -141,9 +141,9 @@ use style_traits::ToCss;
#[cfg(feature = "gecko")] pub use gecko_string_cache::Atom as LocalName;
#[cfg(feature = "servo")] pub use servo_atoms::Atom;
#[cfg(feature = "servo")] pub use html5ever_atoms::Prefix;
#[cfg(feature = "servo")] pub use html5ever_atoms::LocalName;
#[cfg(feature = "servo")] pub use html5ever_atoms::Namespace;
#[cfg(feature = "servo")] pub use html5ever::Prefix;
#[cfg(feature = "servo")] pub use html5ever::LocalName;
#[cfg(feature = "servo")] pub use html5ever::Namespace;
/// The CSS properties supported by the style system.
/// Generated from the properties.mako.rs template by build.rs

Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше