CramLink_v2/SplashContext.cs
2025-05-05 11:45:57 -05:00

28 lines
630 B
C#

using System;
using System.Windows.Forms;
using System.Threading.Tasks;
namespace CramLinkClientGUI
{
public class SplashContext : ApplicationContext
{
private SplashForm splash;
private MainForm main;
public SplashContext()
{
splash = new SplashForm();
splash.Shown += async (s, e) =>
{
await Task.Delay(2500);
splash.Hide();
main = new MainForm();
main.FormClosed += (s2, e2) => ExitThread();
main.Show();
};
splash.Show();
}
}
}