mirror of
https://github.com/DSheirer/sdrtrunk.git
synced 2026-11-12 08:37:25 -05:00
135 WIP - updates to resolve issue with all audio being recorded, even when user has not elected to record the audio.
This commit is contained in:
@@ -55,7 +55,8 @@ public class Metadata
|
||||
|
||||
//Lazily constructed member variables.
|
||||
private Integer mAudioPriority;
|
||||
protected Boolean mRecordable;
|
||||
protected Boolean mRecordable = false;
|
||||
protected Boolean mDoNotRecord;
|
||||
private List<BroadcastChannel> mBroadcastChannels;
|
||||
|
||||
|
||||
@@ -141,12 +142,12 @@ public class Metadata
|
||||
*/
|
||||
public boolean isRecordable()
|
||||
{
|
||||
if(mRecordable == null)
|
||||
if(mDoNotRecord == null)
|
||||
{
|
||||
determineRecordable();
|
||||
}
|
||||
|
||||
return mRecordable;
|
||||
return mRecordable & !mDoNotRecord;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -545,29 +546,29 @@ public class Metadata
|
||||
*/
|
||||
private void determineRecordable()
|
||||
{
|
||||
mRecordable = true;
|
||||
mDoNotRecord = false;
|
||||
|
||||
if(mPrimaryAddressTo.hasAlias() && !mPrimaryAddressTo.getAlias().isRecordable())
|
||||
{
|
||||
mRecordable = false;
|
||||
mDoNotRecord = true;
|
||||
return;
|
||||
}
|
||||
|
||||
if(mPrimaryAddressFrom.hasAlias() && !mPrimaryAddressFrom.getAlias().isRecordable())
|
||||
{
|
||||
mRecordable = false;
|
||||
mDoNotRecord = true;
|
||||
return;
|
||||
}
|
||||
|
||||
if(mSecondaryAddressTo.hasAlias() && !mSecondaryAddressTo.getAlias().isRecordable())
|
||||
{
|
||||
mRecordable = false;
|
||||
mDoNotRecord = true;
|
||||
return;
|
||||
}
|
||||
|
||||
if(mSecondaryAddressFrom.hasAlias() && !mSecondaryAddressFrom.getAlias().isRecordable())
|
||||
{
|
||||
mRecordable = false;
|
||||
mDoNotRecord = true;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user