Upload large backup attachments using a foreground service.

This commit is contained in:
jeffrey-signal
2025-06-11 12:02:23 -04:00
committed by GitHub
parent f8d8558cdb
commit cd18db613a
18 changed files with 137 additions and 72 deletions

View File

@@ -3,6 +3,7 @@ package org.thoughtcrime.securesms.events;
import androidx.annotation.NonNull;
import org.thoughtcrime.securesms.attachments.Attachment;
import org.whispersystems.signalservice.api.messages.AttachmentTransferProgress;
public final class PartProgressEvent {
@@ -22,4 +23,11 @@ public final class PartProgressEvent {
this.total = total;
this.progress = progress;
}
public PartProgressEvent(@NonNull Attachment attachment, @NonNull Type type, @NonNull AttachmentTransferProgress progress) {
this.attachment = attachment;
this.type = type;
this.total = progress.getTotal().getInWholeBytes();
this.progress = progress.getTransmitted().getInWholeBytes();
}
}