Opened 14 years ago
Closed 14 years ago
#3912 closed bug (fixed)
Effects problems with non-numeric duration
Reported by: | kbwood | Owned by: | |
---|---|---|---|
Priority: | minor | Milestone: | 1.7 |
Component: | ui.effects.core | Version: | 1.6rc5 |
Keywords: | Cc: | ||
Blocked by: | Blocking: |
Description (last modified by )
Some effects perform a calculation on the duration before proceeding with the animation, such as bounce, fold, and pulsate. However, they fail to cater for non-numeric durations, such as slow, normal, or fast. There needs to be a common function to resolve the non-numeric duration to a numeric value that can then be used without further problems. The code below is based on the jQuery 1.3 code (replace
with two vertical bars - can't seem to enter these directly).
function resolveDuration(duration) {
return (typeof duration === "number" && !isNaN(duration) ? duration :
jQuery.fx.speeds[duration]
jQuery.fx.speeds._default);
}
Change History (4)
comment:1 Changed 14 years ago by
Component: | ui.core → effects.core |
---|
comment:2 Changed 14 years ago by
Description: | modified (diff) |
---|
comment:3 Changed 14 years ago by
Milestone: | TBD → 1.6 |
---|
comment:4 Changed 14 years ago by
Resolution: | → fixed |
---|---|
Status: | new → closed |
Fixed in r1853.