зеркало из https://github.com/mozilla/gecko-dev.git
servo: Merge #5677 - Update WHATWG links to use HTTPS (from frewsxcv:https); r=Ms2ger
Extracted this out of #5649 This commit was created with the following commands: ``` find . -iname "*.webidl" -type f -print0 | xargs -0 sed -i '' 's/http:\(.*\)whatwg.org/https:\1whatwg.org/g' ``` ``` find . -iname "*.rs" -type f -print0 | xargs -0 sed -i '' 's/http:\(.*\)whatwg.org/https:\1whatwg.org/g' ``` Source-Repo: https://github.com/servo/servo Source-Revision: 4997d3a112354a407365fede1ab1944834a2e13c
This commit is contained in:
Родитель
750e000989
Коммит
5c841a0070
|
@ -560,7 +560,7 @@ impl<'le> TElement<'le> for LayoutElement<'le> {
|
||||||
// FIXME: This is HTML only.
|
// FIXME: This is HTML only.
|
||||||
let node: &Node = NodeCast::from_actual(self.element);
|
let node: &Node = NodeCast::from_actual(self.element);
|
||||||
match node.type_id_for_layout() {
|
match node.type_id_for_layout() {
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/multipage/selectors.html#
|
// https://www.whatwg.org/specs/web-apps/current-work/multipage/selectors.html#
|
||||||
// selector-link
|
// selector-link
|
||||||
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLAnchorElement)) |
|
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLAnchorElement)) |
|
||||||
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLAreaElement)) |
|
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLAreaElement)) |
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
//! An implementation of the [CORS preflight cache](http://fetch.spec.whatwg.org/#cors-preflight-cache)
|
//! An implementation of the [CORS preflight cache](https://fetch.spec.whatwg.org/#cors-preflight-cache)
|
||||||
//! For now this library is XHR-specific.
|
//! For now this library is XHR-specific.
|
||||||
//! For stuff involving `<img>`, `<iframe>`, `<form>`, etc please check what
|
//! For stuff involving `<img>`, `<iframe>`, `<form>`, etc please check what
|
||||||
//! the request mode should be and compare with the fetch spec
|
//! the request mode should be and compare with the fetch spec
|
||||||
|
@ -74,24 +74,24 @@ pub struct CacheRequestDetails {
|
||||||
|
|
||||||
/// Trait for a generic CORS Cache
|
/// Trait for a generic CORS Cache
|
||||||
pub trait CORSCache {
|
pub trait CORSCache {
|
||||||
/// [Clear the cache](http://fetch.spec.whatwg.org/#concept-cache-clear)
|
/// [Clear the cache](https://fetch.spec.whatwg.org/#concept-cache-clear)
|
||||||
fn clear (&mut self, request: CacheRequestDetails);
|
fn clear (&mut self, request: CacheRequestDetails);
|
||||||
|
|
||||||
/// Remove old entries
|
/// Remove old entries
|
||||||
fn cleanup(&mut self);
|
fn cleanup(&mut self);
|
||||||
|
|
||||||
/// Returns true if an entry with a [matching header](http://fetch.spec.whatwg.org/#concept-cache-match-header) is found
|
/// Returns true if an entry with a [matching header](https://fetch.spec.whatwg.org/#concept-cache-match-header) is found
|
||||||
fn match_header(&mut self, request: CacheRequestDetails, header_name: &str) -> bool;
|
fn match_header(&mut self, request: CacheRequestDetails, header_name: &str) -> bool;
|
||||||
|
|
||||||
/// Updates max age if an entry for a [matching header](http://fetch.spec.whatwg.org/#concept-cache-match-header) is found.
|
/// Updates max age if an entry for a [matching header](https://fetch.spec.whatwg.org/#concept-cache-match-header) is found.
|
||||||
///
|
///
|
||||||
/// If not, it will insert an equivalent entry
|
/// If not, it will insert an equivalent entry
|
||||||
fn match_header_and_update(&mut self, request: CacheRequestDetails, header_name: &str, new_max_age: u32) -> bool;
|
fn match_header_and_update(&mut self, request: CacheRequestDetails, header_name: &str, new_max_age: u32) -> bool;
|
||||||
|
|
||||||
/// Returns true if an entry with a [matching method](http://fetch.spec.whatwg.org/#concept-cache-match-method) is found
|
/// Returns true if an entry with a [matching method](https://fetch.spec.whatwg.org/#concept-cache-match-method) is found
|
||||||
fn match_method(&mut self, request: CacheRequestDetails, method: Method) -> bool;
|
fn match_method(&mut self, request: CacheRequestDetails, method: Method) -> bool;
|
||||||
|
|
||||||
/// Updates max age if an entry for [a matching method](http://fetch.spec.whatwg.org/#concept-cache-match-method) is found.
|
/// Updates max age if an entry for [a matching method](https://fetch.spec.whatwg.org/#concept-cache-match-method) is found.
|
||||||
///
|
///
|
||||||
/// If not, it will insert an equivalent entry
|
/// If not, it will insert an equivalent entry
|
||||||
fn match_method_and_update(&mut self, request: CacheRequestDetails, method: Method, new_max_age: u32) -> bool;
|
fn match_method_and_update(&mut self, request: CacheRequestDetails, method: Method, new_max_age: u32) -> bool;
|
||||||
|
@ -132,7 +132,7 @@ impl BasicCORSCache {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl CORSCache for BasicCORSCache {
|
impl CORSCache for BasicCORSCache {
|
||||||
/// http://fetch.spec.whatwg.org/#concept-cache-clear
|
/// https://fetch.spec.whatwg.org/#concept-cache-clear
|
||||||
#[allow(dead_code)]
|
#[allow(dead_code)]
|
||||||
fn clear (&mut self, request: CacheRequestDetails) {
|
fn clear (&mut self, request: CacheRequestDetails) {
|
||||||
let BasicCORSCache(buf) = self.clone();
|
let BasicCORSCache(buf) = self.clone();
|
||||||
|
|
|
@ -10,7 +10,7 @@ use hyper::header::ContentType;
|
||||||
use fetch::cors_cache::CORSCache;
|
use fetch::cors_cache::CORSCache;
|
||||||
use fetch::response::Response;
|
use fetch::response::Response;
|
||||||
|
|
||||||
/// A [request context](http://fetch.spec.whatwg.org/#concept-request-context)
|
/// A [request context](https://fetch.spec.whatwg.org/#concept-request-context)
|
||||||
#[derive(Copy)]
|
#[derive(Copy)]
|
||||||
pub enum Context {
|
pub enum Context {
|
||||||
Audio, Beacon, CSPreport, Download, Embed, Eventsource,
|
Audio, Beacon, CSPreport, Download, Embed, Eventsource,
|
||||||
|
@ -20,7 +20,7 @@ pub enum Context {
|
||||||
Style, Track, Video, Worker, XMLHttpRequest, XSLT
|
Style, Track, Video, Worker, XMLHttpRequest, XSLT
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A [request context frame type](http://fetch.spec.whatwg.org/#concept-request-context-frame-type)
|
/// A [request context frame type](https://fetch.spec.whatwg.org/#concept-request-context-frame-type)
|
||||||
#[derive(Copy)]
|
#[derive(Copy)]
|
||||||
pub enum ContextFrameType {
|
pub enum ContextFrameType {
|
||||||
Auxiliary,
|
Auxiliary,
|
||||||
|
@ -29,14 +29,14 @@ pub enum ContextFrameType {
|
||||||
ContextNone
|
ContextNone
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A [referer](http://fetch.spec.whatwg.org/#concept-request-referrer)
|
/// A [referer](https://fetch.spec.whatwg.org/#concept-request-referrer)
|
||||||
pub enum Referer {
|
pub enum Referer {
|
||||||
RefererNone,
|
RefererNone,
|
||||||
Client,
|
Client,
|
||||||
RefererUrl(Url)
|
RefererUrl(Url)
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A [request mode](http://fetch.spec.whatwg.org/#concept-request-mode)
|
/// A [request mode](https://fetch.spec.whatwg.org/#concept-request-mode)
|
||||||
#[derive(Copy)]
|
#[derive(Copy)]
|
||||||
pub enum RequestMode {
|
pub enum RequestMode {
|
||||||
SameOrigin,
|
SameOrigin,
|
||||||
|
@ -45,7 +45,7 @@ pub enum RequestMode {
|
||||||
ForcedPreflightMode
|
ForcedPreflightMode
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Request [credentials mode](http://fetch.spec.whatwg.org/#concept-request-credentials-mode)
|
/// Request [credentials mode](https://fetch.spec.whatwg.org/#concept-request-credentials-mode)
|
||||||
#[derive(Copy)]
|
#[derive(Copy)]
|
||||||
pub enum CredentialsMode {
|
pub enum CredentialsMode {
|
||||||
Omit,
|
Omit,
|
||||||
|
@ -53,7 +53,7 @@ pub enum CredentialsMode {
|
||||||
Include
|
Include
|
||||||
}
|
}
|
||||||
|
|
||||||
/// [Response tainting](http://fetch.spec.whatwg.org/#concept-request-response-tainting)
|
/// [Response tainting](https://fetch.spec.whatwg.org/#concept-request-response-tainting)
|
||||||
#[derive(Copy)]
|
#[derive(Copy)]
|
||||||
pub enum ResponseTainting {
|
pub enum ResponseTainting {
|
||||||
Basic,
|
Basic,
|
||||||
|
@ -61,7 +61,7 @@ pub enum ResponseTainting {
|
||||||
Opaque
|
Opaque
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A [Request](http://fetch.spec.whatwg.org/#requests) as defined by the Fetch spec
|
/// A [Request](https://fetch.spec.whatwg.org/#requests) as defined by the Fetch spec
|
||||||
pub struct Request {
|
pub struct Request {
|
||||||
pub method: Method,
|
pub method: Method,
|
||||||
pub url: Url,
|
pub url: Url,
|
||||||
|
@ -117,7 +117,7 @@ impl Request {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// [Basic fetch](http://fetch.spec.whatwg.org#basic-fetch)
|
/// [Basic fetch](https://fetch.spec.whatwg.org#basic-fetch)
|
||||||
pub fn basic_fetch(&mut self) -> Response {
|
pub fn basic_fetch(&mut self) -> Response {
|
||||||
match &*self.url.scheme {
|
match &*self.url.scheme {
|
||||||
"about" => match self.url.non_relative_scheme_data() {
|
"about" => match self.url.non_relative_scheme_data() {
|
||||||
|
@ -142,7 +142,7 @@ impl Request {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// [HTTP fetch](http://fetch.spec.whatwg.org#http-fetch)
|
// [HTTP fetch](https://fetch.spec.whatwg.org#http-fetch)
|
||||||
pub fn http_fetch(&mut self, _cors_flag: bool, cors_preflight_flag: bool, _authentication_fetch_flag: bool) -> Response {
|
pub fn http_fetch(&mut self, _cors_flag: bool, cors_preflight_flag: bool, _authentication_fetch_flag: bool) -> Response {
|
||||||
let response = Response::new();
|
let response = Response::new();
|
||||||
// TODO: Service worker fetch
|
// TODO: Service worker fetch
|
||||||
|
|
|
@ -8,7 +8,7 @@ use hyper::header::Headers;
|
||||||
use std::ascii::AsciiExt;
|
use std::ascii::AsciiExt;
|
||||||
use std::sync::mpsc::Receiver;
|
use std::sync::mpsc::Receiver;
|
||||||
|
|
||||||
/// [Response type](http://fetch.spec.whatwg.org/#concept-response-type)
|
/// [Response type](https://fetch.spec.whatwg.org/#concept-response-type)
|
||||||
#[derive(Clone, PartialEq, Copy)]
|
#[derive(Clone, PartialEq, Copy)]
|
||||||
pub enum ResponseType {
|
pub enum ResponseType {
|
||||||
Basic,
|
Basic,
|
||||||
|
@ -18,7 +18,7 @@ pub enum ResponseType {
|
||||||
Opaque
|
Opaque
|
||||||
}
|
}
|
||||||
|
|
||||||
/// [Response termination reason](http://fetch.spec.whatwg.org/#concept-response-termination-reason)
|
/// [Response termination reason](https://fetch.spec.whatwg.org/#concept-response-termination-reason)
|
||||||
#[derive(Clone, Copy)]
|
#[derive(Clone, Copy)]
|
||||||
pub enum TerminationReason {
|
pub enum TerminationReason {
|
||||||
EndUserAbort,
|
EndUserAbort,
|
||||||
|
@ -49,7 +49,7 @@ pub struct ResponseLoader {
|
||||||
chan: Receiver<ResponseMsg>
|
chan: Receiver<ResponseMsg>
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A [Response](http://fetch.spec.whatwg.org/#concept-response) as defined by the Fetch spec
|
/// A [Response](https://fetch.spec.whatwg.org/#concept-response) as defined by the Fetch spec
|
||||||
#[derive(Clone)]
|
#[derive(Clone)]
|
||||||
pub struct Response {
|
pub struct Response {
|
||||||
pub response_type: ResponseType,
|
pub response_type: ResponseType,
|
||||||
|
@ -59,7 +59,7 @@ pub struct Response {
|
||||||
pub status: Option<StatusCode>,
|
pub status: Option<StatusCode>,
|
||||||
pub headers: Headers,
|
pub headers: Headers,
|
||||||
pub body: ResponseBody,
|
pub body: ResponseBody,
|
||||||
/// [Internal response](http://fetch.spec.whatwg.org/#concept-internal-response), only used if the Response is a filtered response
|
/// [Internal response](https://fetch.spec.whatwg.org/#concept-internal-response), only used if the Response is a filtered response
|
||||||
pub internal_response: Option<Box<Response>>,
|
pub internal_response: Option<Box<Response>>,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -250,7 +250,7 @@ reason: \"certificate verify failed\" }]";
|
||||||
if response.status.class() == StatusClass::Redirection {
|
if response.status.class() == StatusClass::Redirection {
|
||||||
match response.headers.get::<Location>() {
|
match response.headers.get::<Location>() {
|
||||||
Some(&Location(ref new_url)) => {
|
Some(&Location(ref new_url)) => {
|
||||||
// CORS (http://fetch.spec.whatwg.org/#http-fetch, status section, point 9, 10)
|
// CORS (https://fetch.spec.whatwg.org/#http-fetch, status section, point 9, 10)
|
||||||
match load_data.cors {
|
match load_data.cors {
|
||||||
Some(ref c) => {
|
Some(ref c) => {
|
||||||
if c.preflight {
|
if c.preflight {
|
||||||
|
|
|
@ -47,7 +47,7 @@ pub mod resource_task;
|
||||||
pub mod storage_task;
|
pub mod storage_task;
|
||||||
pub mod mime_classifier;
|
pub mod mime_classifier;
|
||||||
|
|
||||||
/// An implementation of the [Fetch spec](http://fetch.spec.whatwg.org/)
|
/// An implementation of the [Fetch spec](https://fetch.spec.whatwg.org/)
|
||||||
pub mod fetch {
|
pub mod fetch {
|
||||||
#![allow(dead_code, unused)] // XXXManishearth this is only temporary until the Fetch mod starts being used
|
#![allow(dead_code, unused)] // XXXManishearth this is only temporary until the Fetch mod starts being used
|
||||||
pub mod request;
|
pub mod request;
|
||||||
|
|
|
@ -128,7 +128,7 @@ impl Metadata {
|
||||||
content_type: None,
|
content_type: None,
|
||||||
charset: None,
|
charset: None,
|
||||||
headers: None,
|
headers: None,
|
||||||
// http://fetch.spec.whatwg.org/#concept-response-status-message
|
// https://fetch.spec.whatwg.org/#concept-response-status-message
|
||||||
status: Some(RawStatus(200, "OK".into_cow())),
|
status: Some(RawStatus(200, "OK".into_cow())),
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,12 +32,12 @@ pub struct CORSRequest {
|
||||||
pub mode: RequestMode,
|
pub mode: RequestMode,
|
||||||
pub method: Method,
|
pub method: Method,
|
||||||
pub headers: Headers,
|
pub headers: Headers,
|
||||||
/// CORS preflight flag (http://fetch.spec.whatwg.org/#concept-http-fetch)
|
/// CORS preflight flag (https://fetch.spec.whatwg.org/#concept-http-fetch)
|
||||||
/// Indicates that a CORS preflight request and/or cache check is to be performed
|
/// Indicates that a CORS preflight request and/or cache check is to be performed
|
||||||
pub preflight_flag: bool
|
pub preflight_flag: bool
|
||||||
}
|
}
|
||||||
|
|
||||||
/// http://fetch.spec.whatwg.org/#concept-request-mode
|
/// https://fetch.spec.whatwg.org/#concept-request-mode
|
||||||
/// This only covers some of the request modes. The
|
/// This only covers some of the request modes. The
|
||||||
/// `same-origin` and `no CORS` modes are unnecessary for XHR.
|
/// `same-origin` and `no CORS` modes are unnecessary for XHR.
|
||||||
#[derive(PartialEq, Copy, Clone)]
|
#[derive(PartialEq, Copy, Clone)]
|
||||||
|
@ -88,7 +88,7 @@ impl CORSRequest {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// http://fetch.spec.whatwg.org/#concept-http-fetch
|
/// https://fetch.spec.whatwg.org/#concept-http-fetch
|
||||||
/// This method assumes that the CORS flag is set
|
/// This method assumes that the CORS flag is set
|
||||||
/// This does not perform the full HTTP fetch, rather it handles part of the CORS filtering
|
/// This does not perform the full HTTP fetch, rather it handles part of the CORS filtering
|
||||||
/// if self.mode is ForcedPreflight, then the CORS-with-forced-preflight
|
/// if self.mode is ForcedPreflight, then the CORS-with-forced-preflight
|
||||||
|
@ -112,7 +112,7 @@ impl CORSRequest {
|
||||||
response
|
response
|
||||||
}
|
}
|
||||||
|
|
||||||
/// http://fetch.spec.whatwg.org/#cors-preflight-fetch
|
/// https://fetch.spec.whatwg.org/#cors-preflight-fetch
|
||||||
fn preflight_fetch(&self) -> CORSResponse {
|
fn preflight_fetch(&self) -> CORSResponse {
|
||||||
let error = CORSResponse::new_error();
|
let error = CORSResponse::new_error();
|
||||||
let mut cors_response = CORSResponse::new();
|
let mut cors_response = CORSResponse::new();
|
||||||
|
@ -159,7 +159,7 @@ impl CORSRequest {
|
||||||
_ => return error
|
_ => return error
|
||||||
}
|
}
|
||||||
cors_response.headers = response.headers.clone();
|
cors_response.headers = response.headers.clone();
|
||||||
// Substeps 1-3 (parsing rules: http://fetch.spec.whatwg.org/#http-new-header-syntax)
|
// Substeps 1-3 (parsing rules: https://fetch.spec.whatwg.org/#http-new-header-syntax)
|
||||||
let methods_substep4 = [self.method.clone()];
|
let methods_substep4 = [self.method.clone()];
|
||||||
let mut methods = match response.headers.get() {
|
let mut methods = match response.headers.get() {
|
||||||
Some(&AccessControlAllowMethods(ref v)) => v.as_slice(),
|
Some(&AccessControlAllowMethods(ref v)) => v.as_slice(),
|
||||||
|
@ -292,7 +292,7 @@ impl CORSCacheEntry {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl CORSCache {
|
impl CORSCache {
|
||||||
/// http://fetch.spec.whatwg.org/#concept-cache-clear
|
/// https://fetch.spec.whatwg.org/#concept-cache-clear
|
||||||
#[allow(dead_code)]
|
#[allow(dead_code)]
|
||||||
fn clear (&mut self, request: &CORSRequest) {
|
fn clear (&mut self, request: &CORSRequest) {
|
||||||
let CORSCache(buf) = self.clone();
|
let CORSCache(buf) = self.clone();
|
||||||
|
@ -308,7 +308,7 @@ impl CORSCache {
|
||||||
*self = CORSCache(new_buf);
|
*self = CORSCache(new_buf);
|
||||||
}
|
}
|
||||||
|
|
||||||
/// http://fetch.spec.whatwg.org/#concept-cache-match-header
|
/// https://fetch.spec.whatwg.org/#concept-cache-match-header
|
||||||
fn find_entry_by_header<'a>(&'a mut self, request: &CORSRequest, header_name: &str) -> Option<&'a mut CORSCacheEntry> {
|
fn find_entry_by_header<'a>(&'a mut self, request: &CORSRequest, header_name: &str) -> Option<&'a mut CORSCacheEntry> {
|
||||||
self.cleanup();
|
self.cleanup();
|
||||||
let CORSCache(ref mut buf) = *self;
|
let CORSCache(ref mut buf) = *self;
|
||||||
|
@ -342,7 +342,7 @@ impl CORSCache {
|
||||||
entry
|
entry
|
||||||
}
|
}
|
||||||
|
|
||||||
/// http://fetch.spec.whatwg.org/#concept-cache-match-method
|
/// https://fetch.spec.whatwg.org/#concept-cache-match-method
|
||||||
fn match_method(&mut self, request: &CORSRequest, method: &Method) -> bool {
|
fn match_method(&mut self, request: &CORSRequest, method: &Method) -> bool {
|
||||||
self.find_entry_by_method(request, method).is_some()
|
self.find_entry_by_method(request, method).is_some()
|
||||||
}
|
}
|
||||||
|
@ -383,7 +383,7 @@ fn is_simple_method(m: &Method) -> bool {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Perform a CORS check on a header list and CORS request
|
/// Perform a CORS check on a header list and CORS request
|
||||||
/// http://fetch.spec.whatwg.org/#cors-check
|
/// https://fetch.spec.whatwg.org/#cors-check
|
||||||
pub fn allow_cross_origin_request(req: &CORSRequest, headers: &Headers) -> bool {
|
pub fn allow_cross_origin_request(req: &CORSRequest, headers: &Headers) -> bool {
|
||||||
//FIXME(seanmonstar): use req.headers.get::<AccessControlAllowOrigin>()
|
//FIXME(seanmonstar): use req.headers.get::<AccessControlAllowOrigin>()
|
||||||
match headers.get() {
|
match headers.get() {
|
||||||
|
|
|
@ -117,7 +117,7 @@ impl<'a> CharacterDataMethods for JSRef<'a, CharacterData> {
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-childnode-remove
|
// https://dom.spec.whatwg.org/#dom-childnode-remove
|
||||||
fn Remove(self) {
|
fn Remove(self) {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.remove_self();
|
node.remove_self();
|
||||||
|
|
|
@ -264,7 +264,7 @@ impl<'a> DocumentHelpers<'a> for JSRef<'a, Document> {
|
||||||
true
|
true
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-url
|
// https://dom.spec.whatwg.org/#dom-document-url
|
||||||
fn url(self) -> Url {
|
fn url(self) -> Url {
|
||||||
self.url.clone()
|
self.url.clone()
|
||||||
}
|
}
|
||||||
|
@ -764,17 +764,17 @@ impl Document {
|
||||||
content_type: match content_type {
|
content_type: match content_type {
|
||||||
Some(string) => string.clone(),
|
Some(string) => string.clone(),
|
||||||
None => match is_html_document {
|
None => match is_html_document {
|
||||||
// http://dom.spec.whatwg.org/#dom-domimplementation-createhtmldocument
|
// https://dom.spec.whatwg.org/#dom-domimplementation-createhtmldocument
|
||||||
IsHTMLDocument::HTMLDocument => "text/html".to_owned(),
|
IsHTMLDocument::HTMLDocument => "text/html".to_owned(),
|
||||||
// http://dom.spec.whatwg.org/#concept-document-content-type
|
// https://dom.spec.whatwg.org/#concept-document-content-type
|
||||||
IsHTMLDocument::NonHTMLDocument => "application/xml".to_owned()
|
IsHTMLDocument::NonHTMLDocument => "application/xml".to_owned()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
last_modified: last_modified,
|
last_modified: last_modified,
|
||||||
url: url,
|
url: url,
|
||||||
// http://dom.spec.whatwg.org/#concept-document-quirks
|
// https://dom.spec.whatwg.org/#concept-document-quirks
|
||||||
quirks_mode: Cell::new(NoQuirks),
|
quirks_mode: Cell::new(NoQuirks),
|
||||||
// http://dom.spec.whatwg.org/#concept-document-encoding
|
// https://dom.spec.whatwg.org/#concept-document-encoding
|
||||||
encoding_name: DOMRefCell::new("UTF-8".to_owned()),
|
encoding_name: DOMRefCell::new("UTF-8".to_owned()),
|
||||||
is_html_document: is_html_document == IsHTMLDocument::HTMLDocument,
|
is_html_document: is_html_document == IsHTMLDocument::HTMLDocument,
|
||||||
images: Default::default(),
|
images: Default::default(),
|
||||||
|
@ -792,7 +792,7 @@ impl Document {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document
|
// https://dom.spec.whatwg.org/#dom-document
|
||||||
pub fn Constructor(global: GlobalRef) -> Fallible<Temporary<Document>> {
|
pub fn Constructor(global: GlobalRef) -> Fallible<Temporary<Document>> {
|
||||||
Ok(Document::new(global.as_window(), None,
|
Ok(Document::new(global.as_window(), None,
|
||||||
IsHTMLDocument::NonHTMLDocument, None,
|
IsHTMLDocument::NonHTMLDocument, None,
|
||||||
|
@ -866,12 +866,12 @@ impl<'a> PrivateClickEventHelpers for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> DocumentMethods for JSRef<'a, Document> {
|
impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
// http://dom.spec.whatwg.org/#dom-document-implementation
|
// https://dom.spec.whatwg.org/#dom-document-implementation
|
||||||
fn Implementation(self) -> Temporary<DOMImplementation> {
|
fn Implementation(self) -> Temporary<DOMImplementation> {
|
||||||
self.implementation.or_init(|| DOMImplementation::new(self))
|
self.implementation.or_init(|| DOMImplementation::new(self))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-url
|
// https://dom.spec.whatwg.org/#dom-document-url
|
||||||
fn URL(self) -> DOMString {
|
fn URL(self) -> DOMString {
|
||||||
self.url().serialize()
|
self.url().serialize()
|
||||||
}
|
}
|
||||||
|
@ -889,12 +889,12 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-documenturi
|
// https://dom.spec.whatwg.org/#dom-document-documenturi
|
||||||
fn DocumentURI(self) -> DOMString {
|
fn DocumentURI(self) -> DOMString {
|
||||||
self.URL()
|
self.URL()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-compatmode
|
// https://dom.spec.whatwg.org/#dom-document-compatmode
|
||||||
fn CompatMode(self) -> DOMString {
|
fn CompatMode(self) -> DOMString {
|
||||||
match self.quirks_mode.get() {
|
match self.quirks_mode.get() {
|
||||||
LimitedQuirks | NoQuirks => "CSS1Compat".to_owned(),
|
LimitedQuirks | NoQuirks => "CSS1Compat".to_owned(),
|
||||||
|
@ -902,26 +902,26 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-characterset
|
// https://dom.spec.whatwg.org/#dom-document-characterset
|
||||||
fn CharacterSet(self) -> DOMString {
|
fn CharacterSet(self) -> DOMString {
|
||||||
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
||||||
let encoding_name = self.encoding_name.borrow();
|
let encoding_name = self.encoding_name.borrow();
|
||||||
encoding_name.clone()
|
encoding_name.clone()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-inputencoding
|
// https://dom.spec.whatwg.org/#dom-document-inputencoding
|
||||||
fn InputEncoding(self) -> DOMString {
|
fn InputEncoding(self) -> DOMString {
|
||||||
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
||||||
let encoding_name = self.encoding_name.borrow();
|
let encoding_name = self.encoding_name.borrow();
|
||||||
encoding_name.clone()
|
encoding_name.clone()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-content_type
|
// https://dom.spec.whatwg.org/#dom-document-content_type
|
||||||
fn ContentType(self) -> DOMString {
|
fn ContentType(self) -> DOMString {
|
||||||
self.content_type.clone()
|
self.content_type.clone()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-doctype
|
// https://dom.spec.whatwg.org/#dom-document-doctype
|
||||||
fn GetDoctype(self) -> Option<Temporary<DocumentType>> {
|
fn GetDoctype(self) -> Option<Temporary<DocumentType>> {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.children()
|
node.children()
|
||||||
|
@ -930,33 +930,33 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
.next()
|
.next()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-documentelement
|
// https://dom.spec.whatwg.org/#dom-document-documentelement
|
||||||
fn GetDocumentElement(self) -> Option<Temporary<Element>> {
|
fn GetDocumentElement(self) -> Option<Temporary<Element>> {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.child_elements().next()
|
node.child_elements().next()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-getelementsbytagname
|
// https://dom.spec.whatwg.org/#dom-document-getelementsbytagname
|
||||||
fn GetElementsByTagName(self, tag_name: DOMString) -> Temporary<HTMLCollection> {
|
fn GetElementsByTagName(self, tag_name: DOMString) -> Temporary<HTMLCollection> {
|
||||||
let window = self.window.root();
|
let window = self.window.root();
|
||||||
HTMLCollection::by_tag_name(window.r(), NodeCast::from_ref(self), tag_name)
|
HTMLCollection::by_tag_name(window.r(), NodeCast::from_ref(self), tag_name)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-getelementsbytagnamens
|
// https://dom.spec.whatwg.org/#dom-document-getelementsbytagnamens
|
||||||
fn GetElementsByTagNameNS(self, maybe_ns: Option<DOMString>, tag_name: DOMString)
|
fn GetElementsByTagNameNS(self, maybe_ns: Option<DOMString>, tag_name: DOMString)
|
||||||
-> Temporary<HTMLCollection> {
|
-> Temporary<HTMLCollection> {
|
||||||
let window = self.window.root();
|
let window = self.window.root();
|
||||||
HTMLCollection::by_tag_name_ns(window.r(), NodeCast::from_ref(self), tag_name, maybe_ns)
|
HTMLCollection::by_tag_name_ns(window.r(), NodeCast::from_ref(self), tag_name, maybe_ns)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-getelementsbyclassname
|
// https://dom.spec.whatwg.org/#dom-document-getelementsbyclassname
|
||||||
fn GetElementsByClassName(self, classes: DOMString) -> Temporary<HTMLCollection> {
|
fn GetElementsByClassName(self, classes: DOMString) -> Temporary<HTMLCollection> {
|
||||||
let window = self.window.root();
|
let window = self.window.root();
|
||||||
|
|
||||||
HTMLCollection::by_class_name(window.r(), NodeCast::from_ref(self), classes)
|
HTMLCollection::by_class_name(window.r(), NodeCast::from_ref(self), classes)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-nonelementparentnode-getelementbyid
|
// https://dom.spec.whatwg.org/#dom-nonelementparentnode-getelementbyid
|
||||||
fn GetElementById(self, id: DOMString) -> Option<Temporary<Element>> {
|
fn GetElementById(self, id: DOMString) -> Option<Temporary<Element>> {
|
||||||
let id = Atom::from_slice(&id);
|
let id = Atom::from_slice(&id);
|
||||||
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
||||||
|
@ -964,7 +964,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
idmap.get(&id).map(|ref elements| Temporary::new((*elements)[0].clone()))
|
idmap.get(&id).map(|ref elements| Temporary::new((*elements)[0].clone()))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createelement
|
// https://dom.spec.whatwg.org/#dom-document-createelement
|
||||||
fn CreateElement(self, mut local_name: DOMString) -> Fallible<Temporary<Element>> {
|
fn CreateElement(self, mut local_name: DOMString) -> Fallible<Temporary<Element>> {
|
||||||
if xml_name_type(&local_name) == InvalidXMLName {
|
if xml_name_type(&local_name) == InvalidXMLName {
|
||||||
debug!("Not a valid element name");
|
debug!("Not a valid element name");
|
||||||
|
@ -977,7 +977,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
Ok(Element::create(name, None, self, ElementCreator::ScriptCreated))
|
Ok(Element::create(name, None, self, ElementCreator::ScriptCreated))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createelementns
|
// https://dom.spec.whatwg.org/#dom-document-createelementns
|
||||||
fn CreateElementNS(self,
|
fn CreateElementNS(self,
|
||||||
namespace: Option<DOMString>,
|
namespace: Option<DOMString>,
|
||||||
qualified_name: DOMString) -> Fallible<Temporary<Element>> {
|
qualified_name: DOMString) -> Fallible<Temporary<Element>> {
|
||||||
|
@ -987,7 +987,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
Ok(Element::create(name, prefix, self, ElementCreator::ScriptCreated))
|
Ok(Element::create(name, prefix, self, ElementCreator::ScriptCreated))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createattribute
|
// https://dom.spec.whatwg.org/#dom-document-createattribute
|
||||||
fn CreateAttribute(self, local_name: DOMString) -> Fallible<Temporary<Attr>> {
|
fn CreateAttribute(self, local_name: DOMString) -> Fallible<Temporary<Attr>> {
|
||||||
if xml_name_type(&local_name) == InvalidXMLName {
|
if xml_name_type(&local_name) == InvalidXMLName {
|
||||||
debug!("Not a valid element name");
|
debug!("Not a valid element name");
|
||||||
|
@ -1003,7 +1003,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
Ok(Attr::new(window.r(), name, value, l_name, ns!(""), None, None))
|
Ok(Attr::new(window.r(), name, value, l_name, ns!(""), None, None))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createattributens
|
// https://dom.spec.whatwg.org/#dom-document-createattributens
|
||||||
fn CreateAttributeNS(self, namespace: Option<DOMString>, qualified_name: DOMString)
|
fn CreateAttributeNS(self, namespace: Option<DOMString>, qualified_name: DOMString)
|
||||||
-> Fallible<Temporary<Attr>> {
|
-> Fallible<Temporary<Attr>> {
|
||||||
let (namespace, prefix, local_name) =
|
let (namespace, prefix, local_name) =
|
||||||
|
@ -1015,22 +1015,22 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
namespace, prefix, None))
|
namespace, prefix, None))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createdocumentfragment
|
// https://dom.spec.whatwg.org/#dom-document-createdocumentfragment
|
||||||
fn CreateDocumentFragment(self) -> Temporary<DocumentFragment> {
|
fn CreateDocumentFragment(self) -> Temporary<DocumentFragment> {
|
||||||
DocumentFragment::new(self)
|
DocumentFragment::new(self)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createtextnode
|
// https://dom.spec.whatwg.org/#dom-document-createtextnode
|
||||||
fn CreateTextNode(self, data: DOMString) -> Temporary<Text> {
|
fn CreateTextNode(self, data: DOMString) -> Temporary<Text> {
|
||||||
Text::new(data, self)
|
Text::new(data, self)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createcomment
|
// https://dom.spec.whatwg.org/#dom-document-createcomment
|
||||||
fn CreateComment(self, data: DOMString) -> Temporary<Comment> {
|
fn CreateComment(self, data: DOMString) -> Temporary<Comment> {
|
||||||
Comment::new(data, self)
|
Comment::new(data, self)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createprocessinginstruction
|
// https://dom.spec.whatwg.org/#dom-document-createprocessinginstruction
|
||||||
fn CreateProcessingInstruction(self, target: DOMString, data: DOMString) ->
|
fn CreateProcessingInstruction(self, target: DOMString, data: DOMString) ->
|
||||||
Fallible<Temporary<ProcessingInstruction>> {
|
Fallible<Temporary<ProcessingInstruction>> {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
|
@ -1047,7 +1047,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
Ok(ProcessingInstruction::new(target, data, self))
|
Ok(ProcessingInstruction::new(target, data, self))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-importnode
|
// https://dom.spec.whatwg.org/#dom-document-importnode
|
||||||
fn ImportNode(self, node: JSRef<Node>, deep: bool) -> Fallible<Temporary<Node>> {
|
fn ImportNode(self, node: JSRef<Node>, deep: bool) -> Fallible<Temporary<Node>> {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
if node.is_document() {
|
if node.is_document() {
|
||||||
|
@ -1063,7 +1063,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
Ok(Node::clone(node, Some(self), clone_children))
|
Ok(Node::clone(node, Some(self), clone_children))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-adoptnode
|
// https://dom.spec.whatwg.org/#dom-document-adoptnode
|
||||||
fn AdoptNode(self, node: JSRef<Node>) -> Fallible<Temporary<Node>> {
|
fn AdoptNode(self, node: JSRef<Node>) -> Fallible<Temporary<Node>> {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
if node.is_document() {
|
if node.is_document() {
|
||||||
|
@ -1077,7 +1077,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
Ok(Temporary::from_rooted(node))
|
Ok(Temporary::from_rooted(node))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createevent
|
// https://dom.spec.whatwg.org/#dom-document-createevent
|
||||||
fn CreateEvent(self, interface: DOMString) -> Fallible<Temporary<Event>> {
|
fn CreateEvent(self, interface: DOMString) -> Fallible<Temporary<Event>> {
|
||||||
let window = self.window.root();
|
let window = self.window.root();
|
||||||
|
|
||||||
|
@ -1098,7 +1098,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-document-lastmodified
|
// https://www.whatwg.org/html/#dom-document-lastmodified
|
||||||
fn LastModified(self) -> DOMString {
|
fn LastModified(self) -> DOMString {
|
||||||
match self.last_modified {
|
match self.last_modified {
|
||||||
Some(ref t) => t.clone(),
|
Some(ref t) => t.clone(),
|
||||||
|
@ -1106,19 +1106,19 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createrange
|
// https://dom.spec.whatwg.org/#dom-document-createrange
|
||||||
fn CreateRange(self) -> Temporary<Range> {
|
fn CreateRange(self) -> Temporary<Range> {
|
||||||
Range::new(self)
|
Range::new(self)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-document-createtreewalker
|
// https://dom.spec.whatwg.org/#dom-document-createtreewalker
|
||||||
fn CreateTreeWalker(self, root: JSRef<Node>, whatToShow: u32, filter: Option<NodeFilter>)
|
fn CreateTreeWalker(self, root: JSRef<Node>, whatToShow: u32, filter: Option<NodeFilter>)
|
||||||
-> Temporary<TreeWalker> {
|
-> Temporary<TreeWalker> {
|
||||||
TreeWalker::new(self, root, whatToShow, filter)
|
TreeWalker::new(self, root, whatToShow, filter)
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: Support root SVG namespace: https://github.com/servo/servo/issues/5315
|
// TODO: Support root SVG namespace: https://github.com/servo/servo/issues/5315
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/#document.title
|
// https://www.whatwg.org/specs/web-apps/current-work/#document.title
|
||||||
fn Title(self) -> DOMString {
|
fn Title(self) -> DOMString {
|
||||||
let title_element = self.GetDocumentElement().root().and_then(|root| {
|
let title_element = self.GetDocumentElement().root().and_then(|root| {
|
||||||
NodeCast::from_ref(root.r()).traverse_preorder().find(|node| {
|
NodeCast::from_ref(root.r()).traverse_preorder().find(|node| {
|
||||||
|
@ -1140,7 +1140,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
}
|
}
|
||||||
|
|
||||||
// TODO: Support root SVG namespace: https://github.com/servo/servo/issues/5315
|
// TODO: Support root SVG namespace: https://github.com/servo/servo/issues/5315
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/#document.title
|
// https://www.whatwg.org/specs/web-apps/current-work/#document.title
|
||||||
fn SetTitle(self, title: DOMString) -> ErrorResult {
|
fn SetTitle(self, title: DOMString) -> ErrorResult {
|
||||||
self.GetDocumentElement().root().map(|root| {
|
self.GetDocumentElement().root().map(|root| {
|
||||||
let root: JSRef<Node> = NodeCast::from_ref(root.r());
|
let root: JSRef<Node> = NodeCast::from_ref(root.r());
|
||||||
|
@ -1179,7 +1179,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/#dom-document-head
|
// https://www.whatwg.org/specs/web-apps/current-work/#dom-document-head
|
||||||
fn GetHead(self) -> Option<Temporary<HTMLHeadElement>> {
|
fn GetHead(self) -> Option<Temporary<HTMLHeadElement>> {
|
||||||
self.get_html_element().and_then(|root| {
|
self.get_html_element().and_then(|root| {
|
||||||
let root = root.root();
|
let root = root.root();
|
||||||
|
@ -1191,12 +1191,12 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/#dom-document-currentscript
|
// https://www.whatwg.org/specs/web-apps/current-work/#dom-document-currentscript
|
||||||
fn GetCurrentScript(self) -> Option<Temporary<HTMLScriptElement>> {
|
fn GetCurrentScript(self) -> Option<Temporary<HTMLScriptElement>> {
|
||||||
self.current_script.get()
|
self.current_script.get()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/#dom-document-body
|
// https://www.whatwg.org/specs/web-apps/current-work/#dom-document-body
|
||||||
fn GetBody(self) -> Option<Temporary<HTMLElement>> {
|
fn GetBody(self) -> Option<Temporary<HTMLElement>> {
|
||||||
self.get_html_element().and_then(|root| {
|
self.get_html_element().and_then(|root| {
|
||||||
let root = root.root();
|
let root = root.root();
|
||||||
|
@ -1213,7 +1213,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/#dom-document-body
|
// https://www.whatwg.org/specs/web-apps/current-work/#dom-document-body
|
||||||
fn SetBody(self, new_body: Option<JSRef<HTMLElement>>) -> ErrorResult {
|
fn SetBody(self, new_body: Option<JSRef<HTMLElement>>) -> ErrorResult {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
let new_body = match new_body {
|
let new_body = match new_body {
|
||||||
|
@ -1256,7 +1256,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/#dom-document-getelementsbyname
|
// https://www.whatwg.org/specs/web-apps/current-work/#dom-document-getelementsbyname
|
||||||
fn GetElementsByName(self, name: DOMString) -> Temporary<NodeList> {
|
fn GetElementsByName(self, name: DOMString) -> Temporary<NodeList> {
|
||||||
self.create_node_list(|node| {
|
self.create_node_list(|node| {
|
||||||
let element: JSRef<Element> = match ElementCast::to_ref(node) {
|
let element: JSRef<Element> = match ElementCast::to_ref(node) {
|
||||||
|
@ -1355,7 +1355,7 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
self.location.or_init(|| Location::new(window))
|
self.location.or_init(|| Location::new(window))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-children
|
// https://dom.spec.whatwg.org/#dom-parentnode-children
|
||||||
fn Children(self) -> Temporary<HTMLCollection> {
|
fn Children(self) -> Temporary<HTMLCollection> {
|
||||||
let window = self.window.root();
|
let window = self.window.root();
|
||||||
HTMLCollection::children(window.r(), NodeCast::from_ref(self))
|
HTMLCollection::children(window.r(), NodeCast::from_ref(self))
|
||||||
|
@ -1376,13 +1376,13 @@ impl<'a> DocumentMethods for JSRef<'a, Document> {
|
||||||
NodeCast::from_ref(self).child_elements().count() as u32
|
NodeCast::from_ref(self).child_elements().count() as u32
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-queryselector
|
// https://dom.spec.whatwg.org/#dom-parentnode-queryselector
|
||||||
fn QuerySelector(self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
|
fn QuerySelector(self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
|
||||||
let root: JSRef<Node> = NodeCast::from_ref(self);
|
let root: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
root.query_selector(selectors)
|
root.query_selector(selectors)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-queryselectorall
|
// https://dom.spec.whatwg.org/#dom-parentnode-queryselectorall
|
||||||
fn QuerySelectorAll(self, selectors: DOMString) -> Fallible<Temporary<NodeList>> {
|
fn QuerySelectorAll(self, selectors: DOMString) -> Fallible<Temporary<NodeList>> {
|
||||||
let root: JSRef<Node> = NodeCast::from_ref(self);
|
let root: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
root.query_selector_all(selectors)
|
root.query_selector_all(selectors)
|
||||||
|
|
|
@ -51,7 +51,7 @@ impl DocumentFragment {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> DocumentFragmentMethods for JSRef<'a, DocumentFragment> {
|
impl<'a> DocumentFragmentMethods for JSRef<'a, DocumentFragment> {
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-children
|
// https://dom.spec.whatwg.org/#dom-parentnode-children
|
||||||
fn Children(self) -> Temporary<HTMLCollection> {
|
fn Children(self) -> Temporary<HTMLCollection> {
|
||||||
let window = window_from_node(self).root();
|
let window = window_from_node(self).root();
|
||||||
HTMLCollection::children(window.r(), NodeCast::from_ref(self))
|
HTMLCollection::children(window.r(), NodeCast::from_ref(self))
|
||||||
|
@ -72,13 +72,13 @@ impl<'a> DocumentFragmentMethods for JSRef<'a, DocumentFragment> {
|
||||||
NodeCast::from_ref(self).child_elements().count() as u32
|
NodeCast::from_ref(self).child_elements().count() as u32
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-queryselector
|
// https://dom.spec.whatwg.org/#dom-parentnode-queryselector
|
||||||
fn QuerySelector(self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
|
fn QuerySelector(self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
|
||||||
let root: JSRef<Node> = NodeCast::from_ref(self);
|
let root: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
root.query_selector(selectors)
|
root.query_selector(selectors)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-queryselectorall
|
// https://dom.spec.whatwg.org/#dom-parentnode-queryselectorall
|
||||||
fn QuerySelectorAll(self, selectors: DOMString) -> Fallible<Temporary<NodeList>> {
|
fn QuerySelectorAll(self, selectors: DOMString) -> Fallible<Temporary<NodeList>> {
|
||||||
let root: JSRef<Node> = NodeCast::from_ref(self);
|
let root: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
root.query_selector_all(selectors)
|
root.query_selector_all(selectors)
|
||||||
|
|
|
@ -83,7 +83,7 @@ impl<'a> DocumentTypeMethods for JSRef<'a, DocumentType> {
|
||||||
self.system_id.clone()
|
self.system_id.clone()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-childnode-remove
|
// https://dom.spec.whatwg.org/#dom-childnode-remove
|
||||||
fn Remove(self) {
|
fn Remove(self) {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.remove_self();
|
node.remove_self();
|
||||||
|
|
|
@ -47,9 +47,9 @@ impl DOMImplementation {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#domimplementation
|
// https://dom.spec.whatwg.org/#domimplementation
|
||||||
impl<'a> DOMImplementationMethods for JSRef<'a, DOMImplementation> {
|
impl<'a> DOMImplementationMethods for JSRef<'a, DOMImplementation> {
|
||||||
// http://dom.spec.whatwg.org/#dom-domimplementation-createdocumenttype
|
// https://dom.spec.whatwg.org/#dom-domimplementation-createdocumenttype
|
||||||
fn CreateDocumentType(self, qualified_name: DOMString, pubid: DOMString, sysid: DOMString)
|
fn CreateDocumentType(self, qualified_name: DOMString, pubid: DOMString, sysid: DOMString)
|
||||||
-> Fallible<Temporary<DocumentType>> {
|
-> Fallible<Temporary<DocumentType>> {
|
||||||
try!(validate_qualified_name(&qualified_name));
|
try!(validate_qualified_name(&qualified_name));
|
||||||
|
@ -57,7 +57,7 @@ impl<'a> DOMImplementationMethods for JSRef<'a, DOMImplementation> {
|
||||||
Ok(DocumentType::new(qualified_name, Some(pubid), Some(sysid), document.r()))
|
Ok(DocumentType::new(qualified_name, Some(pubid), Some(sysid), document.r()))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-domimplementation-createdocument
|
// https://dom.spec.whatwg.org/#dom-domimplementation-createdocument
|
||||||
fn CreateDocument(self, namespace: Option<DOMString>, qname: DOMString,
|
fn CreateDocument(self, namespace: Option<DOMString>, qname: DOMString,
|
||||||
maybe_doctype: Option<JSRef<DocumentType>>) -> Fallible<Temporary<Document>> {
|
maybe_doctype: Option<JSRef<DocumentType>>) -> Fallible<Temporary<Document>> {
|
||||||
let doc = self.document.root();
|
let doc = self.document.root();
|
||||||
|
@ -104,7 +104,7 @@ impl<'a> DOMImplementationMethods for JSRef<'a, DOMImplementation> {
|
||||||
Ok(Temporary::from_rooted(doc.r()))
|
Ok(Temporary::from_rooted(doc.r()))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-domimplementation-createhtmldocument
|
// https://dom.spec.whatwg.org/#dom-domimplementation-createhtmldocument
|
||||||
fn CreateHTMLDocument(self, title: Option<DOMString>) -> Temporary<Document> {
|
fn CreateHTMLDocument(self, title: Option<DOMString>) -> Temporary<Document> {
|
||||||
let document = self.document.root();
|
let document = self.document.root();
|
||||||
let win = document.r().window().root();
|
let win = document.r().window().root();
|
||||||
|
|
|
@ -43,7 +43,7 @@ impl DOMParser {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> DOMParserMethods for JSRef<'a, DOMParser> {
|
impl<'a> DOMParserMethods for JSRef<'a, DOMParser> {
|
||||||
// http://domparsing.spec.whatwg.org/#the-domparser-interface
|
// https://domparsing.spec.whatwg.org/#the-domparser-interface
|
||||||
fn ParseFromString(self,
|
fn ParseFromString(self,
|
||||||
s: DOMString,
|
s: DOMString,
|
||||||
ty: DOMParserBinding::SupportedType)
|
ty: DOMParserBinding::SupportedType)
|
||||||
|
|
|
@ -62,9 +62,9 @@ impl<'a> PrivateDOMTokenListHelpers for JSRef<'a, DOMTokenList> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#domtokenlist
|
// https://dom.spec.whatwg.org/#domtokenlist
|
||||||
impl<'a> DOMTokenListMethods for JSRef<'a, DOMTokenList> {
|
impl<'a> DOMTokenListMethods for JSRef<'a, DOMTokenList> {
|
||||||
// http://dom.spec.whatwg.org/#dom-domtokenlist-length
|
// https://dom.spec.whatwg.org/#dom-domtokenlist-length
|
||||||
fn Length(self) -> u32 {
|
fn Length(self) -> u32 {
|
||||||
self.attribute().root().map(|attr| {
|
self.attribute().root().map(|attr| {
|
||||||
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
||||||
|
@ -74,7 +74,7 @@ impl<'a> DOMTokenListMethods for JSRef<'a, DOMTokenList> {
|
||||||
}).unwrap_or(0) as u32
|
}).unwrap_or(0) as u32
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-domtokenlist-item
|
// https://dom.spec.whatwg.org/#dom-domtokenlist-item
|
||||||
fn Item(self, index: u32) -> Option<DOMString> {
|
fn Item(self, index: u32) -> Option<DOMString> {
|
||||||
self.attribute().root().and_then(|attr| {
|
self.attribute().root().and_then(|attr| {
|
||||||
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
// FIXME(https://github.com/rust-lang/rust/issues/23338)
|
||||||
|
@ -92,7 +92,7 @@ impl<'a> DOMTokenListMethods for JSRef<'a, DOMTokenList> {
|
||||||
item
|
item
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-domtokenlist-contains
|
// https://dom.spec.whatwg.org/#dom-domtokenlist-contains
|
||||||
fn Contains(self, token: DOMString) -> Fallible<bool> {
|
fn Contains(self, token: DOMString) -> Fallible<bool> {
|
||||||
self.check_token_exceptions(&token).map(|token| {
|
self.check_token_exceptions(&token).map(|token| {
|
||||||
self.attribute().root().map(|attr| {
|
self.attribute().root().map(|attr| {
|
||||||
|
|
|
@ -497,7 +497,7 @@ impl<'a> ElementHelpers<'a> for JSRef<'a, Element> {
|
||||||
}
|
}
|
||||||
match self.local_name.as_slice() {
|
match self.local_name.as_slice() {
|
||||||
/* List of void elements from
|
/* List of void elements from
|
||||||
http://www.whatwg.org/specs/web-apps/current-work/multipage/the-end.html#html-fragment-serialization-algorithm */
|
https://www.whatwg.org/specs/web-apps/current-work/multipage/the-end.html#html-fragment-serialization-algorithm */
|
||||||
"area" | "base" | "basefont" | "bgsound" | "br" | "col" | "embed" |
|
"area" | "base" | "basefont" | "bgsound" | "br" | "col" | "embed" |
|
||||||
"frame" | "hr" | "img" | "input" | "keygen" | "link" | "menuitem" |
|
"frame" | "hr" | "img" | "input" | "keygen" | "link" | "menuitem" |
|
||||||
"meta" | "param" | "source" | "track" | "wbr" => true,
|
"meta" | "param" | "source" | "track" | "wbr" => true,
|
||||||
|
@ -685,7 +685,7 @@ pub trait AttributeHandlers {
|
||||||
|
|
||||||
fn set_atomic_attribute(self, local_name: &Atom, value: DOMString);
|
fn set_atomic_attribute(self, local_name: &Atom, value: DOMString);
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#reflecting-content-attributes-in-idl-attributes
|
// https://www.whatwg.org/html/#reflecting-content-attributes-in-idl-attributes
|
||||||
fn has_attribute(self, local_name: &Atom) -> bool;
|
fn has_attribute(self, local_name: &Atom) -> bool;
|
||||||
fn set_bool_attribute(self, local_name: &Atom, value: bool);
|
fn set_bool_attribute(self, local_name: &Atom, value: bool);
|
||||||
fn get_url_attribute(self, local_name: &Atom) -> DOMString;
|
fn get_url_attribute(self, local_name: &Atom) -> DOMString;
|
||||||
|
@ -973,7 +973,7 @@ impl<'a> AttributeHandlers for JSRef<'a, Element> {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> ElementMethods for JSRef<'a, Element> {
|
impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
// http://dom.spec.whatwg.org/#dom-element-namespaceuri
|
// https://dom.spec.whatwg.org/#dom-element-namespaceuri
|
||||||
fn GetNamespaceURI(self) -> Option<DOMString> {
|
fn GetNamespaceURI(self) -> Option<DOMString> {
|
||||||
match self.namespace {
|
match self.namespace {
|
||||||
ns!("") => None,
|
ns!("") => None,
|
||||||
|
@ -986,12 +986,12 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
self.local_name.as_slice().to_owned()
|
self.local_name.as_slice().to_owned()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-prefix
|
// https://dom.spec.whatwg.org/#dom-element-prefix
|
||||||
fn GetPrefix(self) -> Option<DOMString> {
|
fn GetPrefix(self) -> Option<DOMString> {
|
||||||
self.prefix.clone()
|
self.prefix.clone()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-tagname
|
// https://dom.spec.whatwg.org/#dom-element-tagname
|
||||||
fn TagName(self) -> DOMString {
|
fn TagName(self) -> DOMString {
|
||||||
let qualified_name = match self.prefix {
|
let qualified_name = match self.prefix {
|
||||||
Some(ref prefix) => {
|
Some(ref prefix) => {
|
||||||
|
@ -1008,32 +1008,32 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-id
|
// https://dom.spec.whatwg.org/#dom-element-id
|
||||||
fn Id(self) -> DOMString {
|
fn Id(self) -> DOMString {
|
||||||
self.get_string_attribute(&atom!("id"))
|
self.get_string_attribute(&atom!("id"))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-id
|
// https://dom.spec.whatwg.org/#dom-element-id
|
||||||
fn SetId(self, id: DOMString) {
|
fn SetId(self, id: DOMString) {
|
||||||
self.set_atomic_attribute(&atom!("id"), id);
|
self.set_atomic_attribute(&atom!("id"), id);
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-classname
|
// https://dom.spec.whatwg.org/#dom-element-classname
|
||||||
fn ClassName(self) -> DOMString {
|
fn ClassName(self) -> DOMString {
|
||||||
self.get_string_attribute(&atom!("class"))
|
self.get_string_attribute(&atom!("class"))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-classname
|
// https://dom.spec.whatwg.org/#dom-element-classname
|
||||||
fn SetClassName(self, class: DOMString) {
|
fn SetClassName(self, class: DOMString) {
|
||||||
self.set_tokenlist_attribute(&atom!("class"), class);
|
self.set_tokenlist_attribute(&atom!("class"), class);
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-classlist
|
// https://dom.spec.whatwg.org/#dom-element-classlist
|
||||||
fn ClassList(self) -> Temporary<DOMTokenList> {
|
fn ClassList(self) -> Temporary<DOMTokenList> {
|
||||||
self.class_list.or_init(|| DOMTokenList::new(self, &atom!("class")))
|
self.class_list.or_init(|| DOMTokenList::new(self, &atom!("class")))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-attributes
|
// https://dom.spec.whatwg.org/#dom-element-attributes
|
||||||
fn Attributes(self) -> Temporary<NamedNodeMap> {
|
fn Attributes(self) -> Temporary<NamedNodeMap> {
|
||||||
self.attr_list.or_init(|| {
|
self.attr_list.or_init(|| {
|
||||||
let doc = {
|
let doc = {
|
||||||
|
@ -1045,14 +1045,14 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-getattribute
|
// https://dom.spec.whatwg.org/#dom-element-getattribute
|
||||||
fn GetAttribute(self, name: DOMString) -> Option<DOMString> {
|
fn GetAttribute(self, name: DOMString) -> Option<DOMString> {
|
||||||
let name = self.parsed_name(name);
|
let name = self.parsed_name(name);
|
||||||
self.get_attribute_by_name(&Atom::from_slice(&name)).root()
|
self.get_attribute_by_name(&Atom::from_slice(&name)).root()
|
||||||
.map(|s| s.r().Value())
|
.map(|s| s.r().Value())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-getattributens
|
// https://dom.spec.whatwg.org/#dom-element-getattributens
|
||||||
fn GetAttributeNS(self,
|
fn GetAttributeNS(self,
|
||||||
namespace: Option<DOMString>,
|
namespace: Option<DOMString>,
|
||||||
local_name: DOMString) -> Option<DOMString> {
|
local_name: DOMString) -> Option<DOMString> {
|
||||||
|
@ -1061,7 +1061,7 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
.map(|attr| attr.r().Value())
|
.map(|attr| attr.r().Value())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-setattribute
|
// https://dom.spec.whatwg.org/#dom-element-setattribute
|
||||||
fn SetAttribute(self,
|
fn SetAttribute(self,
|
||||||
name: DOMString,
|
name: DOMString,
|
||||||
value: DOMString) -> ErrorResult {
|
value: DOMString) -> ErrorResult {
|
||||||
|
@ -1082,7 +1082,7 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-setattributens
|
// https://dom.spec.whatwg.org/#dom-element-setattributens
|
||||||
fn SetAttributeNS(self,
|
fn SetAttributeNS(self,
|
||||||
namespace: Option<DOMString>,
|
namespace: Option<DOMString>,
|
||||||
qualified_name: DOMString,
|
qualified_name: DOMString,
|
||||||
|
@ -1100,13 +1100,13 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-removeattribute
|
// https://dom.spec.whatwg.org/#dom-element-removeattribute
|
||||||
fn RemoveAttribute(self, name: DOMString) {
|
fn RemoveAttribute(self, name: DOMString) {
|
||||||
let name = Atom::from_slice(&self.parsed_name(name));
|
let name = Atom::from_slice(&self.parsed_name(name));
|
||||||
self.remove_attribute_by_name(&name);
|
self.remove_attribute_by_name(&name);
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-removeattributens
|
// https://dom.spec.whatwg.org/#dom-element-removeattributens
|
||||||
fn RemoveAttributeNS(self,
|
fn RemoveAttributeNS(self,
|
||||||
namespace: Option<DOMString>,
|
namespace: Option<DOMString>,
|
||||||
local_name: DOMString) {
|
local_name: DOMString) {
|
||||||
|
@ -1115,12 +1115,12 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
self.remove_attribute(&namespace, &local_name);
|
self.remove_attribute(&namespace, &local_name);
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-hasattribute
|
// https://dom.spec.whatwg.org/#dom-element-hasattribute
|
||||||
fn HasAttribute(self, name: DOMString) -> bool {
|
fn HasAttribute(self, name: DOMString) -> bool {
|
||||||
self.GetAttribute(name).is_some()
|
self.GetAttribute(name).is_some()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-hasattributens
|
// https://dom.spec.whatwg.org/#dom-element-hasattributens
|
||||||
fn HasAttributeNS(self,
|
fn HasAttributeNS(self,
|
||||||
namespace: Option<DOMString>,
|
namespace: Option<DOMString>,
|
||||||
local_name: DOMString) -> bool {
|
local_name: DOMString) -> bool {
|
||||||
|
@ -1244,7 +1244,7 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
.filter_map(ElementCast::to_temporary).next()
|
.filter_map(ElementCast::to_temporary).next()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-children
|
// https://dom.spec.whatwg.org/#dom-parentnode-children
|
||||||
fn Children(self) -> Temporary<HTMLCollection> {
|
fn Children(self) -> Temporary<HTMLCollection> {
|
||||||
let window = window_from_node(self).root();
|
let window = window_from_node(self).root();
|
||||||
HTMLCollection::children(window.r(), NodeCast::from_ref(self))
|
HTMLCollection::children(window.r(), NodeCast::from_ref(self))
|
||||||
|
@ -1265,25 +1265,25 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
|
||||||
NodeCast::from_ref(self).child_elements().count() as u32
|
NodeCast::from_ref(self).child_elements().count() as u32
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-queryselector
|
// https://dom.spec.whatwg.org/#dom-parentnode-queryselector
|
||||||
fn QuerySelector(self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
|
fn QuerySelector(self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
|
||||||
let root: JSRef<Node> = NodeCast::from_ref(self);
|
let root: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
root.query_selector(selectors)
|
root.query_selector(selectors)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-queryselectorall
|
// https://dom.spec.whatwg.org/#dom-parentnode-queryselectorall
|
||||||
fn QuerySelectorAll(self, selectors: DOMString) -> Fallible<Temporary<NodeList>> {
|
fn QuerySelectorAll(self, selectors: DOMString) -> Fallible<Temporary<NodeList>> {
|
||||||
let root: JSRef<Node> = NodeCast::from_ref(self);
|
let root: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
root.query_selector_all(selectors)
|
root.query_selector_all(selectors)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-childnode-remove
|
// https://dom.spec.whatwg.org/#dom-childnode-remove
|
||||||
fn Remove(self) {
|
fn Remove(self) {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.remove_self();
|
node.remove_self();
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-element-matches
|
// https://dom.spec.whatwg.org/#dom-element-matches
|
||||||
fn Matches(self, selectors: DOMString) -> Fallible<bool> {
|
fn Matches(self, selectors: DOMString) -> Fallible<bool> {
|
||||||
match parse_author_origin_selector_list_from_str(&selectors) {
|
match parse_author_origin_selector_list_from_str(&selectors) {
|
||||||
Err(()) => Err(Syntax),
|
Err(()) => Err(Syntax),
|
||||||
|
@ -1481,7 +1481,7 @@ impl<'a> style::node::TElement<'a> for JSRef<'a, Element> {
|
||||||
// FIXME: This is HTML only.
|
// FIXME: This is HTML only.
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
match node.type_id() {
|
match node.type_id() {
|
||||||
// http://www.whatwg.org/specs/web-apps/current-work/multipage/selectors.html#
|
// https://www.whatwg.org/specs/web-apps/current-work/multipage/selectors.html#
|
||||||
// selector-link
|
// selector-link
|
||||||
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLAnchorElement)) |
|
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLAnchorElement)) |
|
||||||
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLAreaElement)) |
|
NodeTypeId::Element(ElementTypeId::HTMLElement(HTMLElementTypeId::HTMLAreaElement)) |
|
||||||
|
|
|
@ -12,7 +12,7 @@ use dom::event::{Event, EventPhase};
|
||||||
use dom::node::{Node, NodeHelpers};
|
use dom::node::{Node, NodeHelpers};
|
||||||
use dom::virtualmethods::vtable_for;
|
use dom::virtualmethods::vtable_for;
|
||||||
|
|
||||||
// See http://dom.spec.whatwg.org/#concept-event-dispatch for the full dispatch algorithm
|
// See https://dom.spec.whatwg.org/#concept-event-dispatch for the full dispatch algorithm
|
||||||
pub fn dispatch_event<'a, 'b>(target: JSRef<'a, EventTarget>,
|
pub fn dispatch_event<'a, 'b>(target: JSRef<'a, EventTarget>,
|
||||||
pseudo_target: Option<JSRef<'b, EventTarget>>,
|
pseudo_target: Option<JSRef<'b, EventTarget>>,
|
||||||
event: JSRef<Event>) -> bool {
|
event: JSRef<Event>) -> bool {
|
||||||
|
|
|
@ -72,10 +72,10 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> {
|
||||||
ValidityState::new(window.r())
|
ValidityState::new(window.r())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fe-disabled
|
// https://www.whatwg.org/html/#dom-fe-disabled
|
||||||
make_bool_getter!(Disabled);
|
make_bool_getter!(Disabled);
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fe-disabled
|
// https://www.whatwg.org/html/#dom-fe-disabled
|
||||||
make_bool_setter!(SetDisabled, "disabled");
|
make_bool_setter!(SetDisabled, "disabled");
|
||||||
|
|
||||||
// https://html.spec.whatwg.org/multipage/forms.html#dom-button-type
|
// https://html.spec.whatwg.org/multipage/forms.html#dom-button-type
|
||||||
|
|
|
@ -175,7 +175,7 @@ impl HTMLCollection {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> HTMLCollectionMethods for JSRef<'a, HTMLCollection> {
|
impl<'a> HTMLCollectionMethods for JSRef<'a, HTMLCollection> {
|
||||||
// http://dom.spec.whatwg.org/#dom-htmlcollection-length
|
// https://dom.spec.whatwg.org/#dom-htmlcollection-length
|
||||||
fn Length(self) -> u32 {
|
fn Length(self) -> u32 {
|
||||||
match self.collection {
|
match self.collection {
|
||||||
CollectionTypeId::Static(ref elems) => elems.len() as u32,
|
CollectionTypeId::Static(ref elems) => elems.len() as u32,
|
||||||
|
@ -188,7 +188,7 @@ impl<'a> HTMLCollectionMethods for JSRef<'a, HTMLCollection> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-htmlcollection-item
|
// https://dom.spec.whatwg.org/#dom-htmlcollection-item
|
||||||
fn Item(self, index: u32) -> Option<Temporary<Element>> {
|
fn Item(self, index: u32) -> Option<Temporary<Element>> {
|
||||||
let index = index as usize;
|
let index = index as usize;
|
||||||
match self.collection {
|
match self.collection {
|
||||||
|
@ -205,7 +205,7 @@ impl<'a> HTMLCollectionMethods for JSRef<'a, HTMLCollection> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-htmlcollection-nameditem
|
// https://dom.spec.whatwg.org/#dom-htmlcollection-nameditem
|
||||||
fn NamedItem(self, key: DOMString) -> Option<Temporary<Element>> {
|
fn NamedItem(self, key: DOMString) -> Option<Temporary<Element>> {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
if key.is_empty() {
|
if key.is_empty() {
|
||||||
|
|
|
@ -92,7 +92,7 @@ impl<'a> HTMLElementMethods for JSRef<'a, HTMLElement> {
|
||||||
make_getter!(Lang);
|
make_getter!(Lang);
|
||||||
make_setter!(SetLang, "lang");
|
make_setter!(SetLang, "lang");
|
||||||
|
|
||||||
// http://html.spec.whatwg.org/multipage/#dom-hidden
|
// https://html.spec.whatwg.org/multipage/#dom-hidden
|
||||||
make_bool_getter!(Hidden);
|
make_bool_getter!(Hidden);
|
||||||
make_bool_setter!(SetHidden, "hidden");
|
make_bool_setter!(SetHidden, "hidden");
|
||||||
|
|
||||||
|
|
|
@ -48,7 +48,7 @@ impl HTMLFieldSetElement {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> HTMLFieldSetElementMethods for JSRef<'a, HTMLFieldSetElement> {
|
impl<'a> HTMLFieldSetElementMethods for JSRef<'a, HTMLFieldSetElement> {
|
||||||
// http://www.whatwg.org/html/#dom-fieldset-elements
|
// https://www.whatwg.org/html/#dom-fieldset-elements
|
||||||
fn Elements(self) -> Temporary<HTMLCollection> {
|
fn Elements(self) -> Temporary<HTMLCollection> {
|
||||||
#[jstraceable]
|
#[jstraceable]
|
||||||
struct ElementsFilter;
|
struct ElementsFilter;
|
||||||
|
@ -70,10 +70,10 @@ impl<'a> HTMLFieldSetElementMethods for JSRef<'a, HTMLFieldSetElement> {
|
||||||
ValidityState::new(window.r())
|
ValidityState::new(window.r())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fieldset-disabled
|
// https://www.whatwg.org/html/#dom-fieldset-disabled
|
||||||
make_bool_getter!(Disabled);
|
make_bool_getter!(Disabled);
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fieldset-disabled
|
// https://www.whatwg.org/html/#dom-fieldset-disabled
|
||||||
make_bool_setter!(SetDisabled, "disabled");
|
make_bool_setter!(SetDisabled, "disabled");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -68,7 +68,7 @@ impl HTMLIFrameElementDerived for EventTarget {
|
||||||
pub trait HTMLIFrameElementHelpers {
|
pub trait HTMLIFrameElementHelpers {
|
||||||
fn is_sandboxed(self) -> bool;
|
fn is_sandboxed(self) -> bool;
|
||||||
fn get_url(self) -> Option<Url>;
|
fn get_url(self) -> Option<Url>;
|
||||||
/// http://www.whatwg.org/html/#process-the-iframe-attributes
|
/// https://www.whatwg.org/html/#process-the-iframe-attributes
|
||||||
fn process_the_iframe_attributes(self);
|
fn process_the_iframe_attributes(self);
|
||||||
fn generate_new_subpage_id(self) -> (SubpageId, Option<SubpageId>);
|
fn generate_new_subpage_id(self) -> (SubpageId, Option<SubpageId>);
|
||||||
fn navigate_child_browsing_context(self, url: Url);
|
fn navigate_child_browsing_context(self, url: Url);
|
||||||
|
|
|
@ -209,10 +209,10 @@ impl RawLayoutHTMLInputElementHelpers for HTMLInputElement {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> HTMLInputElementMethods for JSRef<'a, HTMLInputElement> {
|
impl<'a> HTMLInputElementMethods for JSRef<'a, HTMLInputElement> {
|
||||||
// http://www.whatwg.org/html/#dom-fe-disabled
|
// https://www.whatwg.org/html/#dom-fe-disabled
|
||||||
make_bool_getter!(Disabled);
|
make_bool_getter!(Disabled);
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fe-disabled
|
// https://www.whatwg.org/html/#dom-fe-disabled
|
||||||
make_bool_setter!(SetDisabled, "disabled");
|
make_bool_setter!(SetDisabled, "disabled");
|
||||||
|
|
||||||
// https://html.spec.whatwg.org/multipage/forms.html#dom-input-defaultchecked
|
// https://html.spec.whatwg.org/multipage/forms.html#dom-input-defaultchecked
|
||||||
|
|
|
@ -46,10 +46,10 @@ impl HTMLOptGroupElement {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> HTMLOptGroupElementMethods for JSRef<'a, HTMLOptGroupElement> {
|
impl<'a> HTMLOptGroupElementMethods for JSRef<'a, HTMLOptGroupElement> {
|
||||||
// http://www.whatwg.org/html#dom-optgroup-disabled
|
// https://www.whatwg.org/html#dom-optgroup-disabled
|
||||||
make_bool_getter!(Disabled);
|
make_bool_getter!(Disabled);
|
||||||
|
|
||||||
// http://www.whatwg.org/html#dom-optgroup-disabled
|
// https://www.whatwg.org/html#dom-optgroup-disabled
|
||||||
make_bool_setter!(SetDisabled, "disabled");
|
make_bool_setter!(SetDisabled, "disabled");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -69,16 +69,16 @@ fn collect_text(node: &JSRef<Node>, value: &mut DOMString) {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> HTMLOptionElementMethods for JSRef<'a, HTMLOptionElement> {
|
impl<'a> HTMLOptionElementMethods for JSRef<'a, HTMLOptionElement> {
|
||||||
// http://www.whatwg.org/html/#dom-option-disabled
|
// https://www.whatwg.org/html/#dom-option-disabled
|
||||||
make_bool_getter!(Disabled);
|
make_bool_getter!(Disabled);
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-option-disabled
|
// https://www.whatwg.org/html/#dom-option-disabled
|
||||||
fn SetDisabled(self, disabled: bool) {
|
fn SetDisabled(self, disabled: bool) {
|
||||||
let elem: JSRef<Element> = ElementCast::from_ref(self);
|
let elem: JSRef<Element> = ElementCast::from_ref(self);
|
||||||
elem.set_bool_attribute(&atom!("disabled"), disabled)
|
elem.set_bool_attribute(&atom!("disabled"), disabled)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-option-text
|
// https://www.whatwg.org/html/#dom-option-text
|
||||||
fn Text(self) -> DOMString {
|
fn Text(self) -> DOMString {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
let mut content = String::new();
|
let mut content = String::new();
|
||||||
|
@ -87,7 +87,7 @@ impl<'a> HTMLOptionElementMethods for JSRef<'a, HTMLOptionElement> {
|
||||||
v.connect(" ")
|
v.connect(" ")
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-option-text
|
// https://www.whatwg.org/html/#dom-option-text
|
||||||
fn SetText(self, value: DOMString) {
|
fn SetText(self, value: DOMString) {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.SetTextContent(Some(value))
|
node.SetTextContent(Some(value))
|
||||||
|
|
|
@ -96,7 +96,7 @@ impl HTMLScriptElement {
|
||||||
}
|
}
|
||||||
|
|
||||||
pub trait HTMLScriptElementHelpers {
|
pub trait HTMLScriptElementHelpers {
|
||||||
/// Prepare a script (<http://www.whatwg.org/html/#prepare-a-script>)
|
/// Prepare a script (<https://www.whatwg.org/html/#prepare-a-script>)
|
||||||
fn prepare(self);
|
fn prepare(self);
|
||||||
|
|
||||||
/// [Execute a script block]
|
/// [Execute a script block]
|
||||||
|
@ -126,7 +126,7 @@ pub trait HTMLScriptElementHelpers {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// Supported script types as defined by
|
/// Supported script types as defined by
|
||||||
/// <http://whatwg.org/html/#support-the-scripting-language>.
|
/// <https://whatwg.org/html/#support-the-scripting-language>.
|
||||||
static SCRIPT_JS_MIMES: StaticStringVec = &[
|
static SCRIPT_JS_MIMES: StaticStringVec = &[
|
||||||
"application/ecmascript",
|
"application/ecmascript",
|
||||||
"application/javascript",
|
"application/javascript",
|
||||||
|
@ -522,12 +522,12 @@ impl<'a> HTMLScriptElementMethods for JSRef<'a, HTMLScriptElement> {
|
||||||
|
|
||||||
make_setter!(SetSrc, "src");
|
make_setter!(SetSrc, "src");
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-script-text
|
// https://www.whatwg.org/html/#dom-script-text
|
||||||
fn Text(self) -> DOMString {
|
fn Text(self) -> DOMString {
|
||||||
Node::collect_text_contents(NodeCast::from_ref(self).children())
|
Node::collect_text_contents(NodeCast::from_ref(self).children())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-script-text
|
// https://www.whatwg.org/html/#dom-script-text
|
||||||
fn SetText(self, value: DOMString) {
|
fn SetText(self, value: DOMString) {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.SetTextContent(Some(value))
|
node.SetTextContent(Some(value))
|
||||||
|
|
|
@ -60,10 +60,10 @@ impl<'a> HTMLSelectElementMethods for JSRef<'a, HTMLSelectElement> {
|
||||||
fn Add(self, _element: HTMLOptionElementOrHTMLOptGroupElement, _before: Option<HTMLElementOrLong>) {
|
fn Add(self, _element: HTMLOptionElementOrHTMLOptGroupElement, _before: Option<HTMLElementOrLong>) {
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fe-disabled
|
// https://www.whatwg.org/html/#dom-fe-disabled
|
||||||
make_bool_getter!(Disabled);
|
make_bool_getter!(Disabled);
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fe-disabled
|
// https://www.whatwg.org/html/#dom-fe-disabled
|
||||||
make_bool_setter!(SetDisabled, "disabled");
|
make_bool_setter!(SetDisabled, "disabled");
|
||||||
|
|
||||||
// https://html.spec.whatwg.org/multipage/forms.html#dom-select-type
|
// https://html.spec.whatwg.org/multipage/forms.html#dom-select-type
|
||||||
|
|
|
@ -60,7 +60,7 @@ impl HTMLTableElement {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> HTMLTableElementMethods for JSRef<'a, HTMLTableElement> {
|
impl<'a> HTMLTableElementMethods for JSRef<'a, HTMLTableElement> {
|
||||||
// http://www.whatwg.org/html/#dom-table-caption
|
// https://www.whatwg.org/html/#dom-table-caption
|
||||||
fn GetCaption(self) -> Option<Temporary<HTMLTableCaptionElement>> {
|
fn GetCaption(self) -> Option<Temporary<HTMLTableCaptionElement>> {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.children()
|
node.children()
|
||||||
|
@ -71,7 +71,7 @@ impl<'a> HTMLTableElementMethods for JSRef<'a, HTMLTableElement> {
|
||||||
.next()
|
.next()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-table-caption
|
// https://www.whatwg.org/html/#dom-table-caption
|
||||||
fn SetCaption(self, new_caption: Option<JSRef<HTMLTableCaptionElement>>) {
|
fn SetCaption(self, new_caption: Option<JSRef<HTMLTableCaptionElement>>) {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
let old_caption = self.GetCaption();
|
let old_caption = self.GetCaption();
|
||||||
|
|
|
@ -116,10 +116,10 @@ impl<'a> HTMLTextAreaElementMethods for JSRef<'a, HTMLTextAreaElement> {
|
||||||
// https://html.spec.whatwg.org/multipage/forms.html#dom-textarea-cols
|
// https://html.spec.whatwg.org/multipage/forms.html#dom-textarea-cols
|
||||||
make_uint_setter!(SetCols, "cols");
|
make_uint_setter!(SetCols, "cols");
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fe-disabled
|
// https://www.whatwg.org/html/#dom-fe-disabled
|
||||||
make_bool_getter!(Disabled);
|
make_bool_getter!(Disabled);
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-fe-disabled
|
// https://www.whatwg.org/html/#dom-fe-disabled
|
||||||
make_bool_setter!(SetDisabled, "disabled");
|
make_bool_setter!(SetDisabled, "disabled");
|
||||||
|
|
||||||
// https://html.spec.whatwg.org/multipage/forms.html#attr-fe-name
|
// https://html.spec.whatwg.org/multipage/forms.html#attr-fe-name
|
||||||
|
|
|
@ -44,7 +44,7 @@ impl HTMLTitleElement {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> HTMLTitleElementMethods for JSRef<'a, HTMLTitleElement> {
|
impl<'a> HTMLTitleElementMethods for JSRef<'a, HTMLTitleElement> {
|
||||||
// http://www.whatwg.org/html/#dom-title-text
|
// https://www.whatwg.org/html/#dom-title-text
|
||||||
fn Text(self) -> DOMString {
|
fn Text(self) -> DOMString {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
let mut content = String::new();
|
let mut content = String::new();
|
||||||
|
@ -59,7 +59,7 @@ impl<'a> HTMLTitleElementMethods for JSRef<'a, HTMLTitleElement> {
|
||||||
content
|
content
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dom-title-text
|
// https://www.whatwg.org/html/#dom-title-text
|
||||||
fn SetText(self, value: DOMString) {
|
fn SetText(self, value: DOMString) {
|
||||||
let node: JSRef<Node> = NodeCast::from_ref(self);
|
let node: JSRef<Node> = NodeCast::from_ref(self);
|
||||||
node.SetTextContent(Some(value))
|
node.SetTextContent(Some(value))
|
||||||
|
|
|
@ -185,8 +185,8 @@ impl Drop for Node {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// suppress observers flag
|
/// suppress observers flag
|
||||||
/// http://dom.spec.whatwg.org/#concept-node-insert
|
/// https://dom.spec.whatwg.org/#concept-node-insert
|
||||||
/// http://dom.spec.whatwg.org/#concept-node-remove
|
/// https://dom.spec.whatwg.org/#concept-node-remove
|
||||||
#[derive(Copy)]
|
#[derive(Copy)]
|
||||||
enum SuppressObserver {
|
enum SuppressObserver {
|
||||||
Suppressed,
|
Suppressed,
|
||||||
|
@ -283,7 +283,7 @@ trait PrivateNodeHelpers {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> PrivateNodeHelpers for JSRef<'a, Node> {
|
impl<'a> PrivateNodeHelpers for JSRef<'a, Node> {
|
||||||
// http://dom.spec.whatwg.org/#node-is-inserted
|
// https://dom.spec.whatwg.org/#node-is-inserted
|
||||||
fn node_inserted(self) {
|
fn node_inserted(self) {
|
||||||
assert!(self.parent_node().is_some());
|
assert!(self.parent_node().is_some());
|
||||||
let document = document_from_node(self).root();
|
let document = document_from_node(self).root();
|
||||||
|
@ -299,7 +299,7 @@ impl<'a> PrivateNodeHelpers for JSRef<'a, Node> {
|
||||||
document.r().content_and_heritage_changed(self, NodeDamage::OtherNodeDamage);
|
document.r().content_and_heritage_changed(self, NodeDamage::OtherNodeDamage);
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#node-is-removed
|
// https://dom.spec.whatwg.org/#node-is-removed
|
||||||
fn node_removed(self, parent_in_doc: bool) {
|
fn node_removed(self, parent_in_doc: bool) {
|
||||||
assert!(self.parent_node().is_none());
|
assert!(self.parent_node().is_none());
|
||||||
for node in self.traverse_preorder() {
|
for node in self.traverse_preorder() {
|
||||||
|
@ -802,7 +802,7 @@ impl<'a> NodeHelpers for JSRef<'a, Node> {
|
||||||
window_from_node(self).root().r().content_boxes_query(self.to_trusted_node_address())
|
window_from_node(self).root().r().content_boxes_query(self.to_trusted_node_address())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-queryselector
|
// https://dom.spec.whatwg.org/#dom-parentnode-queryselector
|
||||||
fn query_selector(self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
|
fn query_selector(self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
match parse_author_origin_selector_list_from_str(selectors.as_slice()) {
|
match parse_author_origin_selector_list_from_str(selectors.as_slice()) {
|
||||||
|
@ -841,7 +841,7 @@ impl<'a> NodeHelpers for JSRef<'a, Node> {
|
||||||
Ok(nodes)
|
Ok(nodes)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-parentnode-queryselectorall
|
// https://dom.spec.whatwg.org/#dom-parentnode-queryselectorall
|
||||||
#[allow(unsafe_code)]
|
#[allow(unsafe_code)]
|
||||||
fn query_selector_all(self, selectors: DOMString) -> Fallible<Temporary<NodeList>> {
|
fn query_selector_all(self, selectors: DOMString) -> Fallible<Temporary<NodeList>> {
|
||||||
let mut nodes = RootedVec::new();
|
let mut nodes = RootedVec::new();
|
||||||
|
@ -1292,7 +1292,7 @@ impl Node {
|
||||||
self.layout_data.borrow_unchecked()
|
self.layout_data.borrow_unchecked()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-adopt
|
// https://dom.spec.whatwg.org/#concept-node-adopt
|
||||||
pub fn adopt(node: JSRef<Node>, document: JSRef<Document>) {
|
pub fn adopt(node: JSRef<Node>, document: JSRef<Document>) {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
match node.parent_node().root() {
|
match node.parent_node().root() {
|
||||||
|
@ -1314,7 +1314,7 @@ impl Node {
|
||||||
// If node is an element, it is _affected by a base URL change_.
|
// If node is an element, it is _affected by a base URL change_.
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-pre-insert
|
// https://dom.spec.whatwg.org/#concept-node-pre-insert
|
||||||
fn pre_insert(node: JSRef<Node>, parent: JSRef<Node>, child: Option<JSRef<Node>>)
|
fn pre_insert(node: JSRef<Node>, parent: JSRef<Node>, child: Option<JSRef<Node>>)
|
||||||
-> Fallible<Temporary<Node>> {
|
-> Fallible<Temporary<Node>> {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
|
@ -1452,7 +1452,7 @@ impl Node {
|
||||||
return Ok(Temporary::from_rooted(node))
|
return Ok(Temporary::from_rooted(node))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-insert
|
// https://dom.spec.whatwg.org/#concept-node-insert
|
||||||
fn insert(node: JSRef<Node>,
|
fn insert(node: JSRef<Node>,
|
||||||
parent: JSRef<Node>,
|
parent: JSRef<Node>,
|
||||||
child: Option<JSRef<Node>>,
|
child: Option<JSRef<Node>>,
|
||||||
|
@ -1519,7 +1519,7 @@ impl Node {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-replace-all
|
// https://dom.spec.whatwg.org/#concept-node-replace-all
|
||||||
pub fn replace_all(node: Option<JSRef<Node>>, parent: JSRef<Node>) {
|
pub fn replace_all(node: Option<JSRef<Node>>, parent: JSRef<Node>) {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
match node {
|
match node {
|
||||||
|
@ -1571,7 +1571,7 @@ impl Node {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-pre-remove
|
// https://dom.spec.whatwg.org/#concept-node-pre-remove
|
||||||
fn pre_remove(child: JSRef<Node>, parent: JSRef<Node>) -> Fallible<Temporary<Node>> {
|
fn pre_remove(child: JSRef<Node>, parent: JSRef<Node>) -> Fallible<Temporary<Node>> {
|
||||||
// Step 1.
|
// Step 1.
|
||||||
match child.parent_node() {
|
match child.parent_node() {
|
||||||
|
@ -1587,7 +1587,7 @@ impl Node {
|
||||||
Ok(Temporary::from_rooted(child))
|
Ok(Temporary::from_rooted(child))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-remove
|
// https://dom.spec.whatwg.org/#concept-node-remove
|
||||||
fn remove(node: JSRef<Node>, parent: JSRef<Node>, suppress_observers: SuppressObserver) {
|
fn remove(node: JSRef<Node>, parent: JSRef<Node>, suppress_observers: SuppressObserver) {
|
||||||
assert!(node.parent_node().map_or(false, |node_parent| node_parent == Temporary::from_rooted(parent)));
|
assert!(node.parent_node().map_or(false, |node_parent| node_parent == Temporary::from_rooted(parent)));
|
||||||
|
|
||||||
|
@ -1605,7 +1605,7 @@ impl Node {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-clone
|
// https://dom.spec.whatwg.org/#concept-node-clone
|
||||||
pub fn clone(node: JSRef<Node>, maybe_doc: Option<JSRef<Document>>,
|
pub fn clone(node: JSRef<Node>, maybe_doc: Option<JSRef<Document>>,
|
||||||
clone_children: CloneChildrenFlag) -> Temporary<Node> {
|
clone_children: CloneChildrenFlag) -> Temporary<Node> {
|
||||||
|
|
||||||
|
@ -1734,7 +1734,7 @@ impl Node {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> NodeMethods for JSRef<'a, Node> {
|
impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
// http://dom.spec.whatwg.org/#dom-node-nodetype
|
// https://dom.spec.whatwg.org/#dom-node-nodetype
|
||||||
fn NodeType(self) -> u16 {
|
fn NodeType(self) -> u16 {
|
||||||
match self.type_id {
|
match self.type_id {
|
||||||
NodeTypeId::Element(_) => NodeConstants::ELEMENT_NODE,
|
NodeTypeId::Element(_) => NodeConstants::ELEMENT_NODE,
|
||||||
|
@ -1747,7 +1747,7 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-nodename
|
// https://dom.spec.whatwg.org/#dom-node-nodename
|
||||||
fn NodeName(self) -> DOMString {
|
fn NodeName(self) -> DOMString {
|
||||||
match self.type_id {
|
match self.type_id {
|
||||||
NodeTypeId::Element(..) => {
|
NodeTypeId::Element(..) => {
|
||||||
|
@ -1770,13 +1770,13 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-baseuri
|
// https://dom.spec.whatwg.org/#dom-node-baseuri
|
||||||
fn GetBaseURI(self) -> Option<DOMString> {
|
fn GetBaseURI(self) -> Option<DOMString> {
|
||||||
// FIXME (#1824) implement.
|
// FIXME (#1824) implement.
|
||||||
None
|
None
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-ownerdocument
|
// https://dom.spec.whatwg.org/#dom-node-ownerdocument
|
||||||
fn GetOwnerDocument(self) -> Option<Temporary<Document>> {
|
fn GetOwnerDocument(self) -> Option<Temporary<Document>> {
|
||||||
match self.type_id {
|
match self.type_id {
|
||||||
NodeTypeId::Element(..) |
|
NodeTypeId::Element(..) |
|
||||||
|
@ -1789,12 +1789,12 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-parentnode
|
// https://dom.spec.whatwg.org/#dom-node-parentnode
|
||||||
fn GetParentNode(self) -> Option<Temporary<Node>> {
|
fn GetParentNode(self) -> Option<Temporary<Node>> {
|
||||||
self.parent_node.get()
|
self.parent_node.get()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-parentelement
|
// https://dom.spec.whatwg.org/#dom-node-parentelement
|
||||||
fn GetParentElement(self) -> Option<Temporary<Element>> {
|
fn GetParentElement(self) -> Option<Temporary<Element>> {
|
||||||
self.parent_node.get()
|
self.parent_node.get()
|
||||||
.and_then(|parent| {
|
.and_then(|parent| {
|
||||||
|
@ -1805,12 +1805,12 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-haschildnodes
|
// https://dom.spec.whatwg.org/#dom-node-haschildnodes
|
||||||
fn HasChildNodes(self) -> bool {
|
fn HasChildNodes(self) -> bool {
|
||||||
self.first_child.get().is_some()
|
self.first_child.get().is_some()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-childnodes
|
// https://dom.spec.whatwg.org/#dom-node-childnodes
|
||||||
fn ChildNodes(self) -> Temporary<NodeList> {
|
fn ChildNodes(self) -> Temporary<NodeList> {
|
||||||
self.child_list.or_init(|| {
|
self.child_list.or_init(|| {
|
||||||
let doc = self.owner_doc().root();
|
let doc = self.owner_doc().root();
|
||||||
|
@ -1819,27 +1819,27 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-firstchild
|
// https://dom.spec.whatwg.org/#dom-node-firstchild
|
||||||
fn GetFirstChild(self) -> Option<Temporary<Node>> {
|
fn GetFirstChild(self) -> Option<Temporary<Node>> {
|
||||||
self.first_child.get()
|
self.first_child.get()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-lastchild
|
// https://dom.spec.whatwg.org/#dom-node-lastchild
|
||||||
fn GetLastChild(self) -> Option<Temporary<Node>> {
|
fn GetLastChild(self) -> Option<Temporary<Node>> {
|
||||||
self.last_child.get()
|
self.last_child.get()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-previoussibling
|
// https://dom.spec.whatwg.org/#dom-node-previoussibling
|
||||||
fn GetPreviousSibling(self) -> Option<Temporary<Node>> {
|
fn GetPreviousSibling(self) -> Option<Temporary<Node>> {
|
||||||
self.prev_sibling.get()
|
self.prev_sibling.get()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-nextsibling
|
// https://dom.spec.whatwg.org/#dom-node-nextsibling
|
||||||
fn GetNextSibling(self) -> Option<Temporary<Node>> {
|
fn GetNextSibling(self) -> Option<Temporary<Node>> {
|
||||||
self.next_sibling.get()
|
self.next_sibling.get()
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-nodevalue
|
// https://dom.spec.whatwg.org/#dom-node-nodevalue
|
||||||
fn GetNodeValue(self) -> Option<DOMString> {
|
fn GetNodeValue(self) -> Option<DOMString> {
|
||||||
match self.type_id {
|
match self.type_id {
|
||||||
NodeTypeId::Comment |
|
NodeTypeId::Comment |
|
||||||
|
@ -1854,7 +1854,7 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-nodevalue
|
// https://dom.spec.whatwg.org/#dom-node-nodevalue
|
||||||
fn SetNodeValue(self, val: Option<DOMString>) {
|
fn SetNodeValue(self, val: Option<DOMString>) {
|
||||||
match self.type_id {
|
match self.type_id {
|
||||||
NodeTypeId::Comment |
|
NodeTypeId::Comment |
|
||||||
|
@ -1866,7 +1866,7 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-textcontent
|
// https://dom.spec.whatwg.org/#dom-node-textcontent
|
||||||
fn GetTextContent(self) -> Option<DOMString> {
|
fn GetTextContent(self) -> Option<DOMString> {
|
||||||
match self.type_id {
|
match self.type_id {
|
||||||
NodeTypeId::DocumentFragment |
|
NodeTypeId::DocumentFragment |
|
||||||
|
@ -1887,7 +1887,7 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-textcontent
|
// https://dom.spec.whatwg.org/#dom-node-textcontent
|
||||||
fn SetTextContent(self, value: Option<DOMString>) {
|
fn SetTextContent(self, value: Option<DOMString>) {
|
||||||
let value = null_str_as_empty(&value);
|
let value = null_str_as_empty(&value);
|
||||||
match self.type_id {
|
match self.type_id {
|
||||||
|
@ -1919,17 +1919,17 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-insertbefore
|
// https://dom.spec.whatwg.org/#dom-node-insertbefore
|
||||||
fn InsertBefore(self, node: JSRef<Node>, child: Option<JSRef<Node>>) -> Fallible<Temporary<Node>> {
|
fn InsertBefore(self, node: JSRef<Node>, child: Option<JSRef<Node>>) -> Fallible<Temporary<Node>> {
|
||||||
Node::pre_insert(node, self, child)
|
Node::pre_insert(node, self, child)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-appendchild
|
// https://dom.spec.whatwg.org/#dom-node-appendchild
|
||||||
fn AppendChild(self, node: JSRef<Node>) -> Fallible<Temporary<Node>> {
|
fn AppendChild(self, node: JSRef<Node>) -> Fallible<Temporary<Node>> {
|
||||||
Node::pre_insert(node, self, None)
|
Node::pre_insert(node, self, None)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-replace
|
// https://dom.spec.whatwg.org/#concept-node-replace
|
||||||
fn ReplaceChild(self, node: JSRef<Node>, child: JSRef<Node>) -> Fallible<Temporary<Node>> {
|
fn ReplaceChild(self, node: JSRef<Node>, child: JSRef<Node>) -> Fallible<Temporary<Node>> {
|
||||||
|
|
||||||
// Step 1.
|
// Step 1.
|
||||||
|
@ -2085,13 +2085,13 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
Ok(Temporary::from_rooted(child))
|
Ok(Temporary::from_rooted(child))
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-removechild
|
// https://dom.spec.whatwg.org/#dom-node-removechild
|
||||||
fn RemoveChild(self, node: JSRef<Node>)
|
fn RemoveChild(self, node: JSRef<Node>)
|
||||||
-> Fallible<Temporary<Node>> {
|
-> Fallible<Temporary<Node>> {
|
||||||
Node::pre_remove(node, self)
|
Node::pre_remove(node, self)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-normalize
|
// https://dom.spec.whatwg.org/#dom-node-normalize
|
||||||
fn Normalize(self) {
|
fn Normalize(self) {
|
||||||
let mut prev_text: Option<Temporary<Text>> = None;
|
let mut prev_text: Option<Temporary<Text>> = None;
|
||||||
for child in self.children() {
|
for child in self.children() {
|
||||||
|
@ -2121,7 +2121,7 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-clonenode
|
// https://dom.spec.whatwg.org/#dom-node-clonenode
|
||||||
fn CloneNode(self, deep: bool) -> Temporary<Node> {
|
fn CloneNode(self, deep: bool) -> Temporary<Node> {
|
||||||
Node::clone(self, None, if deep {
|
Node::clone(self, None, if deep {
|
||||||
CloneChildrenFlag::CloneChildren
|
CloneChildrenFlag::CloneChildren
|
||||||
|
@ -2130,7 +2130,7 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-isequalnode
|
// https://dom.spec.whatwg.org/#dom-node-isequalnode
|
||||||
fn IsEqualNode(self, maybe_node: Option<JSRef<Node>>) -> bool {
|
fn IsEqualNode(self, maybe_node: Option<JSRef<Node>>) -> bool {
|
||||||
fn is_equal_doctype(node: JSRef<Node>, other: JSRef<Node>) -> bool {
|
fn is_equal_doctype(node: JSRef<Node>, other: JSRef<Node>) -> bool {
|
||||||
let doctype: JSRef<DocumentType> = DocumentTypeCast::to_ref(node).unwrap();
|
let doctype: JSRef<DocumentType> = DocumentTypeCast::to_ref(node).unwrap();
|
||||||
|
@ -2211,7 +2211,7 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-comparedocumentposition
|
// https://dom.spec.whatwg.org/#dom-node-comparedocumentposition
|
||||||
fn CompareDocumentPosition(self, other: JSRef<Node>) -> u16 {
|
fn CompareDocumentPosition(self, other: JSRef<Node>) -> u16 {
|
||||||
if self == other {
|
if self == other {
|
||||||
// step 2.
|
// step 2.
|
||||||
|
@ -2269,7 +2269,7 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-contains
|
// https://dom.spec.whatwg.org/#dom-node-contains
|
||||||
fn Contains(self, maybe_other: Option<JSRef<Node>>) -> bool {
|
fn Contains(self, maybe_other: Option<JSRef<Node>>) -> bool {
|
||||||
match maybe_other {
|
match maybe_other {
|
||||||
None => false,
|
None => false,
|
||||||
|
@ -2277,19 +2277,19 @@ impl<'a> NodeMethods for JSRef<'a, Node> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-lookupprefix
|
// https://dom.spec.whatwg.org/#dom-node-lookupprefix
|
||||||
fn LookupPrefix(self, _prefix: Option<DOMString>) -> Option<DOMString> {
|
fn LookupPrefix(self, _prefix: Option<DOMString>) -> Option<DOMString> {
|
||||||
// FIXME (#1826) implement.
|
// FIXME (#1826) implement.
|
||||||
None
|
None
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-lookupnamespaceuri
|
// https://dom.spec.whatwg.org/#dom-node-lookupnamespaceuri
|
||||||
fn LookupNamespaceURI(self, _namespace: Option<DOMString>) -> Option<DOMString> {
|
fn LookupNamespaceURI(self, _namespace: Option<DOMString>) -> Option<DOMString> {
|
||||||
// FIXME (#1826) implement.
|
// FIXME (#1826) implement.
|
||||||
None
|
None
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-node-isdefaultnamespace
|
// https://dom.spec.whatwg.org/#dom-node-isdefaultnamespace
|
||||||
fn IsDefaultNamespace(self, _namespace: Option<DOMString>) -> bool {
|
fn IsDefaultNamespace(self, _namespace: Option<DOMString>) -> bool {
|
||||||
// FIXME (#1826) implement.
|
// FIXME (#1826) implement.
|
||||||
false
|
false
|
||||||
|
|
|
@ -37,7 +37,7 @@ impl Range {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> RangeMethods for JSRef<'a, Range> {
|
impl<'a> RangeMethods for JSRef<'a, Range> {
|
||||||
/// http://dom.spec.whatwg.org/#dom-range-detach
|
/// https://dom.spec.whatwg.org/#dom-range-detach
|
||||||
fn Detach(self) {
|
fn Detach(self) {
|
||||||
// This method intentionally left blank.
|
// This method intentionally left blank.
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,7 +15,7 @@ use dom::bindings::utils::{Reflector, reflect_dom_object};
|
||||||
use dom::document::{Document, DocumentHelpers};
|
use dom::document::{Document, DocumentHelpers};
|
||||||
use dom::node::{Node, NodeHelpers};
|
use dom::node::{Node, NodeHelpers};
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#interface-treewalker
|
// https://dom.spec.whatwg.org/#interface-treewalker
|
||||||
#[dom_struct]
|
#[dom_struct]
|
||||||
pub struct TreeWalker {
|
pub struct TreeWalker {
|
||||||
reflector_: Reflector,
|
reflector_: Reflector,
|
||||||
|
@ -149,7 +149,7 @@ trait PrivateTreeWalkerHelpers {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> PrivateTreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
impl<'a> PrivateTreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
||||||
// http://dom.spec.whatwg.org/#concept-traverse-children
|
// https://dom.spec.whatwg.org/#concept-traverse-children
|
||||||
fn traverse_children<F, G>(self,
|
fn traverse_children<F, G>(self,
|
||||||
next_child: F,
|
next_child: F,
|
||||||
next_sibling: G)
|
next_sibling: G)
|
||||||
|
@ -231,7 +231,7 @@ impl<'a> PrivateTreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
||||||
Ok(None)
|
Ok(None)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-traverse-siblings
|
// https://dom.spec.whatwg.org/#concept-traverse-siblings
|
||||||
fn traverse_siblings<F, G>(self,
|
fn traverse_siblings<F, G>(self,
|
||||||
next_child: F,
|
next_child: F,
|
||||||
next_sibling: G)
|
next_sibling: G)
|
||||||
|
@ -296,7 +296,7 @@ impl<'a> PrivateTreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-tree-following
|
// https://dom.spec.whatwg.org/#concept-tree-following
|
||||||
fn first_following_node_not_following_root(self, node: JSRef<Node>)
|
fn first_following_node_not_following_root(self, node: JSRef<Node>)
|
||||||
-> Option<Temporary<Node>> {
|
-> Option<Temporary<Node>> {
|
||||||
// "An object A is following an object B if A and B are in the same tree
|
// "An object A is following an object B if A and B are in the same tree
|
||||||
|
@ -323,7 +323,7 @@ impl<'a> PrivateTreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#concept-node-filter
|
// https://dom.spec.whatwg.org/#concept-node-filter
|
||||||
fn accept_node(self, node: JSRef<Node>) -> Fallible<u16> {
|
fn accept_node(self, node: JSRef<Node>) -> Fallible<u16> {
|
||||||
// "To filter node run these steps:"
|
// "To filter node run these steps:"
|
||||||
// "1. Let n be node's nodeType attribute value minus 1."
|
// "1. Let n be node's nodeType attribute value minus 1."
|
||||||
|
@ -364,7 +364,7 @@ pub trait TreeWalkerHelpers {
|
||||||
}
|
}
|
||||||
|
|
||||||
impl<'a> TreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
impl<'a> TreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
||||||
// http://dom.spec.whatwg.org/#dom-treewalker-parentnode
|
// https://dom.spec.whatwg.org/#dom-treewalker-parentnode
|
||||||
fn parent_node(self) -> Fallible<Option<Temporary<Node>>> {
|
fn parent_node(self) -> Fallible<Option<Temporary<Node>>> {
|
||||||
// "1. Let node be the value of the currentNode attribute."
|
// "1. Let node be the value of the currentNode attribute."
|
||||||
let mut node = self.current_node.get().root().get_unsound_ref_forever();
|
let mut node = self.current_node.get().root().get_unsound_ref_forever();
|
||||||
|
@ -391,35 +391,35 @@ impl<'a> TreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
||||||
Ok(None)
|
Ok(None)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-treewalker-firstchild
|
// https://dom.spec.whatwg.org/#dom-treewalker-firstchild
|
||||||
fn first_child(self) -> Fallible<Option<Temporary<Node>>> {
|
fn first_child(self) -> Fallible<Option<Temporary<Node>>> {
|
||||||
// "The firstChild() method must traverse children of type first."
|
// "The firstChild() method must traverse children of type first."
|
||||||
self.traverse_children(|node| node.first_child(),
|
self.traverse_children(|node| node.first_child(),
|
||||||
|node| node.next_sibling())
|
|node| node.next_sibling())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-treewalker-lastchild
|
// https://dom.spec.whatwg.org/#dom-treewalker-lastchild
|
||||||
fn last_child(self) -> Fallible<Option<Temporary<Node>>> {
|
fn last_child(self) -> Fallible<Option<Temporary<Node>>> {
|
||||||
// "The lastChild() method must traverse children of type last."
|
// "The lastChild() method must traverse children of type last."
|
||||||
self.traverse_children(|node| node.last_child(),
|
self.traverse_children(|node| node.last_child(),
|
||||||
|node| node.prev_sibling())
|
|node| node.prev_sibling())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-treewalker-nextsibling
|
// https://dom.spec.whatwg.org/#dom-treewalker-nextsibling
|
||||||
fn next_sibling(self) -> Fallible<Option<Temporary<Node>>> {
|
fn next_sibling(self) -> Fallible<Option<Temporary<Node>>> {
|
||||||
// "The nextSibling() method must traverse siblings of type next."
|
// "The nextSibling() method must traverse siblings of type next."
|
||||||
self.traverse_siblings(|node| node.first_child(),
|
self.traverse_siblings(|node| node.first_child(),
|
||||||
|node| node.next_sibling())
|
|node| node.next_sibling())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-treewalker-previoussibling
|
// https://dom.spec.whatwg.org/#dom-treewalker-previoussibling
|
||||||
fn prev_sibling(self) -> Fallible<Option<Temporary<Node>>> {
|
fn prev_sibling(self) -> Fallible<Option<Temporary<Node>>> {
|
||||||
// "The previousSibling() method must traverse siblings of type previous."
|
// "The previousSibling() method must traverse siblings of type previous."
|
||||||
self.traverse_siblings(|node| node.last_child(),
|
self.traverse_siblings(|node| node.last_child(),
|
||||||
|node| node.prev_sibling())
|
|node| node.prev_sibling())
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-treewalker-previousnode
|
// https://dom.spec.whatwg.org/#dom-treewalker-previousnode
|
||||||
fn prev_node(self) -> Fallible<Option<Temporary<Node>>> {
|
fn prev_node(self) -> Fallible<Option<Temporary<Node>>> {
|
||||||
// "1. Let node be the value of the currentNode attribute."
|
// "1. Let node be the value of the currentNode attribute."
|
||||||
let mut node = self.current_node.get().root().get_unsound_ref_forever();
|
let mut node = self.current_node.get().root().get_unsound_ref_forever();
|
||||||
|
@ -479,7 +479,7 @@ impl<'a> TreeWalkerHelpers for JSRef<'a, TreeWalker> {
|
||||||
Ok(None)
|
Ok(None)
|
||||||
}
|
}
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#dom-treewalker-nextnode
|
// https://dom.spec.whatwg.org/#dom-treewalker-nextnode
|
||||||
fn next_node(self) -> Fallible<Option<Temporary<Node>>> {
|
fn next_node(self) -> Fallible<Option<Temporary<Node>>> {
|
||||||
// "1. Let node be the value of the currentNode attribute."
|
// "1. Let node be the value of the currentNode attribute."
|
||||||
let mut node = self.current_node.get().root().get_unsound_ref_forever();
|
let mut node = self.current_node.get().root().get_unsound_ref_forever();
|
||||||
|
|
|
@ -47,7 +47,7 @@ impl URLSearchParams {
|
||||||
match init {
|
match init {
|
||||||
Some(eString(_s)) => {
|
Some(eString(_s)) => {
|
||||||
// XXXManishearth we need to parse the input here
|
// XXXManishearth we need to parse the input here
|
||||||
// http://url.spec.whatwg.org/#concept-urlencoded-parser
|
// https://url.spec.whatwg.org/#concept-urlencoded-parser
|
||||||
// We can use rust-url's implementation here:
|
// We can use rust-url's implementation here:
|
||||||
// https://github.com/SimonSapin/rust-url/blob/master/form_urlencoded.rs#L29
|
// https://github.com/SimonSapin/rust-url/blob/master/form_urlencoded.rs#L29
|
||||||
},
|
},
|
||||||
|
@ -115,9 +115,9 @@ pub trait URLSearchParamsHelpers {
|
||||||
|
|
||||||
impl URLSearchParamsHelpers for URLSearchParams {
|
impl URLSearchParamsHelpers for URLSearchParams {
|
||||||
fn serialize(&self, encoding: Option<EncodingRef>) -> Vec<u8> {
|
fn serialize(&self, encoding: Option<EncodingRef>) -> Vec<u8> {
|
||||||
// http://url.spec.whatwg.org/#concept-urlencoded-serializer
|
// https://url.spec.whatwg.org/#concept-urlencoded-serializer
|
||||||
fn serialize_string(value: &DOMString, encoding: EncodingRef) -> Vec<u8> {
|
fn serialize_string(value: &DOMString, encoding: EncodingRef) -> Vec<u8> {
|
||||||
// http://url.spec.whatwg.org/#concept-urlencoded-byte-serializer
|
// https://url.spec.whatwg.org/#concept-urlencoded-byte-serializer
|
||||||
|
|
||||||
let value = value.as_slice();
|
let value = value.as_slice();
|
||||||
// XXXManishearth should this be a strict encoding? Can unwrap()ing the result fail?
|
// XXXManishearth should this be a strict encoding? Can unwrap()ing the result fail?
|
||||||
|
@ -139,7 +139,7 @@ impl URLSearchParamsHelpers for URLSearchParams {
|
||||||
0x41...0x5A | 0x5F | 0x61...0x7A => vec!(*i),
|
0x41...0x5A | 0x5F | 0x61...0x7A => vec!(*i),
|
||||||
|
|
||||||
// Encode everything else using 'percented-encoded bytes'
|
// Encode everything else using 'percented-encoded bytes'
|
||||||
// http://url.spec.whatwg.org/#percent-encode
|
// https://url.spec.whatwg.org/#percent-encode
|
||||||
a => format!("%{:X}", a).into_bytes(),
|
a => format!("%{:X}", a).into_bytes(),
|
||||||
};
|
};
|
||||||
buf.push_all(&append);
|
buf.push_all(&append);
|
||||||
|
@ -170,6 +170,6 @@ impl URLSearchParamsHelpers for URLSearchParams {
|
||||||
|
|
||||||
fn update_steps(&self) {
|
fn update_steps(&self) {
|
||||||
// XXXManishearth Implement this when the URL interface is implemented
|
// XXXManishearth Implement this when the URL interface is implemented
|
||||||
// http://url.spec.whatwg.org/#concept-uq-update
|
// https://url.spec.whatwg.org/#concept-uq-update
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://dom.spec.whatwg.org/#interface-attr
|
* https://dom.spec.whatwg.org/#interface-attr
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
|
|
||||||
enum CanvasWindingRule { "nonzero", "evenodd" };
|
enum CanvasWindingRule { "nonzero", "evenodd" };
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#2dcontext
|
// https://www.whatwg.org/html/#2dcontext
|
||||||
typedef (HTMLImageElement or
|
typedef (HTMLImageElement or
|
||||||
/* HTMLVideoElement or */
|
/* HTMLVideoElement or */
|
||||||
HTMLCanvasElement or
|
HTMLCanvasElement or
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://dom.spec.whatwg.org/#characterdata
|
* https://dom.spec.whatwg.org/#characterdata
|
||||||
*
|
*
|
||||||
* Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
|
* Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
|
||||||
* liability, trademark and document use rules apply.
|
* liability, trademark and document use rules apply.
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is:
|
* The origin of this IDL file is:
|
||||||
* http://dom.spec.whatwg.org/#interface-childnode
|
* https://dom.spec.whatwg.org/#interface-childnode
|
||||||
*/
|
*/
|
||||||
|
|
||||||
[NoInterfaceObject]
|
[NoInterfaceObject]
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://dom.spec.whatwg.org/#comment
|
* https://dom.spec.whatwg.org/#comment
|
||||||
*
|
*
|
||||||
* Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
|
* Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
|
||||||
* liability, trademark and document use rules apply.
|
* liability, trademark and document use rules apply.
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* For more information on this interface please see
|
* For more information on this interface please see
|
||||||
* http://dom.spec.whatwg.org/#interface-customevent
|
* https://dom.spec.whatwg.org/#interface-customevent
|
||||||
*
|
*
|
||||||
* To the extent possible under law, the editors have waived
|
* To the extent possible under law, the editors have waived
|
||||||
* all copyright and related or neighboring rights to this work.
|
* all copyright and related or neighboring rights to this work.
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is:
|
* The origin of this IDL file is:
|
||||||
* http://dom.spec.whatwg.org/#domexception
|
* https://dom.spec.whatwg.org/#domexception
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// XXXkhuey this is an 'exception', not an interface, but we don't have any
|
// XXXkhuey this is an 'exception', not an interface, but we don't have any
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://dom.spec.whatwg.org/#interface-domimplementation
|
* https://dom.spec.whatwg.org/#interface-domimplementation
|
||||||
*
|
*
|
||||||
* Copyright:
|
* Copyright:
|
||||||
* To the extent possible under law, the editors have waived all copyright and
|
* To the extent possible under law, the editors have waived all copyright and
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://domparsing.spec.whatwg.org/#the-domparser-interface
|
* https://domparsing.spec.whatwg.org/#the-domparser-interface
|
||||||
*/
|
*/
|
||||||
|
|
||||||
enum SupportedType {
|
enum SupportedType {
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#domtokenlist
|
// https://dom.spec.whatwg.org/#domtokenlist
|
||||||
interface DOMTokenList {
|
interface DOMTokenList {
|
||||||
readonly attribute unsigned long length;
|
readonly attribute unsigned long length;
|
||||||
getter DOMString? item(unsigned long index);
|
getter DOMString? item(unsigned long index);
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#dedicatedworkerglobalscope
|
// https://www.whatwg.org/html/#dedicatedworkerglobalscope
|
||||||
[Global/*=Worker,DedicatedWorker*/]
|
[Global/*=Worker,DedicatedWorker*/]
|
||||||
/*sealed*/ interface DedicatedWorkerGlobalScope : WorkerGlobalScope {
|
/*sealed*/ interface DedicatedWorkerGlobalScope : WorkerGlobalScope {
|
||||||
[Throws]
|
[Throws]
|
||||||
|
|
|
@ -4,11 +4,11 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is:
|
* The origin of this IDL file is:
|
||||||
* http://dom.spec.whatwg.org/#interface-document
|
* https://dom.spec.whatwg.org/#interface-document
|
||||||
* http://www.whatwg.org/specs/web-apps/current-work/#the-document-object
|
* https://www.whatwg.org/specs/web-apps/current-work/#the-document-object
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* http://dom.spec.whatwg.org/#interface-document */
|
/* https://dom.spec.whatwg.org/#interface-document */
|
||||||
[Constructor]
|
[Constructor]
|
||||||
interface Document : Node {
|
interface Document : Node {
|
||||||
readonly attribute DOMImplementation implementation;
|
readonly attribute DOMImplementation implementation;
|
||||||
|
@ -66,7 +66,7 @@ Document implements ParentNode;
|
||||||
|
|
||||||
enum DocumentReadyState { "loading", "interactive", "complete" };
|
enum DocumentReadyState { "loading", "interactive", "complete" };
|
||||||
|
|
||||||
/* http://www.whatwg.org/specs/web-apps/current-work/#the-document-object */
|
/* https://www.whatwg.org/specs/web-apps/current-work/#the-document-object */
|
||||||
partial interface Document {
|
partial interface Document {
|
||||||
// resource metadata management
|
// resource metadata management
|
||||||
readonly attribute DocumentReadyState readyState;
|
readonly attribute DocumentReadyState readyState;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://dom.spec.whatwg.org/#interface-documentfragment
|
// https://dom.spec.whatwg.org/#interface-documentfragment
|
||||||
[Constructor]
|
[Constructor]
|
||||||
interface DocumentFragment : Node {
|
interface DocumentFragment : Node {
|
||||||
};
|
};
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://dom.spec.whatwg.org/#documenttype
|
* https://dom.spec.whatwg.org/#documenttype
|
||||||
*
|
*
|
||||||
* Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
|
* Copyright © 2012 W3C® (MIT, ERCIM, Keio), All Rights Reserved. W3C
|
||||||
* liability, trademark and document use rules apply.
|
* liability, trademark and document use rules apply.
|
||||||
|
|
|
@ -4,8 +4,8 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://dom.spec.whatwg.org/#element and
|
* https://dom.spec.whatwg.org/#element and
|
||||||
* http://domparsing.spec.whatwg.org/ and
|
* https://domparsing.spec.whatwg.org/ and
|
||||||
* http://dev.w3.org/csswg/cssom-view/ and
|
* http://dev.w3.org/csswg/cssom-view/ and
|
||||||
* http://www.w3.org/TR/selectors-api/
|
* http://www.w3.org/TR/selectors-api/
|
||||||
*
|
*
|
||||||
|
@ -61,7 +61,7 @@ partial interface Element {
|
||||||
DOMRect getBoundingClientRect();
|
DOMRect getBoundingClientRect();
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://domparsing.spec.whatwg.org/#extensions-to-the-element-interface
|
// https://domparsing.spec.whatwg.org/#extensions-to-the-element-interface
|
||||||
partial interface Element {
|
partial interface Element {
|
||||||
[Throws,TreatNullAs=EmptyString]
|
[Throws,TreatNullAs=EmptyString]
|
||||||
attribute DOMString innerHTML;
|
attribute DOMString innerHTML;
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://www.whatwg.org/specs/web-apps/current-work/#eventhandler
|
* https://www.whatwg.org/specs/web-apps/current-work/#eventhandler
|
||||||
*
|
*
|
||||||
* © Copyright 2004-2011 Apple Computer, Inc., Mozilla Foundation, and
|
* © Copyright 2004-2011 Apple Computer, Inc., Mozilla Foundation, and
|
||||||
* Opera Software ASA. You are granted a license to use, reproduce
|
* Opera Software ASA. You are granted a license to use, reproduce
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://xhr.spec.whatwg.org
|
* https://xhr.spec.whatwg.org
|
||||||
*/
|
*/
|
||||||
|
|
||||||
typedef (File or DOMString) FormDataEntryValue;
|
typedef (File or DOMString) FormDataEntryValue;
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://www.whatwg.org/specs/web-apps/current-work/#functiocn
|
* https://www.whatwg.org/specs/web-apps/current-work/#functiocn
|
||||||
*
|
*
|
||||||
* © Copyright 2004-2011 Apple Computer, Inc., Mozilla Foundation, and
|
* © Copyright 2004-2011 Apple Computer, Inc., Mozilla Foundation, and
|
||||||
* Opera Software ASA. You are granted a license to use, reproduce
|
* Opera Software ASA. You are granted a license to use, reproduce
|
||||||
|
|
|
@ -4,14 +4,14 @@
|
||||||
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
* You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
*
|
*
|
||||||
* The origin of this IDL file is
|
* The origin of this IDL file is
|
||||||
* http://www.whatwg.org/specs/web-apps/current-work/#the-a-element
|
* https://www.whatwg.org/specs/web-apps/current-work/#the-a-element
|
||||||
* http://www.whatwg.org/specs/web-apps/current-work/#other-elements,-attributes-and-apis
|
* https://www.whatwg.org/specs/web-apps/current-work/#other-elements,-attributes-and-apis
|
||||||
* © Copyright 2004-2011 Apple Computer, Inc., Mozilla Foundation, and
|
* © Copyright 2004-2011 Apple Computer, Inc., Mozilla Foundation, and
|
||||||
* Opera Software ASA. You are granted a license to use, reproduce
|
* Opera Software ASA. You are granted a license to use, reproduce
|
||||||
* and create derivative works of this document.
|
* and create derivative works of this document.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlanchorelement
|
// https://www.whatwg.org/html/#htmlanchorelement
|
||||||
interface HTMLAnchorElement : HTMLElement {
|
interface HTMLAnchorElement : HTMLElement {
|
||||||
// attribute DOMString target;
|
// attribute DOMString target;
|
||||||
// attribute DOMString download;
|
// attribute DOMString download;
|
||||||
|
@ -28,7 +28,7 @@ interface HTMLAnchorElement : HTMLElement {
|
||||||
};
|
};
|
||||||
//HTMLAnchorElement implements URLUtils;
|
//HTMLAnchorElement implements URLUtils;
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLAnchorElement-partial
|
// https://www.whatwg.org/html/#HTMLAnchorElement-partial
|
||||||
partial interface HTMLAnchorElement {
|
partial interface HTMLAnchorElement {
|
||||||
// attribute DOMString coords;
|
// attribute DOMString coords;
|
||||||
// attribute DOMString charset;
|
// attribute DOMString charset;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlappletelement
|
// https://www.whatwg.org/html/#htmlappletelement
|
||||||
interface HTMLAppletElement : HTMLElement {
|
interface HTMLAppletElement : HTMLElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
// attribute DOMString alt;
|
// attribute DOMString alt;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlareaelement
|
// https://www.whatwg.org/html/#htmlareaelement
|
||||||
interface HTMLAreaElement : HTMLElement {
|
interface HTMLAreaElement : HTMLElement {
|
||||||
// attribute DOMString alt;
|
// attribute DOMString alt;
|
||||||
// attribute DOMString coords;
|
// attribute DOMString coords;
|
||||||
|
@ -20,7 +20,7 @@ interface HTMLAreaElement : HTMLElement {
|
||||||
};
|
};
|
||||||
//HTMLAreaElement implements URLUtils;
|
//HTMLAreaElement implements URLUtils;
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLAreaElement-partial
|
// https://www.whatwg.org/html/#HTMLAreaElement-partial
|
||||||
partial interface HTMLAreaElement {
|
partial interface HTMLAreaElement {
|
||||||
// attribute boolean noHref;
|
// attribute boolean noHref;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,6 +3,6 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlaudioelement
|
// https://www.whatwg.org/html/#htmlaudioelement
|
||||||
//[NamedConstructor=Audio(optional DOMString src)]
|
//[NamedConstructor=Audio(optional DOMString src)]
|
||||||
interface HTMLAudioElement : HTMLMediaElement {};
|
interface HTMLAudioElement : HTMLMediaElement {};
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlbrelement
|
// https://www.whatwg.org/html/#htmlbrelement
|
||||||
interface HTMLBRElement : HTMLElement {
|
interface HTMLBRElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLBRElement-partial
|
// https://www.whatwg.org/html/#HTMLBRElement-partial
|
||||||
partial interface HTMLBRElement {
|
partial interface HTMLBRElement {
|
||||||
// attribute DOMString clear;
|
// attribute DOMString clear;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlbaseelement
|
// https://www.whatwg.org/html/#htmlbaseelement
|
||||||
interface HTMLBaseElement : HTMLElement {
|
interface HTMLBaseElement : HTMLElement {
|
||||||
// attribute DOMString href;
|
// attribute DOMString href;
|
||||||
// attribute DOMString target;
|
// attribute DOMString target;
|
||||||
|
|
|
@ -3,14 +3,14 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlbodyelement
|
// https://www.whatwg.org/html/#htmlbodyelement
|
||||||
interface HTMLBodyElement : HTMLElement {
|
interface HTMLBodyElement : HTMLElement {
|
||||||
|
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
HTMLBodyElement implements WindowEventHandlers;
|
HTMLBodyElement implements WindowEventHandlers;
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLBodyElement-partial
|
// https://www.whatwg.org/html/#HTMLBodyElement-partial
|
||||||
partial interface HTMLBodyElement {
|
partial interface HTMLBodyElement {
|
||||||
//[TreatNullAs=EmptyString] attribute DOMString text;
|
//[TreatNullAs=EmptyString] attribute DOMString text;
|
||||||
//[TreatNullAs=EmptyString] attribute DOMString link;
|
//[TreatNullAs=EmptyString] attribute DOMString link;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlbuttonelement
|
// https://www.whatwg.org/html/#htmlbuttonelement
|
||||||
interface HTMLButtonElement : HTMLElement {
|
interface HTMLButtonElement : HTMLElement {
|
||||||
// attribute boolean autofocus;
|
// attribute boolean autofocus;
|
||||||
attribute boolean disabled;
|
attribute boolean disabled;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlcanvaselement
|
// https://www.whatwg.org/html/#htmlcanvaselement
|
||||||
//typedef (CanvasRenderingContext2D or WebGLRenderingContext) RenderingContext;
|
//typedef (CanvasRenderingContext2D or WebGLRenderingContext) RenderingContext;
|
||||||
|
|
||||||
interface HTMLCanvasElement : HTMLElement {
|
interface HTMLCanvasElement : HTMLElement {
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmldlistelement
|
// https://www.whatwg.org/html/#htmldlistelement
|
||||||
interface HTMLDListElement : HTMLElement {
|
interface HTMLDListElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLDListElement-partial
|
// https://www.whatwg.org/html/#HTMLDListElement-partial
|
||||||
partial interface HTMLDListElement {
|
partial interface HTMLDListElement {
|
||||||
// attribute boolean compact;
|
// attribute boolean compact;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmldataelement
|
// https://www.whatwg.org/html/#htmldataelement
|
||||||
interface HTMLDataElement : HTMLElement {
|
interface HTMLDataElement : HTMLElement {
|
||||||
// attribute DOMString value;
|
// attribute DOMString value;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmldatalistelement
|
// https://www.whatwg.org/html/#htmldatalistelement
|
||||||
interface HTMLDataListElement : HTMLElement {
|
interface HTMLDataListElement : HTMLElement {
|
||||||
readonly attribute HTMLCollection options;
|
readonly attribute HTMLCollection options;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmldialogelement
|
// https://www.whatwg.org/html/#htmldialogelement
|
||||||
interface HTMLDialogElement : HTMLElement {
|
interface HTMLDialogElement : HTMLElement {
|
||||||
//attribute boolean open;
|
//attribute boolean open;
|
||||||
//attribute DOMString returnValue;
|
//attribute DOMString returnValue;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmldirectoryelement
|
// https://www.whatwg.org/html/#htmldirectoryelement
|
||||||
interface HTMLDirectoryElement : HTMLElement {
|
interface HTMLDirectoryElement : HTMLElement {
|
||||||
// attribute boolean compact;
|
// attribute boolean compact;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmldivelement
|
// https://www.whatwg.org/html/#htmldivelement
|
||||||
interface HTMLDivElement : HTMLElement {
|
interface HTMLDivElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLDivElement-partial
|
// https://www.whatwg.org/html/#HTMLDivElement-partial
|
||||||
partial interface HTMLDivElement {
|
partial interface HTMLDivElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlelement
|
// https://www.whatwg.org/html/#htmlelement
|
||||||
interface HTMLElement : Element {
|
interface HTMLElement : Element {
|
||||||
// metadata attributes
|
// metadata attributes
|
||||||
attribute DOMString title;
|
attribute DOMString title;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlembedelement
|
// https://www.whatwg.org/html/#htmlembedelement
|
||||||
interface HTMLEmbedElement : HTMLElement {
|
interface HTMLEmbedElement : HTMLElement {
|
||||||
// attribute DOMString src;
|
// attribute DOMString src;
|
||||||
// attribute DOMString type;
|
// attribute DOMString type;
|
||||||
|
@ -14,7 +14,7 @@ interface HTMLEmbedElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLEmbedElement-partial
|
// https://www.whatwg.org/html/#HTMLEmbedElement-partial
|
||||||
partial interface HTMLEmbedElement {
|
partial interface HTMLEmbedElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
// attribute DOMString name;
|
// attribute DOMString name;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlfieldsetelement
|
// https://www.whatwg.org/html/#htmlfieldsetelement
|
||||||
interface HTMLFieldSetElement : HTMLElement {
|
interface HTMLFieldSetElement : HTMLElement {
|
||||||
attribute boolean disabled;
|
attribute boolean disabled;
|
||||||
//readonly attribute HTMLFormElement? form;
|
//readonly attribute HTMLFormElement? form;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlfontelement
|
// https://www.whatwg.org/html/#htmlfontelement
|
||||||
interface HTMLFontElement : HTMLElement {
|
interface HTMLFontElement : HTMLElement {
|
||||||
//[TreatNullAs=EmptyString] attribute DOMString color;
|
//[TreatNullAs=EmptyString] attribute DOMString color;
|
||||||
// attribute DOMString face;
|
// attribute DOMString face;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlformelement
|
// https://www.whatwg.org/html/#htmlformelement
|
||||||
//[OverrideBuiltins]
|
//[OverrideBuiltins]
|
||||||
interface HTMLFormElement : HTMLElement {
|
interface HTMLFormElement : HTMLElement {
|
||||||
attribute DOMString acceptCharset;
|
attribute DOMString acceptCharset;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlframeelement
|
// https://www.whatwg.org/html/#htmlframeelement
|
||||||
interface HTMLFrameElement : HTMLElement {
|
interface HTMLFrameElement : HTMLElement {
|
||||||
// attribute DOMString name;
|
// attribute DOMString name;
|
||||||
// attribute DOMString scrolling;
|
// attribute DOMString scrolling;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlframesetelement
|
// https://www.whatwg.org/html/#htmlframesetelement
|
||||||
interface HTMLFrameSetElement : HTMLElement {
|
interface HTMLFrameSetElement : HTMLElement {
|
||||||
// attribute DOMString cols;
|
// attribute DOMString cols;
|
||||||
// attribute DOMString rows;
|
// attribute DOMString rows;
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlhrelement
|
// https://www.whatwg.org/html/#htmlhrelement
|
||||||
interface HTMLHRElement : HTMLElement {
|
interface HTMLHRElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLHRElement-partial
|
// https://www.whatwg.org/html/#HTMLHRElement-partial
|
||||||
partial interface HTMLHRElement {
|
partial interface HTMLHRElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
// attribute DOMString color;
|
// attribute DOMString color;
|
||||||
|
|
|
@ -3,5 +3,5 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlheadelement
|
// https://www.whatwg.org/html/#htmlheadelement
|
||||||
interface HTMLHeadElement : HTMLElement {};
|
interface HTMLHeadElement : HTMLElement {};
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlheadingelement
|
// https://www.whatwg.org/html/#htmlheadingelement
|
||||||
interface HTMLHeadingElement : HTMLElement {
|
interface HTMLHeadingElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLHeadingElement-partial
|
// https://www.whatwg.org/html/#HTMLHeadingElement-partial
|
||||||
partial interface HTMLHeadingElement {
|
partial interface HTMLHeadingElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlhtmlelement
|
// https://www.whatwg.org/html/#htmlhtmlelement
|
||||||
interface HTMLHtmlElement : HTMLElement {
|
interface HTMLHtmlElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLHtmlElement-partial
|
// https://www.whatwg.org/html/#HTMLHtmlElement-partial
|
||||||
partial interface HTMLHtmlElement {
|
partial interface HTMLHtmlElement {
|
||||||
// attribute DOMString version;
|
// attribute DOMString version;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmliframeelement
|
// https://www.whatwg.org/html/#htmliframeelement
|
||||||
interface HTMLIFrameElement : HTMLElement {
|
interface HTMLIFrameElement : HTMLElement {
|
||||||
attribute DOMString src;
|
attribute DOMString src;
|
||||||
// attribute DOMString srcdoc;
|
// attribute DOMString srcdoc;
|
||||||
|
@ -21,7 +21,7 @@ interface HTMLIFrameElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLIFrameElement-partial
|
// https://www.whatwg.org/html/#HTMLIFrameElement-partial
|
||||||
partial interface HTMLIFrameElement {
|
partial interface HTMLIFrameElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
// attribute DOMString scrolling;
|
// attribute DOMString scrolling;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlimageelement
|
// https://www.whatwg.org/html/#htmlimageelement
|
||||||
//[NamedConstructor=Image(optional unsigned long width, optional unsigned long height)]
|
//[NamedConstructor=Image(optional unsigned long width, optional unsigned long height)]
|
||||||
interface HTMLImageElement : HTMLElement {
|
interface HTMLImageElement : HTMLElement {
|
||||||
attribute DOMString alt;
|
attribute DOMString alt;
|
||||||
|
@ -21,7 +21,7 @@ interface HTMLImageElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLImageElement-partial
|
// https://www.whatwg.org/html/#HTMLImageElement-partial
|
||||||
partial interface HTMLImageElement {
|
partial interface HTMLImageElement {
|
||||||
attribute DOMString name;
|
attribute DOMString name;
|
||||||
// attribute DOMString lowsrc;
|
// attribute DOMString lowsrc;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlinputelement
|
// https://www.whatwg.org/html/#htmlinputelement
|
||||||
interface HTMLInputElement : HTMLElement {
|
interface HTMLInputElement : HTMLElement {
|
||||||
// attribute DOMString accept;
|
// attribute DOMString accept;
|
||||||
// attribute DOMString alt;
|
// attribute DOMString alt;
|
||||||
|
@ -69,7 +69,7 @@ interface HTMLInputElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLInputElement-partial
|
// https://www.whatwg.org/html/#HTMLInputElement-partial
|
||||||
partial interface HTMLInputElement {
|
partial interface HTMLInputElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
// attribute DOMString useMap;
|
// attribute DOMString useMap;
|
||||||
|
|
|
@ -3,14 +3,14 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmllielement
|
// https://www.whatwg.org/html/#htmllielement
|
||||||
interface HTMLLIElement : HTMLElement {
|
interface HTMLLIElement : HTMLElement {
|
||||||
// attribute long value;
|
// attribute long value;
|
||||||
|
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLLIElement-partial
|
// https://www.whatwg.org/html/#HTMLLIElement-partial
|
||||||
partial interface HTMLLIElement {
|
partial interface HTMLLIElement {
|
||||||
// attribute DOMString type;
|
// attribute DOMString type;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmllabelelement
|
// https://www.whatwg.org/html/#htmllabelelement
|
||||||
interface HTMLLabelElement : HTMLElement {
|
interface HTMLLabelElement : HTMLElement {
|
||||||
//readonly attribute HTMLFormElement? form;
|
//readonly attribute HTMLFormElement? form;
|
||||||
// attribute DOMString htmlFor;
|
// attribute DOMString htmlFor;
|
||||||
|
|
|
@ -3,14 +3,14 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmllegendelement
|
// https://www.whatwg.org/html/#htmllegendelement
|
||||||
interface HTMLLegendElement : HTMLElement {
|
interface HTMLLegendElement : HTMLElement {
|
||||||
//readonly attribute HTMLFormElement? form;
|
//readonly attribute HTMLFormElement? form;
|
||||||
|
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLLegendElement-partial
|
// https://www.whatwg.org/html/#HTMLLegendElement-partial
|
||||||
partial interface HTMLLegendElement {
|
partial interface HTMLLegendElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmllinkelement
|
// https://www.whatwg.org/html/#htmllinkelement
|
||||||
interface HTMLLinkElement : HTMLElement {
|
interface HTMLLinkElement : HTMLElement {
|
||||||
attribute DOMString href;
|
attribute DOMString href;
|
||||||
// attribute DOMString crossOrigin;
|
// attribute DOMString crossOrigin;
|
||||||
|
@ -18,7 +18,7 @@ interface HTMLLinkElement : HTMLElement {
|
||||||
};
|
};
|
||||||
//HTMLLinkElement implements LinkStyle;
|
//HTMLLinkElement implements LinkStyle;
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLLinkElement-partial
|
// https://www.whatwg.org/html/#HTMLLinkElement-partial
|
||||||
partial interface HTMLLinkElement {
|
partial interface HTMLLinkElement {
|
||||||
// attribute DOMString charset;
|
// attribute DOMString charset;
|
||||||
// attribute DOMString rev;
|
// attribute DOMString rev;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlmapelement
|
// https://www.whatwg.org/html/#htmlmapelement
|
||||||
interface HTMLMapElement : HTMLElement {
|
interface HTMLMapElement : HTMLElement {
|
||||||
// attribute DOMString name;
|
// attribute DOMString name;
|
||||||
//readonly attribute HTMLCollection areas;
|
//readonly attribute HTMLCollection areas;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlmediaelement
|
// https://www.whatwg.org/html/#htmlmediaelement
|
||||||
//enum CanPlayTypeResult { "" /* empty string */, "maybe", "probably" };
|
//enum CanPlayTypeResult { "" /* empty string */, "maybe", "probably" };
|
||||||
interface HTMLMediaElement : HTMLElement {
|
interface HTMLMediaElement : HTMLElement {
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlmetaelement
|
// https://www.whatwg.org/html/#htmlmetaelement
|
||||||
interface HTMLMetaElement : HTMLElement {
|
interface HTMLMetaElement : HTMLElement {
|
||||||
// attribute DOMString name;
|
// attribute DOMString name;
|
||||||
// attribute DOMString httpEquiv;
|
// attribute DOMString httpEquiv;
|
||||||
|
@ -12,7 +12,7 @@ interface HTMLMetaElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLMetaElement-partial
|
// https://www.whatwg.org/html/#HTMLMetaElement-partial
|
||||||
partial interface HTMLMetaElement {
|
partial interface HTMLMetaElement {
|
||||||
// attribute DOMString scheme;
|
// attribute DOMString scheme;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlmeterelement
|
// https://www.whatwg.org/html/#htmlmeterelement
|
||||||
interface HTMLMeterElement : HTMLElement {
|
interface HTMLMeterElement : HTMLElement {
|
||||||
// attribute double value;
|
// attribute double value;
|
||||||
// attribute double min;
|
// attribute double min;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlmodelement
|
// https://www.whatwg.org/html/#htmlmodelement
|
||||||
interface HTMLModElement : HTMLElement {
|
interface HTMLModElement : HTMLElement {
|
||||||
// attribute DOMString cite;
|
// attribute DOMString cite;
|
||||||
// attribute DOMString dateTime;
|
// attribute DOMString dateTime;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlolistelement
|
// https://www.whatwg.org/html/#htmlolistelement
|
||||||
interface HTMLOListElement : HTMLElement {
|
interface HTMLOListElement : HTMLElement {
|
||||||
// attribute boolean reversed;
|
// attribute boolean reversed;
|
||||||
// attribute long start;
|
// attribute long start;
|
||||||
|
@ -12,7 +12,7 @@ interface HTMLOListElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLOListElement-partial
|
// https://www.whatwg.org/html/#HTMLOListElement-partial
|
||||||
partial interface HTMLOListElement {
|
partial interface HTMLOListElement {
|
||||||
// attribute boolean compact;
|
// attribute boolean compact;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlobjectelement
|
// https://www.whatwg.org/html/#htmlobjectelement
|
||||||
interface HTMLObjectElement : HTMLElement {
|
interface HTMLObjectElement : HTMLElement {
|
||||||
// attribute DOMString data;
|
// attribute DOMString data;
|
||||||
attribute DOMString type;
|
attribute DOMString type;
|
||||||
|
@ -28,7 +28,7 @@ interface HTMLObjectElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLObjectElement-partial
|
// https://www.whatwg.org/html/#HTMLObjectElement-partial
|
||||||
partial interface HTMLObjectElement {
|
partial interface HTMLObjectElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
// attribute DOMString archive;
|
// attribute DOMString archive;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmloptgroupelement
|
// https://www.whatwg.org/html/#htmloptgroupelement
|
||||||
interface HTMLOptGroupElement : HTMLElement {
|
interface HTMLOptGroupElement : HTMLElement {
|
||||||
attribute boolean disabled;
|
attribute boolean disabled;
|
||||||
// attribute DOMString label;
|
// attribute DOMString label;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmloptionelement
|
// https://www.whatwg.org/html/#htmloptionelement
|
||||||
//[NamedConstructor=Option(optional DOMString text = "", optional DOMString value, optional boolean defaultSelected = false, optional boolean selected = false)]
|
//[NamedConstructor=Option(optional DOMString text = "", optional DOMString value, optional boolean defaultSelected = false, optional boolean selected = false)]
|
||||||
interface HTMLOptionElement : HTMLElement {
|
interface HTMLOptionElement : HTMLElement {
|
||||||
attribute boolean disabled;
|
attribute boolean disabled;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmloutputelement
|
// https://www.whatwg.org/html/#htmloutputelement
|
||||||
interface HTMLOutputElement : HTMLElement {
|
interface HTMLOutputElement : HTMLElement {
|
||||||
//[PutForwards=value] readonly attribute DOMSettableTokenList htmlFor;
|
//[PutForwards=value] readonly attribute DOMSettableTokenList htmlFor;
|
||||||
//readonly attribute HTMLFormElement? form;
|
//readonly attribute HTMLFormElement? form;
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlparagraphelement
|
// https://www.whatwg.org/html/#htmlparagraphelement
|
||||||
interface HTMLParagraphElement : HTMLElement {
|
interface HTMLParagraphElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLParagraphElement-partial
|
// https://www.whatwg.org/html/#HTMLParagraphElement-partial
|
||||||
partial interface HTMLParagraphElement {
|
partial interface HTMLParagraphElement {
|
||||||
// attribute DOMString align;
|
// attribute DOMString align;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlparamelement
|
// https://www.whatwg.org/html/#htmlparamelement
|
||||||
interface HTMLParamElement : HTMLElement {
|
interface HTMLParamElement : HTMLElement {
|
||||||
// attribute DOMString name;
|
// attribute DOMString name;
|
||||||
// attribute DOMString value;
|
// attribute DOMString value;
|
||||||
|
@ -11,7 +11,7 @@ interface HTMLParamElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLParamElement-partial
|
// https://www.whatwg.org/html/#HTMLParamElement-partial
|
||||||
partial interface HTMLParamElement {
|
partial interface HTMLParamElement {
|
||||||
// attribute DOMString type;
|
// attribute DOMString type;
|
||||||
// attribute DOMString valueType;
|
// attribute DOMString valueType;
|
||||||
|
|
|
@ -3,12 +3,12 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlpreelement
|
// https://www.whatwg.org/html/#htmlpreelement
|
||||||
interface HTMLPreElement : HTMLElement {
|
interface HTMLPreElement : HTMLElement {
|
||||||
// also has obsolete members
|
// also has obsolete members
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#HTMLPreElement-partial
|
// https://www.whatwg.org/html/#HTMLPreElement-partial
|
||||||
partial interface HTMLPreElement {
|
partial interface HTMLPreElement {
|
||||||
// attribute long width;
|
// attribute long width;
|
||||||
};
|
};
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlprogresselement
|
// https://www.whatwg.org/html/#htmlprogresselement
|
||||||
interface HTMLProgressElement : HTMLElement {
|
interface HTMLProgressElement : HTMLElement {
|
||||||
// attribute double value;
|
// attribute double value;
|
||||||
// attribute double max;
|
// attribute double max;
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
* 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/. */
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
||||||
|
|
||||||
// http://www.whatwg.org/html/#htmlquoteelement
|
// https://www.whatwg.org/html/#htmlquoteelement
|
||||||
interface HTMLQuoteElement : HTMLElement {
|
interface HTMLQuoteElement : HTMLElement {
|
||||||
// attribute DOMString cite;
|
// attribute DOMString cite;
|
||||||
};
|
};
|
||||||
|
|
Некоторые файлы не были показаны из-за слишком большого количества измененных файлов Показать больше
Загрузка…
Ссылка в новой задаче