mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Implement Element.removeAttribute()/removeAttributeNS().
This commit is contained in:
parent
31e2f22d20
commit
7a9ecffaa0
5 changed files with 108 additions and 5 deletions
|
@ -67,6 +67,17 @@ impl HTMLImageElement {
|
|||
}
|
||||
}
|
||||
|
||||
pub fn AfterRemoveAttr(&mut self, name: DOMString) {
|
||||
// FIXME (#1469):
|
||||
// This might not handle remove src attribute actually since
|
||||
// `self.update_image()` will see the missing src attribute and return early.
|
||||
if "src" == name {
|
||||
let document = self.htmlelement.element.node.owner_doc();
|
||||
let window = document.document().window;
|
||||
self.update_image(window.image_cache_task.clone(), None);
|
||||
}
|
||||
}
|
||||
|
||||
pub fn Alt(&self) -> DOMString {
|
||||
~""
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue