Fix broken lastGain property usage

This commit is contained in:
Charles J. Cliffe 2016-03-07 20:15:27 -05:00
parent 29d411cead
commit b155338b1d
2 changed files with 2 additions and 1 deletions

View File

@ -1189,6 +1189,7 @@ void AppFrame::OnIdle(wxIdleEvent& event) {
if (demod != activeDemodulator) {
demodSignalMeter->setInputValue(demod->getSquelchLevel());
demodGainMeter->setInputValue(demod->getGain());
wxGetApp().getDemodMgr().setLastGain(demod->getGain());
int outputDevice = demod->getOutputDevice();
scopeCanvas->setDeviceName(outputDevices[outputDevice].name);
outputDeviceMenuItems[outputDevice]->Check(true);
@ -1848,6 +1849,7 @@ int AppFrame::OnGlobalKeyDown(wxKeyEvent &event) {
wxGetApp().getDemodMgr().setActiveDemodulator(nullptr);
wxGetApp().getDemodMgr().setActiveDemodulator(demod, false);
}
return 1;
break;
default:
break;

View File

@ -359,7 +359,6 @@ int DemodulatorInstance::getAudioSampleRate() {
void DemodulatorInstance::setGain(float gain_in) {
currentAudioGain = gain_in;
audioThread->setGain(gain_in);
wxGetApp().getDemodMgr().setLastGain(gain_in);
}
float DemodulatorInstance::getGain() {