diff --git a/content/base/src/nsGkAtomList.h b/content/base/src/nsGkAtomList.h index abce1f00dc2..4824a948b59 100644 --- a/content/base/src/nsGkAtomList.h +++ b/content/base/src/nsGkAtomList.h @@ -921,6 +921,7 @@ GK_ATOM(statedatasource, "statedatasource") GK_ATOM(staticHint, "staticHint") GK_ATOM(statusbar, "statusbar") GK_ATOM(statustext, "statustext") +GK_ATOM(step, "step") GK_ATOM(stop, "stop") GK_ATOM(stretch, "stretch") GK_ATOM(strike, "strike") diff --git a/content/html/content/src/nsHTMLInputElement.cpp b/content/html/content/src/nsHTMLInputElement.cpp index b0ac0ebadee..f0c4645596a 100644 --- a/content/html/content/src/nsHTMLInputElement.cpp +++ b/content/html/content/src/nsHTMLInputElement.cpp @@ -862,6 +862,7 @@ NS_IMPL_STRING_ATTR(nsHTMLInputElement, Name, name) NS_IMPL_BOOL_ATTR(nsHTMLInputElement, ReadOnly, readonly) NS_IMPL_BOOL_ATTR(nsHTMLInputElement, Required, required) NS_IMPL_URI_ATTR(nsHTMLInputElement, Src, src) +NS_IMPL_STRING_ATTR(nsHTMLInputElement, Step, step) NS_IMPL_INT_ATTR(nsHTMLInputElement, TabIndex, tabindex) NS_IMPL_STRING_ATTR(nsHTMLInputElement, UseMap, usemap) //NS_IMPL_STRING_ATTR(nsHTMLInputElement, Value, value) diff --git a/content/html/content/test/forms/test_input_attributes_reflection.html b/content/html/content/test/forms/test_input_attributes_reflection.html index 94b1a32490b..ab77ab872a1 100644 --- a/content/html/content/test/forms/test_input_attributes_reflection.html +++ b/content/html/content/test/forms/test_input_attributes_reflection.html @@ -179,7 +179,10 @@ reflectUnsignedInt({ // TODO: src (URL) // .step -todo("step" in document.createElement("input"), "step isn't implemented yet"); +reflectString({ + element: document.createElement('input'), + attribute: 'step', +}); // .type reflectLimitedEnumerated({ diff --git a/dom/interfaces/html/nsIDOMHTMLInputElement.idl b/dom/interfaces/html/nsIDOMHTMLInputElement.idl index 1c94d43038d..9313260b611 100644 --- a/dom/interfaces/html/nsIDOMHTMLInputElement.idl +++ b/dom/interfaces/html/nsIDOMHTMLInputElement.idl @@ -20,7 +20,7 @@ interface nsIDOMValidityState; * http://www.whatwg.org/specs/web-apps/current-work/ */ -[scriptable, uuid(261b0fa1-dfcc-445d-8ac8-6b3817ec63cb)] +[scriptable, uuid(e20b7e26-e952-4bba-9192-99bd1a4b3816)] interface nsIDOMHTMLInputElement : nsIDOMHTMLElement { attribute DOMString accept; @@ -55,6 +55,7 @@ interface nsIDOMHTMLInputElement : nsIDOMHTMLElement attribute DOMString placeholder; attribute boolean readOnly; attribute boolean required; + attribute DOMString step; attribute DOMString align;