mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-22 14:38:14 +02:00
check error message in between implemented in gui
git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorGui@161 af1100a4-978c-4157-bff7-07162d2ba061
This commit is contained in:
parent
4ac8439202
commit
db1aaf041a
@ -232,21 +232,11 @@ void qDrawPlot::SetupWidgetWindow(){
|
|||||||
boxPlot->setFlat(true);
|
boxPlot->setFlat(true);
|
||||||
boxPlot->setContentsMargins(0,15,0,0);
|
boxPlot->setContentsMargins(0,15,0,0);
|
||||||
|
|
||||||
//plot1D_hists = NULL;
|
|
||||||
|
|
||||||
plotLayout = new QGridLayout(boxPlot);
|
plotLayout = new QGridLayout(boxPlot);
|
||||||
plotLayout->addWidget(plot1D,1,1,1,1);
|
plotLayout->addWidget(plot1D,1,1,1,1);
|
||||||
plotLayout->addWidget(plot2D,1,1,1,1);
|
plotLayout->addWidget(plot2D,1,1,1,1);
|
||||||
|
|
||||||
/*
|
|
||||||
//clear eveything again
|
|
||||||
nHists=0;
|
|
||||||
histXAxis=0;
|
|
||||||
histYAxis[0]=0;
|
|
||||||
Clear1DPlot();
|
|
||||||
for(QVector<SlsQtH1D*>::iterator h = plot1D_hists.begin();h!=plot1D_hists.end();h++) delete *h;
|
|
||||||
plot1D_hists.clear();
|
|
||||||
*/
|
|
||||||
//callbacks
|
//callbacks
|
||||||
|
|
||||||
// Setting the callback function to get data from detector class
|
// Setting the callback function to get data from detector class
|
||||||
@ -257,6 +247,8 @@ void qDrawPlot::SetupWidgetWindow(){
|
|||||||
myDet->registerMeasurementFinishedCallback(&(GetMeasurementFinishedCallBack),this);
|
myDet->registerMeasurementFinishedCallback(&(GetMeasurementFinishedCallBack),this);
|
||||||
//Setting the callback function to get progress from detector class(using receivers)
|
//Setting the callback function to get progress from detector class(using receivers)
|
||||||
myDet->registerProgressCallback(&(GetProgressCallBack),this);
|
myDet->registerProgressCallback(&(GetProgressCallBack),this);
|
||||||
|
|
||||||
|
qDefs::checkErrorMessage(myDet);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -349,10 +341,13 @@ void qDrawPlot::StartStopDaqToggle(bool stop_if_running){
|
|||||||
|
|
||||||
StartDaq(true);
|
StartDaq(true);
|
||||||
running=!running;
|
running=!running;
|
||||||
|
|
||||||
|
qDefs::checkErrorMessage(myDet);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** if this is set during client initation */
|
/** if this is set during client initation */
|
||||||
clientInitiated = false;
|
clientInitiated = false;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -491,10 +486,10 @@ void qDrawPlot::SetScanArgument(int scanArg){
|
|||||||
lastImageArray[py*nPixelsX+px] = 0;
|
lastImageArray[py*nPixelsX+px] = 0;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
UnlockLastImageArray();
|
UnlockLastImageArray();
|
||||||
|
|
||||||
|
qDefs::checkErrorMessage(myDet);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -1136,7 +1131,10 @@ void qDrawPlot::ClonePlot(){
|
|||||||
|
|
||||||
string sFilePath;
|
string sFilePath;
|
||||||
if(running) sFilePath = filePath.toAscii().constData();
|
if(running) sFilePath = filePath.toAscii().constData();
|
||||||
else sFilePath = myDet->getFilePath();
|
else {
|
||||||
|
sFilePath = myDet->getFilePath();
|
||||||
|
qDefs::checkErrorMessage(myDet);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -1254,7 +1252,10 @@ void qDrawPlot::SavePlot(){
|
|||||||
|
|
||||||
QString fName;
|
QString fName;
|
||||||
if(running) fName = filePath;
|
if(running) fName = filePath;
|
||||||
else fName = QString(myDet->getFilePath().c_str());
|
else {
|
||||||
|
fName = QString(myDet->getFilePath().c_str());
|
||||||
|
qDefs::checkErrorMessage(myDet);
|
||||||
|
}
|
||||||
|
|
||||||
if(boxPlot->title().contains('.')){
|
if(boxPlot->title().contains('.')){
|
||||||
fName.append(QString('/')+boxPlot->title());
|
fName.append(QString('/')+boxPlot->title());
|
||||||
@ -1282,7 +1283,10 @@ void qDrawPlot::SavePlotAutomatic(){
|
|||||||
|
|
||||||
QString qFilePath;
|
QString qFilePath;
|
||||||
if(running) qFilePath = filePath;
|
if(running) qFilePath = filePath;
|
||||||
else qFilePath = QString(myDet->getFilePath().c_str());
|
else {
|
||||||
|
qFilePath = QString(myDet->getFilePath().c_str());
|
||||||
|
qDefs::checkErrorMessage(myDet);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
lastSavedFrame = currentFrame;
|
lastSavedFrame = currentFrame;
|
||||||
@ -1385,6 +1389,9 @@ int qDrawPlot::UpdateTrimbitPlot(bool fromDetector,bool Histogram){
|
|||||||
#ifdef VERBOSE
|
#ifdef VERBOSE
|
||||||
cout << "Got Trimbits" << endl;
|
cout << "Got Trimbits" << endl;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
qDefs::checkErrorMessage(myDet);
|
||||||
|
|
||||||
//defining axes
|
//defining axes
|
||||||
if(Histogram) nPixelsX = TRIM_HISTOGRAM_XMAX+1;
|
if(Histogram) nPixelsX = TRIM_HISTOGRAM_XMAX+1;
|
||||||
else nPixelsX = actualPixelsX;
|
else nPixelsX = actualPixelsX;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user