35
35
import io .github .dsheirer .identifier .Role ;
36
36
import io .github .dsheirer .identifier .alias .DmrTalkerAliasIdentifier ;
37
37
import io .github .dsheirer .identifier .integer .IntegerIdentifier ;
38
+ import io .github .dsheirer .identifier .radio .RadioIdentifier ;
38
39
import io .github .dsheirer .identifier .talkgroup .TalkgroupIdentifier ;
39
40
import io .github .dsheirer .log .LoggingSuppressor ;
40
41
import io .github .dsheirer .message .EmptyTimeslotPlaceholderMessage ;
@@ -354,7 +355,7 @@ private void updateRestChannel(DMRChannel restChannel)
354
355
//Only respond if this is a standard/control channel (not a traffic channel).
355
356
if (mChannel .isStandardChannel () && getCurrentFrequency () > 0 &&
356
357
restChannel .getDownlinkFrequency () > 0 &&
357
- restChannel .getDownlinkFrequency () != getCurrentFrequency () && mTrafficChannelManager != null )
358
+ restChannel .getDownlinkFrequency () != getCurrentFrequency () && hasTrafficChannelManager () )
358
359
{
359
360
mTrafficChannelManager .convertToTrafficChannel (mChannel , getCurrentFrequency (), restChannel ,
360
361
mNetworkConfigurationMonitor );
@@ -1206,6 +1207,13 @@ private void processLinkControl(LCMessage message, boolean isTerminator)
1206
1207
DmrTalkerAliasIdentifier updated = DmrTalkerAliasIdentifier
1207
1208
.create (alias .getTalkerAliasIdentifier ().getValue () + talkerAlias .getValue ());
1208
1209
getIdentifierCollection ().update (updated );
1210
+
1211
+ Identifier fromRadio = getIdentifierCollection ().getFromIdentifier ();
1212
+
1213
+ if (hasTrafficChannelManager () && fromRadio instanceof RadioIdentifier radio )
1214
+ {
1215
+ mTrafficChannelManager .getTalkerAliasManager ().update (radio , updated );
1216
+ }
1209
1217
}
1210
1218
else
1211
1219
{
@@ -1232,6 +1240,13 @@ private void processLinkControl(LCMessage message, boolean isTerminator)
1232
1240
DmrTalkerAliasIdentifier updated = DmrTalkerAliasIdentifier .create (talkerAlias .getValue () +
1233
1241
alias .getTalkerAliasIdentifier ().getValue ());
1234
1242
getIdentifierCollection ().update (updated );
1243
+
1244
+ Identifier fromRadio = getIdentifierCollection ().getFromIdentifier ();
1245
+
1246
+ if (hasTrafficChannelManager () && fromRadio instanceof RadioIdentifier radio )
1247
+ {
1248
+ mTrafficChannelManager .getTalkerAliasManager ().update (radio , updated );
1249
+ }
1235
1250
}
1236
1251
else
1237
1252
{
@@ -1492,10 +1507,13 @@ public String getActivitySummary()
1492
1507
{
1493
1508
if (networkAdded )
1494
1509
{
1495
- sb .append ("\n \n " );
1510
+ sb .append ("\n " );
1496
1511
}
1497
1512
1498
- sb .append (mTrafficChannelManager .getTalkerAliasManager ().getAliasSummary ());
1513
+ if (hasTrafficChannelManager ())
1514
+ {
1515
+ sb .append (mTrafficChannelManager .getTalkerAliasManager ().getAliasSummary ());
1516
+ }
1499
1517
}
1500
1518
1501
1519
return sb .toString ();
0 commit comments