mirror of
https://github.com/DSheirer/sdrtrunk.git
synced 2026-11-12 16:47:31 -05:00
MPT1327: Fix for call timeout setting not being honored (#823)
* MPT1327: Fix for call timeout setting not being honored
This commit is contained in:
committed by
GitHub
parent
8167e9e9f2
commit
e1194d26bd
@@ -40,6 +40,7 @@ import io.github.dsheirer.identifier.configuration.SiteConfigurationIdentifier;
|
||||
import io.github.dsheirer.identifier.configuration.SystemConfigurationIdentifier;
|
||||
import io.github.dsheirer.identifier.decoder.ChannelStateIdentifier;
|
||||
import io.github.dsheirer.module.decode.config.DecodeConfiguration;
|
||||
import io.github.dsheirer.module.decode.config.WithCallTimeout;
|
||||
import io.github.dsheirer.module.decode.event.IDecodeEvent;
|
||||
import io.github.dsheirer.sample.Listener;
|
||||
import io.github.dsheirer.source.ISourceEventListener;
|
||||
@@ -115,7 +116,12 @@ public class SingleChannelState extends AbstractChannelState implements IDecoder
|
||||
}
|
||||
else
|
||||
{
|
||||
mStateMachine.setFadeTimeoutBuffer(DecodeConfiguration.DEFAULT_CALL_TIMEOUT_DELAY_SECONDS * 1000);
|
||||
final DecodeConfiguration decodeConfig = channel.getDecodeConfiguration();
|
||||
final int fadeTimeoutSeconds = decodeConfig instanceof WithCallTimeout
|
||||
? ((WithCallTimeout) decodeConfig).getCallTimeout()
|
||||
: DecodeConfiguration.DEFAULT_CALL_TIMEOUT_DELAY_SECONDS;
|
||||
|
||||
mStateMachine.setFadeTimeoutBuffer(fadeTimeoutSeconds * 1000);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user