Sleep before install
This commit is contained in:
parent
b395ab2d81
commit
a64d3ab4bc
|
@ -4,6 +4,7 @@ using System.IO.Compression;
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Net;
|
using System.Net;
|
||||||
using System.Security.Cryptography;
|
using System.Security.Cryptography;
|
||||||
|
using System.Threading;
|
||||||
using System.Windows.Forms;
|
using System.Windows.Forms;
|
||||||
using System.Xml.Linq;
|
using System.Xml.Linq;
|
||||||
using UpToolLib;
|
using UpToolLib;
|
||||||
|
@ -19,11 +20,11 @@ namespace Installer
|
||||||
[STAThread]
|
[STAThread]
|
||||||
private static void Main(string[] args)
|
private static void Main(string[] args)
|
||||||
{
|
{
|
||||||
MutexLock.Lock();
|
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
if (!args.Any(s => new[] {"install", "i"}.Contains(s.TrimStart('-', '/').ToLower())))
|
if (!args.Any(s => new[] {"install", "i"}.Contains(s.TrimStart('-', '/').ToLower())))
|
||||||
{
|
{
|
||||||
|
MutexLock.Lock();
|
||||||
Application.SetHighDpiMode(HighDpiMode.SystemAware);
|
Application.SetHighDpiMode(HighDpiMode.SystemAware);
|
||||||
Application.EnableVisualStyles();
|
Application.EnableVisualStyles();
|
||||||
Application.SetCompatibleTextRenderingDefault(false);
|
Application.SetCompatibleTextRenderingDefault(false);
|
||||||
|
@ -31,6 +32,8 @@ namespace Installer
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Thread.Sleep(2000);
|
||||||
|
MutexLock.Lock();
|
||||||
ExternalFunctionalityManager.Init(new UtLibFunctionsCli());
|
ExternalFunctionalityManager.Init(new UtLibFunctionsCli());
|
||||||
WebClient client = new WebClient();
|
WebClient client = new WebClient();
|
||||||
Console.WriteLine("Downloading metadata");
|
Console.WriteLine("Downloading metadata");
|
||||||
|
|
Reference in New Issue
Block a user