mirror of
https://github.com/jquery/jquery-ui.git
synced 2025-01-07 20:34:24 +00:00
Fixed the initialization of color animations for cases where the first step of the animation doesn't happen in the same millisecond as the call to animate. Fixes #4251 - NaN in color animation (Firefox 3).
This commit is contained in:
parent
c6990895be
commit
217266fb62
3
ui/jquery.effects.core.js
vendored
3
ui/jquery.effects.core.js
vendored
@ -336,9 +336,10 @@ $.each(['backgroundColor', 'borderBottomColor', 'borderLeftColor',
|
||||
'borderRightColor', 'borderTopColor', 'color', 'outlineColor'],
|
||||
function(i, attr) {
|
||||
$.fx.step[attr] = function(fx) {
|
||||
if (fx.state === 0) {
|
||||
if (!fx.colorInit) {
|
||||
fx.start = getColor(fx.elem, attr);
|
||||
fx.end = getRGB(fx.end);
|
||||
fx.colorInit = true;
|
||||
}
|
||||
|
||||
fx.elem.style[attr] = 'rgb(' +
|
||||
|
Loading…
Reference in New Issue
Block a user