Prevent waterfall from clearing itself when RX mode changes.

ms-macos-dropout-improvement
Mooneer Salem 2025-05-18 22:54:33 -04:00
parent c345ab81b4
commit a2066cb865
2 changed files with 7 additions and 1 deletions

View File

@ -1028,6 +1028,7 @@ MainFrame::MainFrame(wxWindow *parent) : TopFrame(parent, wxID_ANY, _("FreeDV ")
#endif // defined(__linux__)
terminating_ = false;
realigned_ = false;
// Add config file name to title bar if provided at the command line.
if (wxGetApp().customConfigFileName != "")
@ -2051,7 +2052,9 @@ void MainFrame::OnTimer(wxTimerEvent &evt)
mode[STR_LENGTH], bits[STR_LENGTH], errors[STR_LENGTH], ber[STR_LENGTH],
resyncs[STR_LENGTH], clockoffset[STR_LENGTH], freqoffset[STR_LENGTH], syncmetric[STR_LENGTH];
snprintf(mode, STR_LENGTH, "Mode: %s", freedvInterface.getCurrentModeStr()); wxString modeString(mode);
bool relayout = m_textCurrentDecodeMode->GetLabel() != modeString;
bool relayout =
m_textCurrentDecodeMode->GetLabel() != modeString &&
!realigned_;
m_textCurrentDecodeMode->SetLabel(modeString);
if (relayout)
{
@ -2072,6 +2075,8 @@ void MainFrame::OnTimer(wxTimerEvent &evt)
{
SetSize(w, h);
});
realigned_ = true;
}
snprintf(bits, STR_LENGTH, "Bits: %d", freedvInterface.getTotalBits()); wxString bits_string(bits); m_textBits->SetLabel(bits_string);

View File

@ -496,6 +496,7 @@ class MainFrame : public TopFrame
wxMenuItem* recordNewVoiceKeyerFileMenuItem_;
bool terminating_; // used for terminating FreeDV
bool realigned_; // used to inhibit resize hack once already done
int getSoundCardIDFromName(wxString& name, bool input);
bool validateSoundCardSetup();