mirror of
https://github.com/nextcloud/android.git
synced 2024-11-22 13:15:35 +03:00
Rebase master
Signed-off-by: alperozturk <alper_ozturk@proton.me>
This commit is contained in:
parent
df7f32cd1e
commit
bb0a580ada
2 changed files with 6 additions and 6 deletions
|
@ -68,8 +68,8 @@ class FilesUploadWorker(
|
|||
val context: Context,
|
||||
params: WorkerParameters
|
||||
) : Worker(context, params), OnDatatransferProgressListener {
|
||||
private var lastPercent = 0
|
||||
|
||||
private var lastPercent = 0
|
||||
private val notificationManager = UploadNotificationManager(context, viewThemeUtils)
|
||||
private val intents = FileUploaderIntents(context)
|
||||
private val fileUploaderDelegate = FileUploaderDelegate()
|
||||
|
@ -134,9 +134,6 @@ class FilesUploadWorker(
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* from @{link FileUploader#retryUploads()}
|
||||
*/
|
||||
private fun createUploadFileOperation(upload: OCUpload, user: User): UploadFileOperation {
|
||||
return UploadFileOperation(
|
||||
uploadsStorageManager,
|
||||
|
|
|
@ -60,6 +60,8 @@ class FilesUploadHelper {
|
|||
companion object {
|
||||
private val TAG = FilesUploadWorker::class.java.simpleName
|
||||
|
||||
// TODO is needed with worker?
|
||||
// val pendingUploads = IndexedForest<UploadFileOperation>()
|
||||
val mBoundListeners = HashMap<String, OnDatatransferProgressListener>()
|
||||
|
||||
fun buildRemoteName(accountName: String, remotePath: String): String {
|
||||
|
@ -215,8 +217,9 @@ class FilesUploadHelper {
|
|||
backgroundJobManager.startFilesUploadJob(user)
|
||||
}
|
||||
|
||||
fun cancel(accountName: String?) {
|
||||
// cancelPendingUploads(accountName)
|
||||
fun cancel(accountName: String) {
|
||||
// pendingUploads.remove(accountName)
|
||||
uploadsStorageManager.removeUploads(accountName)
|
||||
restartUploadJob(accountManager.getUser(accountName).get())
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue