Last active
August 29, 2015 14:08
-
-
Save juareznjunior/c1076171658e9be21e2b to your computer and use it in GitHub Desktop.
jQuery UI Dialog Prototype
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* prototype jQuery UI Dialog | |
* @param d jQuery | |
* @author: Juarez G. N. Junior | |
*/ | |
;(function(d){ | |
// options | |
d.extend(d.ui.dialog.prototype.options,{ | |
autoOpen : false | |
,modal : true | |
,draggable:false | |
,resizable:false | |
}); | |
d.widget('ui.dialog', d.ui.dialog, { | |
_title: function( title ) { | |
title.html( !this.options.title ? " " : this.options.title ); | |
} | |
,superCreateOverlay : d.ui.dialog.prototype._createOverlay | |
,superDestroyOverlay: d.ui.dialog.prototype._destroyOverlay | |
,_createOverlay: function() { | |
this.superCreateOverlay.apply(this,arguments); | |
$(this._appendTo()).addClass('ui-widget-overlay-overflow-hidden'); | |
} | |
,_destroyOverlay: function() { | |
this.superDestroyOverlay.apply(this,arguments); | |
$(this._appendTo()).removeClass('ui-widget-overlay-overflow-hidden'); | |
} | |
}); | |
}(jQuery)); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment