X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGUI%2FGHS3DPluginGUI_AdvWidget.cxx;fp=src%2FGUI%2FGHS3DPluginGUI_AdvWidget.cxx;h=e70781f946be6f53064488a8fbe5b7c0f628ab1a;hb=379a8afb5ce6cf8d8b4cfbf2ea585bdccd51c596;hp=b2dc3a15c0c63f604fe3737a242266379f398a92;hpb=d96b871b2634572db28aae9eda5a89912312a1ac;p=plugins%2Fghs3dplugin.git diff --git a/src/GUI/GHS3DPluginGUI_AdvWidget.cxx b/src/GUI/GHS3DPluginGUI_AdvWidget.cxx index b2dc3a1..e70781f 100644 --- a/src/GUI/GHS3DPluginGUI_AdvWidget.cxx +++ b/src/GUI/GHS3DPluginGUI_AdvWidget.cxx @@ -135,3 +135,23 @@ void GHS3DPluginGUI_AdvWidget::itemChanged(QTreeWidgetItem * tblRow, int column) myOptionTable->blockSignals( false ); } } + +void GHS3DPluginGUI_AdvWidget::EnableAdvancedOptions( bool isMGTetra ) +{ + int iRow = 0, nbRows = myOptionTable->topLevelItemCount(); + // hard coded: register all possible options here + std::vector_commonOptions = { "split_overconstrained_tetrahedra" }; + std::vector::iterator tk; + for ( ; iRow < nbRows; ++iRow ) + { + // Have to allow advanced option for MGTetra HPC to work + tk = std::find( _commonOptions.begin(), + _commonOptions.end(), + myOptionTable->topLevelItem( iRow )->data( NAME_COL, PARAM_NAME ).toString().toStdString() + ); + + if ( tk == _commonOptions.end() ) + myOptionTable->topLevelItem( iRow )->setDisabled( !isMGTetra ); + + } +} \ No newline at end of file