jQuery backward compatibility
This commit is contained in:
parent
b25833bd96
commit
3c84e9b599
@ -266,16 +266,18 @@ function dmsfDragOutHandler(e) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function dmsfSetupFileDrop() {
|
function dmsfSetupFileDrop() {
|
||||||
|
|
||||||
if (window.File && window.FileList && window.ProgressEvent && window.FormData) {
|
if (window.File && window.FileList && window.ProgressEvent && window.FormData) {
|
||||||
|
|
||||||
$.event.fixHooks.drop = { props: [ 'dataTransfer' ] };
|
$.event.addProp('dataTransfer');
|
||||||
|
|
||||||
|
$('form span.dmsf-uploader:not(.dmsffiledroplistner)').has('input:file').each(function () {
|
||||||
|
|
||||||
$('form span.dmsf-uploader').has('input:file').each(function() {
|
|
||||||
$(this).on({
|
$(this).on({
|
||||||
dragover: dmsfDragOverHandler,
|
dragover: dmsfDragOverHandler,
|
||||||
dragleave: dmsfDragOutHandler,
|
dragleave: dmsfDragOutHandler,
|
||||||
drop: dmsfHandleFileDropEvent
|
drop: dmsfHandleFileDropEvent
|
||||||
});
|
}).addClass('dmsffiledroplistner');
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user