Skip to content

Commit

Permalink
Splash screen as background process
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanpmartell committed Aug 8, 2024
1 parent adfaef0 commit 575ebb9
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions LittleWarGameClient/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,13 @@ internal static class Program
[STAThread]
static void Main()
{
Thread _thread = new Thread(() =>
Thread splashthread = new Thread(() =>
{
SplashScreen.Instance.ShowDialog();
});
_thread.SetApartmentState(ApartmentState.STA);
_thread.Start();
splashthread.IsBackground = true;
splashthread.SetApartmentState(ApartmentState.STA);
splashthread.Start();
bool createdNew = true;
using (Mutex mutex = new Mutex(true, "Global\\LittleWarGameClient", out createdNew))
{
Expand Down

0 comments on commit 575ebb9

Please sign in to comment.