Permalink
Browse files

Fixed issue with anchor and input focus prevention. If element has a …

…lower zIndex than that of the overlay, even if its inside the dialog being display, it is refused. This shouldn't happen, since you still want elements with a low z-index and _inside_ the dialog to be focussable.
  • Loading branch information...
1 parent 259638d commit 6fbbed9f11bdb25ae40285f24cfaae19a176eb18 @Craga89 committed Jun 15, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 ui/jquery.ui.dialog.js
View
@@ -695,7 +695,8 @@ $.extend( $.ui.dialog.overlay, {
$( document ).bind( $.ui.dialog.overlay.events, function( event ) {
// stop events if the z-index of the target is < the z-index 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 ) {
+ if ( $( event.target ).zIndex() < $.ui.dialog.overlay.maxZ &&
+ $(event.target).closest('.ui-dialog').length < 1) {
return false;
}
});

0 comments on commit 6fbbed9

Please sign in to comment.