public frmMain() { InitializeComponent(); airPort = AirPortClass.GetInstance(); gateA = AirPortClass.GetInstance().gates[0]; gateB = AirPortClass.GetInstance().gates[1]; gateC = AirPortClass.GetInstance().gates[2]; timerCountDown.Start(); }
public static AirPortClass GetInstance() { if (instance == null) { lock (lockObjest) { instance = new AirPortClass(); } } return(instance); }
public frm() { InitializeComponent(); airPort = AirPortClass.GetInstance(); gateA = AirPortClass.GetInstance().gates[0]; gateB = AirPortClass.GetInstance().gates[1]; gateC = AirPortClass.GetInstance().gates[2]; runtime = new Timer(); runtime.Interval = 1000; runtime.Tick += Runtime_Tick; looptime = new Timer(); looptime.Interval = Constand.LOOP_TIME; looptime.Tick += Looptime_Tick; }