From 1a696678878f48748912b4c9d5df6da91c760b98 Mon Sep 17 00:00:00 2001 From: Dale Kocian Date: Tue, 16 Oct 2012 09:17:21 -0400 Subject: [PATCH] Dialog: Added mousedown event handler on dialog title to focus. Fixed #8063 - Dialog: Escape closes incorrect dialog. --- ui/jquery.ui.dialog.js | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/ui/jquery.ui.dialog.js b/ui/jquery.ui.dialog.js index 8593fff85..d83059ade 100644 --- a/ui/jquery.ui.dialog.js +++ b/ui/jquery.ui.dialog.js @@ -119,6 +119,10 @@ $.widget("ui.dialog", { uiDialogTitlebar = ( this.uiDialogTitlebar = $( "
" ) ) .addClass( "ui-dialog-titlebar ui-widget-header " + "ui-corner-all ui-helper-clearfix" ) + .bind( "mousedown", function() { + // Dialog isn't getting focus when dragging (#8063) + uiDialog.focus(); + }) .prependTo( uiDialog ), uiDialogTitlebarClose = $( "" ) -- 2.39.5