mirror of
https://github.com/servo/servo.git
synced 2025-10-09 04:59:23 +01:00
Remove needless '&self mut' from VirtualMethods trait.
This commit is contained in:
parent
d8483d2365
commit
2aa1554b0c
13 changed files with 109 additions and 102 deletions
|
@ -68,12 +68,12 @@ impl<'a> PrivateHTMLAnchorElementHelpers for JSRef<'a, HTMLAnchorElement> {
|
|||
}
|
||||
|
||||
impl<'a> VirtualMethods for JSRef<'a, HTMLAnchorElement> {
|
||||
fn super_type<'a>(&'a mut self) -> Option<&'a mut VirtualMethods:> {
|
||||
let htmlelement: &mut JSRef<HTMLElement> = HTMLElementCast::from_mut_ref(self);
|
||||
Some(htmlelement as &mut VirtualMethods:)
|
||||
fn super_type<'a>(&'a self) -> Option<&'a VirtualMethods:> {
|
||||
let htmlelement: &JSRef<HTMLElement> = HTMLElementCast::from_ref(self);
|
||||
Some(htmlelement as &VirtualMethods:)
|
||||
}
|
||||
|
||||
fn handle_event(&mut self, event: &JSRef<Event>) {
|
||||
fn handle_event(&self, event: &JSRef<Event>) {
|
||||
match self.super_type() {
|
||||
Some(s) => {
|
||||
s.handle_event(event);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue