Skip to content

Commit 7902f5c

Browse files
committed
remove 'update-check' delay on first form show
1 parent 6d86f2b commit 7902f5c

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

OpenHardwareMonitor/UI/MainForm.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
using System.IO;
66
using System.Linq;
77
using System.Runtime.InteropServices;
8+
using System.Threading.Tasks;
89
using System.Windows.Forms;
910
using Aga.Controls.Tree;
1011
using Aga.Controls.Tree.NodeControls;
@@ -658,7 +659,9 @@ private void MainForm_Load(object sender, EventArgs e)
658659
RestoreCollapsedNodeState(treeView);
659660
treeView.Width += 1; //just to apply column auto-resize
660661

661-
Updater.CheckForUpdates(true); //will display prompt only if update available & when main form displayed
662+
//will display prompt only if update available & when main form displayed
663+
Task task = Task.Delay(1000)
664+
.ContinueWith(t => Updater.CheckForUpdates(true));
662665

663666
FormClosed += MainForm_FormClosed;
664667
}

0 commit comments

Comments
 (0)