// close dialog by overlay click
$.widget(
'ui.dialog',
$.ui.dialog,
{
_createOverlay: function()
{
this._super();
if (!this.options.modal)
{
return;
}
this._on(this.overlay, { click: 'close' });
}
}
);
// http://stackoverflow.com/questions/19690131/jquery-ui-modal-dialog-global-close-on-overlay-click
// https://gist.github.com/jurchiks/7264596