Skip to content
Permalink
Browse files

Datepicker: No longer dependent on dialog in order to close datepicke…

…r when dialog is closed (Refixed #4453 UI Datepicker inside UI Dialog Issue)
  • Loading branch information
btburnett3 committed Feb 1, 2010
1 parent bae22fb commit d549ba6d43072f65c56159a136ad4c077d859d36
Showing with 1 addition and 11 deletions.
  1. +0 −7 ui/jquery.ui.datepicker.js
  2. +1 −4 ui/jquery.ui.dialog.js
@@ -652,10 +652,6 @@ $.extend(Datepicker.prototype, {
if (inst.input.is(':visible') && !inst.input.is(':disabled'))
inst.input[0].focus();
$.datepicker._curInst = inst;

// find the dialog wrapping the input, if any, and bind to close event
inst._dialog = $(input).closest('.ui-dialog-content')
.bind('dialogclose.datepicker', function() { $.datepicker._hideDatepicker(input); });
}
},

@@ -780,9 +776,6 @@ $.extend(Datepicker.prototype, {
}
}
this._inDialog = false;

if (inst._dialog)
inst._dialog.unbind('dialogclose.datepicker');
}
},

@@ -114,9 +114,6 @@ $.widget("ui.dialog", {
.blur(function() {
uiDialogTitlebarClose.removeClass('ui-state-focus');
})
.mousedown(function(ev) {
ev.stopPropagation();
})
.click(function(event) {
self.close(event);
return false;
@@ -327,7 +324,7 @@ $.widget("ui.dialog", {
heightBeforeDrag;

self.uiDialog.draggable({
cancel: '.ui-dialog-content',
cancel: '.ui-dialog-content, .ui-dialog-titlebar-close',
handle: '.ui-dialog-titlebar',
containment: 'document',
start: function(event) {

0 comments on commit d549ba6

Please sign in to comment.
You can’t perform that action at this time.