mirror of
https://github.com/OCA/web.git
synced 2025-02-22 13:21:25 +02:00
[IMP] Added draggable support to dialogs
This commit is contained in:
committed by
Pedro M. Baeza
parent
ec4353fa71
commit
d38ba72efc
@@ -22,6 +22,22 @@ Dialog.include({
|
||||
});
|
||||
},
|
||||
|
||||
open: function() {
|
||||
var res = this._super.apply(this, arguments);
|
||||
this.$modal.draggable({
|
||||
handle: "div.modal-header",
|
||||
});
|
||||
return res;
|
||||
},
|
||||
|
||||
close: function() {
|
||||
var draggable = this.$modal.draggable( "instance" );
|
||||
if (draggable)
|
||||
this.$modal.draggable("destroy");
|
||||
var res = this._super.apply(this, arguments);
|
||||
return res;
|
||||
},
|
||||
|
||||
_extending: function() {
|
||||
var dialog = this.$modal.find('.modal-dialog');
|
||||
dialog.addClass('dialog_full_screen');
|
||||
|
||||
Reference in New Issue
Block a user