From: ouv Date: Thu, 19 Jun 2014 10:21:25 +0000 (+0400) Subject: 0002187: select several surfaces in “Setup surfaces” dialog X-Git-Tag: CTH_1_10_a~6 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=9464c1c87601439a227c30bc76b3126523aca7ff;p=modules%2Fgui.git 0002187: select several surfaces in “Setup surfaces” dialog --- diff --git a/src/Plot2d/Plot2d_SetupCurvesDlg.cxx b/src/Plot2d/Plot2d_SetupCurvesDlg.cxx index 711137416..e48d39d07 100755 --- a/src/Plot2d/Plot2d_SetupCurvesDlg.cxx +++ b/src/Plot2d/Plot2d_SetupCurvesDlg.cxx @@ -159,7 +159,7 @@ Plot2d_SetupCurvesDlg::Plot2d_SetupCurvesDlg( QWidget* theParent ) aLabels.append( tr( "NB_MARKERS" ) ); myTable->setHorizontalHeaderLabels( aLabels ); myTable->verticalHeader()->hide(); - myTable->setSelectionMode( QTableWidget::NoSelection ); + myTable->setSelectionMode( QTableWidget::ExtendedSelection ); QComboBox* aCombo = new QComboBox( 0 ); myTable->verticalHeader()->setDefaultSectionSize( aCombo->sizeHint().height() ); @@ -437,7 +437,7 @@ void Plot2d_SetupCurvesDlg::onRemove( ) for ( selIter = aRegs.begin(); selIter != aRegs.end(); ++selIter ) { const QTableWidgetSelectionRange& aReg = *selIter; - for ( int i = aReg.topRow(), n = aReg.bottomRow(); i < n; i++ ) + for ( int i = aReg.topRow(), n = aReg.bottomRow(); i <= n; i++ ) aSelRows.insert( i ); } diff --git a/src/Plot3d/Plot3d_SetupSurfacesDlg.cxx b/src/Plot3d/Plot3d_SetupSurfacesDlg.cxx index 36c2ffb14..b4d820405 100644 --- a/src/Plot3d/Plot3d_SetupSurfacesDlg.cxx +++ b/src/Plot3d/Plot3d_SetupSurfacesDlg.cxx @@ -70,7 +70,7 @@ Plot3d_SetupSurfacesDlg::Plot3d_SetupSurfacesDlg( QWidget* theParent ) aLabels.append( tr( "COLOR_SCALE" ) ); myTable->setHorizontalHeaderLabels( aLabels ); myTable->verticalHeader()->hide(); - myTable->setSelectionMode( QTableWidget::NoSelection ); + myTable->setSelectionMode( QTableWidget::ExtendedSelection ); QComboBox* aCombo = new QComboBox( 0 ); myTable->verticalHeader()->setDefaultSectionSize( aCombo->sizeHint().height() ); @@ -212,7 +212,7 @@ void Plot3d_SetupSurfacesDlg::onRemove() for ( selIter = aRegs.begin(); selIter != aRegs.end(); ++selIter ) { const QTableWidgetSelectionRange& aReg = *selIter; - for ( int i = aReg.topRow(), n = aReg.bottomRow(); i < n; i++ ) + for ( int i = aReg.topRow(), n = aReg.bottomRow(); i <= n; i++ ) aSelRows.insert( i ); }