From: Scott González Date: Fri, 25 Jan 2013 13:51:13 +0000 (-0500) Subject: Dialog: Allow interaction with datepickers from modal dialogs. Fixes #8989 - Dialog... X-Git-Tag: 1.10.1~38 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=c53198c2099d25e80887c86af6d0e624414cc2f7;p=jquery-ui.git Dialog: Allow interaction with datepickers from modal dialogs. Fixes #8989 - Dialog: Cannot change month/year in datepicker within modal. --- diff --git a/ui/jquery.ui.dialog.js b/ui/jquery.ui.dialog.js index bfe37235e..1d3a7a88f 100644 --- a/ui/jquery.ui.dialog.js +++ b/ui/jquery.ui.dialog.js @@ -679,7 +679,10 @@ $.widget( "ui.dialog", { if ( $.ui.dialog.overlayInstances ) { this._on( this.document, { focusin: function( event ) { - if ( !$( event.target ).closest(".ui-dialog").length ) { + if ( !$( event.target ).closest(".ui-dialog").length && + // TODO: Remove hack when datepicker implements + // the .ui-front logic (#8989) + !$( event.target ).closest(".ui-datepicker").length ) { event.preventDefault(); $(".ui-dialog:visible:last .ui-dialog-content") .data("ui-dialog")._focusTabbable();