mirror of
https://github.com/coderaiser/cloudcmd.git
synced 2026-01-23 18:55:26 +00:00
refactor(edit) onDrop: for -> forEach
This commit is contained in:
parent
4fcddfdaa9
commit
e546874045
1 changed files with 5 additions and 10 deletions
|
|
@ -412,19 +412,14 @@ var CloudCmd, Util, DOM, CloudFunc, ace, DiffProto, diff_match_patch, Zip;
|
|||
|
||||
event.preventDefault();
|
||||
|
||||
files = event.dataTransfer.files;
|
||||
files = event.dataTransfer.files;
|
||||
|
||||
if (files.length) {
|
||||
n = files.length;
|
||||
|
||||
for (i = 0; i < n; i++) {
|
||||
reader = new FileReader();
|
||||
file = files[i];
|
||||
|
||||
if (files)
|
||||
files.forEach(function(file) {
|
||||
reader = new FileReader();
|
||||
DOM.Events.add('load', onLoad, reader);
|
||||
reader.readAsBinaryString(file);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
this.showMessage = function(text) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue