mirror of
https://github.com/chylex/TweetDuck.git
synced 2024-10-17 09:42:45 +02:00
Daniel Chýlek
1ccefe853a
* Switch to .NET Framework 4.7.2 & C# 8.0, update libraries * Add TweetLib.Core project targeting .NET Standard 2.0 * Enable reference nullability checks for TweetLib.Core * Move a bunch of utility classes into TweetLib.Core & refactor * Partially move TweetDuck plugin & update system to TweetLib.Core * Move some constants and CultureInfo setup to TweetLib.Core * Move some configuration classes to TweetLib.Core * Minor refactoring and warning suppression * Add App to TweetLib.Core * Add IAppErrorHandler w/ implementation * Continue moving config, plugin, and update classes to TweetLib.Core * Fix a few nullability checks * Update installers to check for .NET Framework 4.7.2
32 lines
904 B
C#
32 lines
904 B
C#
using System;
|
|
using System.Windows.Forms;
|
|
using TweetLib.Core.Features.Updates;
|
|
|
|
namespace TweetDuck.Updates{
|
|
sealed partial class FormUpdateDownload : Form{
|
|
private readonly UpdateInfo updateInfo;
|
|
|
|
public FormUpdateDownload(UpdateInfo info){
|
|
InitializeComponent();
|
|
|
|
this.updateInfo = info;
|
|
|
|
Text = "Updating "+Program.BrandName;
|
|
labelDescription.Text = "Downloading version "+info.VersionTag+"...";
|
|
timerDownloadCheck.Start();
|
|
}
|
|
|
|
private void btnCancel_Click(object sender, EventArgs e){
|
|
Close();
|
|
}
|
|
|
|
private void timerDownloadCheck_Tick(object sender, EventArgs e){
|
|
if (updateInfo.DownloadStatus.IsFinished(false)){
|
|
timerDownloadCheck.Stop();
|
|
DialogResult = DialogResult.OK;
|
|
Close();
|
|
}
|
|
}
|
|
}
|
|
}
|