mirror of
https://github.com/servo/servo.git
synced 2025-08-05 13:40:08 +01:00
auto merge of #920 : jdm/servo/setattrabstract, r=metajack
r? @metajack
This commit is contained in:
commit
ab743c17fe
6 changed files with 42 additions and 19 deletions
|
@ -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()));
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue