Short URL: http://html5.org/r/4106
| SVN | Bug | Comment | Time (UTC) |
|---|---|---|---|
| 4106 | Make stepUp() and stepDown() arguments optional. | 2009-10-12 01:10 |
Index: source
===================================================================
--- source (revision 4105)
+++ source (revision 4106)
@@ -34666,8 +34666,8 @@
readonly attribute <span>HTMLOptionElement</span> <span title="dom-input-selectedOption">selectedOption</span>;
attribute DOMString <span title="dom-dim-width">width</span>;
- void <span title="dom-input-stepUp">stepUp</span>(in long n);
- void <span title="dom-input-stepDown">stepDown</span>(in long n);
+ void <span title="dom-input-stepUp">stepUp</span>(in optional long n);
+ void <span title="dom-input-stepDown">stepDown</span>(in optional long n);
readonly attribute boolean <span title="dom-cva-willValidate">willValidate</span>;
readonly attribute <span>ValidityState</span> <span title="dom-cva-validity">validity</span>;
@@ -39928,15 +39928,15 @@
</dd>
- <dt><var title="">input</var> . <code title="dom-input-stepUp">stepUp</code>(<var title="">n</var>)</dt>
- <dt><var title="">input</var> . <code title="dom-input-stepDown">stepDown</code>(<var title="">n</var>)</dt>
+ <dt><var title="">input</var> . <code title="dom-input-stepUp">stepUp</code>( [ <var title="">n</var> ] )</dt>
+ <dt><var title="">input</var> . <code title="dom-input-stepDown">stepDown</code>( [ <var title="">n</var> ] )</dt>
<dd>
<p>Changes the form control's <span
title="concept-fe-value">value</span> by the value given in the
<code title="attr-input-step">step</code> attribute, multiplied by
- <var title="">n</var>.</p>
+ <var title="">n</var>. The default is 1.</p>
<p>Throws <code>INVALID_STATE_ERR</code> exception if the control
is neither date- or time-based nor numeric, if the <code
@@ -40157,6 +40157,9 @@
these steps; otherwise, let <var title="">value</var> be the result
of that algorithm.</p></li>
+ <li><p>Let <var title="">n</var> be the argument, or 1 if the
+ argument was omitted.</p></li>
+
<li><p>Let <var title="">delta</var> be the <span
title="concept-input-step">allowed value step</span> multiplied by
<var title="">n</var>.</p></li>
@@ -94572,6 +94575,7 @@
Sam Weinig,
Sander van Lambalgen,
Sarven Capadisli,
+ Scott González,
Scott Hess,
Sean Fraser,
Sean Hogan,