Skip to content

Commit 75b405b

Browse files
committed
Fixed update window not showing when an update was available
1 parent eadd963 commit 75b405b

9 files changed

+41
-23
lines changed

FileAES-Legacy/Core.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ class Core
77
{
88
private const bool _flagIsDevBuild = false;
99
private const bool _flagIsBetaBuild = true;
10-
private const string _betaBuildTag = "BETA_1";
10+
private const string _betaBuildTag = "BETA_2";
1111
private const string _copyrightInfo = "mullak99 © 2019";
1212

1313
private bool _versionSpoof = false;

FileAES-Legacy/FileAES-Decrypt.Designer.cs

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

FileAES-Legacy/FileAES-Decrypt.cs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,13 @@ public FileAES_Decrypt(string file, string password = null)
3333
progressBar.VisualMode = ProgressBarDisplayMode.Percentage;
3434
}
3535

36-
private void FileAES_Decrypt_Load(object sender, EventArgs e)
36+
private void FileAES_Decrypt_Shown(object sender, EventArgs e)
3737
{
3838
update.CheckForUpdate();
39+
}
40+
41+
private void FileAES_Decrypt_Load(object sender, EventArgs e)
42+
{
3943
hintTextbox.Text = _fileToDecrypt.GetPasswordHint();
4044

4145
if (_autoPassword != null && _autoPassword.Length > 3)

FileAES-Legacy/FileAES-Encrypt.Designer.cs

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

FileAES-Legacy/FileAES-Encrypt.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,13 @@ public FileAES_Encrypt(string file, string password = null)
3737
progressBar.VisualMode = ProgressBarDisplayMode.Percentage;
3838
}
3939

40-
private void FileAES_Encrypt_Load(object sender, EventArgs e)
40+
private void FileAES_Encrypt_Shown(object sender, EventArgs e)
4141
{
4242
update.CheckForUpdate();
43+
}
4344

45+
private void FileAES_Encrypt_Load(object sender, EventArgs e)
46+
{
4447
if (_autoPassword != null && _autoPassword.Length > 3)
4548
{
4649
passwordInput.Text = _autoPassword;

FileAES-Legacy/FileAES-Main.Designer.cs

Lines changed: 4 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

FileAES-Legacy/FileAES-Main.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,14 @@ public FileAES_Main()
1717
copyrightLabel.Text = core.getCopyrightInfo();
1818
}
1919

20-
private void FileAES_Main_Load(object sender, EventArgs e)
20+
private void FileAES_Main_Shown(object sender, EventArgs e)
2121
{
2222
update.CheckForUpdate();
2323
}
2424

25+
private void FileAES_Main_Load(object sender, EventArgs e)
26+
{ }
27+
2528
private void encryptFileDrop_DragEnter(object sender, DragEventArgs e)
2629
{
2730
if (e.Data.GetDataPresent(DataFormats.FileDrop))

FileAES-Legacy/FileAES-Update.Designer.cs

Lines changed: 14 additions & 14 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

FileAES-Legacy/FileAES-Update.cs

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ public partial class FileAES_Update : Form
1616
private string _latestVersion;
1717
private bool _updateThreadRunning = false;
1818
private bool _updateUI = false;
19+
private bool _showOnce = false;
1920

2021
private static Core core = new Core();
2122

@@ -118,8 +119,6 @@ public void CheckForUpdate()
118119
_updateThreadRunning = false;
119120
});
120121
threaddedUpdateCheck.Start();
121-
122-
if (_appUpdateStatus == UpdateStatus.AppOutdated && !Program.GetSkipUpdate()) this.Show();
123122
}
124123
}
125124

@@ -188,6 +187,12 @@ public void UpdateUI()
188187
downloadLatestButton.Visible = false;
189188
downloadLatestButton.Enabled = false;
190189
latestVerLabel.Text = "Latest Version: " + latestVersion;
190+
191+
if (_appUpdateStatus == UpdateStatus.AppOutdated && !Program.GetSkipUpdate() && !_showOnce)
192+
{
193+
_showOnce = true;
194+
this.Show();
195+
}
191196
}
192197
_updateUI = false;
193198
}

0 commit comments

Comments
 (0)