SafeDispatch/Safedispatch_4_0/WaitToLoad.cs

52 lines
1.8 KiB
C#
Raw Permalink Normal View History

2024-02-22 16:43:59 +00:00
using SafeMobileLib;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Telerik.WinControls;
namespace Safedispatch_4_0
{
public partial class WaitToLoad : Telerik.WinControls.UI.RadForm
{
public WaitToLoad(Boolean restartProcces)
{
InitializeComponent();
// create transparent background for labels when over a picture box
// this means to set the parent of the labels to the picture
// and then set the background to transparent
labelLoadingMap.Parent = pictureBox1;
labelLoading.Parent = pictureBox1;
labelLoadingMap.BackColor = Color.Transparent;
labelLoading.BackColor = Color.Transparent;
this.Text = labelLoadingMap.Text = MainForm2.returnLNGString("loadingMap");
labelLoading.Text = MainForm2.returnLNGString("autoCloseWin");
if (MainForm2.radioType == RADIOTYPE.SIMOCO)
this.Icon = Dispatcher.Properties.Resources.simoco_dispatch_24;
if (MainForm2.radioType == RADIOTYPE.EXCERA)
this.Icon = Dispatcher.Properties.Resources.AXYS_ICON;
if (restartProcces)
{
this.Text = MainForm2.returnLNGString("restartWindow");
this.panel1.BackgroundImage = null;
this.labelLoadingMap.Text = MainForm2.returnLNGString("restartSD");
this.labelLoading.Text = MainForm2.returnLNGString("wait5sec");
}
}
private void CloseWindowTimer_Tick(object sender, EventArgs e)
{
CloseWindowTimer.Stop();
CloseWindowTimer.Enabled = false;
this.Close();
}
}
}