From be09eef7942facccd98bcc3ae3c5e07ce0ef4cd5 Mon Sep 17 00:00:00 2001 From: pxzleo Date: Thu, 7 Sep 2017 18:00:24 +0800 Subject: [PATCH] =?UTF-8?q?1=E5=B0=86=E9=A3=9E=E6=9C=BA=E7=9A=84=E6=96=87?= =?UTF-8?q?=E6=9C=AC=E6=8F=90=E7=A4=BA=E8=AE=B0=E5=85=A5=E6=97=A5=E5=BF=97?= =?UTF-8?q?=E6=96=87=E4=BB=B6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Plane.FormationCreator/App.xaml.cs | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Plane.FormationCreator/App.xaml.cs b/Plane.FormationCreator/App.xaml.cs index c231ce8..0e5bc3a 100644 --- a/Plane.FormationCreator/App.xaml.cs +++ b/Plane.FormationCreator/App.xaml.cs @@ -127,7 +127,10 @@ namespace Plane.FormationCreator UdpServerConnectionManager.Instance.ConnectionEstablished += ConnectionManager_ConnectionEstablished; UdpServerConnectionManager.Instance.StartReceiving(); } - + private void Copter_TextReceived(object sender, MessageCreatedEventArgs e) + { + _logger.Log(e.Message ); + } private async Task AddOrUpdateCopter(string ip, IConnection Connection) { var copters = _copterManager.Copters; @@ -145,7 +148,10 @@ namespace Plane.FormationCreator }; int _index; _index=copters.AddCopter(copter); - copterStatus.Insert(_index,false); + copterStatus.Insert(_index,false); + + copter.TextReceived += Copter_TextReceived; + })); } else