Back to index

salome-geom  6.5.0
TransformationGUI_PositionDlg.cxx
Go to the documentation of this file.
00001 // Copyright (C) 2007-2012  CEA/DEN, EDF R&D, OPEN CASCADE
00002 //
00003 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
00004 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
00005 //
00006 // This library is free software; you can redistribute it and/or
00007 // modify it under the terms of the GNU Lesser General Public
00008 // License as published by the Free Software Foundation; either
00009 // version 2.1 of the License.
00010 //
00011 // This library is distributed in the hope that it will be useful,
00012 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014 // Lesser General Public License for more details.
00015 //
00016 // You should have received a copy of the GNU Lesser General Public
00017 // License along with this library; if not, write to the Free Software
00018 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
00019 //
00020 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
00021 //
00022 
00023 // GEOM GEOMGUI : GUI for Geometry component
00024 // File   : TransformationGUI_PositionDlg.cxx
00025 // Author : Damien COQUERET, Open CASCADE S.A.S.
00026 //
00027 #include "TransformationGUI_PositionDlg.h"
00028 
00029 #include <DlgRef.h>
00030 #include <GeometryGUI.h>
00031 #include <GEOMBase.h>
00032 
00033 #include <SUIT_Session.h>
00034 #include <SUIT_ResourceMgr.h>
00035 #include <SalomeApp_Application.h>
00036 #include <LightApp_SelectionMgr.h>
00037 #include <TColStd_IndexedMapOfInteger.hxx>
00038 
00039 // OCCT Includes
00040 #include <TColStd_MapOfInteger.hxx>
00041 
00042 #include <GEOMImpl_Types.hxx>
00043 
00044 //=================================================================================
00045 // class    : TransformationGUI_PositionDlg()
00046 // purpose  : Constructs a TransformationGUI_PositionDlg which is a child of 'parent', with the
00047 //            name 'name' and widget flags set to 'f'.
00048 //            The dialog will by default be modeless, unless you set 'modal' to
00049 //            TRUE to construct a modal dialog.
00050 //=================================================================================
00051 TransformationGUI_PositionDlg::TransformationGUI_PositionDlg
00052 (GeometryGUI* theGeometryGUI, QWidget* parent, bool modal, Qt::WindowFlags fl)
00053   : GEOMBase_Skeleton(theGeometryGUI, parent, modal, fl),
00054     myInitial(true)
00055 {
00056   SUIT_ResourceMgr* aResMgr = myGeomGUI->getApp()->resourceMgr();
00057   QPixmap image0 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_POSITION")));
00058   QPixmap image1 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_POSITION2")));
00059   QPixmap image2 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_POSITION3")));
00060   QPixmap imageselect (aResMgr->loadPixmap("GEOM", tr("ICON_SELECT")));
00061 
00062   setWindowTitle(tr("GEOM_POSITION_TITLE"));
00063 
00064   /***************************************************************/
00065   mainFrame()->GroupConstructors->setTitle(tr("GEOM_POSITION"));
00066   mainFrame()->RadioButton1->setIcon(image0);
00067   mainFrame()->RadioButton2->setIcon(image1);
00068   mainFrame()->RadioButton3->setIcon(image2);
00069 
00070   Group1 = new DlgRef_4Sel1Spin3Check(centralWidget());
00071   Group1->GroupBox1->setTitle(tr("GEOM_ARGUMENTS"));
00072   Group1->TextLabel1->setText(tr("GEOM_OBJECTS"));
00073   Group1->TextLabel2->setText(tr("GEOM_START_LCS"));
00074   Group1->TextLabel3->setText(tr("GEOM_DISTANCE"));
00075   Group1->TextLabel4->setText(tr("GEOM_END_LCS"));
00076   Group1->TextLabel5->setText(tr("GEOM_PATH_OBJECT"));
00077   Group1->PushButton1->setIcon(imageselect);
00078   Group1->PushButton2->setIcon(imageselect);
00079   Group1->PushButton4->setIcon(imageselect);
00080   Group1->PushButton5->setIcon(imageselect);
00081   Group1->CheckButton1->setText(tr("GEOM_CREATE_COPY"));
00082   Group1->CheckButton2->setText(tr("SELECT_UNPUBLISHED_EDGES"));
00083   Group1->CheckButton3->setText(tr("GEOM_REVERSE_DIRECTION"));
00084 
00085   QVBoxLayout* layout = new QVBoxLayout(centralWidget());
00086   layout->setMargin(0); layout->setSpacing(6);
00087   layout->addWidget(Group1);
00088   /***************************************************************/
00089 
00090   setHelpFileName("modify_location_operation_page.html");
00091 
00092   // Activate Create a Copy mode
00093   Group1->CheckButton1->setChecked(true);
00094   CreateCopyModeChanged();
00095 
00096   Init();
00097 }
00098 
00099 //=================================================================================
00100 // function : ~TransformationGUI_PositionDlg()
00101 // purpose  : Destroys the object and frees any allocated resources
00102 //=================================================================================
00103 TransformationGUI_PositionDlg::~TransformationGUI_PositionDlg()
00104 {
00105   // no need to delete child widgets, Qt does it all for us
00106 }
00107 
00108 //=================================================================================
00109 // function : Init()
00110 // purpose  :
00111 //=================================================================================
00112 void TransformationGUI_PositionDlg::Init()
00113 {
00114   // init variables
00115   Group1->LineEdit1->setReadOnly(true);
00116   Group1->LineEdit2->setReadOnly(true);
00117   Group1->LineEdit4->setReadOnly(true);
00118   Group1->LineEdit5->setReadOnly(true);
00119 
00120   Group1->LineEdit1->setText("");
00121   Group1->LineEdit2->setText("");
00122   Group1->LineEdit4->setText("");
00123   Group1->LineEdit5->setText("");
00124 
00125   initSpinBox(Group1->SpinBox_DX, 0, 1, 0.05, "parametric_precision" );
00126   Group1->SpinBox_DX->setValue(0);
00127 
00128   Group1->CheckButton2->setEnabled(false);
00129 
00130   myObjects.clear();
00131   myStartLCS.nullify();
00132   myEndLCS.nullify();
00133   myPath.nullify();
00134 
00135   mainFrame()->GroupBoxPublish->show();
00136 
00137   // signals and slots connections
00138   connect(buttonOk(),    SIGNAL(clicked()), this, SLOT(ClickOnOk()));
00139   connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));
00140 
00141   connect(this, SIGNAL(constructorsClicked(int)), this, SLOT(ConstructorsClicked(int)));
00142 
00143   connect(Group1->PushButton1, SIGNAL(clicked()),       this, SLOT(SetEditCurrentArgument()));
00144   connect(Group1->PushButton2, SIGNAL(clicked()),       this, SLOT(SetEditCurrentArgument()));
00145   connect(Group1->PushButton4, SIGNAL(clicked()),       this, SLOT(SetEditCurrentArgument()));
00146   connect(Group1->PushButton5, SIGNAL(clicked()),       this, SLOT(SetEditCurrentArgument()));
00147 
00148   connect(Group1->CheckButton1,   SIGNAL(toggled(bool)), this, SLOT(CreateCopyModeChanged()));
00149   connect(Group1->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
00150 
00151   connect(Group1->CheckButton2,   SIGNAL(toggled(bool)), this, SLOT(SelectionTypeButtonClicked()));
00152   connect(Group1->CheckButton3,   SIGNAL(toggled(bool)), this, SLOT(ValueChangedInSpinBox()));
00153 
00154   initName(tr("GEOM_POSITION"));
00155 
00156   ConstructorsClicked(0);
00157 }
00158 
00159 //=================================================================================
00160 // function : ConstructorsClicked()
00161 // purpose  : Radio button management
00162 //=================================================================================
00163 void TransformationGUI_PositionDlg::ConstructorsClicked (int constructorId)
00164 {
00165   disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
00166 
00167   Group1->LineEdit2->clear();
00168   Group1->LineEdit4->clear();
00169   Group1->LineEdit5->clear();
00170   myStartLCS.nullify();
00171   myEndLCS.nullify();
00172   myPath.nullify();
00173 
00174   switch (constructorId) {
00175   case 0:
00176     {
00177       Group1->LineEdit2->hide();
00178       Group1->TextLabel2->hide();
00179       Group1->PushButton2->hide();
00180 
00181       Group1->LineEdit5->hide();
00182       Group1->TextLabel5->hide();
00183       Group1->PushButton5->hide();
00184 
00185       Group1->SpinBox_DX->hide();
00186       Group1->TextLabel3->hide();
00187 
00188       Group1->LineEdit4->show();
00189       Group1->TextLabel4->show();
00190       Group1->PushButton4->show();
00191 
00192       Group1->PushButton1->click();
00193 
00194       Group1->CheckButton2->hide();
00195       Group1->CheckButton3->hide();
00196     }
00197     break;
00198   case 1:
00199     {
00200       Group1->LineEdit2->show();
00201       Group1->TextLabel2->show();
00202       Group1->PushButton2->show();
00203 
00204       Group1->LineEdit5->hide();
00205       Group1->TextLabel5->hide();
00206       Group1->PushButton5->hide();
00207 
00208       Group1->SpinBox_DX->hide();
00209       Group1->TextLabel3->hide();
00210 
00211       Group1->PushButton1->click();
00212 
00213       Group1->CheckButton2->hide();
00214       Group1->CheckButton3->hide();
00215     }
00216     break;
00217   case 2:
00218     {
00219       Group1->LineEdit4->hide();
00220       Group1->TextLabel4->hide();
00221       Group1->PushButton4->hide();
00222 
00223       Group1->LineEdit2->hide();
00224       Group1->TextLabel2->hide();
00225       Group1->PushButton2->hide();
00226 
00227       Group1->LineEdit5->show();
00228       Group1->TextLabel5->show();
00229       Group1->PushButton5->show();
00230 
00231       Group1->SpinBox_DX->show();
00232       Group1->TextLabel3->show();
00233 
00234       Group1->PushButton1->click();
00235 
00236       Group1->CheckButton2->show();
00237       Group1->CheckButton3->show();
00238     }
00239     break;
00240   }
00241 
00242   qApp->processEvents();
00243   updateGeometry();
00244   resize(minimumSizeHint());
00245 
00246   if (myInitial) {
00247     myInitial = false;
00248     SelectionIntoArgument();
00249   }
00250   else {
00251     processPreview();
00252   }
00253 }
00254 
00255 //=================================================================================
00256 // function : SelectionBittonClicked()
00257 // purpose  : Selection type Radio button management
00258 //=================================================================================
00259 void TransformationGUI_PositionDlg::SelectionTypeButtonClicked()
00260 {
00261   if ( Group1->CheckButton2->isChecked() ) {
00262     localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE );
00263   } else {
00264     TColStd_MapOfInteger aMap;
00265     aMap.Add(GEOM_WIRE);
00266     aMap.Add(GEOM_LINE);
00267     globalSelection(aMap);
00268   }
00269 }
00270 
00271 //=================================================================================
00272 // function : ValueChangedInSpinBox()
00273 // purpose  :
00274 //=================================================================================
00275 void TransformationGUI_PositionDlg::ValueChangedInSpinBox()
00276 {
00277   processPreview();
00278 }
00279 
00280 //=================================================================================
00281 // function : ClickOnOk()
00282 // purpose  :
00283 //=================================================================================
00284 void TransformationGUI_PositionDlg::ClickOnOk()
00285 {
00286   setIsApplyAndClose( true );
00287   if (ClickOnApply())
00288     ClickOnCancel();
00289 }
00290 
00291 //=================================================================================
00292 // function : ClickOnApply()
00293 // purpose  :
00294 //=================================================================================
00295 bool TransformationGUI_PositionDlg::ClickOnApply()
00296 {
00297   if (!onAccept(Group1->CheckButton1->isChecked()))
00298     return false;
00299 
00300   initName();
00301 
00302   // activate selection and connect selection manager
00303   ConstructorsClicked(getConstructorId());
00304   SelectionIntoArgument();
00305 
00306   return true;
00307 }
00308 
00309 //=================================================================================
00310 // function : SelectionIntoArgument()
00311 // purpose  : Called when selection is changed or on dialog initialization or activation
00312 //=================================================================================
00313 void TransformationGUI_PositionDlg::SelectionIntoArgument()
00314 {
00315   erasePreview();
00316   myEditCurrentArgument->setText("");
00317 
00318   if ( myEditCurrentArgument == Group1->LineEdit1 ) {
00319     myObjects = getSelected( TopAbs_SHAPE, -1 );
00320     if ( !myObjects.isEmpty() ) {
00321       QString aName = myObjects.count() > 1 ? QString( "%1_objects").arg( myObjects.count() ) : GEOMBase::GetName( myObjects[0].get() );
00322       myEditCurrentArgument->setText( aName );
00323     }
00324   }
00325   else if ( myEditCurrentArgument == Group1->LineEdit5 ) {
00326     QList<TopAbs_ShapeEnum> types;
00327     types << TopAbs_EDGE << TopAbs_WIRE;
00328     GEOM::GeomObjPtr aSelectedObject = getSelected( types );
00329     TopoDS_Shape aShape;
00330     if ( aSelectedObject && GEOMBase::GetShape( aSelectedObject.get(), aShape ) && !aShape.IsNull() ) {
00331       QString aName = GEOMBase::GetName( aSelectedObject.get() );
00332       myEditCurrentArgument->setText( aName );
00333       myPath = aSelectedObject;
00334       if ( myObjects.isEmpty() )
00335        Group1->PushButton1->click();
00336     }
00337     else {
00338       myPath.nullify();
00339     }
00340   }
00341   else {
00342     GEOM::GeomObjPtr aSelectedObject = getSelected( TopAbs_SHAPE );
00343     TopoDS_Shape aShape;
00344     if ( aSelectedObject && GEOMBase::GetShape( aSelectedObject.get(), aShape ) && !aShape.IsNull() ) {
00345       QString aName = GEOMBase::GetName( aSelectedObject.get() );
00346       myEditCurrentArgument->setText( aName );
00347       if ( myEditCurrentArgument == Group1->LineEdit2 ) {
00348        myStartLCS = aSelectedObject;
00349        if ( !myEndLCS )
00350          Group1->PushButton4->click();
00351        else if ( myObjects.isEmpty() )
00352          Group1->PushButton1->click();
00353       }
00354       else if ( myEditCurrentArgument == Group1->LineEdit4 ) {
00355        myEndLCS = aSelectedObject;
00356        if ( myObjects.isEmpty() )
00357          Group1->PushButton1->click();
00358        else if ( getConstructorId() == 1 && !myStartLCS )
00359          Group1->PushButton2->click();
00360       }
00361     }
00362     else {
00363       if ( myEditCurrentArgument == Group1->LineEdit2 )
00364        myStartLCS.nullify();
00365       else if ( myEditCurrentArgument == Group1->LineEdit4 )
00366        myEndLCS.nullify();
00367     }
00368   }
00369 
00370   processPreview();
00371 }
00372 
00373 //=================================================================================
00374 // function : SetEditCurrentArgument()
00375 // purpose  :
00376 //=================================================================================
00377 void TransformationGUI_PositionDlg::SetEditCurrentArgument()
00378 {
00379   QPushButton* send = (QPushButton*)sender();
00380 
00381   disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
00382   if (send == Group1->PushButton1) {
00383     myEditCurrentArgument = Group1->LineEdit1;
00384 
00385     globalSelection();
00386 
00387     Group1->PushButton2->setDown(false);
00388     Group1->PushButton4->setDown(false);
00389     Group1->PushButton5->setDown(false);
00390     Group1->LineEdit2->setEnabled(false);
00391     Group1->LineEdit4->setEnabled(false);
00392     Group1->LineEdit5->setEnabled(false);
00393 
00394     Group1->CheckButton2->setEnabled(false);
00395   }
00396   else if (send == Group1->PushButton2) {
00397     myEditCurrentArgument = Group1->LineEdit2;
00398 
00399     TColStd_MapOfInteger aMap;
00400     aMap.Add(GEOM_PLANE);
00401     aMap.Add(GEOM_MARKER);
00402     globalSelection(aMap);
00403 
00404     Group1->PushButton1->setDown(false);
00405     Group1->PushButton4->setDown(false);
00406     Group1->PushButton5->setDown(false);
00407     Group1->LineEdit1->setEnabled(false);
00408     Group1->LineEdit4->setEnabled(false);
00409     Group1->LineEdit5->setEnabled(false);
00410 
00411     Group1->CheckButton2->setEnabled(false);
00412   }
00413   else if (send == Group1->PushButton4) {
00414     myEditCurrentArgument = Group1->LineEdit4;
00415 
00416     TColStd_MapOfInteger aMap;
00417     aMap.Add(GEOM_PLANE);
00418     aMap.Add(GEOM_MARKER);
00419     globalSelection(aMap);
00420 
00421     Group1->PushButton1->setDown(false);
00422     Group1->PushButton2->setDown(false);
00423     Group1->PushButton5->setDown(false);
00424     Group1->LineEdit1->setEnabled(false);
00425     Group1->LineEdit2->setEnabled(false);
00426     Group1->LineEdit5->setEnabled(false);
00427 
00428     Group1->CheckButton2->setEnabled(false);
00429   }
00430   else if (send == Group1->PushButton5) {
00431     myEditCurrentArgument = Group1->LineEdit5;
00432 
00433     Group1->CheckButton2->setEnabled(true);
00434 
00435     if ( Group1->CheckButton2->isChecked() ) {
00436       localSelection( GEOM::GEOM_Object::_nil(), TopAbs_EDGE );
00437     } else {
00438       TColStd_MapOfInteger aMap;
00439       aMap.Add(GEOM_WIRE);
00440       aMap.Add(GEOM_LINE);
00441       globalSelection(aMap);
00442     }
00443 
00444     Group1->PushButton1->setDown(false);
00445     Group1->PushButton2->setDown(false);
00446     Group1->PushButton4->setDown(false);
00447     Group1->LineEdit1->setEnabled(false);
00448     Group1->LineEdit2->setEnabled(false);
00449     Group1->LineEdit4->setEnabled(false);
00450   }
00451   connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
00452           this, SLOT(SelectionIntoArgument()));
00453 
00454   // enable line edit
00455   myEditCurrentArgument->setEnabled(true);
00456   myEditCurrentArgument->setFocus();
00457   // after setFocus(), because it will be setDown(false) when loses focus
00458   send->setDown(true);
00459 
00460   // seems we need it only to avoid preview disappearing, caused by selection mode change
00461   processPreview();
00462 }
00463 
00464 //=================================================================================
00465 // function : ActivateThisDialog()
00466 // purpose  :
00467 //=================================================================================
00468 void TransformationGUI_PositionDlg::ActivateThisDialog()
00469 {
00470   GEOMBase_Skeleton::ActivateThisDialog();
00471   connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
00472            this, SLOT( SelectionIntoArgument() ) );
00473 
00474   connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
00475            this, SLOT( SelectionIntoArgument() ) );
00476 
00477   ConstructorsClicked( getConstructorId() );
00478 }
00479 
00480 //=================================================================================
00481 // function : enterEvent()
00482 // purpose  : when mouse enter onto the QWidget
00483 //=================================================================================
00484 void TransformationGUI_PositionDlg::enterEvent (QEvent*)
00485 {
00486   if (!mainFrame()->GroupConstructors->isEnabled())
00487     ActivateThisDialog();
00488 }
00489 
00490 //=================================================================================
00491 // function : createOperation
00492 // purpose  :
00493 //=================================================================================
00494 GEOM::GEOM_IOperations_ptr TransformationGUI_PositionDlg::createOperation()
00495 {
00496   return getGeomEngine()->GetITransformOperations(getStudyId());
00497 }
00498 
00499 //=================================================================================
00500 // function : isValid
00501 // purpose  :
00502 //=================================================================================
00503 bool TransformationGUI_PositionDlg::isValid (QString& /*msg*/)
00504 {
00505   bool ok = false;
00506   switch (getConstructorId()) {
00507   case 0:
00508     ok = !myObjects.isEmpty() && myEndLCS;
00509     break;
00510   case 1:
00511     ok = !myObjects.isEmpty() && myStartLCS && myEndLCS;
00512     break;
00513   case 2:
00514     ok = !myObjects.isEmpty() && myPath;
00515     break;
00516   default:
00517     break;
00518   }
00519   return ok;
00520 }
00521 
00522 //=================================================================================
00523 // function : execute
00524 // purpose  :
00525 //=================================================================================
00526 bool TransformationGUI_PositionDlg::execute (ObjectList& objects)
00527 {
00528   bool res = false;
00529   bool toCreateCopy = IsPreview() || Group1->CheckButton1->isChecked();
00530   GEOM::GEOM_Object_var anObj;
00531 
00532   GEOM::GEOM_ITransformOperations_var anOper = GEOM::GEOM_ITransformOperations::_narrow(getOperation());
00533 
00534   switch (getConstructorId()) {
00535   case 0:
00536     {
00537       for (int i = 0; i < myObjects.count(); i++) {
00538         anObj = toCreateCopy ? 
00539           anOper->PositionShapeCopy(myObjects[i].get(), myObjects[i].get(), myEndLCS.get()) :
00540           anOper->PositionShape(myObjects[i].get(), myObjects[i].get(), myEndLCS.get());
00541 
00542         if (!anObj->_is_nil())
00543           objects.push_back(anObj._retn());
00544       }
00545       res = true;
00546       break;
00547     }
00548   case 1:
00549     {
00550       for (int i = 0; i < myObjects.count(); i++) {
00551           anObj = toCreateCopy ? 
00552             anOper->PositionShapeCopy(myObjects[i].get(), myStartLCS.get(), myEndLCS.get()) :
00553             anOper->PositionShape(myObjects[i].get(), myStartLCS.get(), myEndLCS.get());
00554         if (!anObj->_is_nil())
00555           objects.push_back(anObj._retn());
00556       }
00557       res = true;
00558       break;
00559     }
00560   case 2:
00561     {
00562       double aDistance = Group1->SpinBox_DX->value();
00563       bool toReverse = Group1->CheckButton3->isChecked();
00564       for (int i = 0; i < myObjects.count(); i++) {
00565         anObj = anOper->PositionAlongPath(myObjects[i].get(), myPath.get(), aDistance, toCreateCopy, toReverse);
00566         if (!anObj->_is_nil())
00567           objects.push_back(anObj._retn());
00568       }
00569       res = true;
00570       break;
00571     }
00572   }
00573 
00574   return res;
00575 }
00576 
00577 //=================================================================================
00578 // function : restoreSubShapes
00579 // purpose  :
00580 //=================================================================================
00581 void TransformationGUI_PositionDlg::restoreSubShapes (SALOMEDS::Study_ptr   theStudy,
00582                                                       SALOMEDS::SObject_ptr theSObject)
00583 {
00584   if (mainFrame()->CheckBoxRestoreSS->isChecked()) {
00585     // empty list of arguments means that all arguments should be restored
00586     getGeomEngine()->RestoreSubShapesSO(theStudy, theSObject, GEOM::ListOfGO(),
00587                                         /*theFindMethod=*/GEOM::FSM_Transformed,
00588                                         /*theInheritFirstArg=*/true,
00589                                         mainFrame()->CheckBoxAddPrefix->isChecked());
00590   }
00591 }
00592 
00593 //=================================================================================
00594 // function :  CreateCopyModeChanged()
00595 // purpose  :
00596 //=================================================================================
00597 void TransformationGUI_PositionDlg::CreateCopyModeChanged()
00598 {
00599   mainFrame()->GroupBoxName->setEnabled(Group1->CheckButton1->isChecked());
00600 }
00601 
00602 //=================================================================================
00603 // function : addSubshapeToStudy
00604 // purpose  : virtual method to add new SubObjects if local selection
00605 //=================================================================================
00606 void TransformationGUI_PositionDlg::addSubshapesToStudy()
00607 {
00608   if ( getConstructorId() == 2 )
00609     GEOMBase::PublishSubObject( myPath.get() );
00610 }