コード例 #1
0
ファイル: MainView.cs プロジェクト: kouweizhong/vrs
 private void FlightSimulatorXView_CloseClicked(object sender, EventArgs e)
 {
     if (_FlightSimulatorXView != null)
     {
         _FlightSimulatorXView.CloseClicked -= FlightSimulatorXView_CloseClicked;
         _FlightSimulatorXView.Close();
         _FlightSimulatorXView.Dispose();
         _FlightSimulatorXView = null;
     }
 }
コード例 #2
0
ファイル: MainView.cs プロジェクト: kouweizhong/vrs
 private void menuFlightSimulatorXModeToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (_FlightSimulatorXView != null)
     {
         _FlightSimulatorXView.Activate();
     }
     else
     {
         var webServer = Factory.Singleton.ResolveSingleton <IAutoConfigWebServer>().WebServer;
         _FlightSimulatorXView = new FlightSimulatorXView();
         _FlightSimulatorXView.CloseClicked += FlightSimulatorXView_CloseClicked;
         _FlightSimulatorXView.Initialise(null, _FlightSimulatorXAircraftList, webServer);
         _FlightSimulatorXView.Show();
     }
 }
コード例 #3
0
 private void menuFlightSimulatorXModeToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if(_FlightSimulatorXView != null) _FlightSimulatorXView.Activate();
     else {
         var webServer = Factory.Singleton.Resolve<IAutoConfigWebServer>().Singleton.WebServer;
         _FlightSimulatorXView = new FlightSimulatorXView();
         _FlightSimulatorXView.CloseClicked += FlightSimulatorXView_CloseClicked;
         _FlightSimulatorXView.Initialise(_BaseStationAircraftList, _FlightSimulatorXAircraftList, webServer);
         _FlightSimulatorXView.Show();
     }
 }
コード例 #4
0
 private void FlightSimulatorXView_CloseClicked(object sender, EventArgs e)
 {
     if(_FlightSimulatorXView != null) {
         _FlightSimulatorXView.CloseClicked -= FlightSimulatorXView_CloseClicked;
         _FlightSimulatorXView.Close();
         _FlightSimulatorXView.Dispose();
         _FlightSimulatorXView = null;
     }
 }