From 654aae238335e1d85308d4012d7ebd362d277162 Mon Sep 17 00:00:00 2001 From: "Charles J. Cliffe" Date: Thu, 9 Jun 2016 18:16:03 -0400 Subject: [PATCH] Add 'p' key as peak-hold toggle --- src/AppFrame.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/AppFrame.cpp b/src/AppFrame.cpp index ab04eab..902e258 100644 --- a/src/AppFrame.cpp +++ b/src/AppFrame.cpp @@ -1898,6 +1898,7 @@ int AppFrame::OnGlobalKeyDown(wxKeyEvent &event) { case 'L': case 'U': case 'S': + case 'P': return 1; case '0': case '1': @@ -2013,6 +2014,12 @@ int AppFrame::OnGlobalKeyUp(wxKeyEvent &event) { wxGetApp().setSoloMode(!wxGetApp().getSoloMode()); return 1; break; + case 'P': + wxGetApp().getSpectrumProcessor()->setPeakHold(!wxGetApp().getSpectrumProcessor()->getPeakHold()); + wxGetApp().getDemodSpectrumProcessor()->setPeakHold(wxGetApp().getSpectrumProcessor()->getPeakHold()); + peakHoldButton->setSelection(wxGetApp().getSpectrumProcessor()->getPeakHold()?1:0); + peakHoldButton->clearModeChanged(); + break; case ']': case '[': return 1;