Page Menu
Home
Code
Search
Configure Global Search
Log In
Files
F1127647
NumberSpinner.js
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1000 B
Subscribers
None
NumberSpinner.js
View Options
if
(
!
dojo
.
_hasResource
[
"dijit.form.NumberSpinner"
]){
//_hasResource checks added by build. Do not use _hasResource directly in your code.
dojo
.
_hasResource
[
"dijit.form.NumberSpinner"
]
=
true
;
dojo
.
provide
(
"dijit.form.NumberSpinner"
);
dojo
.
require
(
"dijit.form._Spinner"
);
dojo
.
require
(
"dijit.form.NumberTextBox"
);
dojo
.
declare
(
"dijit.form.NumberSpinner"
,
[
dijit
.
form
.
_Spinner
,
dijit
.
form
.
NumberTextBoxMixin
],
{
// summary: Number Spinner
// description: This widget is the same as NumberTextBox but with up/down arrows added
required
:
true
,
adjust
:
function
(
/* Object */
val
,
/*Number*/
delta
){
// summary: change Number val by the given amount
var
newval
=
val
+
delta
;
if
(
isNaN
(
val
)
||
isNaN
(
newval
)){
return
val
;
}
if
((
typeof
this
.
constraints
.
max
==
"number"
)
&&
(
newval
>
this
.
constraints
.
max
)){
newval
=
this
.
constraints
.
max
;
}
if
((
typeof
this
.
constraints
.
min
==
"number"
)
&&
(
newval
<
this
.
constraints
.
min
)){
newval
=
this
.
constraints
.
min
;
}
return
newval
;
}
});
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Jun 19, 12:46 (2 w, 6 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
26867
Default Alt Text
NumberSpinner.js (1000 B)
Attached To
rZED Zed
Event Timeline
Log In to Comment