Back to index

salome-geom  6.5.0
Public Member Functions | Protected Member Functions | Private Slots | Private Member Functions | Private Attributes
OperationGUI_FilletDlg Class Reference

#include <OperationGUI_FilletDlg.h>

List of all members.

Public Member Functions

 OperationGUI_FilletDlg (GeometryGUI *, QWidget *)
 ~OperationGUI_FilletDlg ()

Protected Member Functions

virtual GEOM::GEOM_IOperations_ptr createOperation ()
virtual bool isValid (QString &)
virtual bool execute (ObjectList &)

Private Slots

void ClickOnOk ()
bool ClickOnApply ()
void ActivateThisDialog ()
void LineEditReturnPressed ()
void SelectionIntoArgument ()
void SetEditCurrentArgument ()
void ValueChangedInSpinBox (double)
void ConstructorsClicked (int)
void RadioButtonClicked ()

Private Member Functions

void Init ()
void enterEvent (QEvent *)
void activateSelection ()
void enableWidgets ()
double getRadius () const

Private Attributes

int myConstructorId
GEOM::GEOM_Object_var myShape
TColStd_IndexedMapOfInteger myEdges
TColStd_IndexedMapOfInteger myFaces
bool myInitial
DlgRef_1Sel1Spin * Group1
DlgRef_2Sel3Spin2Rb * Group2
DlgRef_2Sel3Spin2Rb * Group3

Detailed Description

Definition at line 41 of file OperationGUI_FilletDlg.h.


Constructor & Destructor Documentation

OperationGUI_FilletDlg::OperationGUI_FilletDlg ( GeometryGUI *  theGeometryGUI,
QWidget *  parent 
)

Definition at line 55 of file OperationGUI_FilletDlg.cxx.

  : GEOMBase_Skeleton(theGeometryGUI, parent, false),
    myInitial(true)
{
  SUIT_ResourceMgr* aResMgr = myGeomGUI->getApp()->resourceMgr();
  QPixmap image0 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_FILLET_ALL")));
  QPixmap image1 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_FILLET_EDGE")));
  QPixmap image2 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_FILLET_FACE")));

  QPixmap iconSelect (aResMgr->loadPixmap("GEOM", tr("ICON_SELECT")));

  setWindowTitle(tr("GEOM_FILLET_TITLE"));

  /***************************************************************/
  mainFrame()->GroupConstructors->setTitle(tr("GEOM_FILLET"));
  mainFrame()->RadioButton1->setIcon(image0);
  mainFrame()->RadioButton2->setIcon(image1);
  mainFrame()->RadioButton3->setIcon(image2);

  Group1 = new DlgRef_1Sel1Spin(centralWidget());
  Group1->GroupBox1->setTitle(tr("GEOM_FILLET_ALL"));
  Group1->TextLabel1->setText(tr("GEOM_MAIN_OBJECT"));
  Group1->TextLabel2->setText(tr("GEOM_RADIUS"));
  Group1->PushButton1->setIcon(iconSelect);
  Group1->LineEdit1->setReadOnly(true);

  Group2 = new DlgRef_2Sel3Spin2Rb(centralWidget());
  Group2->GroupBox1->setTitle(tr("GEOM_FILLET_EDGES"));
  Group2->TextLabel1->setText(tr("GEOM_MAIN_OBJECT"));
  Group2->TextLabel2->setText(tr("SELECTED_EDGES"));
  Group2->TextLabel3->setText(tr("GEOM_RADIUS"));
  Group2->TextLabel4->setText(tr("GEOM_R1"));
  Group2->TextLabel5->setText(tr("GEOM_R2"));
  Group2->PushButton1->setIcon(iconSelect);
  Group2->PushButton2->setIcon(iconSelect);
  Group2->LineEdit1->setReadOnly(true);
  Group2->LineEdit2->setReadOnly(true);

  Group3 = new DlgRef_2Sel3Spin2Rb(centralWidget());
  Group3->GroupBox1->setTitle(tr("GEOM_FILLET_FACES"));
  Group3->TextLabel1->setText(tr("GEOM_MAIN_OBJECT"));
  Group3->TextLabel2->setText(tr("SELECTED_FACES"));
  Group3->TextLabel3->setText(tr("GEOM_RADIUS"));
  Group3->TextLabel4->setText(tr("GEOM_R1"));
  Group3->TextLabel5->setText(tr("GEOM_R2"));
  Group3->PushButton1->setIcon(iconSelect);
  Group3->PushButton2->setIcon(iconSelect);
  Group3->LineEdit1->setReadOnly(true);
  Group3->LineEdit2->setReadOnly(true);

  QVBoxLayout* layout = new QVBoxLayout(centralWidget());
  layout->setMargin(0); layout->setSpacing(6);
  layout->addWidget(Group1);
  layout->addWidget(Group2);
  layout->addWidget(Group3);
  /***************************************************************/

  // Set range of spinboxes
  double SpecificStep = 10.0;
  initSpinBox(Group1->SpinBox_DX, 0.001, COORD_MAX, SpecificStep, "length_precision" );
  initSpinBox(Group2->SpinBox_DX, 0.001, COORD_MAX, SpecificStep, "length_precision" );
  initSpinBox(Group2->SpinBox_DY, 0.001, COORD_MAX, SpecificStep, "length_precision" );
  initSpinBox(Group2->SpinBox_DZ, 0.001, COORD_MAX, SpecificStep, "length_precision" );
  initSpinBox(Group3->SpinBox_DX, 0.001, COORD_MAX, SpecificStep, "length_precision" );
  initSpinBox(Group3->SpinBox_DY, 0.001, COORD_MAX, SpecificStep, "length_precision" );
  initSpinBox(Group3->SpinBox_DZ, 0.001, COORD_MAX, SpecificStep, "length_precision" );

  setHelpFileName("fillet_operation_page.html");

  // Initialisation
  Init();
}

Here is the call graph for this function:

Definition at line 132 of file OperationGUI_FilletDlg.cxx.

{
}

Member Function Documentation

Definition at line 541 of file OperationGUI_FilletDlg.cxx.

{
  disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);

  if (!myShape->_is_nil() && myEditCurrentArgument == Group2->LineEdit2)
    localSelection(myShape, TopAbs_EDGE);
  else if (!myShape->_is_nil() && myEditCurrentArgument == Group3->LineEdit2)
    localSelection(myShape, TopAbs_FACE);
  else {
    TColStd_MapOfInteger aMap;
    aMap.Add(GEOM_SHELL);
    aMap.Add(GEOM_SOLID);
    aMap.Add(GEOM_COMPOUND);
    globalSelection(aMap);
  }

  connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
          this, SLOT(SelectionIntoArgument()));
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 509 of file OperationGUI_FilletDlg.cxx.

{
  GEOMBase_Skeleton::ActivateThisDialog();
  connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
           this, SLOT( SelectionIntoArgument() ) );

  ConstructorsClicked( getConstructorId() );
}

Here is the call graph for this function:

Here is the caller graph for this function:

bool OperationGUI_FilletDlg::ClickOnApply ( ) [private, slot]

Definition at line 320 of file OperationGUI_FilletDlg.cxx.

{
  if (!onAccept())
    return false;

  initName();
  // activate selection and connect selection manager
  ConstructorsClicked(getConstructorId());
  return true;
}

Here is the call graph for this function:

Here is the caller graph for this function:

void OperationGUI_FilletDlg::ClickOnOk ( ) [private, slot]

Definition at line 309 of file OperationGUI_FilletDlg.cxx.

{
  setIsApplyAndClose( true );
  if (ClickOnApply())
    ClickOnCancel();
}

Here is the call graph for this function:

Here is the caller graph for this function:

void OperationGUI_FilletDlg::ConstructorsClicked ( int  constructorId) [private, slot]

Definition at line 211 of file OperationGUI_FilletDlg.cxx.

{
  if (myGeomGUI->getApp()->desktop()->activeWindow()->getViewManager()->getType()
      != OCCViewer_Viewer::Type()) {
    mainFrame()->RadioButton1->setChecked(true);
    return;
  }

  if (myConstructorId == constructorId)
    return;

  // Get radius from previous widget
  QString R = "5", R1 = "5", R2 = "5";
  if      (myConstructorId == 0) {
    R = Group1->SpinBox_DX->text();
  }
  else if (myConstructorId == 1) {
    R = Group2->SpinBox_DX->text();
    R1 = Group2->SpinBox_DY->text();
    R2 = Group2->SpinBox_DZ->text();
  }
  else {
    R = Group3->SpinBox_DX->text();
    R1 = Group3->SpinBox_DY->text();
    R2 = Group3->SpinBox_DZ->text();
  }

  myConstructorId = constructorId;

  switch (constructorId) {
  case 0:
    Group2->hide();
    Group3->hide();
    Group1->show();
    Group1->SpinBox_DX->setText(R);
    break;
  case 1:
    Group1->hide();
    Group3->hide();
    Group2->show();
    Group2->SpinBox_DX->setText(R);
    Group2->SpinBox_DY->setText(R1);
    Group2->SpinBox_DZ->setText(R2);
    break;
  case 2:
    Group1->hide();
    Group2->hide();
    Group3->show();
    Group3->SpinBox_DX->setText(R);
    Group3->SpinBox_DY->setText(R1);
    Group3->SpinBox_DZ->setText(R2);
    break;
  default:
    break;
  }

  if      (constructorId == 0) Group1->PushButton1->click();
  else if (constructorId == 1) Group2->PushButton1->click();
  else                         Group3->PushButton1->click();

  enableWidgets();

  if (myInitial) {
    myInitial = false;
    SelectionIntoArgument();
  }
  else {
    if (!myShape->_is_nil()) {
      myEditCurrentArgument->setText(GEOMBase::GetName(myShape));
      GEOMBase_Skeleton::LineEditReturnPressed();
      switch (getConstructorId()) {
      case 1:
        if (myEdges.Extent() == 0)
          Group2->PushButton2->click();
        break;
      case 2:
        if (myFaces.Extent() == 0)
          Group3->PushButton2->click();
        break;
      default:
        break;
      }
    }
    else
      myEditCurrentArgument->setText("");

    processPreview();
  }

  qApp->processEvents();
  updateGeometry();
  resize(minimumSizeHint());
}

Here is the call graph for this function:

Here is the caller graph for this function:

GEOM::GEOM_IOperations_ptr OperationGUI_FilletDlg::createOperation ( ) [protected, virtual]

Definition at line 595 of file OperationGUI_FilletDlg.cxx.

{
  return getGeomEngine()->GetILocalOperations(getStudyId());
}

Definition at line 565 of file OperationGUI_FilletDlg.cxx.

{
  int anId = getConstructorId();

  bool toEnable = !myShape->_is_nil();

  if (anId == 1) {
    //Group2->LineEdit2->setEnabled(toEnable);
    Group2->PushButton2->setEnabled(toEnable);

    if (!toEnable) {
      Group2->LineEdit2->setText("");
      myEdges.Clear();
    }
  }
  else if (anId == 2) {
    //Group3->LineEdit2->setEnabled(toEnable);
    Group3->PushButton2->setEnabled(toEnable);

    if (!toEnable) {
      Group3->LineEdit2->setText("");
      myFaces.Clear();
    }
  }
}

Here is the caller graph for this function:

void OperationGUI_FilletDlg::enterEvent ( QEvent *  ) [private]

Definition at line 522 of file OperationGUI_FilletDlg.cxx.

{
  if (!mainFrame()->GroupConstructors->isEnabled())
    this->ActivateThisDialog();
}

Here is the call graph for this function:

bool OperationGUI_FilletDlg::execute ( ObjectList objects) [protected, virtual]

Definition at line 638 of file OperationGUI_FilletDlg.cxx.

{
  QStringList aParameters;
  GEOM::GEOM_Object_var anObj;

  int anId = getConstructorId();

  GEOM::GEOM_ILocalOperations_var anOper = GEOM::GEOM_ILocalOperations::_narrow(getOperation());

  if (anId == 0) {
    anObj = anOper->MakeFilletAll(myShape, getRadius());
    if (!anObj->_is_nil())
      aParameters << Group1->SpinBox_DX->text();
  }
  else if (anId == 1) {
    GEOM::ListOfLong_var aList = new GEOM::ListOfLong;
    aList->length(myEdges.Extent());

    for (int i = 1, n = myEdges.Extent(); i <= n; i++)
      aList[ i - 1 ] = myEdges(i);

    if (Group2->RadioButton1->isChecked())
    {
      anObj = anOper->MakeFilletEdges(myShape, getRadius(), aList);
      if (!anObj->_is_nil())
        aParameters << Group2->SpinBox_DX->text();
    }
    else
    {
      anObj = anOper->MakeFilletEdgesR1R2(myShape,
                                          Group2->SpinBox_DY->value(),
                                          Group2->SpinBox_DZ->value(),
                                          aList);
      if (!anObj->_is_nil())
      {
        aParameters << Group2->SpinBox_DY->text();
        aParameters << Group2->SpinBox_DZ->text();
      }
    }
  }
  else if (anId == 2) {
    GEOM::ListOfLong_var aList = new GEOM::ListOfLong;
    aList->length(myFaces.Extent());

    for (int i = 1, n = myFaces.Extent(); i <= n; i++)
      aList[ i - 1 ] = myFaces(i);

    if (Group3->RadioButton1->isChecked()) {
      anObj = anOper->MakeFilletFaces(myShape, getRadius(), aList);
      if (!anObj->_is_nil())
        aParameters << Group3->SpinBox_DX->text();
    }
    else {
      anObj = anOper->MakeFilletFacesR1R2(myShape,
                                          Group3->SpinBox_DY->value(),
                                          Group3->SpinBox_DZ->value(), aList);
      if (!anObj->_is_nil())
      {
        aParameters << Group3->SpinBox_DY->text();
        aParameters << Group3->SpinBox_DZ->text();
      }
    }
  }

  if (!anObj->_is_nil())
  {
    if (!IsPreview())
      anObj->SetParameters(aParameters.join(":").toLatin1().constData());
    objects.push_back(anObj._retn());
  }

  return true;
}

Here is the call graph for this function:

double OperationGUI_FilletDlg::getRadius ( ) const [private]

Definition at line 716 of file OperationGUI_FilletDlg.cxx.

{
  int anId = getConstructorId();
  if      (anId == 0) return Group1->SpinBox_DX->value();
  else if (anId == 1) return Group2->SpinBox_DX->value();
  else                return Group3->SpinBox_DX->value();
}

Here is the caller graph for this function:

void OperationGUI_FilletDlg::Init ( ) [private]

Definition at line 140 of file OperationGUI_FilletDlg.cxx.

{
  // Set Initial values of spinboxes
  Group1->SpinBox_DX->setValue(5);
  Group2->SpinBox_DX->setValue(5);
  Group2->SpinBox_DY->setValue(5);
  Group2->SpinBox_DZ->setValue(5);
  Group3->SpinBox_DX->setValue(5);
  Group3->SpinBox_DY->setValue(5);
  Group3->SpinBox_DZ->setValue(5);

  // Clear line edits
  Group1->LineEdit1->setText("");
  Group2->LineEdit1->setText("");
  Group2->LineEdit2->setText("");
  Group3->LineEdit1->setText("");
  Group3->LineEdit2->setText("");

  myShape = GEOM::GEOM_Object::_nil();

  myFaces.Clear();
  myEdges.Clear();

  showOnlyPreviewControl();

  // signals and slots connections

  // main buttons
  connect(buttonOk(),    SIGNAL(clicked()), this, SLOT(ClickOnOk()   ));
  connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));

  // group box
  connect(this,          SIGNAL(constructorsClicked(int)), this, SLOT(ConstructorsClicked(int)));

  // push buttons
  connect(Group1->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
  connect(Group2->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
  connect(Group3->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
  connect(Group2->PushButton2, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
  connect(Group3->PushButton2, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));

  // line edits
  connect(Group1->LineEdit1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
  connect(Group2->LineEdit1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
  connect(Group3->LineEdit1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));

  // spin boxes
  connect(Group1->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
  connect(Group2->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
  connect(Group2->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
  connect(Group2->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
  connect(Group3->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
  connect(Group3->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
  connect(Group3->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));

  // radio buttons
  connect(Group2->RadioButton1, SIGNAL(clicked()), this, SLOT(RadioButtonClicked()));
  connect(Group2->RadioButton2, SIGNAL(clicked()), this, SLOT(RadioButtonClicked()));
  connect(Group3->RadioButton1, SIGNAL(clicked()), this, SLOT(RadioButtonClicked()));
  connect(Group3->RadioButton2, SIGNAL(clicked()), this, SLOT(RadioButtonClicked()));

  initName(tr("GEOM_FILLET"));

  myConstructorId = -1;
  ConstructorsClicked(0);
}

Here is the call graph for this function:

Here is the caller graph for this function:

bool OperationGUI_FilletDlg::isValid ( QString &  msg) [protected, virtual]

Definition at line 604 of file OperationGUI_FilletDlg.cxx.

{
  bool ok = true;
  switch (getConstructorId())
  {
    case 0:
      ok = Group1->SpinBox_DX->isValid( msg, !IsPreview() ) && ok;
      return !myShape->_is_nil() && ok;
    case 1:
      if (Group2->RadioButton1->isChecked())
        ok = Group2->SpinBox_DX->isValid( msg, !IsPreview() );
      else
      {
        ok = Group2->SpinBox_DY->isValid( msg, !IsPreview() ) && ok;
        ok = Group2->SpinBox_DZ->isValid( msg, !IsPreview() ) && ok;
      }
      return !myShape->_is_nil() && myEdges.Extent() > 0 && ok;
    case 2:
      if (Group3->RadioButton1->isChecked())
        ok = Group3->SpinBox_DX->isValid( msg, !IsPreview() );
      else
      {
        ok = Group3->SpinBox_DY->isValid( msg, !IsPreview() ) && ok;
        ok = Group3->SpinBox_DZ->isValid( msg, !IsPreview() ) && ok;
      }
      return !myShape->_is_nil() && myFaces.Extent() > 0 && ok;
    default: return false;
  }
}

Definition at line 489 of file OperationGUI_FilletDlg.cxx.

{
  QLineEdit* send = (QLineEdit*)sender();

  if (send == Group1->LineEdit1)
    myEditCurrentArgument = Group1->LineEdit1;
  else if (send == Group2->LineEdit1)
    myEditCurrentArgument = Group2->LineEdit1;
  else if (send == Group3->LineEdit1)
    myEditCurrentArgument = Group3->LineEdit1;
  else
    return;

  GEOMBase_Skeleton::LineEditReturnPressed();
}

Here is the caller graph for this function:

Definition at line 728 of file OperationGUI_FilletDlg.cxx.

{
  const QObject* s = sender();

  bool flag = s == Group2->RadioButton1 || s == Group3->RadioButton1;

  Group2->RadioButton1->blockSignals(true);
  Group2->RadioButton2->blockSignals(true);
  Group3->RadioButton1->blockSignals(true);
  Group3->RadioButton2->blockSignals(true);

  Group2->SpinBox_DX->setEnabled(flag);
  Group2->SpinBox_DY->setEnabled(!flag);
  Group2->SpinBox_DZ->setEnabled(!flag);
  Group2->RadioButton1->setChecked(flag);
  Group2->RadioButton2->setChecked(!flag);
  Group3->SpinBox_DX->setEnabled(flag);
  Group3->SpinBox_DY->setEnabled(!flag);
  Group3->SpinBox_DZ->setEnabled(!flag);
  Group3->RadioButton1->setChecked(flag);
  Group3->RadioButton2->setChecked(!flag);

  Group2->RadioButton1->blockSignals(false);
  Group2->RadioButton2->blockSignals(false);
  Group3->RadioButton1->blockSignals(false);
  Group3->RadioButton2->blockSignals(false);

  processPreview();
}

Here is the caller graph for this function:

Definition at line 335 of file OperationGUI_FilletDlg.cxx.

{
  erasePreview();
  myEditCurrentArgument->setText("");

  LightApp_SelectionMgr* aSelMgr = myGeomGUI->getApp()->selectionMgr();
  SALOME_ListIO aSelList;
  aSelMgr->selectedObjects(aSelList);

  // If selection of main object is activated
  if (myEditCurrentArgument == Group1->LineEdit1 ||
      myEditCurrentArgument == Group2->LineEdit1 ||
      myEditCurrentArgument == Group3->LineEdit1)
  {
    myShape = GEOM::GEOM_Object::_nil();
    if (aSelList.Extent() == 1) {
      GEOM::GEOM_Object_var anObj =
        GEOMBase::ConvertIOinGEOMObject( aSelList.First() );

      if ( !anObj->_is_nil() ) {
        myShape = anObj;
        myEditCurrentArgument->setText(GEOMBase::GetName(anObj));
        processPreview();
      }
    }

    enableWidgets();
  }
  // If face or edge selection is activated
  else if (myEditCurrentArgument == Group2->LineEdit2 ||
           myEditCurrentArgument == Group3->LineEdit2)
  {
    if (myEditCurrentArgument == Group2->LineEdit2) myEdges.Clear();
    else myFaces.Clear();
    if (aSelList.Extent() == 1) {
      GEOM::GEOM_Object_var anObj =
        GEOMBase::ConvertIOinGEOMObject( aSelList.First() );

      if ( !anObj->_is_nil() ) {
        TColStd_IndexedMapOfInteger anIndexes;
        aSelMgr->GetIndexes(aSelList.First(), anIndexes);

        if (anIndexes.Extent() > 0) {
          QString aName;
          if (anIndexes.Extent() == 1) {
            int anIndex = anIndexes(1);

            aName = QString(GEOMBase::GetName(anObj)) + QString(":%1").arg(anIndex);
          }
          else {
            aName = tr("GEOM_MEN_POPUP_NAME").arg(anIndexes.Extent());
          }

          myEditCurrentArgument->setText(aName);

          if (myConstructorId == 1)
            myEdges = anIndexes;
          else
            myFaces = anIndexes;

          processPreview();
        }
      }
    }
  }

  // clear selection of the faces or edges
  if (!(myEditCurrentArgument == Group2->LineEdit2 ||
        myEditCurrentArgument == Group3->LineEdit2)) {
    disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
    myGeomGUI->getApp()->selectionMgr()->clearSelected();
    connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
            this, SLOT(SelectionIntoArgument()));
  }

  switch (getConstructorId()) {
  case 1:
    if (myEditCurrentArgument == Group2->LineEdit1) {
      if (!myShape->_is_nil() && myEdges.Extent() == 0)
        Group2->PushButton2->click();
    }
    break;
  case 2:
    if (myEditCurrentArgument == Group3->LineEdit1) {
      if (!myShape->_is_nil() && myFaces.Extent() == 0)
        Group3->PushButton2->click();
    }
    break;
  default:
    break;
  }

  //rnv: To fix the bug IPAL22041 TC5.1.5: "Fillet Construcion" dialog loses current selection.
  // Restore selection of the main shape, if need,
  // because it was canceled.
  aSelMgr->selectedObjects(aSelList);
  if (aSelList.Extent() == 0 && !myShape->_is_nil()) {
    disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
    ObjectList list;
       list.push_back(myShape);
    selectObjects(list);
    connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
            this, SLOT(SelectionIntoArgument()));
  }
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 445 of file OperationGUI_FilletDlg.cxx.

{
  QPushButton* send = (QPushButton*)sender();

  if (send == Group1->PushButton1) {
    myEditCurrentArgument = Group1->LineEdit1;
  }
  else if (send == Group2->PushButton1) {
    myEditCurrentArgument = Group2->LineEdit1;
    Group2->PushButton2->setDown(false);
    Group2->LineEdit2->setEnabled(false);
  }
  else if (send == Group2->PushButton2) {
    myEditCurrentArgument = Group2->LineEdit2;
    Group2->PushButton1->setDown(false);
    Group2->LineEdit1->setEnabled(false);
  }
  else if (send == Group3->PushButton1) {
    myEditCurrentArgument = Group3->LineEdit1;
    Group3->PushButton2->setDown(false);
    Group3->LineEdit2->setEnabled(false);
  }
  else if (send == Group3->PushButton2) {
    myEditCurrentArgument = Group3->LineEdit2;
    Group3->PushButton1->setDown(false);
    Group3->LineEdit1->setEnabled(false);
  }

  // enable line edit
  myEditCurrentArgument->setEnabled(true);
  myEditCurrentArgument->setFocus();
  // after setFocus(), because it will be setDown(false) when loses focus
  send->setDown(true);

  activateSelection();

  // seems we need it only to avoid preview disappearing, caused by selection mode change
  processPreview();
}

Here is the call graph for this function:

Here is the caller graph for this function:

void OperationGUI_FilletDlg::ValueChangedInSpinBox ( double  ) [private, slot]

Definition at line 532 of file OperationGUI_FilletDlg.cxx.

{
  processPreview();
}

Here is the caller graph for this function:


Member Data Documentation

DlgRef_1Sel1Spin* OperationGUI_FilletDlg::Group1 [private]

Definition at line 83 of file OperationGUI_FilletDlg.h.

DlgRef_2Sel3Spin2Rb* OperationGUI_FilletDlg::Group2 [private]

Definition at line 84 of file OperationGUI_FilletDlg.h.

DlgRef_2Sel3Spin2Rb* OperationGUI_FilletDlg::Group3 [private]

Definition at line 85 of file OperationGUI_FilletDlg.h.

Definition at line 74 of file OperationGUI_FilletDlg.h.

TColStd_IndexedMapOfInteger OperationGUI_FilletDlg::myEdges [private]

Definition at line 77 of file OperationGUI_FilletDlg.h.

TColStd_IndexedMapOfInteger OperationGUI_FilletDlg::myFaces [private]

Definition at line 78 of file OperationGUI_FilletDlg.h.

Definition at line 81 of file OperationGUI_FilletDlg.h.

GEOM::GEOM_Object_var OperationGUI_FilletDlg::myShape [private]

Definition at line 76 of file OperationGUI_FilletDlg.h.


The documentation for this class was generated from the following files: