Beispiel #1
0
 /// <summary>
 /// Something has Changed in our Connections update the Pad!!!
 /// </summary>
 /// <param name="source"></param>
 /// <param name="arg"></param>
 /// <param name="state"></param>
 void currentUAV_CommunicationStatusChanged(UAVCommons.UAVBase source, UAVCommons.CommunicationEndpoint arg, string state)
 {
     try
     {
         if (this.dataGridView1.InvokeRequired)
         {
             this.dataGridView1.Invoke((MethodInvoker) delegate {
                 UpdateGrid(source.knownEndpoints);
             });
         }
         else
         {
             UpdateGrid(source.knownEndpoints);
         }
     }
     catch (Exception ex) { }
 }
Beispiel #2
0
 void currentUAV_CommunicationStatusChanged(UAVCommons.UAVBase source, UAVCommons.CommunicationEndpoint arg, string state)
 {
     if (ShowConnectionsStateChanges)
     {
         string connectedstring = "";
         if (arg.Connected())
         {
             connectedstring = " established";
         }
         else
         {
             connectedstring = " lost";
         }
         if (logbox.InvokeRequired)
         {
             logbox.Invoke((MethodInvoker) delegate { logbox.Items.Insert(0, "Verbindung mit uav:" + arg.commType.ToString() + connectedstring); });
         }
     }
 }