コード例 #1
0
 public override void Start()
 {
     download.CompleteCallback += new DownloadCompleteHandler(InternalDownloadComplete);
     if (download.SavedFilePath != null && download.SavedFilePath.Length > 0)
     {
         download.BackgroundDownloadFile();
     }
     else
     {
         download.BackgroundDownloadMemory();
     }
 }
コード例 #2
0
ファイル: ColorBar.cs プロジェクト: jpespartero/WorldWind
		/// <summary>
		/// Loads a bitmap from the web in background and displays.
		/// </summary>
		public void LoadImageInBackground( string url )
		{
			if(url != null && !url.ToLower().StartsWith("http://"))
			{
				// Local file
				Image = Image.FromFile(url);
				return;
			}

			oldText = Text;
			Text = Text + ": Loading...";
			WebDownload client = new WebDownload(url);
		////	client.CompleteCallback += new DownloadCompleteHandler(DownloadComplete);
			client.BackgroundDownloadMemory();
		}
コード例 #3
0
ファイル: MainForm.cs プロジェクト: paladin74/Dapple
 private void CheckForUpdates(bool bFromMenu)
 {
     m_bUpdateFromMenu = bFromMenu;
     WebDownload download = new WebDownload(WebsiteUrl + VersionFile);
     download.DownloadType = DownloadType.Unspecified;
     download.CompleteCallback += new DownloadCompleteHandler(UpdateDownloadComplete);
     download.BackgroundDownloadMemory();
 }