diff options
author | Brant Burnett <btburnett3@gmail.com> | 2010-01-29 21:18:57 +0000 |
---|---|---|
committer | Brant Burnett <btburnett3@gmail.com> | 2010-01-29 21:18:57 +0000 |
commit | 58a3a99e1e7ed9be36761baaaac3996ed645ea84 (patch) | |
tree | b4ba87145bd5580a4f911e9bb0b459ab948d0d6f /ui/jquery.ui.dialog.js | |
parent | 76f7e835b3d552842e59bf98b78d7757efa4976d (diff) | |
download | jquery-ui-58a3a99e1e7ed9be36761baaaac3996ed645ea84.tar.gz jquery-ui-58a3a99e1e7ed9be36761baaaac3996ed645ea84.zip |
Dialog: Changed overlay to use zIndex() to test which events to cancel (fixed #4363 Datepicker Month/Year Dropdowns Not Working In Safari In A Dialog)
Diffstat (limited to 'ui/jquery.ui.dialog.js')
-rw-r--r-- | ui/jquery.ui.dialog.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ui/jquery.ui.dialog.js b/ui/jquery.ui.dialog.js index a0be847d4..7694810b1 100644 --- a/ui/jquery.ui.dialog.js +++ b/ui/jquery.ui.dialog.js @@ -600,8 +600,8 @@ $.extend($.ui.dialog.overlay, { // handle $(el).dialog().dialog('close') (see #4065) if ($.ui.dialog.overlay.instances.length) { $(document).bind($.ui.dialog.overlay.events, function(event) { - var dialogZ = $(event.target).parents('.ui-dialog').css('zIndex') || 0; - return (dialogZ > $.ui.dialog.overlay.maxZ); + // stop events if the z-index of the target is <= the z-index of the overlay + return ($(event.target).zIndex() > $.ui.dialog.overlay.maxZ); }); } }, 1); |