This commit is contained in:
yz.gao 2024-10-19 01:21:55 +11:00
parent c7065e103b
commit 17a035230c

View file

@ -116,6 +116,7 @@ class PendingUploadsFragment :
/**
* Cancels a specific upload after getting a confirmation from the user using Dialog.
* And if the deleted upload is the last one, will set app off paused, allowing a fresh new start for future uploads.
*/
override fun deleteUpload(contribution: Contribution?) {
showAlertDialog(
@ -131,6 +132,8 @@ class PendingUploadsFragment :
String.format(Locale.getDefault(), requireActivity().getString(R.string.yes)),
String.format(Locale.getDefault(), requireActivity().getString(R.string.no)),
{
if(contributionsList.size== 1)
{CommonsApplication.isPaused = false}
ViewUtil.showShortToast(context, R.string.cancelling_upload)
pendingUploadsPresenter.deleteUpload(
contribution,