Added "F" and "M" shortcuts to speak frequency and mode.

merge-requests/1/merge
Elliott Liggett 2019-02-07 10:15:10 -08:00
rodzic 7370064500
commit 8d131208e2
2 zmienionych plików z 24 dodań i 0 usunięć

Wyświetl plik

@ -117,7 +117,13 @@ wfmain::wfmain(QWidget *parent) :
keyControlPlus->setKey(Qt::CTRL + Qt::Key_Plus);
connect(keyControlPlus, SIGNAL(activated()), this, SLOT(shortcutControlPlus()));
keyF = new QShortcut(this);
keyF->setKey(Qt::Key_F);
connect(keyF, SIGNAL(activated()), this, SLOT(shortcutF()));
keyM = new QShortcut(this);
keyM->setKey(Qt::Key_M);
connect(keyM, SIGNAL(activated()), this, SLOT(shortcutM()));
setDefaultColors(); // set of UI colors with defaults populated
@ -652,6 +658,18 @@ void wfmain::shortcutControlPlus()
ui->freqDial->setValue( ui->freqDial->value() + ui->freqDial->pageStep() );
}
void wfmain::shortcutF()
{
showStatusBarText("Sending speech command (frequency) to radio.");
emit sayFrequency();
}
void wfmain::shortcutM()
{
showStatusBarText("Sending speech command (mode) to radio.");
emit sayMode();
}
void wfmain::getInitialRigState()
{

Wyświetl plik

@ -92,6 +92,9 @@ private slots:
void shortcutControlMinus();
void shortcutControlPlus();
void shortcutF();
void shortcutM();
void handlePttLimit(); // hit at 3 min transmit length
void on_startBtn_clicked();
@ -264,6 +267,9 @@ private:
QShortcut *keyControlMinus;
QShortcut *keyControlPlus;
QShortcut *keyF;
QShortcut *keyM;
rigCommander * rig;
QThread * rigThread;