mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2026-06-10 01:49:21 -04:00
Add a shift+click waterfall option to set Tx DF
Thanks to Mike W9MDB for contributing this patch. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6512 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
+13
-4
@@ -520,11 +520,20 @@ void CPlotter::mousePressEvent(QMouseEvent *event) //mousePressEvent
|
||||
if(x<0) x=0;
|
||||
if(x>m_Size.width()) x=m_Size.width();
|
||||
bool ctrl = (event->modifiers() & Qt::ControlModifier);
|
||||
int freq = int(FreqfromX(x)+0.5);
|
||||
int tx_freq = m_txFreq;
|
||||
if (ctrl or m_lockTxFreq) tx_freq = freq;
|
||||
bool shift = (event->modifiers() & Qt::ShiftModifier);
|
||||
int newFreq = int(FreqfromX(x)+0.5);
|
||||
int oldTxFreq = m_txFreq;
|
||||
int oldRxFreq = m_rxFreq;
|
||||
|
||||
emit setFreq1 (freq, tx_freq);
|
||||
if (ctrl or m_lockTxFreq) {
|
||||
emit setFreq1 (newFreq, newFreq);
|
||||
}
|
||||
else if (shift) {
|
||||
emit setFreq1 (oldRxFreq, newFreq);
|
||||
}
|
||||
else {
|
||||
emit setFreq1(newFreq,oldTxFreq);
|
||||
}
|
||||
|
||||
int n=1;
|
||||
if(ctrl) n+=100;
|
||||
|
||||
Reference in New Issue
Block a user