diff options
author | bors-servo <release+servo@mozilla.com> | 2014-05-30 14:45:57 -0400 |
---|---|---|
committer | bors-servo <release+servo@mozilla.com> | 2014-05-30 14:45:57 -0400 |
commit | d7cac61d9cc8e4e9f4ef73aeac21075cc46c62b4 (patch) | |
tree | f5568f02d189cf0c1f927f87e41a1a0739b91461 /src/components/script/dom/htmlbuttonelement.rs | |
parent | da896b8299620ad31bcdc84d931ecdcb3efd6979 (diff) | |
parent | af653d1ce0128d10ec9869fcf5c0bccecdcf64c6 (diff) | |
download | servo-d7cac61d9cc8e4e9f4ef73aeac21075cc46c62b4.tar.gz servo-d7cac61d9cc8e4e9f4ef73aeac21075cc46c62b4.zip |
auto merge of #2520 : saneyuki/servo/mut, r=Ms2ger
Related #2514
- This removes needless `&mut self`s from some DOM type method simply.
- This doesn't include some DOM Types which have basis method called from other types (e.g. `Element`). We still have to need to open their changes.
- This does not include to remove an implicit `deref_mut()`.
Diffstat (limited to 'src/components/script/dom/htmlbuttonelement.rs')
-rw-r--r-- | src/components/script/dom/htmlbuttonelement.rs | 52 |
1 files changed, 26 insertions, 26 deletions
diff --git a/src/components/script/dom/htmlbuttonelement.rs b/src/components/script/dom/htmlbuttonelement.rs index 5274097dd2e..1618d0b5b8f 100644 --- a/src/components/script/dom/htmlbuttonelement.rs +++ b/src/components/script/dom/htmlbuttonelement.rs @@ -41,33 +41,33 @@ impl HTMLButtonElement { pub trait HTMLButtonElementMethods { fn Autofocus(&self) -> bool; - fn SetAutofocus(&mut self, _autofocus: bool) -> ErrorResult; + fn SetAutofocus(&self, _autofocus: bool) -> ErrorResult; fn Disabled(&self) -> bool; - fn SetDisabled(&mut self, _disabled: bool) -> ErrorResult; + fn SetDisabled(&self, _disabled: bool) -> ErrorResult; fn GetForm(&self) -> Option<Temporary<HTMLFormElement>>; fn FormAction(&self) -> DOMString; - fn SetFormAction(&mut self, _formaction: DOMString) -> ErrorResult; + fn SetFormAction(&self, _formaction: DOMString) -> ErrorResult; fn FormEnctype(&self) -> DOMString; - fn SetFormEnctype(&mut self, _formenctype: DOMString) -> ErrorResult; + fn SetFormEnctype(&self, _formenctype: DOMString) -> ErrorResult; fn FormMethod(&self) -> DOMString; - fn SetFormMethod(&mut self, _formmethod: DOMString) -> ErrorResult; + fn SetFormMethod(&self, _formmethod: DOMString) -> ErrorResult; fn FormNoValidate(&self) -> bool; - fn SetFormNoValidate(&mut self, _novalidate: bool) -> ErrorResult; + fn SetFormNoValidate(&self, _novalidate: bool) -> ErrorResult; fn FormTarget(&self) -> DOMString; - fn SetFormTarget(&mut self, _formtarget: DOMString) -> ErrorResult; + fn SetFormTarget(&self, _formtarget: DOMString) -> ErrorResult; fn Name(&self) -> DOMString; - fn SetName(&mut self, _name: DOMString) -> ErrorResult; + fn SetName(&self, _name: DOMString) -> ErrorResult; fn Type(&self) -> DOMString; - fn SetType(&mut self, _type: DOMString) -> ErrorResult; + fn SetType(&self, _type: DOMString) -> ErrorResult; fn Value(&self) -> DOMString; - fn SetValue(&mut self, _value: DOMString) -> ErrorResult; + fn SetValue(&self, _value: DOMString) -> ErrorResult; fn WillValidate(&self) -> bool; - fn SetWillValidate(&mut self, _will_validate: bool); + fn SetWillValidate(&self, _will_validate: bool); fn Validity(&self) -> Temporary<ValidityState>; fn ValidationMessage(&self) -> DOMString; - fn SetValidationMessage(&mut self, _message: DOMString) -> ErrorResult; + fn SetValidationMessage(&self, _message: DOMString) -> ErrorResult; fn CheckValidity(&self) -> bool; - fn SetCustomValidity(&mut self, _error: DOMString); + fn SetCustomValidity(&self, _error: DOMString); } impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { @@ -75,7 +75,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { false } - fn SetAutofocus(&mut self, _autofocus: bool) -> ErrorResult { + fn SetAutofocus(&self, _autofocus: bool) -> ErrorResult { Ok(()) } @@ -83,7 +83,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { false } - fn SetDisabled(&mut self, _disabled: bool) -> ErrorResult { + fn SetDisabled(&self, _disabled: bool) -> ErrorResult { Ok(()) } @@ -95,7 +95,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { "".to_owned() } - fn SetFormAction(&mut self, _formaction: DOMString) -> ErrorResult { + fn SetFormAction(&self, _formaction: DOMString) -> ErrorResult { Ok(()) } @@ -103,7 +103,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { "".to_owned() } - fn SetFormEnctype(&mut self, _formenctype: DOMString) -> ErrorResult { + fn SetFormEnctype(&self, _formenctype: DOMString) -> ErrorResult { Ok(()) } @@ -111,7 +111,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { "".to_owned() } - fn SetFormMethod(&mut self, _formmethod: DOMString) -> ErrorResult { + fn SetFormMethod(&self, _formmethod: DOMString) -> ErrorResult { Ok(()) } @@ -119,7 +119,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { false } - fn SetFormNoValidate(&mut self, _novalidate: bool) -> ErrorResult { + fn SetFormNoValidate(&self, _novalidate: bool) -> ErrorResult { Ok(()) } @@ -127,7 +127,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { "".to_owned() } - fn SetFormTarget(&mut self, _formtarget: DOMString) -> ErrorResult { + fn SetFormTarget(&self, _formtarget: DOMString) -> ErrorResult { Ok(()) } @@ -135,7 +135,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { "".to_owned() } - fn SetName(&mut self, _name: DOMString) -> ErrorResult { + fn SetName(&self, _name: DOMString) -> ErrorResult { Ok(()) } @@ -143,7 +143,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { "".to_owned() } - fn SetType(&mut self, _type: DOMString) -> ErrorResult { + fn SetType(&self, _type: DOMString) -> ErrorResult { Ok(()) } @@ -151,7 +151,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { "".to_owned() } - fn SetValue(&mut self, _value: DOMString) -> ErrorResult { + fn SetValue(&self, _value: DOMString) -> ErrorResult { Ok(()) } @@ -159,7 +159,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { false } - fn SetWillValidate(&mut self, _will_validate: bool) { + fn SetWillValidate(&self, _will_validate: bool) { } fn Validity(&self) -> Temporary<ValidityState> { @@ -171,7 +171,7 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { "".to_owned() } - fn SetValidationMessage(&mut self, _message: DOMString) -> ErrorResult { + fn SetValidationMessage(&self, _message: DOMString) -> ErrorResult { Ok(()) } @@ -179,6 +179,6 @@ impl<'a> HTMLButtonElementMethods for JSRef<'a, HTMLButtonElement> { true } - fn SetCustomValidity(&mut self, _error: DOMString) { + fn SetCustomValidity(&self, _error: DOMString) { } } |