diff options
Diffstat (limited to 'ui/jquery.effects.highlight.js')
-rw-r--r-- | ui/jquery.effects.highlight.js | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/ui/jquery.effects.highlight.js b/ui/jquery.effects.highlight.js index 2049ec015..b2ffb15e8 100644 --- a/ui/jquery.effects.highlight.js +++ b/ui/jquery.effects.highlight.js @@ -12,20 +12,20 @@ */ (function( $, undefined ) { -$.effects.highlight = function(o) { - return this.queue(function() { - var elem = $(this), - props = ['backgroundImage', 'backgroundColor', 'opacity'], - mode = $.effects.setMode(elem, o.mode || 'show'), +$.effects.highlight = function( o ) { + return this.queue( function() { + var elem = $( this ), + props = [ 'backgroundImage', 'backgroundColor', 'opacity' ], + mode = $.effects.setMode( elem, o.mode || 'show' ), animation = { - backgroundColor: elem.css('backgroundColor') + backgroundColor: elem.css( 'backgroundColor' ) }; if (mode == 'hide') { animation.opacity = 0; } - $.effects.save(elem, props); + $.effects.save( elem, props ); elem .show() @@ -33,15 +33,15 @@ $.effects.highlight = function(o) { backgroundImage: 'none', backgroundColor: o.color || '#ffff99' }) - .animate(animation, { + .animate( animation, { queue: false, duration: o.duration, easing: o.easing, complete: function() { (mode == 'hide' && elem.hide()); - $.effects.restore(elem, props); - (mode == 'show' && !$.support.opacity && this.style.removeAttribute('filter')); - (o.complete && o.complete.apply(this, arguments)); + $.effects.restore( elem, props ); + (mode == 'show' && !$.support.opacity && this.style.removeAttribute( 'filter' )); + jQuery.isFunction(o.complete) && o.complete.apply(this, arguments); elem.dequeue(); } }); |