mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 08:26:37 +02:00
MDL-83989 file upload: Filemanager breaks if you drop file outside of it
This commit is contained in:
parent
e6c92dc291
commit
0a6cb5f2fa
1 changed files with 4 additions and 1 deletions
|
@ -176,10 +176,13 @@ M.form_dndupload.init = function(Y, options) {
|
|||
init_page_events: function() {
|
||||
this.Y.on('dragenter', this.drag_enter_page, 'body', this);
|
||||
this.Y.on('dragleave', this.drag_leave_page, 'body', this);
|
||||
this.Y.on('dragover', function(e) {
|
||||
e.preventDefault();
|
||||
}, 'body', this);
|
||||
this.Y.on('drop', function() {
|
||||
this.pageentercount = 0;
|
||||
this.hide_drop_target();
|
||||
}.bind(this));
|
||||
}, 'body', this);
|
||||
},
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue