mirror of
				https://github.com/commons-app/apps-android-commons.git
				synced 2025-11-04 00:33:55 +01:00 
			
		
		
		
	Merge 045cfa24b3 into 78d29bcf20
				
					
				
			This commit is contained in:
		
						commit
						e794d114f5
					
				
					 1 changed files with 3 additions and 0 deletions
				
			
		| 
						 | 
					@ -117,6 +117,7 @@ class PendingUploadsFragment :
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    /**
 | 
					    /**
 | 
				
			||||||
     * Cancels a specific upload after getting a confirmation from the user using Dialog.
 | 
					     * 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?) {
 | 
					    override fun deleteUpload(contribution: Contribution?) {
 | 
				
			||||||
        val activity = requireActivity()
 | 
					        val activity = requireActivity()
 | 
				
			||||||
| 
						 | 
					@ -128,6 +129,8 @@ class PendingUploadsFragment :
 | 
				
			||||||
            String.format(locale, activity.getString(R.string.yes)),
 | 
					            String.format(locale, activity.getString(R.string.yes)),
 | 
				
			||||||
            String.format(locale, activity.getString(R.string.no)),
 | 
					            String.format(locale, activity.getString(R.string.no)),
 | 
				
			||||||
            {
 | 
					            {
 | 
				
			||||||
 | 
					                if(contributionsList.size== 1)
 | 
				
			||||||
 | 
					                {CommonsApplication.isPaused = false}
 | 
				
			||||||
                ViewUtil.showShortToast(context, R.string.cancelling_upload)
 | 
					                ViewUtil.showShortToast(context, R.string.cancelling_upload)
 | 
				
			||||||
                pendingUploadsPresenter.deleteUpload(
 | 
					                pendingUploadsPresenter.deleteUpload(
 | 
				
			||||||
                    contribution, requireContext().applicationContext,
 | 
					                    contribution, requireContext().applicationContext,
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue