소스 검색

Doktor receives and update help text

Janco Kock 10 년 전
부모
커밋
1160cbca65
2개의 변경된 파일7개의 추가작업 그리고 2개의 파일을 삭제
  1. 4 2
      ErgometerIPR/ErgometerApplication/ClientApplicatie.cs
  2. 3 0
      ErgometerIPR/ErgometerDoctorApplication/Client/ClientThread.cs

+ 4 - 2
ErgometerIPR/ErgometerApplication/ClientApplicatie.cs

@@ -31,7 +31,7 @@ namespace ErgometerApplication
 
         private void updateBeep(object sender, EventArgs e)
         {
-            MainClient.RPMBeatAudio();
+            Console.Beep(1000,5);
         }
         private void updateTimer_Tick(object sender, EventArgs e)
         {
@@ -103,6 +103,8 @@ namespace ErgometerApplication
         public void updateStepsText(string text)
         {
             steps.setText(text);
+            MainClient.SendNetCommand(new NetCommand(MainClient.Session, text));
+            Console.Beep(1200, 500);
         }
 
         public void CreateNewTest(char geslacht, int leeftijd, int gewicht, int lengte)
@@ -117,7 +119,7 @@ namespace ErgometerApplication
             MainClient.ComPort.Read();
             ergotest = new ErgometerTest(gewicht, lengte, leeftijd, geslacht, this);
             updateTimer.Start();
-            beeptimer.Start();
+            
         }
 
         private void buttonLogOff_Click(object sender, EventArgs e)

+ 3 - 0
ErgometerIPR/ErgometerDoctorApplication/Client/ClientThread.cs

@@ -54,6 +54,9 @@ namespace ErgometerDoctorApplication
                     Chat.Add(chat);
                     window.panelClientChat.Invoke(window.panelClientChat.passChatMessage, new Object[] { chat });
                     break;
+                case NetCommand.CommandType.UITLEG:
+                    window.updateStepsText(command.UitlegText);
+                    break;
             }
         }