auto merge of #920 : jdm/servo/setattrabstract, r=metajack

r? @metajack
This commit is contained in:
bors-servo 2013-09-12 15:51:49 -07:00
commit ab743c17fe
6 changed files with 42 additions and 19 deletions

View file

@ -77,9 +77,13 @@ impl HTMLImageElement {
}
}
pub fn SetWidth(&mut self, width: u32, _rv: &mut ErrorResult) {
pub fn SetWidth(&mut self,
abstract_self: AbstractNode<ScriptView>,
width: u32,
_rv: &mut ErrorResult) {
let node = &mut self.parent.parent;
node.set_attr(&str(~"width"),
node.set_attr(abstract_self,
&str(~"width"),
&str(width.to_str()));
}
@ -110,9 +114,13 @@ impl HTMLImageElement {
}
}
pub fn SetHeight(&mut self, height: u32, _rv: &mut ErrorResult) {
pub fn SetHeight(&mut self,
abstract_self: AbstractNode<ScriptView>,
height: u32,
_rv: &mut ErrorResult) {
let node = &mut self.parent.parent;
node.set_attr(&str(~"height"),
node.set_attr(abstract_self,
&str(~"height"),
&str(height.to_str()));
}