From d10440fe44c840dd5c69c4efb1c06d2636fa11c6 Mon Sep 17 00:00:00 2001 From: Mike Sherov Date: Sat, 16 Aug 2014 09:44:05 -0400 Subject: Draggable: Only focus the draggable if the event occurs on a handle Refs #10527 --- ui/draggable.js | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) (limited to 'ui') diff --git a/ui/draggable.js b/ui/draggable.js index 3cae40f11..98f065efb 100644 --- a/ui/draggable.js +++ b/ui/draggable.js @@ -123,9 +123,14 @@ $.widget("ui.draggable", $.ui.mouse, { }, - _blurActiveElement: function() { + _blurActiveElement: function( event ) { var document = this.document[ 0 ]; + // Only need to blur if the event occurred on the draggable itself, see #10527 + if ( !this.handleElement.is( event.target ) ) { + return; + } + // support: IE9 // IE9 throws an "Unspecified error" accessing document.activeElement from an