mirror of
https://github.com/servo/servo.git
synced 2025-10-17 16:59:27 +01:00
Move WebIDL methods to traits implemented by JSRef types.
This commit is contained in:
parent
dfdda0098a
commit
76783b029e
106 changed files with 3644 additions and 1912 deletions
|
@ -40,36 +40,48 @@ impl HTMLMetaElement {
|
|||
}
|
||||
}
|
||||
|
||||
impl HTMLMetaElement {
|
||||
pub fn Name(&self) -> DOMString {
|
||||
pub trait HTMLMetaElementMethods {
|
||||
fn Name(&self) -> DOMString;
|
||||
fn SetName(&mut self, _name: DOMString) -> ErrorResult;
|
||||
fn HttpEquiv(&self) -> DOMString;
|
||||
fn SetHttpEquiv(&mut self, _http_equiv: DOMString) -> ErrorResult;
|
||||
fn Content(&self) -> DOMString;
|
||||
fn SetContent(&mut self, _content: DOMString) -> ErrorResult;
|
||||
fn Scheme(&self) -> DOMString;
|
||||
fn SetScheme(&mut self, _scheme: DOMString) -> ErrorResult;
|
||||
}
|
||||
|
||||
impl<'a> HTMLMetaElementMethods for JSRef<'a, HTMLMetaElement> {
|
||||
fn Name(&self) -> DOMString {
|
||||
~""
|
||||
}
|
||||
|
||||
pub fn SetName(&mut self, _name: DOMString) -> ErrorResult {
|
||||
fn SetName(&mut self, _name: DOMString) -> ErrorResult {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub fn HttpEquiv(&self) -> DOMString {
|
||||
fn HttpEquiv(&self) -> DOMString {
|
||||
~""
|
||||
}
|
||||
|
||||
pub fn SetHttpEquiv(&mut self, _http_equiv: DOMString) -> ErrorResult {
|
||||
fn SetHttpEquiv(&mut self, _http_equiv: DOMString) -> ErrorResult {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub fn Content(&self) -> DOMString {
|
||||
fn Content(&self) -> DOMString {
|
||||
~""
|
||||
}
|
||||
|
||||
pub fn SetContent(&mut self, _content: DOMString) -> ErrorResult {
|
||||
fn SetContent(&mut self, _content: DOMString) -> ErrorResult {
|
||||
Ok(())
|
||||
}
|
||||
|
||||
pub fn Scheme(&self) -> DOMString {
|
||||
fn Scheme(&self) -> DOMString {
|
||||
~""
|
||||
}
|
||||
|
||||
pub fn SetScheme(&mut self, _scheme: DOMString) -> ErrorResult {
|
||||
fn SetScheme(&mut self, _scheme: DOMString) -> ErrorResult {
|
||||
Ok(())
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue