Progressbar Widgetversion added: 1.6
Description: Display status of a determinate process.
The progress bar is designed to display the current percent complete for a process. The bar is coded to be flexibly sized through CSS and will scale to fit inside its parent container by default.
This is a determinate progress bar, meaning that it should only be used in situations where the system can accurately update the current status. A determinate progress bar should never fill from left to right, then loop back to empty for a single process — if the actual status cannot be calculated, an indeterminate progress bar or spinner animation is a better way to provide user feedback.
Dependencies
Additional Notes:
- This widget requires some functional CSS, otherwise it won't work. If you build a custom theme, use the widget's specific CSS file as a starting point.
Options
disabled
false
true
.Initialize the progressbar with the disabled
option specified:
1
2
3
|
|
Get or set the disabled
option, after initialization:
1
2
3
4
5
|
|
max
0
Initialize the progressbar with the max
option specified:
1
2
3
|
|
Get or set the max
option, after initialization:
1
2
3
4
5
|
|
value
0
Initialize the progressbar with the value
option specified:
1
2
3
|
|
Get or set the value
option, after initialization:
1
2
3
4
5
|
|
Methods
destroy()Returns: jQuery (plugin only)
- This method does not accept any arguments.
Invoke the destroy method:
1
|
|
disable()Returns: jQuery (plugin only)
- This method does not accept any arguments.
Invoke the disable method:
1
|
|
enable()Returns: jQuery (plugin only)
- This method does not accept any arguments.
Invoke the enable method:
1
|
|
option( optionName )Returns: Object
optionName
.-
optionNameType: StringThe name of the option to get.
Invoke the method:
1
|
|
option()Returns: PlainObject
- This signature does not accept any arguments.
Invoke the method:
1
|
|
option( optionName, value )Returns: jQuery (plugin only)
optionName
.-
optionNameType: StringThe name of the option to set.
-
valueType: ObjectA value to set for the option.
Invoke the method:
1
|
|
option( options )Returns: jQuery (plugin only)
-
optionsType: ObjectA map of option-value pairs to set.
Invoke the method:
1
|
|
value()Returns: Number
- This signature does not accept any arguments.
Invoke the method:
1
|
|
value( value )Returns: jQuery (plugin only)
-
valueType: NumberThe value to set.
Invoke the method:
1
|
|
widget()Returns: jQuery
jQuery
object containing the progressbar.
- This method does not accept any arguments.
Invoke the widget method:
1
|
|
Events
change( event, ui )Type: progressbarchange
Note: The ui
object is empty but included for consistency with other events.
Initialize the progressbar with the change callback specified:
1
2
3
|
|
Bind an event listener to the progressbarchange event:
1
|
|
complete( event, ui )Type: progressbarcomplete
Note: The ui
object is empty but included for consistency with other events.
Initialize the progressbar with the complete callback specified:
1
2
3
|
|
Bind an event listener to the progressbarcomplete event:
1
|
|
create( event, ui )Type: progressbarcreate
Note: The ui
object is empty but included for consistency with other events.
Initialize the progressbar with the create callback specified:
1
2
3
|
|
Bind an event listener to the progressbarcreate event:
1
|
|
Example:
A simple jQuery UI Progressbar
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
|