Added ParentNode.querySelector skeleton

This commit is contained in:
Bruno de Oliveira Abinader 2014-06-03 14:16:49 -07:00
parent f78d04b620
commit f0aadb790d
4 changed files with 23 additions and 0 deletions

View file

@ -429,6 +429,7 @@ pub trait ElementMethods {
fn GetInnerHTML(&self) -> Fallible<DOMString>;
fn GetOuterHTML(&self) -> Fallible<DOMString>;
fn Children(&self) -> Temporary<HTMLCollection>;
fn QuerySelector(&self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>>;
fn Remove(&self);
}
@ -704,6 +705,10 @@ impl<'a> ElementMethods for JSRef<'a, Element> {
HTMLCollection::children(&*window, NodeCast::from_ref(self))
}
fn QuerySelector(&self, selectors: DOMString) -> Fallible<Option<Temporary<Element>>> {
Ok(None)
}
// http://dom.spec.whatwg.org/#dom-childnode-remove
fn Remove(&self) {
let node: &JSRef<Node> = NodeCast::from_ref(self);