mirror of
https://github.com/DSheirer/sdrtrunk.git
synced 2026-11-12 08:37:25 -05:00
Resolves #170 adding support for Airspy Mini tuner's 3 and 6 MHz
sample rates. Resolves issue in PolyphaseChannelManager responding to sample rate changes in the tuner. The manager now recreates the channelizer when needed if the tuner's sample rate has changed since the last time the channelizer was used. Updates the Tuner selection view to reflect tuner lock state. Updates the tuner editors to enable/disable frequency controller and sample rate controls according to the tuner's lock state.
This commit is contained in:
@@ -125,6 +125,8 @@ public class JFrequencyControl extends JPanel implements ISourceEventProcessor
|
||||
mBlankCursor = Toolkit.getDefaultToolkit()
|
||||
.createCustomCursor(cursorImage, new Point(0, 0), "cursor");
|
||||
|
||||
setTooltip(false);
|
||||
|
||||
revalidate();
|
||||
}
|
||||
|
||||
@@ -139,6 +141,26 @@ public class JFrequencyControl extends JPanel implements ISourceEventProcessor
|
||||
}
|
||||
}
|
||||
|
||||
private void setTooltip(boolean locked)
|
||||
{
|
||||
String tooltip = null;
|
||||
|
||||
if(locked)
|
||||
{
|
||||
tooltip = "Frequency control is locked. Disable decoding channels to unlock.";
|
||||
}
|
||||
else
|
||||
{
|
||||
tooltip = "Click on a frequency digit and type a frequency value, or click the upper/lower digits to " +
|
||||
"change the value";
|
||||
}
|
||||
|
||||
for(Digit digit: mDigits.values())
|
||||
{
|
||||
digit.setToolTipText(tooltip);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Receives a frequency change event invoked by another control. We don't
|
||||
* rebroadcast this event, just set the control to indicate the new frequency.
|
||||
@@ -165,6 +187,7 @@ public class JFrequencyControl extends JPanel implements ISourceEventProcessor
|
||||
public void run()
|
||||
{
|
||||
setEnabled(false);
|
||||
setTooltip(true);
|
||||
}
|
||||
});
|
||||
break;
|
||||
@@ -175,6 +198,7 @@ public class JFrequencyControl extends JPanel implements ISourceEventProcessor
|
||||
public void run()
|
||||
{
|
||||
setEnabled(true);
|
||||
setTooltip(false);
|
||||
}
|
||||
});
|
||||
break;
|
||||
|
||||
Reference in New Issue
Block a user