aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorManish Goregaokar <manishsmail@gmail.com>2015-01-31 01:40:09 +0530
committerManish Goregaokar <manishsmail@gmail.com>2015-01-31 06:08:44 +0530
commit2f9eee451dcb98e10cfae5ed2712cd2a65695963 (patch)
tree397b88a22c4d59cc98ca60e8dbcdf6491562fefd
parent26732403b99ca2550d25c2b22aee35a2cdaf3967 (diff)
downloadservo-2f9eee451dcb98e10cfae5ed2712cd2a65695963.tar.gz
servo-2f9eee451dcb98e10cfae5ed2712cd2a65695963.zip
Make mutable() use the disabled state
-rw-r--r--components/script/dom/htmlinputelement.rs3
1 files changed, 2 insertions, 1 deletions
diff --git a/components/script/dom/htmlinputelement.rs b/components/script/dom/htmlinputelement.rs
index f0af836c983..e99bdaf3fcf 100644
--- a/components/script/dom/htmlinputelement.rs
+++ b/components/script/dom/htmlinputelement.rs
@@ -588,7 +588,8 @@ impl<'a> FormControl<'a> for JSRef<'a, HTMLInputElement> {
fn mutable(self) -> bool {
// https://html.spec.whatwg.org/multipage/forms.html#the-input-element:concept-fe-mutable
// https://html.spec.whatwg.org/multipage/forms.html#the-readonly-attribute:concept-fe-mutable
- !(self.Disabled() || self.ReadOnly())
+ let node: JSRef<Node> = NodeCast::from_ref(self);
+ !(node.get_disabled_state() || self.ReadOnly())
}
// https://html.spec.whatwg.org/multipage/forms.html#the-input-element:concept-form-reset-control