mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Support arbitrary protos when wrapping DOM objects with constructors.
This commit is contained in:
parent
d9600ff50f
commit
dbff26bce0
197 changed files with 2028 additions and 586 deletions
|
@ -62,6 +62,7 @@ use encoding_rs::{Encoding, UTF_8};
|
|||
use headers::{ContentType, HeaderMapExt};
|
||||
use html5ever::{LocalName, Prefix};
|
||||
use http::Method;
|
||||
use js::rust::HandleObject;
|
||||
use mime::{self, Mime};
|
||||
use net_traits::http_percent_encode;
|
||||
use net_traits::request::Referrer;
|
||||
|
@ -120,10 +121,12 @@ impl HTMLFormElement {
|
|||
local_name: LocalName,
|
||||
prefix: Option<Prefix>,
|
||||
document: &Document,
|
||||
proto: Option<HandleObject>,
|
||||
) -> DomRoot<HTMLFormElement> {
|
||||
Node::reflect_node(
|
||||
Node::reflect_node_with_proto(
|
||||
Box::new(HTMLFormElement::new_inherited(local_name, prefix, document)),
|
||||
document,
|
||||
proto,
|
||||
)
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue