Exemplo n.º 1
0
 internal bool NotifyDidReceiveDataOfLength(WebDownload download, uint length)
 {
     if (DidCancel)
     {
         download.cancel();
         return(false);
     }
     else
     {
         DownloadReceiveData(this, new DownloadReceiveDataEventArgs(length));
         return(true);
     }
 }
Exemplo n.º 2
0
 private void DownloadForm_FormClosed(object sender, FormClosingEventArgs e)
 {
     if (System.IO.File.Exists(FileForDownloading))
     {
         if (MessageBox.Show("Are you sure you want to cancel this download?", "Downloader", MessageBoxButtons.YesNoCancel) == System.Windows.Forms.DialogResult.Yes)
         {
             download.cancel();
             e.Cancel = false;
             this.Close();
         }
         else
         {
             e.Cancel = true;
         }
     }
 }
Exemplo n.º 3
0
 internal bool NotifyDidReceiveDataOfLength(WebDownload download, uint length)
 {
     if (DidCancel)
     {
         download.cancel();
         return false;
     }
     else
     {
         DownloadReceiveData(this, new DownloadReceiveDataEventArgs(length));
         return true;
     }
 }