Skip to content

Commit e34dbfe

Browse files
fracmakscottgonzalez
authored andcommitted
Dialog: Removed the height() tinkering which stops the dialog from shrinking. Fixes #5916 - Dialog: shrinks on drag in IE in standards mode, worse in quirksmode.
1 parent c7eae7b commit e34dbfe

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

ui/jquery.ui.dialog.js

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -373,8 +373,7 @@ $.widget("ui.dialog", {
373373
_makeDraggable: function() {
374374
var self = this,
375375
options = self.options,
376-
doc = $( document ),
377-
heightBeforeDrag;
376+
doc = $( document );
378377

379378
function filteredUi( ui ) {
380379
return {
@@ -388,9 +387,7 @@ $.widget("ui.dialog", {
388387
handle: ".ui-dialog-titlebar",
389388
containment: "document",
390389
start: function( event, ui ) {
391-
heightBeforeDrag = options.height === "auto" ? "auto" : $( this ).height();
392390
$( this )
393-
.height( $( this ).height() )
394391
.addClass( "ui-dialog-dragging" );
395392
self._trigger( "dragStart", event, filteredUi( ui ) );
396393
},
@@ -403,8 +400,7 @@ $.widget("ui.dialog", {
403400
ui.position.top - doc.scrollTop()
404401
];
405402
$( this )
406-
.removeClass( "ui-dialog-dragging" )
407-
.height( heightBeforeDrag );
403+
.removeClass( "ui-dialog-dragging" );
408404
self._trigger( "dragStop", event, filteredUi( ui ) );
409405
$.ui.dialog.overlay.resize();
410406
}

0 commit comments

Comments
 (0)