Adding support for containment

This commit is contained in:
Frank Glück 2021-09-29 10:07:30 +02:00 committed by GitHub
parent 2802058ba8
commit 73dd7818b1
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -95,7 +95,8 @@ $.widget( "ui.dialog", {
open: null,
resize: null,
resizeStart: null,
resizeStop: null
resizeStop: null,
containment: "document"
},
sizeRelatedOptions: {
@ -547,7 +548,7 @@ $.widget( "ui.dialog", {
this.uiDialog.draggable( {
cancel: ".ui-dialog-content, .ui-dialog-titlebar-close",
handle: ".ui-dialog-titlebar",
containment: "document",
containment: options.containment,
start: function( event, ui ) {
that._addClass( $( this ), "ui-dialog-dragging" );
that._blockFrames();