Making fadeIn and fadeOut more useful

Making fadeIn and fadeOut more useful


fadeIn() and fadeOut() cool be much more useful if they'd work
together instead of queueing up against each other. A usecase where
this comes up is a tooltip widget, where a single element is reused to
display the tooltip of various elements (absolutely necessary for a
large number of tooltipped elements, eg. a large table).
An example of that usecase, implementing an ugly workaround to get the
queuing under control, is here:
http://jquery-ui.googlecode.com/svn/branches/dev/tests/visual/tooltip/default.html
The relevant code of the workaround is this:
open: function(target) {
    [...]
    
    if (this.tooltip.is(":animated"))
        this.tooltip.stop().show().fadeTo("normal", this.opacity);
    else
        this.tooltip.is(':visible') ? this.tooltip.fadeTo("normal",
this.opacity) : this.tooltip.fadeIn();
},
close: function() {
    [...]
    
    if (this.tooltip.is(':animated'))
        this.tooltip.stop().fadeTo("normal", 0);
    else
        this.tooltip.stop().fadeOut();
    
    [...]
}
Where "this.opacity" refers to the opacity value, read in _init:
this.opacity = this.tooltip.css("opacity");
Thats necessary to use the CSS defined opacity value, instead of just
fading to 1.
As you may guess, that workaround isn't easy to come up with - I've
written it some time ago and have no idea why it works. I don't think
this makes sense as a plugin, so I hope we can come up with an idea to
improve fade support in core, to be available and useful for everyone,
not just someone who knows where to copy the workaround from.
Jörn