Skip to content

Commit

Permalink
Merge pull request #459 from drowe67/ms-disable-qsy-same-freq
Browse files Browse the repository at this point in the history
Disable QSY button if the user is already on our frequency.
  • Loading branch information
tmiw authored Jul 4, 2023
2 parents 65efac6 + ce6668a commit 4d86a1c
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 4 deletions.
2 changes: 1 addition & 1 deletion USER_MANUAL.html
Original file line number Diff line number Diff line change
Expand Up @@ -617,7 +617,7 @@ <h2 data-number="17.1" id="v1.8.12-tbd-2023"><span class="header-section-number"
</ul></li>
<li>Enhancements:
<ul>
<li>Add the ability to request that another FreeDV Reporter user QSY. (PR #434, #453, #456, #458)</li>
<li>Add the ability to request that another FreeDV Reporter user QSY. (PR #434, #453, #456, #458, #459)</li>
<li>Display ‘Digital’ on button when Analog mode is active. (PR #447)</li>
<li>Set minimum size for Mode box to 250px. (PR #446)</li>
<li>Notify FreeDV Reporter if only capable of RX. (PR #449)</li>
Expand Down
2 changes: 1 addition & 1 deletion USER_MANUAL.md
Original file line number Diff line number Diff line change
Expand Up @@ -875,7 +875,7 @@ LDPC | Low Density Parity Check Codes - a family of powerful FEC codes
* Disable PTT and Voice Keyer buttons if only RX devices are configured. (PR #449)
* Fix Linux display bugs when switching between dark and light mode. (PR #454)
2. Enhancements:
* Add the ability to request that another FreeDV Reporter user QSY. (PR #434, #453, #456, #458)
* Add the ability to request that another FreeDV Reporter user QSY. (PR #434, #453, #456, #458, #459)
* Display 'Digital' on button when Analog mode is active. (PR #447)
* Set minimum size for Mode box to 250px. (PR #446)
* Notify FreeDV Reporter if only capable of RX. (PR #449)
Expand Down
Binary file modified USER_MANUAL.pdf
Binary file not shown.
10 changes: 8 additions & 2 deletions src/freedv_reporter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -188,9 +188,15 @@ void FreeDVReporterDialog::refreshQSYButtonState()
{
auto selectedCallsign = m_listSpots->GetItemText(selectedIndex);

if (selectedCallsign != wxGetApp().m_reportingCallsign && wxGetApp().m_reportingFrequency > 0)
if (selectedCallsign != wxGetApp().m_reportingCallsign &&
wxGetApp().m_reportingFrequency > 0)
{
enabled = true;
wxString theirFreqString = m_listSpots->GetItemText(selectedIndex, 3);
wxRegEx mhzRegex(" MHz$");
mhzRegex.Replace(&theirFreqString, "");

uint64_t theirFreq = wxAtof(theirFreqString) * 1000 * 1000;
enabled = theirFreq != wxGetApp().m_reportingFrequency;
}
}

Expand Down

0 comments on commit 4d86a1c

Please sign in to comment.