From df6acfab2c181abb6695d2962ff9d40433eb911c Mon Sep 17 00:00:00 2001 From: eap Date: Thu, 7 Dec 2006 08:34:23 +0000 Subject: [PATCH] PAL13473 (Build repetitive mesh): use hypotheses of Regular_1D only --- .../StdMeshersGUI_LayerDistributionParamWdg.cxx | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/StdMeshersGUI/StdMeshersGUI_LayerDistributionParamWdg.cxx b/src/StdMeshersGUI/StdMeshersGUI_LayerDistributionParamWdg.cxx index f8c90e728..836eb5523 100644 --- a/src/StdMeshersGUI/StdMeshersGUI_LayerDistributionParamWdg.cxx +++ b/src/StdMeshersGUI/StdMeshersGUI_LayerDistributionParamWdg.cxx @@ -116,10 +116,17 @@ void StdMeshersGUI_LayerDistributionParamWdg::init() myHypTypePopup = new QPopupMenu(); - QStringList aHypTypeNameList = SMESH::GetAvailableHypotheses( false, 0 ); + // Add to pop-up hypotheses of "Regular_1D" algo myHypTypePopup->clear(); - for ( int i = 0, n = aHypTypeNameList.count(); i < n; i++ ) { - myHypTypePopup->insertItem( aHypTypeNameList[ i ] ); + HypothesisData* algoData = SMESH::GetHypothesisData( "Regular_1D" ); + QStringList aHypTypeNameList = SMESH::GetAvailableHypotheses( false, 0 ); + QStringList::const_iterator anIter = aHypTypeNameList.begin(); + for ( int i = 0; anIter != aHypTypeNameList.end(); ++anIter, ++i ) + { + HypothesisData* hypData = SMESH::GetHypothesisData( *anIter ); + bool bidon; + if ( SMESH::IsAvailableHypothesis( algoData, hypData->TypeName, bidon )) + myHypTypePopup->insertItem( hypData->Label ); } connect( myCreateButton, SIGNAL(clicked()), SLOT(onCreate())); -- 2.39.2