Skip to content

Commit

Permalink
Dialog: Don't return true when we don't want to cancel events. Fixes …
Browse files Browse the repository at this point in the history
…#3523 - Dialog: onclick return value ignored.
  • Loading branch information
scottgonzalez committed Aug 27, 2010
1 parent 1e28040 commit af9864d
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion ui/jquery.ui.dialog.js
Expand Up @@ -693,7 +693,10 @@ $.extend($.ui.dialog.overlay, {
if ($.ui.dialog.overlay.instances.length) { if ($.ui.dialog.overlay.instances.length) {
$(document).bind($.ui.dialog.overlay.events, function(event) { $(document).bind($.ui.dialog.overlay.events, function(event) {
// stop events if the z-index of the target is < the z-index of the overlay // stop events if the z-index of the target is < the z-index of the overlay
return ($(event.target).zIndex() >= $.ui.dialog.overlay.maxZ); // we cannot return true when we don't want to cancel the event (#3523)
if ($(event.target).zIndex() < $.ui.dialog.overlay.maxZ) {
return false;
}
}); });
} }
}, 1); }, 1);
Expand Down

0 comments on commit af9864d

Please sign in to comment.