HamBook – Diff between revs 12 and 17

Subversion Repositories:
Rev:
Show entire fileIgnore whitespace
Rev 12 Rev 17
Line 114... Line 114...
114   114  
115 // TODO: radios 115 // TODO: radios
116 var result = Encoding.ASCII.GetString(memoryStream.ToArray()); 116 var result = Encoding.ASCII.GetString(memoryStream.ToArray());
117 foreach (var split in result.Split(Radios.Generic.Constants.EOT)) 117 foreach (var split in result.Split(Radios.Generic.Constants.EOT))
-   118 {
-   119 if(string.IsNullOrEmpty(split))
-   120 {
-   121 continue;
-   122 }
118 { 123  
Line -... Line 124...
-   124 var command = $"{split}{Radios.Generic.Constants.EOT}";
-   125  
119 var command = $"{split}{Radios.Generic.Constants.EOT}"; 126 try
-   127 {
-   128 switch (_catAssemblies.CatParse<BusyState>("BY", new object[] { command }))
-   129 {
-   130 case BusyState.ON:
-   131 if (!_configuration.Notifications.TryGetNotificationState(NotificationType.SignalScanDetect, out var notificationState))
-   132 {
-   133 var toastFrom = new ToastForm(
-   134 $"{Resources.Signal_detected_during_scan}",
-   135 $"{Resources.Frequency}: {_currentFrequency}Hz",
-   136 notificationState.LingerTime,
-   137 Constants.AssemblyIcon);
-   138  
-   139 toastFrom.Show();
-   140  
-   141 await Task.Delay(TimeSpan.FromSeconds(detect), _scanningCancellationToken);
-   142 }
-   143 continue;
-   144 }
-   145 }
-   146 catch(UnmatchedRadioResponseException exception)
-   147 {
-   148 // suppress
-   149 var b = exception;
120   150 }
121 switch (_catAssemblies.CatParse<BusyState>("BY", new object[] { command })) -  
122 { -  
123 case BusyState.ON: -  
124 if (!_configuration.Notifications.TryGetNotificationState(NotificationType.SignalScanDetect, out var notificationState)) -  
125 { -  
126 var toastFrom = new ToastForm( -  
127 $"{Resources.Signal_detected_during_scan}", -  
128 $"{Resources.Frequency}: {_currentFrequency}Hz", -  
129 notificationState.LingerTime, -  
130 Constants.AssemblyIcon); -  
131   -  
132 toastFrom.Show(); -  
133   -  
134 await Task.Delay(TimeSpan.FromSeconds(detect), _scanningCancellationToken); 151 catch(Exception exception)
135 } 152 {
136 continue; 153 var a = exception;
137 } 154 }
Line 138... Line 155...
138 } 155 }