From 1b165148a6654f64d572bd4c28ddb2cee5f6a332 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Scott=20Gonz=C3=A1lez?= Date: Thu, 10 Nov 2011 07:58:44 -0500 Subject: [PATCH] Widget: Set event.target in ._trigger(). Fixes #7852 - Droppable event target changes under jQuery 1.7. --- ui/jquery.ui.widget.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ui/jquery.ui.widget.js b/ui/jquery.ui.widget.js index 56f465b94..294e321a9 100644 --- a/ui/jquery.ui.widget.js +++ b/ui/jquery.ui.widget.js @@ -393,6 +393,10 @@ $.Widget.prototype = { } } + // the original event may come from any element + // so we need to reset the target on the new event + event.target = this.element[0]; + this.element.trigger( event, data ); args = $.isArray( data ) ?