Uses ProgressUpdateListener interface in GuiUploadFile

This commit is contained in:
CrushedPixel
2015-07-02 23:17:59 +02:00
parent 8c81dd414e
commit 071a44e526
2 changed files with 15 additions and 2 deletions

View File

@@ -84,7 +84,12 @@ public class FileUploader {
while((len = fis.read(buf)) != -1) {
request.write(buf);
current += len;
parent.onProgressChanged(getUploadProgress());
if(cancel) {
parent.onProgressChanged(0f);
uploading = false;
current = 0;
cancel = false;