Fix for following demod frequency

This commit is contained in:
Charles J. Cliffe 2015-03-31 17:51:56 -04:00
parent efa2cd75c9
commit 9b283fbcef

View File

@ -508,13 +508,13 @@ void AppFrame::OnIdle(wxIdleEvent& event) {
}
if (wxGetApp().getFrequency() != demodWaterfallCanvas->getCenterFrequency()) {
if (spectrumCanvas->getViewState() && abs(wxGetApp().getFrequency()-spectrumCanvas->getCenterFrequency()) > (wxGetApp().getSampleRate()/2)) {
spectrumCanvas->setCenterFrequency(wxGetApp().getFrequency());
waterfallCanvas->setCenterFrequency(wxGetApp().getFrequency());
}
demodWaterfallCanvas->setCenterFrequency(wxGetApp().getFrequency());
demodSpectrumCanvas->setCenterFrequency(wxGetApp().getFrequency());
}
if (spectrumCanvas->getViewState() && abs(wxGetApp().getFrequency()-spectrumCanvas->getCenterFrequency()) > (wxGetApp().getSampleRate()/2)) {
spectrumCanvas->setCenterFrequency(wxGetApp().getFrequency());
waterfallCanvas->setCenterFrequency(wxGetApp().getFrequency());
}
}
if (!waterfallCanvas->HasFocus()) {