Hide "Allow Quadrangles" in 3D case

This commit is contained in:
eap 2011-07-05 08:44:56 +00:00
parent 8730f3b877
commit 5acc32009d

View File

@ -185,12 +185,16 @@ QFrame* NETGENPluginGUI_SimpleCreator::buildFrame()
dimRow++;
// * allow quadrangles
const bool is3D = ( hypType()=="NETGEN_SimpleParameters_3D" );
if ( !is3D )
{
myAllowQuadCheckBox = new QCheckBox( tr( "NETGEN_ALLOW_QUADRANGLES" ), dimGroup );
dimLay->addWidget( myAllowQuadCheckBox, dimRow, 0, 1, 2 );
dimRow++;
}
// 3D params group
if ( hypType()=="NETGEN_SimpleParameters_3D" )
if ( is3D )
{
dimGroup = new QGroupBox( tr( "NG_3D" ), argGroup );
argLay->addWidget( dimGroup, argRow, 0, 1, 2 );
@ -289,6 +293,7 @@ void NETGENPluginGUI_SimpleCreator::retrieveParams() const
myLenFromEdgesCheckBox->setChecked( true );
myArea->setEnabled( false );
}
if ( myAllowQuadCheckBox )
myAllowQuadCheckBox->setChecked( h->GetAllowQuadrangles() );
// 3D
@ -349,6 +354,7 @@ QString NETGENPluginGUI_SimpleCreator::storeParams() const
valStr += "; lenFromEdges";
aVariablesList.append(QString());
}
if ( myAllowQuadCheckBox )
h->SetAllowQuadrangles( myAllowQuadCheckBox->isChecked() );
h->SetParameters(aVariablesList.join(":").toLatin1().constData());