Fix statusbar mode update connection
This commit is contained in:
parent
3765e4009f
commit
506502ce02
@ -253,13 +253,6 @@ AppWindow::AppWindow(QWidget *parent)
|
||||
Mode::getActiveMode()->saveSreenshot();
|
||||
});
|
||||
|
||||
auto setModeStatusbar = [=](QString msg) {
|
||||
lModeInfo.setText(msg);
|
||||
};
|
||||
connect(vna, &Mode::statusbarMessage, setModeStatusbar);
|
||||
connect(generator, &Mode::statusbarMessage, setModeStatusbar);
|
||||
connect(spectrumAnalyzer, &Mode::statusbarMessage, setModeStatusbar);
|
||||
|
||||
connect(ui->actionManual_Control, &QAction::triggered, this, &AppWindow::StartManualControl);
|
||||
connect(ui->actionFirmware_Update, &QAction::triggered, this, &AppWindow::StartFirmwareUpdateDialog);
|
||||
connect(ui->actionSource_Calibration, &QAction::triggered, this, &AppWindow::SourceCalibrationDialog);
|
||||
@ -893,6 +886,11 @@ SCPI* AppWindow::getSCPI()
|
||||
return &scpi;
|
||||
}
|
||||
|
||||
void AppWindow::setModeStatus(QString msg)
|
||||
{
|
||||
lModeInfo.setText(msg);
|
||||
}
|
||||
|
||||
int AppWindow::UpdateDeviceList()
|
||||
{
|
||||
deviceActionGroup->setExclusive(true);
|
||||
|
@ -50,6 +50,9 @@ public:
|
||||
|
||||
SCPI* getSCPI();
|
||||
|
||||
public slots:
|
||||
void setModeStatus(QString msg);
|
||||
|
||||
protected:
|
||||
void closeEvent(QCloseEvent *event) override;
|
||||
private slots:
|
||||
|
@ -88,6 +88,7 @@ Mode::Mode(AppWindow *window, QString name, QString SCPIname)
|
||||
delete modes[index];
|
||||
});
|
||||
}
|
||||
connect(this, &Mode::statusbarMessage, window, &AppWindow::setModeStatus);
|
||||
modes.push_back(this);
|
||||
tabbar->blockSignals(true);
|
||||
tabbar->insertTab(tabbar->count(), name);
|
||||
|
Loading…
Reference in New Issue
Block a user