mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Pass an Atom to Element::create.
This commit is contained in:
parent
e8b02acb1d
commit
9435565f85
4 changed files with 8 additions and 8 deletions
|
@ -76,15 +76,15 @@ use dom::htmlulistelement::HTMLUListElement;
|
|||
use dom::htmlunknownelement::HTMLUnknownElement;
|
||||
use dom::htmlvideoelement::HTMLVideoElement;
|
||||
|
||||
use util::str::DOMString;
|
||||
|
||||
use string_cache::QualName;
|
||||
use string_cache::{Atom, QualName};
|
||||
|
||||
use std::borrow::ToOwned;
|
||||
|
||||
pub fn create_element(name: QualName, prefix: Option<DOMString>,
|
||||
pub fn create_element(name: QualName, prefix: Option<Atom>,
|
||||
document: JSRef<Document>, creator: ElementCreator)
|
||||
-> Temporary<Element> {
|
||||
let prefix = prefix.map(|p| (*p).to_owned());
|
||||
|
||||
if name.ns != ns!(HTML) {
|
||||
return Element::new((*name.local).to_owned(), name.ns, prefix, document);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue