made some change in static member used as index to avoid compile time error with new gcc

git-svn-id: file:///afs/psi.ch/project/sls_det_software/svn/slsDetectorGui@121 af1100a4-978c-4157-bff7-07162d2ba061
This commit is contained in:
l_maliakal_d
2012-12-05 08:48:57 +00:00
parent 1e705df5dc
commit 27ef53da4a
2 changed files with 13 additions and 7 deletions

View File

@ -2,12 +2,16 @@
/** /**
* @author Ian Johnson * @author Ian Johnson
* @version 1.0 * @version 1.0
* Dhanya-05.12.2012- included an additional header
*/ */
#ifndef SLSQT2DZOOMER_H #ifndef SLSQT2DZOOMER_H
#define SLSQT2DZOOMER_H #define SLSQT2DZOOMER_H
/**included by Dhanya on 05.12.2012 to avoid compile time errors with the latest gcc*/
#include <cstdio>
/**end of Change by Dhanya*/
#include <qwt_plot_zoomer.h> #include <qwt_plot_zoomer.h>
#include <qwt_plot_panner.h> #include <qwt_plot_panner.h>

View File

@ -84,7 +84,7 @@ void qTabActions::SetupWidgetWindow(){
int hIndent=0, vIndent=0, colspan=6; int hIndent=0, vIndent=0, colspan=6, posVal=0;
QLabel *lblReal; QLabel *lblReal;
// For each level of Actions // For each level of Actions
for(int i=0;i<NumTotalActions;i++){ for(int i=0;i<NumTotalActions;i++){
@ -118,14 +118,16 @@ void qTabActions::SetupWidgetWindow(){
break; break;
case Scan0: case Scan0:
case Scan1: case Scan1:
scanWidget[qScanWidget::NUM_SCAN_WIDGETS] = new qScanWidget(this,myDet); posVal = qScanWidget::NUM_SCAN_WIDGETS;
gridLayout->addWidget(scanWidget[qScanWidget::NUM_SCAN_WIDGETS-1],vIndent+1,hIndent+1,1,colspan); scanWidget[posVal] = new qScanWidget(this,myDet);
scanWidget[qScanWidget::NUM_SCAN_WIDGETS-1]->hide(); gridLayout->addWidget(scanWidget[posVal],vIndent+1,hIndent+1,1,colspan);
scanWidget[posVal]->hide();
break; break;
default: default:
actionWidget[qActionsWidget::NUM_ACTION_WIDGETS] = new qActionsWidget(this,myDet); posVal = qActionsWidget::NUM_ACTION_WIDGETS;
gridLayout->addWidget(actionWidget[qActionsWidget::NUM_ACTION_WIDGETS-1],vIndent+1,hIndent+1,1,colspan); actionWidget[posVal] = new qActionsWidget(this,myDet);
actionWidget[qActionsWidget::NUM_ACTION_WIDGETS-1]->hide(); gridLayout->addWidget(actionWidget[posVal],vIndent+1,hIndent+1,1,colspan);
actionWidget[posVal]->hide();
break; break;
} }