Skip to content

Commit

Permalink
Update dialog.js
Browse files Browse the repository at this point in the history
Update dialog.js
  • Loading branch information
uplusware committed Oct 21, 2021
1 parent 473edf3 commit 83ae561
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions ui/widgets/dialog.js
Original file line number Diff line number Diff line change
Expand Up @@ -463,7 +463,9 @@ $.widget( "ui.dialog", {
event.preventDefault();
this.options.restoreWidth = this.options.width;
this.options.restoreHeight = this.options.height;
this.uiDialog.width( this.uiDialogTitlebar.outerWidth() > 300 ? 300 : this.uiDialogTitlebar.outerWidth() );
this.uiDialog.width( this.uiDialogTitlebar.outerWidth() > 300 ?
300 :
this.uiDialogTitlebar.outerWidth() );
this.uiDialog.height( this.uiDialogTitlebar.outerHeight() );
this.element.hide();
this.uiDialogButtonPane.hide();
Expand All @@ -483,11 +485,13 @@ $.widget( "ui.dialog", {
click: function( event ) {
event.preventDefault();
if ( this.options.restoreWidth !== undefined &&
this.options.restoreWidth !== null && this.options.restoreWidth !== "" ) {
this.options.restoreWidth !== null &&
this.options.restoreWidth !== "" ) {
this.uiDialog.width( this.options.restoreWidth );
}
if ( this.options.restoreHeight !== undefined &&
this.options.restoreHeight !== null && this.options.restoreHeight !== "" ) {
this.options.restoreHeight !== null &&
this.options.restoreHeight !== "" ) {
this.uiDialog.height( this.options.restoreHeight );
}
this.element.show();
Expand Down

0 comments on commit 83ae561

Please sign in to comment.