From ad9901615e76982d824a403fc19c2b90233e1255 Mon Sep 17 00:00:00 2001
From: Tobias Triffterer <tobias@ep1.ruhr-uni-bochum.de>
Date: Mon, 31 May 2021 17:37:43 +0200
Subject: [PATCH] Display Message to explain Gold Foil not used

When the user selects the gold foil measurement mode, a message appears
to explain that this part is currently not used.
---
 src/clientgui.cpp | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/clientgui.cpp b/src/clientgui.cpp
index 7a85234..5588f7c 100644
--- a/src/clientgui.cpp
+++ b/src/clientgui.cpp
@@ -59,13 +59,15 @@ ClientGui::ClientGui(const QString& name, const QString& token, std::unique_ptr<
     connect(_ui.cmdCloseVacuumValve, &QPushButton::clicked, std::bind(&ClientGui::sendSimpleActiontoServer, this, Protocol::Action::closeVacuumValve));
     connect(_ui.cmdTargetClose, &QPushButton::clicked, std::bind(&ClientGui::setBeamholeState, this, ExperimentState::BeamHoleState::Closed));
     connect(_ui.cmdTargetOpen, &QPushButton::clicked, std::bind(&ClientGui::setBeamholeState, this, ExperimentState::BeamHoleState::Open));
-    connect(_ui.cmdTargetGold, &QPushButton::clicked, std::bind(&ClientGui::setBeamholeState, this, ExperimentState::BeamHoleState::GoldFoil));
+    //connect(_ui.cmdTargetGold, &QPushButton::clicked, std::bind(&ClientGui::setBeamholeState, this, ExperimentState::BeamHoleState::GoldFoil));
     connect(_ui.cmdStartAdc, &QPushButton::clicked, std::bind(&ClientGui::sendSimpleActiontoServer, this, Protocol::Action::startAdc));
     connect(_ui.cmdStopAdc, &QPushButton::clicked, std::bind(&ClientGui::sendSimpleActiontoServer, this, Protocol::Action::stopAdc));
     connect(_ui.cmdClearHisto, &QPushButton::clicked, this, &ClientGui::clearHistogram);
     connect(_ui.cmdAdcThresholdUp, &QPushButton::clicked, std::bind(&ClientGui::sendSimpleActiontoServer, this, Protocol::Action::adcThresholdUp));
     connect(_ui.cmdAdcThresholdDown, &QPushButton::clicked, std::bind(&ClientGui::sendSimpleActiontoServer, this, Protocol::Action::adcThresholdDown));
 
+    connect(_ui.cmdTargetGold, &QPushButton::clicked, [this] () -> void {QMessageBox::information(this, tr("Experiment Part not available"), tr("This part of the experiment is currently left out, because it has also been left out in the real experiment in the recent years.\nThis measurement only confirms the calibraton of the setup and takes a long time due to the low activity of the real-world ²⁴¹Am source."), QMessageBox::Ok);});
+
     gStyle->SetCanvasPreferGL(true);
 
     connect(&_rootTimer, &QTimer::timeout, []() -> void {gSystem->ProcessEvents();});
-- 
GitLab