Split-Pole analyzer, disable reaction when run analyzer

This commit is contained in:
Ryan Tang 2024-06-20 13:50:44 -04:00
parent 9ea67c4554
commit 6fcebf0c06

View File

@ -229,6 +229,17 @@ inline void SplitPole::SetUpCanvas(){
chkRunAnalyzer = new QCheckBox("Run Analyzer", this);
boxLayout->addWidget(chkRunAnalyzer, 4, 3);
connect(chkRunAnalyzer, &QCheckBox::stateChanged, this, [=](int state){
sbBfield->setEnabled(state != Qt::Checked);
leTarget->setEnabled(state != Qt::Checked);
leBeam->setEnabled(state != Qt::Checked);
leRecoil->setEnabled(state != Qt::Checked);
sbEnergy->setEnabled(state != Qt::Checked);
sbAngle->setEnabled(state != Qt::Checked);
sbEventWin->setEnabled(state != Qt::Checked);
});
QFrame *separator = new QFrame(box);
separator->setFrameShape(QFrame::HLine);