Clean up the cast calls

This commit is contained in:
Anthony Ramine 2015-10-07 14:55:02 +02:00
parent 13ea3ac413
commit 68014af78e
66 changed files with 412 additions and 718 deletions

View file

@ -72,7 +72,7 @@ impl HTMLTableRowElementMethods for HTMLTableRowElement {
self.cells.or_init(|| {
let window = window_from_node(self);
let filter = box CellsFilter;
HTMLCollection::create(window.r(), self.upcast::<Node>(), filter)
HTMLCollection::create(window.r(), self.upcast(), filter)
})
}
@ -97,8 +97,7 @@ impl HTMLTableRowElementMethods for HTMLTableRowElement {
impl VirtualMethods for HTMLTableRowElement {
fn super_type(&self) -> Option<&VirtualMethods> {
let htmlelement: &HTMLElement = self.upcast::<HTMLElement>();
Some(htmlelement as &VirtualMethods)
Some(self.upcast::<HTMLElement>() as &VirtualMethods)
}
fn attribute_mutated(&self, attr: &Attr, mutation: AttributeMutation) {