Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dialog: Fix for issue #5466, Dialog canceling input events #546

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 4 additions & 1 deletion ui/jquery.ui.dialog.js
Expand Up @@ -692,8 +692,11 @@ $.extend( $.ui.dialog.overlay, {
if ( $.ui.dialog.overlay.instances.length ) {
$( document ).bind( $.ui.dialog.overlay.events, function( event ) {
// stop events if the z-index of the target is < the z-index of the overlay
// and if they are not inside a dialog whose z-index is < that of the overlay
// we cannot return true when we don't want to cancel the event (#3523)
if ( $( event.target ).zIndex() < $.ui.dialog.overlay.maxZ ) {
var maxZ = $.ui.dialog.overlay.maxZ;
var $target = $( event.target );
if ( $target.zIndex() < maxZ && $target.closest('.ui-dialog').zIndex() < maxZ ) {
return false;
}
});
Expand Down