mirror of https://github.com/M66B/FairEmail.git
Cancel Send
This commit is contained in:
parent
636222b2f2
commit
024b823f38
|
@ -185,6 +185,9 @@ public class Send {
|
|||
ws.sendBinary(message);
|
||||
|
||||
seq++;
|
||||
|
||||
if (!intf.isRunning())
|
||||
throw new InterruptedException();
|
||||
}
|
||||
|
||||
Log.i("Send EOF size=" + size);
|
||||
|
@ -261,5 +264,7 @@ public class Send {
|
|||
|
||||
public interface IProgress {
|
||||
void onProgress(int percentage);
|
||||
|
||||
boolean isRunning();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -425,6 +425,11 @@ public class FragmentDialogInsertLink extends FragmentDialogBase {
|
|||
args.putInt("progress", percentage);
|
||||
postProgress(null, args);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isRunning() {
|
||||
return (pbUpload != null);
|
||||
}
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue