aboutsummaryrefslogtreecommitdiffstats
path: root/ui/ui.progressbar.js
diff options
context:
space:
mode:
authorEduardo Lundgren <eduardolundgren@gmail.com>2008-09-20 04:09:27 +0000
committerEduardo Lundgren <eduardolundgren@gmail.com>2008-09-20 04:09:27 +0000
commit2f842cedd686ebe2b8a795ff60115b9a473e46b5 (patch)
tree2d54115431040a84dd095099554be3851955b818 /ui/ui.progressbar.js
parenta522291a7b8a4f44c4d6cf0f1d146eab172bc0c9 (diff)
downloadjquery-ui-2f842cedd686ebe2b8a795ff60115b9a473e46b5.tar.gz
jquery-ui-2f842cedd686ebe2b8a795ff60115b9a473e46b5.zip
Progressbar duration option fixed
Diffstat (limited to 'ui/ui.progressbar.js')
-rw-r--r--ui/ui.progressbar.js19
1 files changed, 13 insertions, 6 deletions
diff --git a/ui/ui.progressbar.js b/ui/ui.progressbar.js
index cccf00b82..34c860c55 100644
--- a/ui/ui.progressbar.js
+++ b/ui/ui.progressbar.js
@@ -102,6 +102,10 @@ $.widget("ui.progressbar", {
self.active = true;
+ if (options.duration < options.interval) {
+ options.duration = options.interval;
+ }
+
setTimeout(
function() {
self.active = false;
@@ -133,11 +137,14 @@ $.widget("ui.progressbar", {
options.interval = interval - elapsedTime;
},
complete: function() {
- delete jQuery.easing[self.identifier];
- self.pause();
-
if (self.active) {
- /*TODO*/
+ options.interval = self._interval;
+ self.bar.width(0);
+ self.textElement.width(0);
+ self._animate();
+ }
+ else {
+ delete jQuery.easing[self.identifier];
}
}
}
@@ -183,8 +190,8 @@ $.widget("ui.progressbar", {
$.ui.progressbar.defaults = {
width: 300,
- duration: 3000,
- interval: 200,
+ duration: 1000,
+ interval: 1000,
increment: 1,
range: true,
text: '',