Exemplo n.º 1
0
        /// <summary>
        ///     Downloads a file.
        /// </summary>
        /// <param name="file">The file</param>
        private async Task DownloadFile(FileManifest file)
        {
            // Subscribe to the download events
            _client.DownloadProgressChanged += OnDownloadProgressChanged;

            string path = GetCorrectFilePath(file.Filename);

            // Download file
            await _client.DownloadFileTaskAsync(file.Url, path);
        }
Exemplo n.º 2
0
 /// <summary>
 ///     Initializes a new instance of the <see cref="FileManifestEventArgs"/> class.
 /// </summary>
 /// <param name="file"></param>
 public FileManifestEventArgs(FileManifest file)
 {
     File = file;
 }