mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-04-24 07:20:01 +02:00
bug fix: after cloning, signals still ocnnected
git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorGui@195 af1100a4-978c-4157-bff7-07162d2ba061
This commit is contained in:
parent
378f7715b9
commit
d49a5cd7b4
@ -190,7 +190,6 @@ protected:
|
||||
* */
|
||||
void resizeEvent(QResizeEvent* event);
|
||||
|
||||
signals:
|
||||
|
||||
};
|
||||
|
||||
|
@ -126,6 +126,10 @@ public:
|
||||
*/
|
||||
bool GetClientInitiated(){return clientInitiated;};
|
||||
|
||||
/** Update all ranges, interpolate etc after cloning
|
||||
* parameters are if they are checked or not
|
||||
*/
|
||||
void UpdateAfterCloning(bool points, bool logy, bool interpolate, bool contour, bool logz);
|
||||
|
||||
public slots:
|
||||
/** To select 1D or 2D plot
|
||||
@ -511,6 +515,7 @@ void ResetZMinZMaxSignal(bool,bool,double,double);
|
||||
void SetCurrentMeasurementSignal(int);
|
||||
void saveErrorSignal(QString);
|
||||
void AcquisitionErrorSignal(QString);
|
||||
void UpdateAfterCloningSignal();
|
||||
};
|
||||
|
||||
|
||||
|
@ -112,7 +112,9 @@ public slots:
|
||||
*/
|
||||
void EnableScanBox();
|
||||
|
||||
|
||||
/** Update all ranges, interpolate etc after cloning
|
||||
*/
|
||||
void UpdateAfterCloning();
|
||||
|
||||
private slots:
|
||||
/** Selects the plot to display, enables/disables widgets
|
||||
|
@ -1,11 +0,0 @@
|
||||
//#define SVNPATH ""
|
||||
#define SVNURL "file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorGui"
|
||||
//#define SVNREPPATH ""
|
||||
#define SVNREPUUID "af1100a4-978c-4157-bff7-07162d2ba061"
|
||||
//#define SVNREV 0x193
|
||||
//#define SVNKIND ""
|
||||
//#define SVNSCHED ""
|
||||
#define SVNAUTH "l_maliakal_d"
|
||||
#define SVNREV 0x193
|
||||
#define SVNDATE 0x20130528
|
||||
//
|
@ -279,6 +279,9 @@ void qDetectorMain::Initialization(){
|
||||
//This should not be called as it will change file name to measurement when run finished
|
||||
//connect(myPlot, SIGNAL(UpdatingPlotFinished()), tab_plot, SLOT(Refresh()));
|
||||
connect(myPlot, SIGNAL(SetCurrentMeasurementSignal(int)), tab_measurement, SLOT(SetCurrentMeasurement(int)));
|
||||
//to update all ranges when a clone has been made
|
||||
connect(myPlot, SIGNAL(UpdateAfterCloningSignal()), tab_plot,SLOT(UpdateAfterCloning()));
|
||||
|
||||
// menubar
|
||||
// Modes Menu
|
||||
connect(menuModes, SIGNAL(triggered(QAction*)), this,SLOT(EnableModes(QAction*)));
|
||||
|
@ -1215,6 +1215,14 @@ void qDrawPlot::ClonePlot(){
|
||||
|
||||
LockLastImageArray();
|
||||
|
||||
//disconnect
|
||||
disconnect(this, SIGNAL(InterpolateSignal(bool)), plot2D, SIGNAL(InterpolateSignal(bool)));
|
||||
disconnect(this, SIGNAL(ContourSignal(bool)), plot2D, SIGNAL(ContourSignal(bool)));
|
||||
disconnect(this, SIGNAL(LogzSignal(bool)), plot2D, SLOT(SetZScaleToLog(bool)));
|
||||
disconnect(this, SIGNAL(LogySignal(bool)), plot1D, SLOT(SetLogY(bool)));
|
||||
disconnect(this, SIGNAL(ResetZMinZMaxSignal(bool,bool,double,double)),plot2D, SLOT(ResetZMinZMax(bool,bool,double,double)));
|
||||
disconnect(this, SIGNAL(SetZRangeSignal(double,double)), plot2D, SLOT(SetZRange(double,double)));
|
||||
|
||||
// create clone
|
||||
winClone[i] = new qCloneWidget(this,i,boxPlot->title(),(int)plot_in_scope,plot1D,plot2D,sFilePath);
|
||||
if(plot_in_scope==1){
|
||||
@ -1267,6 +1275,12 @@ void qDrawPlot::ClonePlot(){
|
||||
connect(this, SIGNAL(ContourSignal(bool)), plot2D, SIGNAL(ContourSignal(bool)));
|
||||
connect(this, SIGNAL(LogzSignal(bool)), plot2D, SLOT(SetZScaleToLog(bool)));
|
||||
connect(this, SIGNAL(LogySignal(bool)), plot1D, SLOT(SetLogY(bool)));
|
||||
connect(this, SIGNAL(ResetZMinZMaxSignal(bool,bool,double,double)),plot2D, SLOT(ResetZMinZMax(bool,bool,double,double)));
|
||||
connect(this, SIGNAL(SetZRangeSignal(double,double)), plot2D, SLOT(SetZRange(double,double)));
|
||||
|
||||
//update ranges on current plot
|
||||
emit UpdateAfterCloningSignal();
|
||||
|
||||
winClone[i]->show();
|
||||
|
||||
// to remember which all clone widgets were closed
|
||||
@ -1632,3 +1646,29 @@ void qDrawPlot::SetFrameFactor(int frame){
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
void qDrawPlot::UpdateAfterCloning(bool points, bool logy, bool interpolate, bool contour, bool logz){
|
||||
#ifdef VERBOSE
|
||||
cout << endl << "**Updating Plot After Cloning" << endl;
|
||||
#endif
|
||||
|
||||
//1d
|
||||
if(plot_in_scope == 1){
|
||||
SetMarkers(points);
|
||||
emit LogySignal(logy);
|
||||
}
|
||||
//2d
|
||||
else{
|
||||
emit InterpolateSignal(interpolate);
|
||||
emit ContourSignal(contour);
|
||||
emit LogzSignal(logz);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
@ -877,4 +877,30 @@ void qTabPlot::Refresh(){
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
|
||||
void qTabPlot::UpdateAfterCloning(){
|
||||
#ifdef VERBOSE
|
||||
cout << endl << "**Updating Plot After Cloning" << endl;
|
||||
#endif
|
||||
EnableRange();
|
||||
EnableTitles();
|
||||
myPlot->UpdateAfterCloning(
|
||||
chkPoints->isChecked(),
|
||||
chk1DLog->isChecked(),
|
||||
chkInterpolate->isChecked(),
|
||||
chkContour->isChecked(),
|
||||
chkLogz->isChecked());
|
||||
|
||||
//1d
|
||||
if(isOneD)
|
||||
EnablePersistency(chkSuperimpose->isChecked());
|
||||
//2d
|
||||
else
|
||||
EnableZRange();
|
||||
|
||||
}
|
||||
|
||||
|
||||
//-------------------------------------------------------------------------------------------------------------------------------------------------
|
||||
|
Loading…
x
Reference in New Issue
Block a user