public void Cancel(IDownloadFileManager manager, IUploadManager uploadManager)
 {
     if (DownloadingProgress > 0 && DownloadingProgress < 1)
     {
         manager.CancelDownloadFile(this);
         DownloadingProgress = 0;
         IsTransferring      = false;
     }
     else if (UploadingProgress > 0 && UploadingProgress < 1)
     {
         uploadManager.CancelUploadFile(Id);
         UploadingProgress = 0;
         IsTransferring    = false;
     }
 }
Пример #2
0
        public void Cancel(IDownloadFileManager manager, IUploadManager uploadManager)
        {
            if (manager != null)
            {
                manager.CancelDownloadFile(this);
                DownloadingProgress = 0;
                IsTransferring      = false;
            }

            if (uploadManager != null)
            {
                uploadManager.CancelUploadFile(Id);
                UploadingProgress = 0;
                IsTransferring    = false;
            }
        }