]> source.dussan.org Git - jquery.git/commitdiff
Moved the fx queueing over to the new expando system.
authorJohn Resig <jeresig@gmail.com>
Sun, 9 Sep 2007 16:17:32 +0000 (16:17 +0000)
committerJohn Resig <jeresig@gmail.com>
Sun, 9 Sep 2007 16:17:32 +0000 (16:17 +0000)
src/fx.js

index c708b1a6071edc8d0528c1ee88f2441c220380ea..c45edc1ece3ff5c7df04ac75b795edd7cc16d6e4 100644 (file)
--- a/src/fx.js
+++ b/src/fx.js
@@ -175,16 +175,13 @@ function queue( elem, type, array ) {
        if ( !elem )
                return;
 
-       if ( !elem.queue )
-               elem.queue = {};
+       var queue = jQuery.data( elem, type + "queue" );
 
-       if ( !elem.queue[type] )
-               elem.queue[type] = [];
+       if ( !queue || array )
+               queue = jQuery.data( elem, type + "queue", 
+                       array ? jQuery.makeArray(array) : [] );
 
-       if ( array )
-               elem.queue[type] = jQuery.makeArray(array);
-
-       return elem.queue[type];
+       return queue;
 }
 
 jQuery.extend({