View Full Version : [FIXED-561] TreePanel animation bug using jQuery v1.4.1

11 Feb 2010, 2:26 PM
When there is an invalid move on my TreePanel the node gets stuck and there is an error.

I traced the cause to be when jQuery animates, it can't understand the parameter xy, similar to this bug (http://www.extjs.com/forum/showthread.php?p=364787#post364787). The issue can be fixed the same way by adding:

case 'callback':
case 'scope':
case 'xy':
// jQuery can't handle xy, callback and scope arguments, so break here
break;I think a better spot might be in the Ext.Fx.shift function. The parameters x, y, and xy are converted into the parameter points (which is properly used by jQuery) so deleting the unused xy parameter also fixes the problem.

if (a.x || a.y || a.xy) {
a.points = a.xy ||
{to : [ a.x ? a.x.to : fly(dom).getX(),
a.y ? a.y.to : fly(dom).getY()]};
delete a.x;
delete a.y;
delete a.xy;
}I don't know if this would break the other adapters or anything else.


Tested in both 3.1.0 and 3.1.1 with jQuery 1.4.1

Jamie Avins
11 Feb 2010, 5:15 PM
Can you post a test case for this issue as well.

11 Feb 2010, 5:54 PM
Attached is a fully runnable test case. Just drag a node off the tree (so it's an invalid drop).

12 Feb 2010, 12:57 AM
@Jamie Avins: In a perfect world, how would I submit an automated test case for an issue? Which testing framework do you guys use, and prefer?

Jamie Avins
12 Feb 2010, 9:07 AM
Many (most) of the test cases we need deal with unexpected behavior instead of hard errors like this one. We are currently experimenting with YUI's testing tools for our own internal tests.

Jamie Avins
16 Feb 2010, 4:32 PM
Fixed in svn 6099.

16 Feb 2010, 4:49 PM
Awesome, did you use one of my solutions? If not can you post (or PM me) the patch? I have an override now but I want to make sure I am doing it right.


Jamie Avins
16 Feb 2010, 5:09 PM
The first one.