mirror of
https://git.salome-platform.org/gitpub/modules/geom.git
synced 2025-04-25 10:22:05 +05:00
Fix bug 10244: 'Display only' breaks local selection.
This commit is contained in:
parent
ae999b751c
commit
8e7ad1edfd
@ -55,9 +55,8 @@ using namespace std;
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_ArcDlg::BasicGUI_ArcDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
BasicGUI_ArcDlg::BasicGUI_ArcDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
const char* name, bool modal, WFlags fl)
|
const char* name, bool modal, WFlags fl)
|
||||||
: GEOMBase_Skeleton(parent, name, modal, WStyle_Customize |
|
: GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
myGeometryGUI(theGeometryGUI)
|
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_ARC")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_ARC")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
@ -108,7 +107,7 @@ BasicGUI_ArcDlg::~BasicGUI_ArcDlg()
|
|||||||
void BasicGUI_ArcDlg::Init()
|
void BasicGUI_ArcDlg::Init()
|
||||||
{
|
{
|
||||||
/* init variables */
|
/* init variables */
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
globalSelection( GEOM_POINT );
|
globalSelection( GEOM_POINT );
|
||||||
|
|
||||||
myEditCurrentArgument = Group3Pnts->LineEdit1;
|
myEditCurrentArgument = Group3Pnts->LineEdit1;
|
||||||
@ -118,8 +117,8 @@ void BasicGUI_ArcDlg::Init()
|
|||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -255,7 +254,7 @@ void BasicGUI_ArcDlg::ActivateThisDialog()
|
|||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
globalSelection( GEOM_POINT );
|
globalSelection( GEOM_POINT );
|
||||||
|
|
||||||
myEditCurrentArgument = Group3Pnts->LineEdit1;
|
myEditCurrentArgument = Group3Pnts->LineEdit1;
|
||||||
@ -273,7 +272,7 @@ void BasicGUI_ArcDlg::ActivateThisDialog()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_ArcDlg::DeactivateActiveDialog()
|
void BasicGUI_ArcDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -293,7 +292,7 @@ void BasicGUI_ArcDlg::enterEvent(QEvent* e)
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_ArcDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_ArcDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetICurvesOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetICurvesOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -334,6 +333,5 @@ bool BasicGUI_ArcDlg::execute( ObjectList& objects )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_ArcDlg::closeEvent( QCloseEvent* e )
|
void BasicGUI_ArcDlg::closeEvent( QCloseEvent* e )
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::closeEvent( e );
|
GEOMBase_Skeleton::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BasicGUI_ArcDlg.h
|
// File : BasicGUI_ArcDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_ARC_H
|
#ifndef DIALOGBOX_ARC_H
|
||||||
#define DIALOGBOX_ARC_H
|
#define DIALOGBOX_ARC_H
|
||||||
@ -45,7 +44,8 @@ class BasicGUI_ArcDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_ArcDlg( GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0 );
|
BasicGUI_ArcDlg( GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0 );
|
||||||
~BasicGUI_ArcDlg();
|
~BasicGUI_ArcDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -60,8 +60,6 @@ private :
|
|||||||
void Init();
|
void Init();
|
||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint1, myPoint2, myPoint3;
|
GEOM::GEOM_Object_var myPoint1, myPoint2, myPoint3;
|
||||||
|
|
||||||
DlgRef_3Sel_QTD* Group3Pnts;
|
DlgRef_3Sel_QTD* Group3Pnts;
|
||||||
|
@ -46,9 +46,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_CircleDlg::BasicGUI_CircleDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
BasicGUI_CircleDlg::BasicGUI_CircleDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),
|
const char* name, bool modal, WFlags fl)
|
||||||
myGeometryGUI(theGeometryGUI)
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CIRCLE_PV")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CIRCLE_PV")));
|
||||||
QPixmap image2(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CIRCLE_PNTS")));
|
QPixmap image2(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CIRCLE_PNTS")));
|
||||||
@ -117,7 +118,7 @@ void BasicGUI_CircleDlg::Init()
|
|||||||
|
|
||||||
myPoint = myDir = myPoint1 = myPoint2 = myPoint3 = GEOM::GEOM_Object::_nil();
|
myPoint = myDir = myPoint1 = myPoint2 = myPoint3 = GEOM::GEOM_Object::_nil();
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
/* Get setting of step value from file configuration */
|
/* Get setting of step value from file configuration */
|
||||||
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
|
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
|
||||||
@ -129,8 +130,8 @@ void BasicGUI_CircleDlg::Init()
|
|||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -146,7 +147,7 @@ void BasicGUI_CircleDlg::Init()
|
|||||||
connect(GroupPntVecR->LineEdit2, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
connect(GroupPntVecR->LineEdit2, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
||||||
|
|
||||||
connect(GroupPntVecR->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupPntVecR->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPntVecR->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPntVecR->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
||||||
@ -320,7 +321,7 @@ void BasicGUI_CircleDlg::ActivateThisDialog()
|
|||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
ConstructorsClicked( getConstructorId() );
|
ConstructorsClicked( getConstructorId() );
|
||||||
}
|
}
|
||||||
@ -342,7 +343,7 @@ void BasicGUI_CircleDlg::enterEvent(QEvent* e)
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_CircleDlg::DeactivateActiveDialog()
|
void BasicGUI_CircleDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -370,7 +371,7 @@ double BasicGUI_CircleDlg::getRadius() const
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_CircleDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_CircleDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetICurvesOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetICurvesOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -431,7 +432,6 @@ bool BasicGUI_CircleDlg::execute( ObjectList& objects )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_CircleDlg::closeEvent( QCloseEvent* e )
|
void BasicGUI_CircleDlg::closeEvent( QCloseEvent* e )
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::closeEvent( e );
|
GEOMBase_Skeleton::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BasicGUI_CircleDlg.h
|
// File : BasicGUI_CircleDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_CIRCLE_H
|
#ifndef DIALOGBOX_CIRCLE_H
|
||||||
#define DIALOGBOX_CIRCLE_H
|
#define DIALOGBOX_CIRCLE_H
|
||||||
@ -35,9 +34,8 @@
|
|||||||
|
|
||||||
#include "BasicGUI.h"
|
#include "BasicGUI.h"
|
||||||
|
|
||||||
//#include "GEOM_EdgeFilter.hxx"
|
|
||||||
//#include "GEOM_ShapeTypeFilter.hxx"
|
|
||||||
#include <gp_Dir.hxx>
|
#include <gp_Dir.hxx>
|
||||||
|
|
||||||
#if defined WNT && defined WIN32 && defined SALOME_WNT_EXPORTS
|
#if defined WNT && defined WIN32 && defined SALOME_WNT_EXPORTS
|
||||||
#define BASICGUI_WNT_EXPORT __declspec( dllexport )
|
#define BASICGUI_WNT_EXPORT __declspec( dllexport )
|
||||||
#else
|
#else
|
||||||
@ -53,7 +51,8 @@ class BasicGUI_CircleDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_CircleDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BasicGUI_CircleDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BasicGUI_CircleDlg();
|
~BasicGUI_CircleDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -69,8 +68,6 @@ private :
|
|||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
double getRadius() const;
|
double getRadius() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint, myDir, myPoint1, myPoint2, myPoint3;
|
GEOM::GEOM_Object_var myPoint, myDir, myPoint1, myPoint2, myPoint3;
|
||||||
|
|
||||||
DlgRef_2Sel1Spin* GroupPntVecR;
|
DlgRef_2Sel1Spin* GroupPntVecR;
|
||||||
@ -90,7 +87,6 @@ private slots:
|
|||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
void ValueChangedInSpinBox();
|
void ValueChangedInSpinBox();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_CIRCLE_H
|
#endif // DIALOGBOX_CIRCLE_H
|
||||||
|
@ -51,9 +51,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_CurveDlg::BasicGUI_CurveDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
BasicGUI_CurveDlg::BasicGUI_CurveDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),
|
const char* name, bool modal, WFlags fl)
|
||||||
myGeometryGUI(theGeometryGUI)
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_POLYLINE")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_POLYLINE")));
|
||||||
QPixmap image2(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SPLINE")));
|
QPixmap image2(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SPLINE")));
|
||||||
@ -109,8 +110,8 @@ void BasicGUI_CurveDlg::Init()
|
|||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -311,7 +312,7 @@ void BasicGUI_CurveDlg::ActivateThisDialog()
|
|||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
globalSelection( GEOM_POINT );
|
globalSelection( GEOM_POINT );
|
||||||
ConstructorsClicked( getConstructorId() );
|
ConstructorsClicked( getConstructorId() );
|
||||||
@ -323,7 +324,7 @@ void BasicGUI_CurveDlg::ActivateThisDialog()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_CurveDlg::DeactivateActiveDialog()
|
void BasicGUI_CurveDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -343,7 +344,7 @@ void BasicGUI_CurveDlg::enterEvent(QEvent* e)
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_CurveDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_CurveDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetICurvesOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetICurvesOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -393,7 +394,6 @@ bool BasicGUI_CurveDlg::execute( ObjectList& objects )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_CurveDlg::closeEvent( QCloseEvent* e )
|
void BasicGUI_CurveDlg::closeEvent( QCloseEvent* e )
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::closeEvent( e );
|
GEOMBase_Skeleton::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -23,7 +23,6 @@
|
|||||||
// File : BasicGUI_CurveDlg.h
|
// File : BasicGUI_CurveDlg.h
|
||||||
// Author : Alexander SLADKOV
|
// Author : Alexander SLADKOV
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef BASICGUI_CURVE_H
|
#ifndef BASICGUI_CURVE_H
|
||||||
#define BASICGUI_CURVE_H
|
#define BASICGUI_CURVE_H
|
||||||
@ -32,13 +31,14 @@
|
|||||||
#include "DlgRef_1Sel_QTD.h"
|
#include "DlgRef_1Sel_QTD.h"
|
||||||
|
|
||||||
#include "BasicGUI.h"
|
#include "BasicGUI.h"
|
||||||
|
|
||||||
#include <list>
|
#include <list>
|
||||||
|
|
||||||
#if defined WNT && defined WIN32 && defined SALOME_WNT_EXPORTS
|
#if defined WNT && defined WIN32 && defined SALOME_WNT_EXPORTS
|
||||||
#define BASICGUI_WNT_EXPORT __declspec( dllexport )
|
#define BASICGUI_WNT_EXPORT __declspec( dllexport )
|
||||||
#else
|
#else
|
||||||
#define BASICGUI_WNT_EXPORT
|
#define BASICGUI_WNT_EXPORT
|
||||||
#endif
|
#endif
|
||||||
//#include "GEOM_ShapeTypeFilter.hxx"
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// class : BasicGUI_CurveDlg
|
// class : BasicGUI_CurveDlg
|
||||||
@ -49,7 +49,8 @@ class BasicGUI_CurveDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_CurveDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BasicGUI_CurveDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BasicGUI_CurveDlg();
|
~BasicGUI_CurveDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -64,8 +65,6 @@ private :
|
|||||||
void Init();
|
void Init();
|
||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
DlgRef_1Sel_QTD* GroupPoints;
|
DlgRef_1Sel_QTD* GroupPoints;
|
||||||
GEOM::ListOfGO_var myPoints;
|
GEOM::ListOfGO_var myPoints;
|
||||||
list<GEOM::GEOM_Object_var> myOrderedSel;//!< This list used for managing orderes selection
|
list<GEOM::GEOM_Object_var> myOrderedSel;//!< This list used for managing orderes selection
|
||||||
|
@ -47,8 +47,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_EllipseDlg::BasicGUI_EllipseDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
BasicGUI_EllipseDlg::BasicGUI_EllipseDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_ELLIPSE_PV")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_ELLIPSE_PV")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
@ -103,7 +105,7 @@ void BasicGUI_EllipseDlg::Init()
|
|||||||
|
|
||||||
myPoint = myDir = GEOM::GEOM_Object::_nil();
|
myPoint = myDir = GEOM::GEOM_Object::_nil();
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
/* Get setting of step value from file configuration */
|
/* Get setting of step value from file configuration */
|
||||||
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
|
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
|
||||||
@ -119,8 +121,8 @@ void BasicGUI_EllipseDlg::Init()
|
|||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -134,8 +136,8 @@ void BasicGUI_EllipseDlg::Init()
|
|||||||
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
connect(GroupPoints->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupPoints->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
||||||
@ -274,7 +276,7 @@ void BasicGUI_EllipseDlg::ActivateThisDialog()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_EllipseDlg::DeactivateActiveDialog()
|
void BasicGUI_EllipseDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -303,7 +305,7 @@ void BasicGUI_EllipseDlg::ValueChangedInSpinBox(double newValue)
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_EllipseDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_EllipseDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetICurvesOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetICurvesOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -344,7 +346,6 @@ bool BasicGUI_EllipseDlg::execute( ObjectList& objects )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_EllipseDlg::closeEvent( QCloseEvent* e )
|
void BasicGUI_EllipseDlg::closeEvent( QCloseEvent* e )
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::closeEvent( e );
|
GEOMBase_Skeleton::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -23,7 +23,6 @@
|
|||||||
// File : BasicGUI_EllipseDlg.h
|
// File : BasicGUI_EllipseDlg.h
|
||||||
// Author : Nicolas REJNERI
|
// Author : Nicolas REJNERI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef BASICGUI_ELLIPSE_H
|
#ifndef BASICGUI_ELLIPSE_H
|
||||||
#define BASICGUI_ELLIPSE_H
|
#define BASICGUI_ELLIPSE_H
|
||||||
@ -33,14 +32,14 @@
|
|||||||
|
|
||||||
#include "BasicGUI.h"
|
#include "BasicGUI.h"
|
||||||
|
|
||||||
//#include "GEOM_ShapeTypeFilter.hxx"
|
|
||||||
//#include "GEOM_EdgeFilter.hxx"
|
|
||||||
#include <gp_Dir.hxx>
|
#include <gp_Dir.hxx>
|
||||||
|
|
||||||
#if defined WNT && defined WIN32 && defined SALOME_WNT_EXPORTS
|
#if defined WNT && defined WIN32 && defined SALOME_WNT_EXPORTS
|
||||||
#define BASICGUI_WNT_EXPORT __declspec( dllexport )
|
#define BASICGUI_WNT_EXPORT __declspec( dllexport )
|
||||||
#else
|
#else
|
||||||
#define BASICGUI_WNT_EXPORT
|
#define BASICGUI_WNT_EXPORT
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// class : BasicGUI_EllipseDlg
|
// class : BasicGUI_EllipseDlg
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -50,7 +49,8 @@ class BasicGUI_EllipseDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_EllipseDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BasicGUI_EllipseDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BasicGUI_EllipseDlg();
|
~BasicGUI_EllipseDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -65,8 +65,6 @@ private :
|
|||||||
void Init();
|
void Init();
|
||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint, myDir;
|
GEOM::GEOM_Object_var myPoint, myDir;
|
||||||
|
|
||||||
DlgRef_2Sel2Spin* GroupPoints;
|
DlgRef_2Sel2Spin* GroupPoints;
|
||||||
|
@ -48,8 +48,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_LineDlg::BasicGUI_LineDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
BasicGUI_LineDlg::BasicGUI_LineDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM",tr("ICON_DLG_LINE_2P")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM",tr("ICON_DLG_LINE_2P")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM",tr("ICON_SELECT")));
|
||||||
@ -101,13 +103,13 @@ void BasicGUI_LineDlg::Init()
|
|||||||
|
|
||||||
myPoint1 = myPoint2 = GEOM::GEOM_Object::_nil();
|
myPoint1 = myPoint2 = GEOM::GEOM_Object::_nil();
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
globalSelection( GEOM_POINT );
|
globalSelection( GEOM_POINT );
|
||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -225,7 +227,7 @@ void BasicGUI_LineDlg::ActivateThisDialog()
|
|||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
globalSelection( GEOM_POINT );
|
globalSelection( GEOM_POINT );
|
||||||
|
|
||||||
myEditCurrentArgument = GroupPoints->LineEdit1;
|
myEditCurrentArgument = GroupPoints->LineEdit1;
|
||||||
@ -242,7 +244,7 @@ void BasicGUI_LineDlg::ActivateThisDialog()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_LineDlg::DeactivateActiveDialog()
|
void BasicGUI_LineDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -262,7 +264,7 @@ void BasicGUI_LineDlg::enterEvent(QEvent* e)
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_LineDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_LineDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -292,7 +294,6 @@ bool BasicGUI_LineDlg::execute( ObjectList& objects )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_LineDlg::closeEvent( QCloseEvent* e )
|
void BasicGUI_LineDlg::closeEvent( QCloseEvent* e )
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::closeEvent( e );
|
GEOMBase_Skeleton::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BasicGUI_LineDlg.h
|
// File : BasicGUI_LineDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_LINE_H
|
#ifndef DIALOGBOX_LINE_H
|
||||||
#define DIALOGBOX_LINE_H
|
#define DIALOGBOX_LINE_H
|
||||||
@ -47,7 +46,8 @@ class BasicGUI_LineDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_LineDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BasicGUI_LineDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BasicGUI_LineDlg();
|
~BasicGUI_LineDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -62,8 +62,6 @@ private :
|
|||||||
void Init();
|
void Init();
|
||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint1;
|
GEOM::GEOM_Object_var myPoint1;
|
||||||
GEOM::GEOM_Object_var myPoint2;
|
GEOM::GEOM_Object_var myPoint2;
|
||||||
|
|
||||||
|
@ -58,8 +58,8 @@
|
|||||||
// purpose : Constructor
|
// purpose : Constructor
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_MarkerDlg::BasicGUI_MarkerDlg( GeometryGUI* theGeometryGUI, QWidget* theParent )
|
BasicGUI_MarkerDlg::BasicGUI_MarkerDlg( GeometryGUI* theGeometryGUI, QWidget* theParent )
|
||||||
: GEOMBase_Skeleton( theParent, "BasicGUI_MarkerDlg", false,
|
: GEOMBase_Skeleton(theGeometryGUI, theParent, "BasicGUI_MarkerDlg", false,
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap iconCS1 ( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_MARKER" ) ) );
|
QPixmap iconCS1 ( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_MARKER" ) ) );
|
||||||
QPixmap iconCS2 ( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_MARKER2" ) ) );
|
QPixmap iconCS2 ( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_MARKER2" ) ) );
|
||||||
@ -160,8 +160,8 @@ void BasicGUI_MarkerDlg::Init()
|
|||||||
connect(Group2->LineEdit3, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
connect(Group2->LineEdit3, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
||||||
|
|
||||||
connect( buttonCancel, SIGNAL( clicked() ), this, SLOT( onClose() ) );
|
connect( buttonCancel, SIGNAL( clicked() ), this, SLOT( onClose() ) );
|
||||||
connect( myGeometryGUI, SIGNAL( SignalDeactivateActiveDialog() ), this, SLOT( onDeactivate() ) );
|
connect( myGeomGUI, SIGNAL( SignalDeactivateActiveDialog() ), this, SLOT( onDeactivate() ) );
|
||||||
connect( myGeometryGUI, SIGNAL( SignalCloseAllDialogs() ), this, SLOT( onClose() ) );
|
connect( myGeomGUI, SIGNAL( SignalCloseAllDialogs() ), this, SLOT( onClose() ) );
|
||||||
|
|
||||||
connect( buttonOk, SIGNAL( clicked() ), this, SLOT( onOk() ) );
|
connect( buttonOk, SIGNAL( clicked() ), this, SLOT( onOk() ) );
|
||||||
connect( buttonApply, SIGNAL( clicked() ), this, SLOT( onApply() ) );
|
connect( buttonApply, SIGNAL( clicked() ), this, SLOT( onApply() ) );
|
||||||
@ -322,7 +322,7 @@ void BasicGUI_MarkerDlg::onSelectionDone0()
|
|||||||
if ( aRes && !aSelectedObj->_is_nil() )
|
if ( aRes && !aSelectedObj->_is_nil() )
|
||||||
{
|
{
|
||||||
TopoDS_Shape aShape;
|
TopoDS_Shape aShape;
|
||||||
if ( myGeomBase->GetShape( aSelectedObj, aShape, TopAbs_SHAPE ) && !aShape.IsNull() )
|
if ( GEOMBase::GetShape( aSelectedObj, aShape, TopAbs_SHAPE ) && !aShape.IsNull() )
|
||||||
{
|
{
|
||||||
if ( aSelectedObj->GetType() == GEOM_MARKER && aShape.ShapeType() == TopAbs_FACE )
|
if ( aSelectedObj->GetType() == GEOM_MARKER && aShape.ShapeType() == TopAbs_FACE )
|
||||||
{
|
{
|
||||||
@ -404,7 +404,7 @@ void BasicGUI_MarkerDlg::onSelectionDone()
|
|||||||
if ( !CORBA::is_nil( aSelectedObj ) && aRes ) {
|
if ( !CORBA::is_nil( aSelectedObj ) && aRes ) {
|
||||||
aName = GEOMBase::GetName( aSelectedObj );
|
aName = GEOMBase::GetName( aSelectedObj );
|
||||||
TopoDS_Shape aShape;
|
TopoDS_Shape aShape;
|
||||||
if ( myGeomBase->GetShape( aSelectedObj, aShape, TopAbs_SHAPE ) ) {
|
if ( GEOMBase::GetShape( aSelectedObj, aShape, TopAbs_SHAPE ) ) {
|
||||||
GEOM::short_array anIndexes;
|
GEOM::short_array anIndexes;
|
||||||
|
|
||||||
TColStd_IndexedMapOfInteger aMap;
|
TColStd_IndexedMapOfInteger aMap;
|
||||||
@ -645,7 +645,7 @@ void BasicGUI_MarkerDlg::enterEvent(QEvent* e)
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_MarkerDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_MarkerDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BasicGUI_MarkerDlg.h
|
// File : BasicGUI_MarkerDlg.h
|
||||||
// Author : Sergey LITONIN
|
// Author : Sergey LITONIN
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_Marker_H
|
#ifndef DIALOGBOX_Marker_H
|
||||||
#define DIALOGBOX_Marker_H
|
#define DIALOGBOX_Marker_H
|
||||||
@ -70,8 +69,6 @@ private :
|
|||||||
void enterEvent( QEvent* e );
|
void enterEvent( QEvent* e );
|
||||||
void onSelectionDone0();
|
void onSelectionDone0();
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void onOk();
|
void onOk();
|
||||||
void onClose();
|
void onClose();
|
||||||
|
@ -46,8 +46,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_PlaneDlg::BasicGUI_PlaneDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
BasicGUI_PlaneDlg::BasicGUI_PlaneDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PLANE_PV")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PLANE_PV")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PLANE_3PNTS")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PLANE_3PNTS")));
|
||||||
@ -125,7 +127,7 @@ void BasicGUI_PlaneDlg::Init()
|
|||||||
|
|
||||||
myPoint = myDir = myPoint1 = myPoint2 = myPoint3 = myFace = GEOM::GEOM_Object::_nil();
|
myPoint = myDir = myPoint1 = myPoint2 = myPoint3 = myFace = GEOM::GEOM_Object::_nil();
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
/* Get setting of step value from file configuration */
|
/* Get setting of step value from file configuration */
|
||||||
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
|
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
|
||||||
@ -143,8 +145,8 @@ void BasicGUI_PlaneDlg::Init()
|
|||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -168,9 +170,9 @@ void BasicGUI_PlaneDlg::Init()
|
|||||||
connect(Group3Pnts->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(Group3Pnts->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
connect(GroupFace->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupFace->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPntDir->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPntDir->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group3Pnts->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), Group3Pnts->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupFace->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupFace->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(), SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(), SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
@ -375,7 +377,7 @@ void BasicGUI_PlaneDlg::ActivateThisDialog()
|
|||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
ConstructorsClicked( getConstructorId() );
|
ConstructorsClicked( getConstructorId() );
|
||||||
}
|
}
|
||||||
@ -386,7 +388,7 @@ void BasicGUI_PlaneDlg::ActivateThisDialog()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_PlaneDlg::DeactivateActiveDialog()
|
void BasicGUI_PlaneDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -431,7 +433,7 @@ double BasicGUI_PlaneDlg::getSize() const
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_PlaneDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_PlaneDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -503,7 +505,6 @@ bool BasicGUI_PlaneDlg::execute( ObjectList& objects )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_PlaneDlg::closeEvent( QCloseEvent* e )
|
void BasicGUI_PlaneDlg::closeEvent( QCloseEvent* e )
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::closeEvent( e );
|
GEOMBase_Skeleton::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BasicGUI_PlaneDlg.h
|
// File : BasicGUI_PlaneDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_PLANE_H
|
#ifndef DIALOGBOX_PLANE_H
|
||||||
#define DIALOGBOX_PLANE_H
|
#define DIALOGBOX_PLANE_H
|
||||||
@ -49,7 +48,8 @@ class BasicGUI_PlaneDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_PlaneDlg( GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BasicGUI_PlaneDlg( GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BasicGUI_PlaneDlg();
|
~BasicGUI_PlaneDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -65,8 +65,6 @@ private :
|
|||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
double getSize() const;
|
double getSize() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint, myDir, myPoint1, myPoint2, myPoint3, myFace;
|
GEOM::GEOM_Object_var myPoint, myDir, myPoint1, myPoint2, myPoint3, myFace;
|
||||||
|
|
||||||
DlgRef_2Sel1Spin* GroupPntDir;
|
DlgRef_2Sel1Spin* GroupPntDir;
|
||||||
|
@ -57,8 +57,9 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_PointDlg::BasicGUI_PointDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
BasicGUI_PointDlg::BasicGUI_PointDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, fl ), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, fl )
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_POINT")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_POINT")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_POINT_EDGE")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_POINT_EDGE")));
|
||||||
@ -128,10 +129,10 @@ BasicGUI_PointDlg::BasicGUI_PointDlg(GeometryGUI* theGeometryGUI, QWidget* paren
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=======================================================================
|
//=================================================================================
|
||||||
// function : ~BasicGUI_PointDlg()
|
// function : ~BasicGUI_PointDlg()
|
||||||
// purpose : Destructor
|
// purpose : Destructor
|
||||||
//=======================================================================
|
//=================================================================================
|
||||||
BasicGUI_PointDlg::~BasicGUI_PointDlg()
|
BasicGUI_PointDlg::~BasicGUI_PointDlg()
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
@ -151,8 +152,6 @@ void BasicGUI_PointDlg::Init()
|
|||||||
|
|
||||||
myEditCurrentArgument = 0;
|
myEditCurrentArgument = 0;
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
|
||||||
|
|
||||||
/* Get setting of step value from file configuration */
|
/* Get setting of step value from file configuration */
|
||||||
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
|
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
|
||||||
double step = resMgr->doubleValue( "Geometry", "SettingsGeomStep", 100);
|
double step = resMgr->doubleValue( "Geometry", "SettingsGeomStep", 100);
|
||||||
@ -178,8 +177,8 @@ void BasicGUI_PointDlg::Init()
|
|||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -196,13 +195,13 @@ void BasicGUI_PointDlg::Init()
|
|||||||
connect(GroupRefPoint->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupRefPoint->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
connect(GroupRefPoint->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupRefPoint->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupOnCurve->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupOnCurve->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupXYZ->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupXYZ->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupXYZ->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupXYZ->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupXYZ->SpinBox_DZ, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupXYZ->SpinBox_DZ, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupRefPoint->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupRefPoint->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupRefPoint->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupRefPoint->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupRefPoint->SpinBox_DZ, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupRefPoint->SpinBox_DZ, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
@ -305,10 +304,10 @@ bool BasicGUI_PointDlg::ClickOnApply()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=======================================================================
|
//=================================================================================
|
||||||
// function : ClickOnCancel()
|
// function : ClickOnCancel()
|
||||||
// purpose :
|
// purpose :
|
||||||
//=======================================================================
|
//=================================================================================
|
||||||
void BasicGUI_PointDlg::ClickOnCancel()
|
void BasicGUI_PointDlg::ClickOnCancel()
|
||||||
{
|
{
|
||||||
GEOMBase_Skeleton::ClickOnCancel();
|
GEOMBase_Skeleton::ClickOnCancel();
|
||||||
@ -342,15 +341,17 @@ void BasicGUI_PointDlg::SelectionIntoArgument()
|
|||||||
if ( id == 0 )
|
if ( id == 0 )
|
||||||
{
|
{
|
||||||
// get CORBA reference to data object
|
// get CORBA reference to data object
|
||||||
TopoDS_Shape aShape = myGeometryGUI->GetShapeReader().GetShape( myGeometryGUI->GetGeomGen(), aSelectedObject );
|
TopoDS_Shape aShape = myGeomGUI->GetShapeReader().GetShape
|
||||||
|
( myGeomGUI->GetGeomGen(), aSelectedObject );
|
||||||
if ( aShape.IsNull() )
|
if ( aShape.IsNull() )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if ( aShape.ShapeType() != TopAbs_VERTEX )
|
if ( aShape.ShapeType() != TopAbs_VERTEX )
|
||||||
{
|
{
|
||||||
TColStd_IndexedMapOfInteger aMap;
|
TColStd_IndexedMapOfInteger aMap;
|
||||||
|
LightApp_Application* anApp =
|
||||||
((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr()->GetIndexes( anIO, aMap );
|
(LightApp_Application*)(SUIT_Session::session()->activeApplication());
|
||||||
|
anApp->selectionMgr()->GetIndexes( anIO, aMap );
|
||||||
|
|
||||||
if ( aMap.Extent() == 1 )
|
if ( aMap.Extent() == 1 )
|
||||||
{
|
{
|
||||||
@ -446,7 +447,7 @@ void BasicGUI_PointDlg::enterEvent(QEvent* e)
|
|||||||
void BasicGUI_PointDlg::ActivateThisDialog( )
|
void BasicGUI_PointDlg::ActivateThisDialog( )
|
||||||
{
|
{
|
||||||
GEOMBase_Skeleton::ActivateThisDialog();
|
GEOMBase_Skeleton::ActivateThisDialog();
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
ConstructorsClicked( getConstructorId() );
|
ConstructorsClicked( getConstructorId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -457,7 +458,7 @@ void BasicGUI_PointDlg::ActivateThisDialog( )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_PointDlg::DeactivateActiveDialog()
|
void BasicGUI_PointDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -471,10 +472,10 @@ void BasicGUI_PointDlg::ValueChangedInSpinBox(double newValue)
|
|||||||
displayPreview();
|
displayPreview();
|
||||||
}
|
}
|
||||||
|
|
||||||
//=======================================================================
|
//=================================================================================
|
||||||
// funcion : getParameter()
|
// funcion : getParameter()
|
||||||
// purpose :
|
// purpose :
|
||||||
//=======================================================================
|
//=================================================================================
|
||||||
double BasicGUI_PointDlg::getParameter() const
|
double BasicGUI_PointDlg::getParameter() const
|
||||||
{
|
{
|
||||||
return GroupOnCurve->SpinBox_DX->GetValue();
|
return GroupOnCurve->SpinBox_DX->GetValue();
|
||||||
@ -502,7 +503,7 @@ void BasicGUI_PointDlg::OnPointSelected( const gp_Pnt& thePnt )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_PointDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_PointDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -549,12 +550,14 @@ bool BasicGUI_PointDlg::execute( ObjectList& objects )
|
|||||||
double dy = GroupRefPoint->SpinBox_DY->GetValue();
|
double dy = GroupRefPoint->SpinBox_DY->GetValue();
|
||||||
double dz = GroupRefPoint->SpinBox_DZ->GetValue();
|
double dz = GroupRefPoint->SpinBox_DZ->GetValue();
|
||||||
|
|
||||||
anObj = GEOM::GEOM_IBasicOperations::_narrow( getOperation() )->MakePointWithReference( myRefPoint, dx, dy, dz );
|
anObj = GEOM::GEOM_IBasicOperations::_narrow( getOperation() )->
|
||||||
|
MakePointWithReference( myRefPoint, dx, dy, dz );
|
||||||
res = true;
|
res = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case 2 :
|
case 2 :
|
||||||
anObj = GEOM::GEOM_IBasicOperations::_narrow( getOperation() )->MakePointOnCurve( myEdge, getParameter() );
|
anObj = GEOM::GEOM_IBasicOperations::_narrow( getOperation() )->
|
||||||
|
MakePointOnCurve( myEdge, getParameter() );
|
||||||
res = true;
|
res = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -592,6 +595,5 @@ bool BasicGUI_PointDlg::execute( ObjectList& objects )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_PointDlg::closeEvent( QCloseEvent* e )
|
void BasicGUI_PointDlg::closeEvent( QCloseEvent* e )
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::closeEvent( e );
|
GEOMBase_Skeleton::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BasicGUI_PointDlg.h
|
// File : BasicGUI_PointDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_POINT_H
|
#ifndef DIALOGBOX_POINT_H
|
||||||
#define DIALOGBOX_POINT_H
|
#define DIALOGBOX_POINT_H
|
||||||
@ -51,7 +50,8 @@ class BasicGUI_PointDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_PointDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BasicGUI_PointDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
|
|
||||||
~BasicGUI_PointDlg();
|
~BasicGUI_PointDlg();
|
||||||
|
|
||||||
@ -71,8 +71,6 @@ private :
|
|||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
double getParameter() const;
|
double getParameter() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myEdge;
|
GEOM::GEOM_Object_var myEdge;
|
||||||
GEOM::GEOM_Object_var myRefPoint;
|
GEOM::GEOM_Object_var myRefPoint;
|
||||||
|
|
||||||
|
@ -48,8 +48,9 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_VectorDlg::BasicGUI_VectorDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
BasicGUI_VectorDlg::BasicGUI_VectorDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, fl ), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, fl)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_VECTOR_2P")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_VECTOR_2P")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_VECTOR_DXYZ")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_VECTOR_DXYZ")));
|
||||||
@ -130,8 +131,8 @@ void BasicGUI_VectorDlg::Init()
|
|||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -147,9 +148,9 @@ void BasicGUI_VectorDlg::Init()
|
|||||||
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
connect(GroupDimensions->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupDimensions->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DZ, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DZ, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(GroupDimensions->CheckBox1, SIGNAL(stateChanged(int)), this, SLOT(ReverseVector(int)));
|
connect(GroupDimensions->CheckBox1, SIGNAL(stateChanged(int)), this, SLOT(ReverseVector(int)));
|
||||||
|
|
||||||
@ -325,7 +326,7 @@ void BasicGUI_VectorDlg::ActivateThisDialog()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_VectorDlg::DeactivateActiveDialog()
|
void BasicGUI_VectorDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -371,7 +372,7 @@ void BasicGUI_VectorDlg::ReverseVector(int state)
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOM::GEOM_IOperations_ptr BasicGUI_VectorDlg::createOperation()
|
GEOM::GEOM_IOperations_ptr BasicGUI_VectorDlg::createOperation()
|
||||||
{
|
{
|
||||||
return myGeometryGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
return myGeomGUI->GetGeomGen()->GetIBasicOperations( getStudyId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BasicGUI_VectorDlg.h
|
// File : BasicGUI_VectorDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_VECTOR_H
|
#ifndef DIALOGBOX_VECTOR_H
|
||||||
#define DIALOGBOX_VECTOR_H
|
#define DIALOGBOX_VECTOR_H
|
||||||
@ -34,13 +33,13 @@
|
|||||||
#include "DlgRef_3Spin1Check.h"
|
#include "DlgRef_3Spin1Check.h"
|
||||||
|
|
||||||
#include "BasicGUI.h"
|
#include "BasicGUI.h"
|
||||||
//#include "GEOM_ShapeTypeFilter.hxx"
|
|
||||||
|
|
||||||
#if defined WNT && defined WIN32 && defined SALOME_WNT_EXPORTS
|
#if defined WNT && defined WIN32 && defined SALOME_WNT_EXPORTS
|
||||||
#define BASICGUI_WNT_EXPORT __declspec( dllexport )
|
#define BASICGUI_WNT_EXPORT __declspec( dllexport )
|
||||||
#else
|
#else
|
||||||
#define BASICGUI_WNT_EXPORT
|
#define BASICGUI_WNT_EXPORT
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// class : BasicGUI_VectorDlg
|
// class : BasicGUI_VectorDlg
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -50,7 +49,8 @@ class BasicGUI_VectorDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_VectorDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BasicGUI_VectorDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BasicGUI_VectorDlg();
|
~BasicGUI_VectorDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -63,8 +63,6 @@ private :
|
|||||||
void Init();
|
void Init();
|
||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint1;
|
GEOM::GEOM_Object_var myPoint1;
|
||||||
GEOM::GEOM_Object_var myPoint2;
|
GEOM::GEOM_Object_var myPoint2;
|
||||||
|
|
||||||
|
@ -61,8 +61,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BasicGUI_WorkingPlaneDlg::BasicGUI_WorkingPlaneDlg(GeometryGUI* theGeometryGUI , QWidget* parent, const char* name, bool modal, WFlags fl)
|
BasicGUI_WorkingPlaneDlg::BasicGUI_WorkingPlaneDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_WPLANE_FACE")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_WPLANE_FACE")));
|
||||||
@ -124,9 +126,9 @@ void BasicGUI_WorkingPlaneDlg::Init()
|
|||||||
{
|
{
|
||||||
/* init variables */
|
/* init variables */
|
||||||
myEditCurrentArgument = Group1->LineEdit1;
|
myEditCurrentArgument = Group1->LineEdit1;
|
||||||
myWPlane = myGeometryGUI->GetWorkingPlane();
|
myWPlane = myGeomGUI->GetWorkingPlane();
|
||||||
|
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
myFace = GEOM::GEOM_Object::_nil();
|
myFace = GEOM::GEOM_Object::_nil();
|
||||||
myVectX = GEOM::GEOM_Object::_nil();
|
myVectX = GEOM::GEOM_Object::_nil();
|
||||||
@ -139,8 +141,8 @@ void BasicGUI_WorkingPlaneDlg::Init()
|
|||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
||||||
connect(GroupConstructors, SIGNAL(clicked(int)), this, SLOT(ConstructorsClicked(int)));
|
connect(GroupConstructors, SIGNAL(clicked(int)), this, SLOT(ConstructorsClicked(int)));
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
@ -170,7 +172,7 @@ void BasicGUI_WorkingPlaneDlg::Init()
|
|||||||
void BasicGUI_WorkingPlaneDlg::ConstructorsClicked(int constructorId)
|
void BasicGUI_WorkingPlaneDlg::ConstructorsClicked(int constructorId)
|
||||||
{
|
{
|
||||||
disconnect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(), 0, this, 0);
|
disconnect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(), 0, this, 0);
|
||||||
// myGeometryGUI->SetState( 0 );
|
// myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
switch (constructorId)
|
switch (constructorId)
|
||||||
{
|
{
|
||||||
@ -251,7 +253,7 @@ void BasicGUI_WorkingPlaneDlg::ClickOnOk()
|
|||||||
bool BasicGUI_WorkingPlaneDlg::ClickOnApply()
|
bool BasicGUI_WorkingPlaneDlg::ClickOnApply()
|
||||||
{
|
{
|
||||||
buttonApply->setFocus();
|
buttonApply->setFocus();
|
||||||
myGeometryGUI->application()->putInfo(tr(""));
|
myGeomGUI->application()->putInfo(tr(""));
|
||||||
const int id = getConstructorId();
|
const int id = getConstructorId();
|
||||||
|
|
||||||
if (id == 0) {
|
if (id == 0) {
|
||||||
@ -264,8 +266,8 @@ bool BasicGUI_WorkingPlaneDlg::ClickOnApply()
|
|||||||
gp_Pln aPln = aGPlane->Pln();
|
gp_Pln aPln = aGPlane->Pln();
|
||||||
|
|
||||||
myWPlane = aPln.Position();
|
myWPlane = aPln.Position();
|
||||||
myGeometryGUI->SetWorkingPlane(myWPlane);
|
myGeomGUI->SetWorkingPlane(myWPlane);
|
||||||
myGeometryGUI->ActiveWorkingPlane();
|
myGeomGUI->ActiveWorkingPlane();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -307,8 +309,8 @@ bool BasicGUI_WorkingPlaneDlg::ClickOnApply()
|
|||||||
|
|
||||||
myWPlane = gp_Ax3(BRep_Tool::Pnt(V1), aDirZ, aDirX);
|
myWPlane = gp_Ax3(BRep_Tool::Pnt(V1), aDirZ, aDirX);
|
||||||
|
|
||||||
myGeometryGUI->SetWorkingPlane(myWPlane);
|
myGeomGUI->SetWorkingPlane(myWPlane);
|
||||||
myGeometryGUI->ActiveWorkingPlane();
|
myGeomGUI->ActiveWorkingPlane();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
} else if (id == 2) {
|
} else if (id == 2) {
|
||||||
@ -330,8 +332,8 @@ bool BasicGUI_WorkingPlaneDlg::ClickOnApply()
|
|||||||
|
|
||||||
myWPlane = gp_Ax3(P1, aDirZ, aDirX);
|
myWPlane = gp_Ax3(P1, aDirZ, aDirX);
|
||||||
|
|
||||||
myGeometryGUI->SetWorkingPlane(myWPlane);
|
myGeomGUI->SetWorkingPlane(myWPlane);
|
||||||
myGeometryGUI->ActiveWorkingPlane();
|
myGeomGUI->ActiveWorkingPlane();
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
return false;
|
return false;
|
||||||
@ -436,7 +438,7 @@ void BasicGUI_WorkingPlaneDlg::ActivateThisDialog( )
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_WorkingPlaneDlg::DeactivateActiveDialog()
|
void BasicGUI_WorkingPlaneDlg::DeactivateActiveDialog()
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
// myGeomGUI->SetState( -1 );
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
GEOMBase_Skeleton::DeactivateActiveDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -465,6 +467,5 @@ void BasicGUI_WorkingPlaneDlg::enterEvent(QEvent* e)
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void BasicGUI_WorkingPlaneDlg::closeEvent( QCloseEvent* e )
|
void BasicGUI_WorkingPlaneDlg::closeEvent( QCloseEvent* e )
|
||||||
{
|
{
|
||||||
// myGeometryGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::closeEvent( e );
|
GEOMBase_Skeleton::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
@ -38,6 +38,7 @@
|
|||||||
#else
|
#else
|
||||||
#define BASICGUI_WNT_EXPORT
|
#define BASICGUI_WNT_EXPORT
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// class : BasicGUI_WorkingPlaneDlg
|
// class : BasicGUI_WorkingPlaneDlg
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -47,7 +48,8 @@ class BASICGUI_WNT_EXPORT BasicGUI_WorkingPlaneDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BasicGUI_WorkingPlaneDlg( GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0 );
|
BasicGUI_WorkingPlaneDlg( GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0 );
|
||||||
~BasicGUI_WorkingPlaneDlg();
|
~BasicGUI_WorkingPlaneDlg();
|
||||||
virtual void closeEvent( QCloseEvent* e );
|
virtual void closeEvent( QCloseEvent* e );
|
||||||
|
|
||||||
@ -55,8 +57,6 @@ private:
|
|||||||
void Init();
|
void Init();
|
||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myFace;
|
GEOM::GEOM_Object_var myFace;
|
||||||
GEOM::GEOM_Object_var myVectX;
|
GEOM::GEOM_Object_var myVectX;
|
||||||
GEOM::GEOM_Object_var myVectZ;
|
GEOM::GEOM_Object_var myVectZ;
|
||||||
|
@ -30,7 +30,6 @@
|
|||||||
#include "BlocksGUI_QuadFaceDlg.h"
|
#include "BlocksGUI_QuadFaceDlg.h"
|
||||||
#include "BlocksGUI_BlockDlg.h"
|
#include "BlocksGUI_BlockDlg.h"
|
||||||
#include "BlocksGUI_TrsfDlg.h"
|
#include "BlocksGUI_TrsfDlg.h"
|
||||||
//#include "BlocksGUI_CheckMultiBlockDlg.h"
|
|
||||||
#include "BlocksGUI_ExplodeDlg.h"
|
#include "BlocksGUI_ExplodeDlg.h"
|
||||||
#include "BlocksGUI_PropagateDlg.h"
|
#include "BlocksGUI_PropagateDlg.h"
|
||||||
|
|
||||||
@ -40,6 +39,8 @@
|
|||||||
#include "SUIT_MessageBox.h"
|
#include "SUIT_MessageBox.h"
|
||||||
#include "SUIT_Session.h"
|
#include "SUIT_Session.h"
|
||||||
|
|
||||||
|
#include "SalomeApp_Application.h"
|
||||||
|
|
||||||
BlocksGUI* BlocksGUI::myGUIObject = 0;
|
BlocksGUI* BlocksGUI::myGUIObject = 0;
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
@ -83,35 +84,13 @@ bool BlocksGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
|
|
||||||
switch (theCommandID)
|
switch (theCommandID)
|
||||||
{
|
{
|
||||||
case 9999:
|
case 9999: aDlg = new BlocksGUI_BlockDlg (getGeometryGUI(), parent); break;
|
||||||
aDlg = new BlocksGUI_BlockDlg (parent);
|
case 9998: aDlg = new BlocksGUI_TrsfDlg (getGeometryGUI(), parent); break;
|
||||||
break;
|
case 9997: aDlg = new BlocksGUI_QuadFaceDlg (getGeometryGUI(), parent); break;
|
||||||
|
case 9995: aDlg = new BlocksGUI_ExplodeDlg (getGeometryGUI(), parent); break;
|
||||||
case 9998:
|
case 99991: aDlg = new BlocksGUI_PropagateDlg (getGeometryGUI(), parent); break;
|
||||||
aDlg = new BlocksGUI_TrsfDlg (parent);
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 9997:
|
|
||||||
aDlg = new BlocksGUI_QuadFaceDlg (parent);
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 9996:
|
|
||||||
// aDlg = new BlocksGUI_CheckMultiBlockDlg (parent, Sel);
|
|
||||||
SUIT_MessageBox::warn1 (parent,
|
|
||||||
QObject::tr("WRN_WARNING"),
|
|
||||||
QObject::tr("WRN_NOT_IMPLEMENTED"),
|
|
||||||
QObject::tr("BUT_OK"));
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 9995:
|
|
||||||
aDlg = new BlocksGUI_ExplodeDlg (parent);
|
|
||||||
break;
|
|
||||||
case 99991:
|
|
||||||
aDlg = new BlocksGUI_PropagateDlg (parent, "");
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
default:
|
||||||
SUIT_Session::session()->activeApplication()->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
getGeometryGUI()->getApp()->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -41,9 +41,8 @@ using namespace std;
|
|||||||
// class : BlocksGUI_BlockDlg()
|
// class : BlocksGUI_BlockDlg()
|
||||||
// purpose : Constructs a BlocksGUI_BlockDlg which is a child of 'parent'.
|
// purpose : Constructs a BlocksGUI_BlockDlg which is a child of 'parent'.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BlocksGUI_BlockDlg::BlocksGUI_BlockDlg (QWidget* parent,
|
BlocksGUI_BlockDlg::BlocksGUI_BlockDlg (GeometryGUI* theGeometryGUI, QWidget* parent, bool modal)
|
||||||
bool modal)
|
: GEOMBase_Skeleton(theGeometryGUI, parent, "BlockDlg", modal,
|
||||||
: GEOMBase_Skeleton(parent, "BlockDlg", modal,
|
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BLOCK_2F")));
|
QPixmap image0 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BLOCK_2F")));
|
||||||
@ -329,15 +328,6 @@ void BlocksGUI_BlockDlg::enterEvent (QEvent* e)
|
|||||||
ActivateThisDialog();
|
ActivateThisDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : DeactivateActiveDialog()
|
|
||||||
// purpose : public slot to deactivate if active
|
|
||||||
//=================================================================================
|
|
||||||
//void BlocksGUI_BlockDlg::DeactivateActiveDialog()
|
|
||||||
//{
|
|
||||||
// GEOMBase_Skeleton::DeactivateActiveDialog();
|
|
||||||
//}
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : createOperation
|
// function : createOperation
|
||||||
// purpose :
|
// purpose :
|
||||||
|
@ -23,7 +23,6 @@
|
|||||||
// File : BlocksGUI_BlockDlg.h
|
// File : BlocksGUI_BlockDlg.h
|
||||||
// Author : Julia DOROVSKIKH
|
// Author : Julia DOROVSKIKH
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_BLOCK_H
|
#ifndef DIALOGBOX_BLOCK_H
|
||||||
#define DIALOGBOX_BLOCK_H
|
#define DIALOGBOX_BLOCK_H
|
||||||
@ -42,7 +41,7 @@ class BlocksGUI_BlockDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BlocksGUI_BlockDlg (QWidget* parent,
|
BlocksGUI_BlockDlg (GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
bool modal = FALSE);
|
bool modal = FALSE);
|
||||||
~BlocksGUI_BlockDlg();
|
~BlocksGUI_BlockDlg();
|
||||||
|
|
||||||
@ -69,7 +68,6 @@ private slots:
|
|||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
// void DeactivateActiveDialog();
|
|
||||||
void ConstructorsClicked (int constructorId);
|
void ConstructorsClicked (int constructorId);
|
||||||
|
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
|
@ -50,9 +50,8 @@
|
|||||||
// class : BlocksGUI_ExplodeDlg()
|
// class : BlocksGUI_ExplodeDlg()
|
||||||
// purpose : Constructs a BlocksGUI_ExplodeDlg which is a child of 'parent'.
|
// purpose : Constructs a BlocksGUI_ExplodeDlg which is a child of 'parent'.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BlocksGUI_ExplodeDlg::BlocksGUI_ExplodeDlg (QWidget* parent,
|
BlocksGUI_ExplodeDlg::BlocksGUI_ExplodeDlg (GeometryGUI* theGeometryGUI, QWidget* parent, bool modal)
|
||||||
bool modal)
|
: GEOMBase_Skeleton(theGeometryGUI, parent, "ExplodeDlg", modal,
|
||||||
: GEOMBase_Skeleton(parent, "ExplodeDlg", modal,
|
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image1 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BLOCK_EXPLODE")));
|
QPixmap image1 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BLOCK_EXPLODE")));
|
||||||
|
@ -23,7 +23,6 @@
|
|||||||
// File : BlocksGUI_ExplodeDlg.h
|
// File : BlocksGUI_ExplodeDlg.h
|
||||||
// Author : Julia DOROVSKIKH
|
// Author : Julia DOROVSKIKH
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_BLOCK_EXPLODE_H
|
#ifndef DIALOGBOX_BLOCK_EXPLODE_H
|
||||||
#define DIALOGBOX_BLOCK_EXPLODE_H
|
#define DIALOGBOX_BLOCK_EXPLODE_H
|
||||||
@ -43,8 +42,7 @@ class BlocksGUI_ExplodeDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BlocksGUI_ExplodeDlg (QWidget* parent,
|
BlocksGUI_ExplodeDlg (GeometryGUI*, QWidget* parent, bool modal = FALSE);
|
||||||
bool modal = FALSE);
|
|
||||||
~BlocksGUI_ExplodeDlg();
|
~BlocksGUI_ExplodeDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
@ -46,8 +46,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BlocksGUI_PropagateDlg::BlocksGUI_PropagateDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
BlocksGUI_PropagateDlg::BlocksGUI_PropagateDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PROPAGATE")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PROPAGATE")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
@ -80,7 +82,6 @@ BlocksGUI_PropagateDlg::BlocksGUI_PropagateDlg(QWidget* parent, const char* name
|
|||||||
Init();
|
Init();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ~BlocksGUI_PropagateDlg()
|
// function : ~BlocksGUI_PropagateDlg()
|
||||||
// purpose : Destroys the object and frees any allocated resources
|
// purpose : Destroys the object and frees any allocated resources
|
||||||
@ -89,7 +90,6 @@ BlocksGUI_PropagateDlg::~BlocksGUI_PropagateDlg()
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : Init()
|
// function : Init()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -104,10 +104,6 @@ void BlocksGUI_PropagateDlg::Init()
|
|||||||
//myGeomGUI->SetState( 0 );
|
//myGeomGUI->SetState( 0 );
|
||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
|
||||||
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
|
||||||
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
|
|
||||||
@ -128,8 +124,6 @@ void BlocksGUI_PropagateDlg::ClickOnOk()
|
|||||||
ClickOnCancel();
|
ClickOnCancel();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ClickOnApply()
|
// function : ClickOnApply()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -150,16 +144,6 @@ bool BlocksGUI_PropagateDlg::ClickOnApply()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : ClickOnCancel()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
void BlocksGUI_PropagateDlg::ClickOnCancel()
|
|
||||||
{
|
|
||||||
GEOMBase_Skeleton::ClickOnCancel();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : SelectionIntoArgument()
|
// function : SelectionIntoArgument()
|
||||||
// purpose : Called when selection
|
// purpose : Called when selection
|
||||||
@ -205,17 +189,6 @@ void BlocksGUI_PropagateDlg::LineEditReturnPressed()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : DeactivateActiveDialog()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
void BlocksGUI_PropagateDlg::DeactivateActiveDialog()
|
|
||||||
{
|
|
||||||
//myGeomGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ActivateThisDialog()
|
// function : ActivateThisDialog()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -318,4 +291,3 @@ GEOM::GEOM_Object_ptr BlocksGUI_PropagateDlg::getFather (GEOM::GEOM_Object_ptr)
|
|||||||
{
|
{
|
||||||
return myObject;
|
return myObject;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BlocksGUI_PropagateDlg.h
|
// File : BlocksGUI_PropagateDlg.h
|
||||||
// Author : VKN
|
// Author : VKN
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_BlocksGUI_PropagateDlg_H
|
#ifndef DIALOGBOX_BlocksGUI_PropagateDlg_H
|
||||||
#define DIALOGBOX_BlocksGUI_PropagateDlg_H
|
#define DIALOGBOX_BlocksGUI_PropagateDlg_H
|
||||||
@ -41,7 +40,8 @@ class BlocksGUI_PropagateDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BlocksGUI_PropagateDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BlocksGUI_PropagateDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = "", bool modal = FALSE, WFlags fl = 0);
|
||||||
~BlocksGUI_PropagateDlg();
|
~BlocksGUI_PropagateDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -54,10 +54,8 @@ protected:
|
|||||||
private slots:
|
private slots:
|
||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ClickOnCancel();
|
|
||||||
|
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void DeactivateActiveDialog();
|
|
||||||
|
|
||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
@ -70,11 +68,9 @@ private :
|
|||||||
void activateSelection();
|
void activateSelection();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myObject;
|
GEOM::GEOM_Object_var myObject;
|
||||||
QPushButton* mySelBtn;
|
QPushButton* mySelBtn;
|
||||||
QLineEdit* mySelName;
|
QLineEdit* mySelName;
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_BlocksGUI_PropagateDlg_H
|
#endif // DIALOGBOX_BlocksGUI_PropagateDlg_H
|
||||||
|
@ -32,23 +32,21 @@
|
|||||||
#include "SalomeApp_Application.h"
|
#include "SalomeApp_Application.h"
|
||||||
#include "LightApp_SelectionMgr.h"
|
#include "LightApp_SelectionMgr.h"
|
||||||
|
|
||||||
//using namespace std;
|
|
||||||
|
|
||||||
#include <qlabel.h>
|
#include <qlabel.h>
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// class : BlocksGUI_QuadFaceDlg()
|
// class : BlocksGUI_QuadFaceDlg()
|
||||||
// purpose : Constructs a BlocksGUI_QuadFaceDlg which is a child of 'parent'.
|
// purpose : Constructs a BlocksGUI_QuadFaceDlg which is a child of 'parent'.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BlocksGUI_QuadFaceDlg::BlocksGUI_QuadFaceDlg (QWidget* parent,
|
BlocksGUI_QuadFaceDlg::BlocksGUI_QuadFaceDlg (GeometryGUI* theGeometryGUI, QWidget* parent, bool modal)
|
||||||
bool modal)
|
: GEOMBase_Skeleton(theGeometryGUI, parent, "QuadFaceDlg", modal,
|
||||||
: GEOMBase_Skeleton(parent, "QuadFaceDlg", modal,
|
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image1 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_QUAD_FACE_4_VERT")));
|
SUIT_ResourceMgr* aResMgr = myGeomGUI->getApp()->resourceMgr();
|
||||||
QPixmap image2 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_QUAD_FACE_2_EDGE")));
|
QPixmap image1 (aResMgr->loadPixmap("GEOM",tr("ICON_DLG_QUAD_FACE_4_VERT")));
|
||||||
QPixmap image3 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_QUAD_FACE_4_EDGE")));
|
QPixmap image2 (aResMgr->loadPixmap("GEOM",tr("ICON_DLG_QUAD_FACE_2_EDGE")));
|
||||||
QPixmap imageS (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image3 (aResMgr->loadPixmap("GEOM",tr("ICON_DLG_QUAD_FACE_4_EDGE")));
|
||||||
|
QPixmap imageS (aResMgr->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
|
|
||||||
setCaption(tr("GEOM_QUAD_FACE_TITLE"));
|
setCaption(tr("GEOM_QUAD_FACE_TITLE"));
|
||||||
|
|
||||||
|
@ -23,7 +23,6 @@
|
|||||||
// File : BlocksGUI_QuadFaceDlg.h
|
// File : BlocksGUI_QuadFaceDlg.h
|
||||||
// Author : Julia DOROVSKIKH
|
// Author : Julia DOROVSKIKH
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_QUAD_FACE_H
|
#ifndef DIALOGBOX_QUAD_FACE_H
|
||||||
#define DIALOGBOX_QUAD_FACE_H
|
#define DIALOGBOX_QUAD_FACE_H
|
||||||
@ -43,8 +42,7 @@ class BlocksGUI_QuadFaceDlg : public GEOMBase_Skeleton
|
|||||||
Edge14, Edge24, Edge34, Edge44 };
|
Edge14, Edge24, Edge34, Edge44 };
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BlocksGUI_QuadFaceDlg (QWidget* parent,
|
BlocksGUI_QuadFaceDlg (GeometryGUI*, QWidget* parent, bool modal = FALSE);
|
||||||
bool modal = FALSE);
|
|
||||||
~BlocksGUI_QuadFaceDlg();
|
~BlocksGUI_QuadFaceDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -79,7 +77,6 @@ private slots:
|
|||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
// void DeactivateActiveDialog();
|
|
||||||
void ConstructorsClicked( int constructorId );
|
void ConstructorsClicked( int constructorId );
|
||||||
|
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
|
@ -42,14 +42,14 @@
|
|||||||
// class : BlocksGUI_TrsfDlg()
|
// class : BlocksGUI_TrsfDlg()
|
||||||
// purpose : Constructs a BlocksGUI_TrsfDlg which is a child of 'parent'.
|
// purpose : Constructs a BlocksGUI_TrsfDlg which is a child of 'parent'.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BlocksGUI_TrsfDlg::BlocksGUI_TrsfDlg (QWidget* parent,
|
BlocksGUI_TrsfDlg::BlocksGUI_TrsfDlg (GeometryGUI* theGeometryGUI, QWidget* parent, bool modal)
|
||||||
bool modal)
|
: GEOMBase_Skeleton(theGeometryGUI, parent, "TrsfDlg", modal,
|
||||||
: GEOMBase_Skeleton(parent, "TrsfDlg", modal,
|
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image1 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BLOCK_MULTITRSF_SIMPLE")));
|
SUIT_ResourceMgr* aResMgr = myGeomGUI->getApp()->resourceMgr();
|
||||||
QPixmap image2 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BLOCK_MULTITRSF_DOUBLE")));
|
QPixmap image1 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_BLOCK_MULTITRSF_SIMPLE")));
|
||||||
QPixmap imageS (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image2 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_BLOCK_MULTITRSF_DOUBLE")));
|
||||||
|
QPixmap imageS (aResMgr->loadPixmap("GEOM", tr("ICON_SELECT")));
|
||||||
|
|
||||||
setCaption(tr("GEOM_BLOCK_MULTITRSF_TITLE"));
|
setCaption(tr("GEOM_BLOCK_MULTITRSF_TITLE"));
|
||||||
|
|
||||||
@ -349,16 +349,6 @@ void BlocksGUI_TrsfDlg::enterEvent (QEvent* e)
|
|||||||
this->ActivateThisDialog();
|
this->ActivateThisDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : DeactivateActiveDialog()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
//void BlocksGUI_TrsfDlg::DeactivateActiveDialog()
|
|
||||||
//{
|
|
||||||
// // disconnect selection
|
|
||||||
// GEOMBase_Skeleton::DeactivateActiveDialog();
|
|
||||||
//}
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ValueChangedInSpinBox()
|
// function : ValueChangedInSpinBox()
|
||||||
// purpose :
|
// purpose :
|
||||||
|
@ -23,7 +23,6 @@
|
|||||||
// File : BlocksGUI_TrsfDlg.h
|
// File : BlocksGUI_TrsfDlg.h
|
||||||
// Author : Julia DOROVSKIKH
|
// Author : Julia DOROVSKIKH
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_BLOCK_MULTITRSF_H
|
#ifndef DIALOGBOX_BLOCK_MULTITRSF_H
|
||||||
#define DIALOGBOX_BLOCK_MULTITRSF_H
|
#define DIALOGBOX_BLOCK_MULTITRSF_H
|
||||||
@ -44,8 +43,7 @@ class BlocksGUI_TrsfDlg : public GEOMBase_Skeleton
|
|||||||
enum { SpinBox1, SpinBox2U, SpinBox2V };
|
enum { SpinBox1, SpinBox2U, SpinBox2V };
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BlocksGUI_TrsfDlg (QWidget* parent,
|
BlocksGUI_TrsfDlg (GeometryGUI*, QWidget* parent, bool modal = FALSE);
|
||||||
bool modal = FALSE);
|
|
||||||
~BlocksGUI_TrsfDlg();
|
~BlocksGUI_TrsfDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -79,7 +77,6 @@ private slots:
|
|||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
// void DeactivateActiveDialog();
|
|
||||||
void ConstructorsClicked (int constructorId);
|
void ConstructorsClicked (int constructorId);
|
||||||
|
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
|
@ -89,7 +89,7 @@ bool BooleanGUI::OnGUIEvent(int theCommandID, SUIT_Desktop* parent)
|
|||||||
else
|
else
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
QDialog* aDlg = new BooleanGUI_Dialog( anOperation, parent, "");
|
QDialog* aDlg = new BooleanGUI_Dialog( anOperation, getGeometryGUI(), parent, "");
|
||||||
aDlg->show();
|
aDlg->show();
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -45,8 +45,9 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BooleanGUI_Dialog::BooleanGUI_Dialog( const int theOperation, QWidget* parent, const char* name, bool modal, WFlags fl)
|
BooleanGUI_Dialog::BooleanGUI_Dialog( const int theOperation, GeometryGUI* theGeometryGUI,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, fl),
|
QWidget* parent, const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, fl),
|
||||||
myOperation( theOperation )
|
myOperation( theOperation )
|
||||||
{
|
{
|
||||||
QPixmap image0;
|
QPixmap image0;
|
||||||
@ -123,7 +124,6 @@ BooleanGUI_Dialog::~BooleanGUI_Dialog()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : Init()
|
// function : Init()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -220,7 +220,6 @@ void BooleanGUI_Dialog::SetEditCurrentArgument()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : LineEditReturnPressed()
|
// function : LineEditReturnPressed()
|
||||||
// purpose :
|
// purpose :
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BooleanGUI_Dialog.h
|
// File : BooleanGUI_Dialog.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef BooleanGUI_Dialog_H
|
#ifndef BooleanGUI_Dialog_H
|
||||||
#define BooleanGUI_Dialog_H
|
#define BooleanGUI_Dialog_H
|
||||||
@ -42,7 +41,8 @@ class BooleanGUI_Dialog : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BooleanGUI_Dialog( const int theOperation, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BooleanGUI_Dialog( const int theOperation, GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BooleanGUI_Dialog();
|
~BooleanGUI_Dialog();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -69,7 +69,6 @@ private slots:
|
|||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // BooleanGUI_Dialog_H
|
#endif // BooleanGUI_Dialog_H
|
||||||
|
@ -85,12 +85,12 @@ bool BuildGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
|
|
||||||
switch ( theCommandID )
|
switch ( theCommandID )
|
||||||
{
|
{
|
||||||
case 4081: aDlg = new BuildGUI_EdgeDlg ( parent, "" ); break;
|
case 4081: aDlg = new BuildGUI_EdgeDlg ( getGeometryGUI(), parent, "" ); break;
|
||||||
case 4082: aDlg = new BuildGUI_WireDlg ( parent, "" ); break;
|
case 4082: aDlg = new BuildGUI_WireDlg ( getGeometryGUI(), parent, "" ); break;
|
||||||
case 4083: aDlg = new BuildGUI_FaceDlg ( parent, "" ); break;
|
case 4083: aDlg = new BuildGUI_FaceDlg ( getGeometryGUI(), parent, "" ); break;
|
||||||
case 4084: aDlg = new BuildGUI_ShellDlg ( parent, "" ); break;
|
case 4084: aDlg = new BuildGUI_ShellDlg ( getGeometryGUI(), parent, "" ); break;
|
||||||
case 4085: aDlg = new BuildGUI_SolidDlg ( parent, "" ); break;
|
case 4085: aDlg = new BuildGUI_SolidDlg ( getGeometryGUI(), parent, "" ); break;
|
||||||
case 4086: aDlg = new BuildGUI_CompoundDlg( parent, "" ); break;
|
case 4086: aDlg = new BuildGUI_CompoundDlg( getGeometryGUI(), parent, "" ); break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
SUIT_Session::session()->activeApplication()->putInfo( tr( "GEOM_PRP_COMMAND" ).arg( theCommandID ) );
|
SUIT_Session::session()->activeApplication()->putInfo( tr( "GEOM_PRP_COMMAND" ).arg( theCommandID ) );
|
||||||
|
@ -42,8 +42,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BuildGUI_CompoundDlg::BuildGUI_CompoundDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
BuildGUI_CompoundDlg::BuildGUI_CompoundDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BUILD_COMPOUND")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BUILD_COMPOUND")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : GEOMBase_CompoundDlg.h
|
// File : GEOMBase_CompoundDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_COMPOUND_H
|
#ifndef DIALOGBOX_COMPOUND_H
|
||||||
#define DIALOGBOX_COMPOUND_H
|
#define DIALOGBOX_COMPOUND_H
|
||||||
@ -41,7 +40,8 @@ class BuildGUI_CompoundDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BuildGUI_CompoundDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BuildGUI_CompoundDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BuildGUI_CompoundDlg();
|
~BuildGUI_CompoundDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -65,7 +65,6 @@ private slots:
|
|||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_COMPOUND_H
|
#endif // DIALOGBOX_COMPOUND_H
|
||||||
|
@ -47,8 +47,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BuildGUI_EdgeDlg::BuildGUI_EdgeDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
BuildGUI_EdgeDlg::BuildGUI_EdgeDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BUILD_EDGE")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BUILD_EDGE")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BuildGUI_EdgeDlg.h
|
// File : BuildGUI_EdgeDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_EDGE_H
|
#ifndef DIALOGBOX_EDGE_H
|
||||||
#define DIALOGBOX_EDGE_H
|
#define DIALOGBOX_EDGE_H
|
||||||
@ -41,7 +40,8 @@ class BuildGUI_EdgeDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BuildGUI_EdgeDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BuildGUI_EdgeDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BuildGUI_EdgeDlg();
|
~BuildGUI_EdgeDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -67,7 +67,6 @@ private slots:
|
|||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_EDGE_H
|
#endif // DIALOGBOX_EDGE_H
|
||||||
|
@ -46,8 +46,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BuildGUI_FaceDlg::BuildGUI_FaceDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
BuildGUI_FaceDlg::BuildGUI_FaceDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BUILD_FACE")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BUILD_FACE")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BuildGUI_FaceDlg.h
|
// File : BuildGUI_FaceDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_FACE_H
|
#ifndef DIALOGBOX_FACE_H
|
||||||
#define DIALOGBOX_FACE_H
|
#define DIALOGBOX_FACE_H
|
||||||
@ -41,7 +40,8 @@ class BuildGUI_FaceDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BuildGUI_FaceDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BuildGUI_FaceDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BuildGUI_FaceDlg();
|
~BuildGUI_FaceDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -64,7 +64,6 @@ private slots:
|
|||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_FACE_H
|
#endif // DIALOGBOX_FACE_H
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
// File : BuildGUI_ShellDlg.cxx
|
// File : BuildGUI_ShellDlg.cxx
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header:
|
// $Header$
|
||||||
|
|
||||||
#include "BuildGUI_ShellDlg.h"
|
#include "BuildGUI_ShellDlg.h"
|
||||||
#include "GEOMImpl_Types.hxx"
|
#include "GEOMImpl_Types.hxx"
|
||||||
@ -44,8 +44,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BuildGUI_ShellDlg::BuildGUI_ShellDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
BuildGUI_ShellDlg::BuildGUI_ShellDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BUILD_SHELL")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BUILD_SHELL")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_SELECT")));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BuildGUI_ShellDlg.h
|
// File : BuildGUI_ShellDlg.h
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header:
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_SHELL_H
|
#ifndef DIALOGBOX_SHELL_H
|
||||||
#define DIALOGBOX_SHELL_H
|
#define DIALOGBOX_SHELL_H
|
||||||
@ -41,7 +40,8 @@ class BuildGUI_ShellDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BuildGUI_ShellDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BuildGUI_ShellDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BuildGUI_ShellDlg();
|
~BuildGUI_ShellDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -65,7 +65,6 @@ private slots:
|
|||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_SHELL_H
|
#endif // DIALOGBOX_SHELL_H
|
||||||
|
@ -24,7 +24,7 @@
|
|||||||
// File : BuildGUI_SolidDlg.cxx
|
// File : BuildGUI_SolidDlg.cxx
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header:
|
// $Header$
|
||||||
|
|
||||||
#include "BuildGUI_SolidDlg.h"
|
#include "BuildGUI_SolidDlg.h"
|
||||||
#include "GEOMImpl_Types.hxx"
|
#include "GEOMImpl_Types.hxx"
|
||||||
@ -44,8 +44,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BuildGUI_SolidDlg::BuildGUI_SolidDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
BuildGUI_SolidDlg::BuildGUI_SolidDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BUILD_SOLID")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BUILD_SOLID")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_SELECT")));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BuildGUI_SolidDlg.h
|
// File : BuildGUI_SolidDlg.h
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header:
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_SOLID_H
|
#ifndef DIALOGBOX_SOLID_H
|
||||||
#define DIALOGBOX_SOLID_H
|
#define DIALOGBOX_SOLID_H
|
||||||
@ -41,7 +40,8 @@ class BuildGUI_SolidDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BuildGUI_SolidDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BuildGUI_SolidDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BuildGUI_SolidDlg();
|
~BuildGUI_SolidDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -67,7 +67,6 @@ private slots:
|
|||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void EnableNameField(bool toEnable);
|
void EnableNameField(bool toEnable);
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_SOLID_H
|
#endif // DIALOGBOX_SOLID_H
|
||||||
|
@ -44,8 +44,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
BuildGUI_WireDlg::BuildGUI_WireDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
BuildGUI_WireDlg::BuildGUI_WireDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BUILD_WIRE")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_BUILD_WIRE")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : BuildGUI_WireDlg.h
|
// File : BuildGUI_WireDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_WIRE_H
|
#ifndef DIALOGBOX_WIRE_H
|
||||||
#define DIALOGBOX_WIRE_H
|
#define DIALOGBOX_WIRE_H
|
||||||
@ -41,7 +40,8 @@ class BuildGUI_WireDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
BuildGUI_WireDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
BuildGUI_WireDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~BuildGUI_WireDlg();
|
~BuildGUI_WireDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -65,7 +65,6 @@ private slots:
|
|||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_WIRE_H
|
#endif // DIALOGBOX_WIRE_H
|
||||||
|
@ -35,10 +35,8 @@
|
|||||||
#include "SUIT_ViewWindow.h"
|
#include "SUIT_ViewWindow.h"
|
||||||
#include "OCCViewer_ViewModel.h"
|
#include "OCCViewer_ViewModel.h"
|
||||||
#include "OCCViewer_ViewManager.h"
|
#include "OCCViewer_ViewManager.h"
|
||||||
//#include "SVTK_ViewModel.h"
|
|
||||||
#include "SalomeApp_Study.h"
|
#include "SalomeApp_Study.h"
|
||||||
#include "SalomeApp_Tools.h"
|
#include "SalomeApp_Tools.h"
|
||||||
//#include "SALOMEGUI_ImportOperation.h"
|
|
||||||
|
|
||||||
#include <TopoDS_Compound.hxx>
|
#include <TopoDS_Compound.hxx>
|
||||||
#include <BRep_Builder.hxx>
|
#include <BRep_Builder.hxx>
|
||||||
@ -73,14 +71,10 @@ EntityGUI* EntityGUI::GetEntityGUI( GeometryGUI* parent )
|
|||||||
//=======================================================================
|
//=======================================================================
|
||||||
EntityGUI::EntityGUI( GeometryGUI* parent ) : GEOMGUI( parent )
|
EntityGUI::EntityGUI( GeometryGUI* parent ) : GEOMGUI( parent )
|
||||||
{
|
{
|
||||||
myGeomBase = new GEOMBase();
|
|
||||||
myGeom = GEOM::GEOM_Gen::_duplicate( GeometryGUI::GetGeomGen() );
|
|
||||||
|
|
||||||
mySimulationShape1 = new AIS_Shape(TopoDS_Shape());
|
mySimulationShape1 = new AIS_Shape(TopoDS_Shape());
|
||||||
mySimulationShape2 = new AIS_Shape(TopoDS_Shape());
|
mySimulationShape2 = new AIS_Shape(TopoDS_Shape());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
// function : ~EntityGUI()
|
// function : ~EntityGUI()
|
||||||
// purpose : Destructor
|
// purpose : Destructor
|
||||||
@ -106,7 +100,7 @@ bool EntityGUI::OnGUIEvent(int theCommandID, SUIT_Desktop* parent)
|
|||||||
aDlg = new EntityGUI_SketcherDlg(getGeometryGUI(), parent, "");
|
aDlg = new EntityGUI_SketcherDlg(getGeometryGUI(), parent, "");
|
||||||
break;
|
break;
|
||||||
case 407: // EXPLODE : use ic
|
case 407: // EXPLODE : use ic
|
||||||
aDlg = new EntityGUI_SubShapeDlg(parent, "");
|
aDlg = new EntityGUI_SubShapeDlg(getGeometryGUI(), parent, "");
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
SUIT_Session::session()->activeApplication()->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
SUIT_Session::session()->activeApplication()->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
||||||
@ -119,46 +113,18 @@ bool EntityGUI::OnGUIEvent(int theCommandID, SUIT_Desktop* parent)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=======================================================================
|
|
||||||
// function : OnSketchEnd()
|
|
||||||
// purpose :
|
|
||||||
//=======================================================================
|
|
||||||
void EntityGUI::OnSketchEnd(const char *Cmd)
|
|
||||||
{
|
|
||||||
/* QAD_Application::getDesktop()->putInfo("Create sketch functionality is NOT implemented in new GEOM kernel
|
|
||||||
(no such Corba interface method). Waiting for SRN to create it...");
|
|
||||||
|
|
||||||
try {
|
|
||||||
GEOM::GEOM_Shape_var result = myGeom->MakeSketcher(Cmd);
|
|
||||||
if(result->_is_nil()) {
|
|
||||||
QAD_Application::getDesktop()->putInfo(tr("GEOM_PRP_NULLSHAPE"));
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
result->NameType(tr("GEOM_WIRE"));
|
|
||||||
if(myGeomBase->Display(result))
|
|
||||||
QAD_Application::getDesktop()->putInfo(tr("GEOM_PRP_DONE"));
|
|
||||||
}
|
|
||||||
catch(const SALOME::SALOME_Exception& S_ex) {
|
|
||||||
SalomeApp_Tools::QtCatchCorbaException(S_ex);
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=====================================================================================
|
//=====================================================================================
|
||||||
// function : DisplaySimulationShape()
|
// function : DisplaySimulationShape()
|
||||||
// purpose : Displays 'this->mySimulationShape' a pure graphical shape from a TopoDS_Shape
|
// purpose : Displays 'this->mySimulationShape' a pure graphical shape from a TopoDS_Shape
|
||||||
//=====================================================================================
|
//=====================================================================================
|
||||||
void EntityGUI::DisplaySimulationShape(const TopoDS_Shape& S1, const TopoDS_Shape& S2)
|
void EntityGUI::DisplaySimulationShape(const TopoDS_Shape& S1, const TopoDS_Shape& S2)
|
||||||
{
|
{
|
||||||
//NRI DEBUG : 14/02/2002
|
SUIT_ViewManager* aVM =
|
||||||
if( SUIT_Session::session()->activeApplication()->desktop()->activeWindow()->getViewManager()->getType()
|
SUIT_Session::session()->activeApplication()->desktop()->activeWindow()->getViewManager();
|
||||||
!= OCCViewer_Viewer::Type() )
|
if (aVM->getType() != OCCViewer_Viewer::Type())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
OCCViewer_Viewer* v3d =
|
OCCViewer_Viewer* v3d = ((OCCViewer_ViewManager*)aVM)->getOCCViewer();
|
||||||
((OCCViewer_ViewManager*)(SUIT_Session::session()->activeApplication()->desktop()->activeWindow()->getViewManager()))->getOCCViewer();
|
|
||||||
Handle(AIS_InteractiveContext) ic = v3d->getAISContext();
|
Handle(AIS_InteractiveContext) ic = v3d->getAISContext();
|
||||||
try {
|
try {
|
||||||
if (!S1.IsNull()) {
|
if (!S1.IsNull()) {
|
||||||
@ -194,7 +160,6 @@ void EntityGUI::DisplaySimulationShape(const TopoDS_Shape& S1, const TopoDS_Shap
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//==================================================================================
|
//==================================================================================
|
||||||
// function : EraseSimulationShape()
|
// function : EraseSimulationShape()
|
||||||
// purpose : Clears the display of 'mySimulationShape' a pure graphical shape
|
// purpose : Clears the display of 'mySimulationShape' a pure graphical shape
|
||||||
@ -229,7 +194,8 @@ void EntityGUI::EraseSimulationShape()
|
|||||||
//=====================================================================================
|
//=====================================================================================
|
||||||
bool EntityGUI::SObjectExist(const _PTR(SObject)& theFatherObject, const char* IOR)
|
bool EntityGUI::SObjectExist(const _PTR(SObject)& theFatherObject, const char* IOR)
|
||||||
{
|
{
|
||||||
SalomeApp_Study* appStudy = dynamic_cast<SalomeApp_Study*>( SUIT_Session::session()->activeApplication()->activeStudy() );
|
SalomeApp_Study* appStudy = dynamic_cast<SalomeApp_Study*>
|
||||||
|
( SUIT_Session::session()->activeApplication()->activeStudy() );
|
||||||
if ( !appStudy ) return false;
|
if ( !appStudy ) return false;
|
||||||
_PTR(Study) aStudy = appStudy->studyDS();
|
_PTR(Study) aStudy = appStudy->studyDS();
|
||||||
_PTR(ChildIterator) it ( aStudy->NewChildIterator(theFatherObject) );
|
_PTR(ChildIterator) it ( aStudy->NewChildIterator(theFatherObject) );
|
||||||
@ -254,416 +220,6 @@ bool EntityGUI::SObjectExist(const _PTR(SObject)& theFatherObject, const char* I
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=====================================================================================
|
|
||||||
// function : OnSubShapeGetAll()
|
|
||||||
// purpose : Explode a shape in all sub shapes with a SubShapeType
|
|
||||||
//=====================================================================================
|
|
||||||
bool EntityGUI::OnSubShapeGetAll(const TopoDS_Shape& ShapeTopo, const char* ShapeTopoIOR, const int SubShapeType)
|
|
||||||
{
|
|
||||||
SUIT_Session::session()->activeApplication()->putInfo("OnSubShapeGetAll method from EntityGUI should be reimplemented ...");
|
|
||||||
/*
|
|
||||||
SALOMEDS::Study_var aStudy = QAD_Application::getDesktop()->getActiveStudy()->getStudyDocument();
|
|
||||||
SALOMEDS::SObject_var theObj = aStudy->FindObjectIOR(ShapeTopoIOR);
|
|
||||||
if(theObj->_is_nil()) {
|
|
||||||
QAD_Application::getDesktop()->putInfo(tr("GEOM_PRP_SHAPE_IN_STUDY"));
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
SALOMEDS::StudyBuilder_var aStudyBuilder = aStudy->NewBuilder();
|
|
||||||
SALOMEDS::SObject_var fatherSF = aStudy->FindObjectID(QAD_Application::getDesktop()->getActiveStudy()->getActiveStudyFrame()->entry());
|
|
||||||
SALOMEDS::GenericAttribute_var anAttr;
|
|
||||||
SALOMEDS::AttributeName_var aName;
|
|
||||||
SALOMEDS::AttributeIOR_var anIOR;
|
|
||||||
SALOMEDS::AttributePixMap_var aPixmap;
|
|
||||||
|
|
||||||
// We create a sub object for each sub shape as attribute of the main object
|
|
||||||
// Each sub object contains list (length=1) containing its index in the main shape
|
|
||||||
GEOM::GEOM_Shape_var aShape = myGeom->GetIORFromString(ShapeTopoIOR);
|
|
||||||
GEOM::GEOM_Gen::ListOfGeomShapes_var listGeomShapes = new GEOM::GEOM_Gen::ListOfGeomShapes;
|
|
||||||
GEOM::GEOM_Shape_var aResult;
|
|
||||||
|
|
||||||
try {
|
|
||||||
listGeomShapes = myGeom->SubShapeAll(aShape, SubShapeType);
|
|
||||||
if(listGeomShapes->length() < 1) {
|
|
||||||
QAD_Application::getDesktop()->putInfo (tr("GEOM_PRP_ABORT"));
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
catch(const SALOME::SALOME_Exception& S_ex) {
|
|
||||||
SalomeApp_Tools::QtCatchCorbaException(S_ex);
|
|
||||||
}
|
|
||||||
|
|
||||||
// open transaction
|
|
||||||
QAD_Operation* op = new SALOMEGUI_ImportOperation(QAD_Application::getDesktop()->getActiveStudy());
|
|
||||||
op->start();
|
|
||||||
|
|
||||||
TopoDS_Shape mainTopo = myGeomGUI->GetShapeReader().GetShape(myGeom, aShape);
|
|
||||||
TopoDS_Shape mainShape;
|
|
||||||
bool main = false;
|
|
||||||
while(!main) {
|
|
||||||
if(aShape->IsMainShape()) {
|
|
||||||
mainShape = myGeomGUI->GetShapeReader().GetShape(myGeom, aShape);
|
|
||||||
main = true;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
aShape = myGeom->GetIORFromString(aShape->MainName());
|
|
||||||
}
|
|
||||||
|
|
||||||
// Loop on each sub shape created
|
|
||||||
// int i = 1 ; index for the nameType
|
|
||||||
for(int j=0; j<listGeomShapes->length(); j++) {
|
|
||||||
// Get each sub shape extracted CORBA and OCC
|
|
||||||
aResult = listGeomShapes[j] ;
|
|
||||||
TopoDS_Shape S = myGeomGUI->GetShapeReader().GetShape(myGeom, aResult);
|
|
||||||
|
|
||||||
if (S.IsNull()) {
|
|
||||||
QAD_Application::getDesktop()->putInfo (tr("GEOM_PRP_ABORT"));
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// Set the nameType of sub shape
|
|
||||||
char* nameG = (char *)malloc(20);
|
|
||||||
Standard_CString Type;
|
|
||||||
if(myGeomBase->GetShapeTypeString(S, Type)) {
|
|
||||||
aResult->NameType(Type);
|
|
||||||
sprintf(nameG, "%s_%d", Type, myGeomBase->GetIndex(S, mainShape, SubShapeType));
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
aResult->NameType(tr("GEOM_SHAPE"));
|
|
||||||
sprintf(nameG, "%s_%d", tr("GEOM_SHAPE").latin1(), myGeomGUI->myNbGeom++);
|
|
||||||
}
|
|
||||||
SALOMEDS::SObject_var SO = aStudy->FindObjectIOR(aResult->Name());
|
|
||||||
|
|
||||||
bool allreadyexist = false;
|
|
||||||
|
|
||||||
if(QAD_Application::getDesktop()->getActiveStudy()->getActiveStudyFrame()->getTypeView() == VIEW_OCC) {
|
|
||||||
OCCViewer_Viewer3d* v3d = ((OCCViewer_ViewFrame*)QAD_Application::getDesktop()->getActiveStudy()->getActiveStudyFrame()->getRightFrame()->getViewFrame())->getViewer();
|
|
||||||
Handle (AIS_InteractiveContext) ic = v3d->getAISContext();
|
|
||||||
|
|
||||||
Handle(GEOM_AISShape) result = new GEOM_AISShape(S, nameG);
|
|
||||||
Handle(GEOM_InteractiveObject) IO = new GEOM_InteractiveObject(aResult->Name(), myGeomGUI->GetFatherior(), "GEOM");
|
|
||||||
|
|
||||||
MESSAGE ("SO->_is_nil() " << SO->_is_nil())
|
|
||||||
|
|
||||||
if(SO->_is_nil()) {
|
|
||||||
SALOMEDS::SObject_var newObj = aStudyBuilder->NewObject(theObj);
|
|
||||||
anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeName");
|
|
||||||
aName = SALOMEDS::AttributeName::_narrow(anAttr);
|
|
||||||
aName->SetValue(nameG);
|
|
||||||
anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeIOR");
|
|
||||||
anIOR = SALOMEDS::AttributeIOR::_narrow(anAttr);
|
|
||||||
anIOR->SetValue(aResult->Name());
|
|
||||||
|
|
||||||
anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributePixMap");
|
|
||||||
aPixmap = SALOMEDS::AttributePixMap::_narrow(anAttr);
|
|
||||||
MESSAGE(" Type " << S.ShapeType())
|
|
||||||
if (S.ShapeType() == TopAbs_COMPOUND)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_COMPOUND");
|
|
||||||
else if(S.ShapeType() == TopAbs_COMPSOLID)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_COMPSOLID");
|
|
||||||
else if(S.ShapeType() == TopAbs_SOLID)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_SOLID");
|
|
||||||
else if(S.ShapeType() == TopAbs_SHELL)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_SHELL");
|
|
||||||
else if(S.ShapeType() == TopAbs_FACE)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_FACE");
|
|
||||||
else if(S.ShapeType() == TopAbs_WIRE)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_WIRE");
|
|
||||||
else if(S.ShapeType() == TopAbs_EDGE)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_EDGE");
|
|
||||||
else if(S.ShapeType() == TopAbs_VERTEX)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_VERTEX");
|
|
||||||
|
|
||||||
MESSAGE(" aPixmap->GetPixMap " << aPixmap->GetPixMap())
|
|
||||||
|
|
||||||
SALOMEDS::SObject_var newObj1 = aStudyBuilder->NewObject(fatherSF);
|
|
||||||
aStudyBuilder->Addreference(newObj1, newObj);
|
|
||||||
IO->setEntry(newObj->GetID());
|
|
||||||
|
|
||||||
aResult->StudyShapeId(newObj->GetID());
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
allreadyexist = true;
|
|
||||||
if(!this->SObjectExist(theObj, aResult->Name())) {
|
|
||||||
SALOMEDS::SObject_var newObj1 = aStudyBuilder->NewObject(theObj);
|
|
||||||
aStudyBuilder->Addreference(newObj1, SO);
|
|
||||||
IO->setEntry(SO->GetID());
|
|
||||||
aResult->StudyShapeId(SO->GetID());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
result->setIO(IO);
|
|
||||||
result->setName(nameG);
|
|
||||||
if(!allreadyexist)
|
|
||||||
ic->Display(result);
|
|
||||||
|
|
||||||
}
|
|
||||||
else if(QAD_Application::getDesktop()->getActiveStudy()->getActiveStudyFrame()->getTypeView() == VIEW_VTK) {
|
|
||||||
SVTK_ViewFrame* vf = dynamic_cast<SVTK_ViewFrame*>( QAD_Application::getDesktop()->getActiveStudy()->getActiveStudyFrame()->getRightFrame()->getViewFrame() );
|
|
||||||
SVTK_RenderWindowInteractor* myRenderInter= vf ? vf->getRWInteractor() : 0;
|
|
||||||
|
|
||||||
int themode = myRenderInter->GetDisplayMode();
|
|
||||||
vtkRenderer *theRenderer = vf->getRenderer();
|
|
||||||
vtkRenderWindow *renWin = theRenderer->GetRenderWindow();
|
|
||||||
|
|
||||||
Handle(GEOM_InteractiveObject) IO = new GEOM_InteractiveObject(aResult->Name(), myGeomGUI->GetFatherior(), "GEOM");
|
|
||||||
|
|
||||||
if(SO->_is_nil()) {
|
|
||||||
SALOMEDS::SObject_var newObj = aStudyBuilder->NewObject(theObj);
|
|
||||||
anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeIOR");
|
|
||||||
anIOR = SALOMEDS::AttributeIOR::_narrow(anAttr);
|
|
||||||
anIOR->SetValue(aResult->Name());
|
|
||||||
anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeName");
|
|
||||||
aName = SALOMEDS::AttributeName::_narrow(anAttr);
|
|
||||||
aName->SetValue(nameG);
|
|
||||||
|
|
||||||
anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributePixMap");
|
|
||||||
aPixmap = SALOMEDS::AttributePixMap::_narrow(anAttr);
|
|
||||||
if(S.ShapeType() == TopAbs_COMPOUND)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_COMPOUND");
|
|
||||||
else if(S.ShapeType() == TopAbs_COMPSOLID)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_COMPSOLID");
|
|
||||||
else if(S.ShapeType() == TopAbs_SOLID)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_SOLID");
|
|
||||||
else if(S.ShapeType() == TopAbs_SHELL)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_SHELL");
|
|
||||||
else if(S.ShapeType() == TopAbs_FACE)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_FACE");
|
|
||||||
else if(S.ShapeType() == TopAbs_WIRE)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_WIRE");
|
|
||||||
else if(S.ShapeType() == TopAbs_EDGE)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_EDGE");
|
|
||||||
else if(S.ShapeType() == TopAbs_VERTEX)
|
|
||||||
aPixmap->SetPixMap("ICON_OBJBROWSER_VERTEX");
|
|
||||||
|
|
||||||
SALOMEDS::SObject_var newObj1 = aStudyBuilder->NewObject(fatherSF);
|
|
||||||
aStudyBuilder->Addreference(newObj1, newObj);
|
|
||||||
IO->setEntry(newObj->GetID());
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
allreadyexist = true;
|
|
||||||
if(!this->SObjectExist(theObj, aResult->Name())) {
|
|
||||||
SALOMEDS::SObject_var newObj1 = aStudyBuilder->NewObject(theObj);
|
|
||||||
aStudyBuilder->Addreference(newObj1, SO);
|
|
||||||
IO->setEntry(SO->GetID());
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if(!allreadyexist) {
|
|
||||||
vtkActorCollection* theActors = GEOM_AssemblyBuilder::BuildActors(S,0,themode,Standard_True);
|
|
||||||
theActors->InitTraversal();
|
|
||||||
vtkActor* anActor = (vtkActor*)theActors->GetNextActor();
|
|
||||||
while(!(anActor==NULL)) {
|
|
||||||
GEOM_Actor* GActor = GEOM_Actor::SafeDownCast(anActor);
|
|
||||||
GActor->setIO(IO);
|
|
||||||
GActor->setName(nameG);
|
|
||||||
theRenderer->AddActor(GActor);
|
|
||||||
renWin->Render();
|
|
||||||
anActor = (vtkActor*)theActors->GetNextActor();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// commit transaction
|
|
||||||
op->finish();
|
|
||||||
|
|
||||||
QAD_Application::getDesktop()->getActiveStudy()->updateObjBrowser();
|
|
||||||
QAD_Application::getDesktop()->putInfo (tr("GEOM_PRP_READY"));
|
|
||||||
*/
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=====================================================================================
|
|
||||||
// function : OnSubShapeGetSelected()
|
|
||||||
// purpose :
|
|
||||||
//=====================================================================================
|
|
||||||
bool EntityGUI::OnSubShapeGetSelected(const TopoDS_Shape& ShapeTopo, const char* ShapeTopoIOR, const int SubShapeType, Standard_Integer& aLocalContextId, bool& myUseLocalContext)
|
|
||||||
{
|
|
||||||
SUIT_Session::session()->activeApplication()->putInfo("OnSubShapeGetSelected method from EntityGUI should be reimplemented ...");
|
|
||||||
// //* Test the type of viewer */
|
|
||||||
// if(QAD_Application::getDesktop()->getActiveStudy()->getActiveStudyFrame()->getTypeView() > VIEW_OCC)
|
|
||||||
// return false;
|
|
||||||
|
|
||||||
// SALOMEDS::Study_var aStudy = QAD_Application::getDesktop()->getActiveStudy()->getStudyDocument();
|
|
||||||
// SALOMEDS::SObject_var theObj = aStudy->FindObjectIOR(ShapeTopoIOR);
|
|
||||||
// if(theObj->_is_nil()) {
|
|
||||||
// QAD_Application::getDesktop()->putInfo(tr("GEOM_PRP_SHAPE_IN_STUDY"));
|
|
||||||
// return false;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// OCCViewer_Viewer3d* v3d = ((OCCViewer_ViewFrame*)QAD_Application::getDesktop()->getActiveStudy()->getActiveStudyFrame()->getRightFrame()->getViewFrame())->getViewer();
|
|
||||||
// Handle(AIS_InteractiveContext) ic = v3d->getAISContext();
|
|
||||||
|
|
||||||
// if( myUseLocalContext == false ) {
|
|
||||||
// /* local context is from DialogBox */
|
|
||||||
// MESSAGE("Error : No local context opened for sub shapes method" << endl ) ;
|
|
||||||
// return false ;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// GEOM::GEOM_Shape_var aShape = myGeom->GetIORFromString( ShapeTopoIOR );
|
|
||||||
// TopoDS_Shape mainTopo = myGeomGUI->GetShapeReader().GetShape(myGeom, aShape);
|
|
||||||
|
|
||||||
// TopoDS_Shape mainShape;
|
|
||||||
// bool main = false;
|
|
||||||
// while(!main) {
|
|
||||||
// if(aShape->IsMainShape()) {
|
|
||||||
// mainShape = myGeomGUI->GetShapeReader().GetShape(myGeom, aShape);
|
|
||||||
// main = true;
|
|
||||||
// }
|
|
||||||
// else
|
|
||||||
// aShape = myGeom->GetIORFromString(aShape->MainName());
|
|
||||||
// }
|
|
||||||
|
|
||||||
// GEOM::GEOM_Shape::ListOfSubShapeID_var ListOfID = new GEOM::GEOM_Shape::ListOfSubShapeID;
|
|
||||||
// ic->InitSelected();
|
|
||||||
// int nbSelected = ic->NbSelected();
|
|
||||||
// ListOfID->length(nbSelected);
|
|
||||||
|
|
||||||
// TopoDS_Compound compound;
|
|
||||||
// ic->InitSelected(); /* to init again */
|
|
||||||
// BRep_Builder B;
|
|
||||||
// B.MakeCompound(compound);
|
|
||||||
|
|
||||||
// int i = 0;
|
|
||||||
// /* We create a unique compound containing all the sub shapes selected by user as attribute of the main shape */
|
|
||||||
// /* the compound is homogenous by selection */
|
|
||||||
// while(ic->MoreSelected()) {
|
|
||||||
// int index = myGeomBase->GetIndex(ic->SelectedShape(), mainShape, SubShapeType);
|
|
||||||
// ListOfID[i] = index;
|
|
||||||
// B.Add(compound, ic->SelectedShape());
|
|
||||||
// i++;
|
|
||||||
// ic->NextSelected();
|
|
||||||
// }
|
|
||||||
|
|
||||||
// /* Test if user has selected sub shapes */
|
|
||||||
// if(ListOfID->length() < 1)
|
|
||||||
// return false;
|
|
||||||
|
|
||||||
// GEOM::GEOM_Shape_var aResult;
|
|
||||||
// try {
|
|
||||||
// aResult = myGeom->SubShape(aShape, SubShapeType, ListOfID);
|
|
||||||
// }
|
|
||||||
// catch (const SALOME::SALOME_Exception& S_ex) {
|
|
||||||
// SalomeApp_Tools::QtCatchCorbaException(S_ex);
|
|
||||||
// }
|
|
||||||
|
|
||||||
// /* local context from DialogBox */
|
|
||||||
// ic->CloseLocalContext(aLocalContextId);
|
|
||||||
// myUseLocalContext = false ;
|
|
||||||
|
|
||||||
// char* nameG = (char *)malloc(20);
|
|
||||||
// Standard_CString Type;
|
|
||||||
|
|
||||||
// Handle(GEOM_AISShape) result;
|
|
||||||
// Handle(GEOM_InteractiveObject) IO;
|
|
||||||
|
|
||||||
// if(nbSelected == 1) {
|
|
||||||
// TopExp_Explorer Exp (compound, TopAbs_ShapeEnum(SubShapeType));
|
|
||||||
// if(Exp.More()) {
|
|
||||||
// if(myGeomBase->GetShapeTypeString(Exp.Current(),Type)) {
|
|
||||||
// aResult->NameType(Type);
|
|
||||||
// sprintf (nameG, "%s_%d", Type, myGeomBase->GetIndex( Exp.Current(), mainTopo, SubShapeType));
|
|
||||||
// }
|
|
||||||
// else {
|
|
||||||
// aResult->NameType(tr("GEOM_SHAPE"));
|
|
||||||
// sprintf (nameG, "%s_%d", tr("GEOM_SHAPE").latin1(), myGeomGUI->myNbGeom++);
|
|
||||||
// }
|
|
||||||
// result = new GEOM_AISShape(Exp.Current(), nameG);
|
|
||||||
// IO = new GEOM_InteractiveObject(aResult->Name(), myGeomGUI->GetFatherior(), "GEOM");
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
// else {
|
|
||||||
// if ( myGeomBase->GetShapeTypeString(compound,Type)) {
|
|
||||||
// aResult->NameType(Type);
|
|
||||||
// sprintf (nameG, "%s_%d", Type, myGeomGUI->myNbGeom++);
|
|
||||||
// } else {
|
|
||||||
// aResult->NameType(tr("GEOM_SHAPE"));
|
|
||||||
// sprintf (nameG, "%s_%d", tr("GEOM_SHAPE").latin1(), myGeomGUI->myNbGeom++);
|
|
||||||
// }
|
|
||||||
// result = new GEOM_AISShape(compound, nameG);
|
|
||||||
// IO = new GEOM_InteractiveObject(aResult->Name(), myGeomGUI->GetFatherior(), "GEOM");
|
|
||||||
// }
|
|
||||||
|
|
||||||
// SALOMEDS::SObject_var SO = aStudy->FindObjectIOR(aResult->Name());
|
|
||||||
|
|
||||||
// /* open transaction */
|
|
||||||
// QAD_Operation* op = new SALOMEGUI_ImportOperation(QAD_Application::getDesktop()->getActiveStudy());
|
|
||||||
// op->start();
|
|
||||||
|
|
||||||
// SALOMEDS::StudyBuilder_var aStudyBuilder = aStudy->NewBuilder();
|
|
||||||
// SALOMEDS::SObject_var fatherSF = aStudy->FindObjectID(QAD_Application::getDesktop()->getActiveStudy()->getActiveStudyFrame()->entry());
|
|
||||||
// SALOMEDS::GenericAttribute_var anAttr;
|
|
||||||
// SALOMEDS::AttributeName_var aName;
|
|
||||||
// SALOMEDS::AttributeIOR_var anIOR;
|
|
||||||
// SALOMEDS::AttributePixMap_var aPixmap;
|
|
||||||
|
|
||||||
// bool allreadyexist = false;
|
|
||||||
|
|
||||||
// if(SO->_is_nil()) {
|
|
||||||
// SALOMEDS::SObject_var newObj = aStudyBuilder->NewObject(theObj);
|
|
||||||
// anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeIOR");
|
|
||||||
// anIOR = SALOMEDS::AttributeIOR::_narrow(anAttr);
|
|
||||||
// anIOR->SetValue(aResult->Name());
|
|
||||||
// anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributeName");
|
|
||||||
// aName = SALOMEDS::AttributeName::_narrow(anAttr);
|
|
||||||
// aName->SetValue(result->getName());
|
|
||||||
|
|
||||||
// anAttr = aStudyBuilder->FindOrCreateAttribute(newObj, "AttributePixMap");
|
|
||||||
// aPixmap = SALOMEDS::AttributePixMap::_narrow(anAttr);
|
|
||||||
// if(result->Shape().ShapeType() == TopAbs_COMPOUND)
|
|
||||||
// aPixmap->SetPixMap("ICON_OBJBROWSER_COMPOUND");
|
|
||||||
// else if(result->Shape().ShapeType() == TopAbs_COMPSOLID)
|
|
||||||
// aPixmap->SetPixMap("ICON_OBJBROWSER_COMPSOLID");
|
|
||||||
// else if(result->Shape().ShapeType() == TopAbs_SOLID)
|
|
||||||
// aPixmap->SetPixMap("ICON_OBJBROWSER_SOLID");
|
|
||||||
// else if(result->Shape().ShapeType() == TopAbs_SHELL)
|
|
||||||
// aPixmap->SetPixMap("ICON_OBJBROWSER_SHELL");
|
|
||||||
// else if(result->Shape().ShapeType() == TopAbs_FACE)
|
|
||||||
// aPixmap->SetPixMap("ICON_OBJBROWSER_FACE");
|
|
||||||
// else if(result->Shape().ShapeType() == TopAbs_WIRE)
|
|
||||||
// aPixmap->SetPixMap("ICON_OBJBROWSER_WIRE");
|
|
||||||
// else if(result->Shape().ShapeType() == TopAbs_EDGE)
|
|
||||||
// aPixmap->SetPixMap("ICON_OBJBROWSER_EDGE");
|
|
||||||
// else if(result->Shape().ShapeType() == TopAbs_VERTEX)
|
|
||||||
// aPixmap->SetPixMap("ICON_OBJBROWSER_VERTEX");
|
|
||||||
|
|
||||||
// SALOMEDS::SObject_var newObj1 = aStudyBuilder->NewObject(fatherSF);
|
|
||||||
// aStudyBuilder->Addreference(newObj1, newObj);
|
|
||||||
|
|
||||||
// IO->setEntry(newObj->GetID());
|
|
||||||
// aResult->StudyShapeId(newObj->GetID());
|
|
||||||
// }
|
|
||||||
// else {
|
|
||||||
// allreadyexist = true;
|
|
||||||
// if(!this->SObjectExist(theObj, aResult->Name())) {
|
|
||||||
// SALOMEDS::SObject_var newObj1 = aStudyBuilder->NewObject(theObj);
|
|
||||||
// aStudyBuilder->Addreference(newObj1, SO);
|
|
||||||
|
|
||||||
// IO->setEntry(SO->GetID());
|
|
||||||
// aResult->StudyShapeId(SO->GetID());
|
|
||||||
// }
|
|
||||||
// }
|
|
||||||
|
|
||||||
// /* commit transaction */
|
|
||||||
// op->finish();
|
|
||||||
|
|
||||||
// result->setIO(IO);
|
|
||||||
// result->setName(nameG);
|
|
||||||
|
|
||||||
// if(!allreadyexist)
|
|
||||||
// ic->Display(result);
|
|
||||||
|
|
||||||
// DisplayGUI* myDisplayGUI = new DisplayGUI();
|
|
||||||
// myDisplayGUI->OnDisplayAll(true);
|
|
||||||
|
|
||||||
// QAD_Application::getDesktop()->getActiveStudy()->updateObjBrowser();
|
|
||||||
// QAD_Application::getDesktop()->putInfo (tr("GEOM_PRP_READY"));
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=====================================================================================
|
//=====================================================================================
|
||||||
// EXPORTED METHODS
|
// EXPORTED METHODS
|
||||||
//=====================================================================================
|
//=====================================================================================
|
||||||
|
@ -24,16 +24,17 @@
|
|||||||
// File : EntityGUI.h
|
// File : EntityGUI.h
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef ENTITYGUI_H
|
#ifndef ENTITYGUI_H
|
||||||
#define ENTITYGUI_H
|
#define ENTITYGUI_H
|
||||||
|
|
||||||
#include "GEOMGUI.h"
|
#include "GEOMGUI.h"
|
||||||
#include "GEOMBase.h"
|
|
||||||
|
|
||||||
#include "SALOMEDSClient.hxx"
|
#include "SALOMEDSClient.hxx"
|
||||||
|
|
||||||
|
#include <TopoDS_Shape.hxx>
|
||||||
|
#include <AIS_Shape.hxx>
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// class : EntityGUI
|
// class : EntityGUI
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -51,29 +52,18 @@ public :
|
|||||||
|
|
||||||
bool OnGUIEvent(int theCommandID, SUIT_Desktop* parent);
|
bool OnGUIEvent(int theCommandID, SUIT_Desktop* parent);
|
||||||
|
|
||||||
void OnSketchEnd(const char *Cmd);
|
|
||||||
|
|
||||||
void DisplaySimulationShape(const TopoDS_Shape& S1, const TopoDS_Shape& S2);
|
void DisplaySimulationShape(const TopoDS_Shape& S1, const TopoDS_Shape& S2);
|
||||||
void EraseSimulationShape();
|
void EraseSimulationShape();
|
||||||
|
|
||||||
void MakeInterpolAndDisplay(GEOM::string_array& listShapesIOR);
|
// Methods for sub shapes explode
|
||||||
void MakeBezierAndDisplay(GEOM::string_array& listShapesIOR);
|
|
||||||
|
|
||||||
/* Methods for sub shapes explode */
|
|
||||||
bool SObjectExist(const _PTR(SObject)& theFatherObject, const char* IOR);
|
bool SObjectExist(const _PTR(SObject)& theFatherObject, const char* IOR);
|
||||||
bool OnSubShapeGetAll(const TopoDS_Shape& ShapeTopo, const char* ShapeTopoIOR, const int SubShapeType);
|
|
||||||
bool OnSubShapeGetSelected(const TopoDS_Shape& ShapeTopo, const char* ShapeTopoIOR, const int SubShapeType,
|
|
||||||
Standard_Integer& aLocalContextId, bool& myUseLocalContext);
|
|
||||||
|
|
||||||
/* AIS shape used only during topo/geom simulations */
|
// AIS shape used only during topo/geom simulations
|
||||||
Handle(AIS_Shape) mySimulationShape1;
|
Handle(AIS_Shape) mySimulationShape1;
|
||||||
Handle(AIS_Shape) mySimulationShape2;
|
Handle(AIS_Shape) mySimulationShape2;
|
||||||
|
|
||||||
GEOMBase* myGeomBase;
|
|
||||||
GEOM::GEOM_Gen_var myGeom; /* Current Geom Component */
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
static EntityGUI* myGUIObject; // the only EntityGUI object
|
static EntityGUI* myGUIObject; //!< the only EntityGUI object
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
@ -29,6 +29,7 @@
|
|||||||
#include "EntityGUI_SketcherDlg.h"
|
#include "EntityGUI_SketcherDlg.h"
|
||||||
#include "Sketcher_Profile.hxx"
|
#include "Sketcher_Profile.hxx"
|
||||||
#include "GEOM_Displayer.h"
|
#include "GEOM_Displayer.h"
|
||||||
|
#include "GEOMBase.h"
|
||||||
|
|
||||||
#include "SUIT_Desktop.h"
|
#include "SUIT_Desktop.h"
|
||||||
#include "SUIT_Session.h"
|
#include "SUIT_Session.h"
|
||||||
@ -62,8 +63,11 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
EntityGUI_SketcherDlg::EntityGUI_SketcherDlg(GeometryGUI* GUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
EntityGUI_SketcherDlg::EntityGUI_SketcherDlg(GeometryGUI* GUI, QWidget* parent,
|
||||||
:EntityGUI_Skeleton_QTD(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu | WDestructiveClose), myIsAllAdded( false ),
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:EntityGUI_Skeleton_QTD(parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu | WDestructiveClose),
|
||||||
|
myIsAllAdded( false ),
|
||||||
GEOMBase_Helper( dynamic_cast<SUIT_Desktop*>( parent ) ),
|
GEOMBase_Helper( dynamic_cast<SUIT_Desktop*>( parent ) ),
|
||||||
myGeometryGUI( GUI )
|
myGeometryGUI( GUI )
|
||||||
{
|
{
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : EntityGUI_SketcherDlg.h
|
// File : EntityGUI_SketcherDlg.h
|
||||||
// Author : Damine COQUERET
|
// Author : Damine COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header:
|
|
||||||
|
|
||||||
#ifndef ENTITYGUI_SKETCHERDLG_H
|
#ifndef ENTITYGUI_SKETCHERDLG_H
|
||||||
#define ENTITYGUI_SKETCHERDLG_H
|
#define ENTITYGUI_SKETCHERDLG_H
|
||||||
@ -63,7 +62,8 @@ class EntityGUI_SketcherDlg : public EntityGUI_Skeleton_QTD, public GEOMBase_Hel
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
EntityGUI_SketcherDlg(GeometryGUI* GUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
EntityGUI_SketcherDlg(GeometryGUI* GUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~EntityGUI_SketcherDlg();
|
~EntityGUI_SketcherDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -131,6 +131,7 @@ private :
|
|||||||
bool createShapes( GEOM::GEOM_Object_ptr theObject,
|
bool createShapes( GEOM::GEOM_Object_ptr theObject,
|
||||||
TopoDS_Shape& theApplyedWire,
|
TopoDS_Shape& theApplyedWire,
|
||||||
TopoDS_Shape& theLastSegment );
|
TopoDS_Shape& theLastSegment );
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void ClickOnEnd();
|
void ClickOnEnd();
|
||||||
void ClickOnCancel();
|
void ClickOnCancel();
|
||||||
@ -149,7 +150,6 @@ private slots:
|
|||||||
void Dir1Clicked(int constructorId);
|
void Dir1Clicked(int constructorId);
|
||||||
void Dir2Clicked(int constructorId);
|
void Dir2Clicked(int constructorId);
|
||||||
void ValueChangedInSpinBox(double newValue);
|
void ValueChangedInSpinBox(double newValue);
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // ENTITYGUI_SKETCHERDLG_H
|
#endif // ENTITYGUI_SKETCHERDLG_H
|
||||||
|
@ -52,8 +52,9 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
EntityGUI_SubShapeDlg::EntityGUI_SubShapeDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
EntityGUI_SubShapeDlg::EntityGUI_SubShapeDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, fl)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, fl)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SUBSHAPE")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SUBSHAPE")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
@ -120,9 +121,7 @@ void EntityGUI_SubShapeDlg::Init()
|
|||||||
GroupPoints->CheckButton1->setEnabled(false);
|
GroupPoints->CheckButton1->setEnabled(false);
|
||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
|
||||||
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
||||||
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
@ -207,7 +206,7 @@ void EntityGUI_SubShapeDlg::SelectionIntoArgument()
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ( !myGeomBase->GetTopoFromSelection( selectedIO(), S ) ||
|
if ( !GEOMBase::GetTopoFromSelection( selectedIO(), S ) ||
|
||||||
S.IsNull() ||
|
S.IsNull() ||
|
||||||
S.ShapeType() == TopAbs_VERTEX )
|
S.ShapeType() == TopAbs_VERTEX )
|
||||||
{
|
{
|
||||||
@ -354,8 +353,7 @@ void EntityGUI_SubShapeDlg::ActivateThisDialog()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void EntityGUI_SubShapeDlg::enterEvent(QEvent* e)
|
void EntityGUI_SubShapeDlg::enterEvent(QEvent* e)
|
||||||
{
|
{
|
||||||
if(GroupConstructors->isEnabled())
|
if (!GroupConstructors->isEnabled())
|
||||||
return;
|
|
||||||
ActivateThisDialog();
|
ActivateThisDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : EntityGUI_SubShapeDlg.h
|
// File : EntityGUI_SubShapeDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_SUBSHAPE_H
|
#ifndef DIALOGBOX_SUBSHAPE_H
|
||||||
#define DIALOGBOX_SUBSHAPE_H
|
#define DIALOGBOX_SUBSHAPE_H
|
||||||
@ -42,10 +41,8 @@ class EntityGUI_SubShapeDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
EntityGUI_SubShapeDlg( QWidget* parent = 0,
|
EntityGUI_SubShapeDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
const char* name = 0,
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
bool modal = FALSE,
|
|
||||||
WFlags fl = 0 );
|
|
||||||
~EntityGUI_SubShapeDlg();
|
~EntityGUI_SubShapeDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
@ -89,23 +89,6 @@ using namespace std;
|
|||||||
#include "SALOMEDSClient.hxx"
|
#include "SALOMEDSClient.hxx"
|
||||||
|
|
||||||
|
|
||||||
//=======================================================================
|
|
||||||
// function : GEOMBase()
|
|
||||||
// purpose : Constructor
|
|
||||||
//=======================================================================
|
|
||||||
GEOMBase::GEOMBase()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=======================================================================
|
|
||||||
// function : ~GEOMBase()
|
|
||||||
// purpose : Destructor
|
|
||||||
//=======================================================================
|
|
||||||
GEOMBase::~GEOMBase()
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
//=====================================================================================
|
//=====================================================================================
|
||||||
// function : GetShapeFromIOR()
|
// function : GetShapeFromIOR()
|
||||||
// purpose : exist also as static method !
|
// purpose : exist also as static method !
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : GEOMBase.h
|
// File : GEOMBase.h
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef GEOMBASE_H
|
#ifndef GEOMBASE_H
|
||||||
#define GEOMBASE_H
|
#define GEOMBASE_H
|
||||||
@ -65,22 +64,14 @@ class QWidget;
|
|||||||
class GEOMBASE_WNT_EXPORT GEOMBase
|
class GEOMBASE_WNT_EXPORT GEOMBase
|
||||||
{
|
{
|
||||||
public :
|
public :
|
||||||
GEOMBase();
|
|
||||||
~GEOMBase();
|
|
||||||
|
|
||||||
// SAN -- TO BE REMOVED !!!
|
|
||||||
static bool Display( GEOM::GEOM_Object_ptr ) {return false;}
|
|
||||||
static bool AddInStudy( GEOM::GEOM_Object_ptr ) {return false;}
|
|
||||||
static void DisplaySimulationShape(const TopoDS_Shape& S) {};
|
|
||||||
static void EraseSimulationShape() {};
|
|
||||||
// SAN -- TO BE REMOVED !!!
|
|
||||||
|
|
||||||
/* Selection and objects management */
|
/* Selection and objects management */
|
||||||
static int GetIndex(const TopoDS_Shape& subshape, const TopoDS_Shape& shape, int ShapeType);
|
static int GetIndex(const TopoDS_Shape& subshape, const TopoDS_Shape& shape, int ShapeType);
|
||||||
static TopoDS_Shape GetShapeFromIOR(QString IOR);
|
static TopoDS_Shape GetShapeFromIOR(QString IOR);
|
||||||
static bool GetShape( const GEOM::GEOM_Object_ptr&, TopoDS_Shape&, const TopAbs_ShapeEnum = TopAbs_SHAPE );
|
static bool GetShape(const GEOM::GEOM_Object_ptr&, TopoDS_Shape&,
|
||||||
|
const TopAbs_ShapeEnum = TopAbs_SHAPE);
|
||||||
static bool GetTopoFromSelection(const SALOME_ListIO& aList, TopoDS_Shape& tds);
|
static bool GetTopoFromSelection(const SALOME_ListIO& aList, TopoDS_Shape& tds);
|
||||||
static int GetNameOfSelectedIObjects(const SALOME_ListIO& aList, QString& aName, const bool theShapesOnly = false );
|
static int GetNameOfSelectedIObjects(const SALOME_ListIO& aList, QString& aName,
|
||||||
|
const bool theShapesOnly = false);
|
||||||
static bool GetShapeTypeString(const TopoDS_Shape& aShape, Standard_CString& aTypeString);
|
static bool GetShapeTypeString(const TopoDS_Shape& aShape, Standard_CString& aTypeString);
|
||||||
|
|
||||||
/* Convertions */
|
/* Convertions */
|
||||||
@ -129,7 +120,8 @@ public :
|
|||||||
static bool CreateArrowForLinearEdge(const TopoDS_Shape& tds, TopoDS_Shape& ArrowCone);
|
static bool CreateArrowForLinearEdge(const TopoDS_Shape& tds, TopoDS_Shape& ArrowCone);
|
||||||
|
|
||||||
/* Generates default names */
|
/* Generates default names */
|
||||||
static bool SelectionByNameInDialogs(QWidget* aWidget, const QString& userObjectName, const SALOME_ListIO& aList);
|
static bool SelectionByNameInDialogs(QWidget* aWidget, const QString& userObjectName,
|
||||||
|
const SALOME_ListIO& aList);
|
||||||
/* Shows message box with error code */
|
/* Shows message box with error code */
|
||||||
static bool DefineDlgPosition(QWidget* aDlg, int& x, int& y);
|
static bool DefineDlgPosition(QWidget* aDlg, int& x, int& y);
|
||||||
|
|
||||||
@ -145,4 +137,3 @@ public :
|
|||||||
};
|
};
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -109,6 +109,7 @@ GEOMBase_Helper::~GEOMBase_Helper()
|
|||||||
|
|
||||||
globalSelection( GEOM_ALLOBJECTS, true );
|
globalSelection( GEOM_ALLOBJECTS, true );
|
||||||
|
|
||||||
|
if (myDisplayer)
|
||||||
delete myDisplayer;
|
delete myDisplayer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -27,12 +27,13 @@
|
|||||||
// $Header$
|
// $Header$
|
||||||
|
|
||||||
#include "GEOMBase_Skeleton.h"
|
#include "GEOMBase_Skeleton.h"
|
||||||
|
|
||||||
#include "GeometryGUI.h"
|
#include "GeometryGUI.h"
|
||||||
|
|
||||||
#include "SUIT_Session.h"
|
|
||||||
#include "SalomeApp_Application.h"
|
#include "SalomeApp_Application.h"
|
||||||
#include "LightApp_Application.h"
|
#include "LightApp_Application.h"
|
||||||
#include "LightApp_SelectionMgr.h"
|
#include "LightApp_SelectionMgr.h"
|
||||||
|
#include "SUIT_Session.h"
|
||||||
#include "SUIT_MessageBox.h"
|
#include "SUIT_MessageBox.h"
|
||||||
|
|
||||||
#include <qpushbutton.h>
|
#include <qpushbutton.h>
|
||||||
@ -46,9 +47,12 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
GEOMBase_Skeleton::GEOMBase_Skeleton(QWidget* parent, const char* name, bool modal, WFlags fl)
|
GEOMBase_Skeleton::GEOMBase_Skeleton(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:DlgRef_Skeleton_QTD( parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu | WDestructiveClose ),
|
const char* name, bool modal, WFlags fl)
|
||||||
GEOMBase_Helper( dynamic_cast<SUIT_Desktop*>( parent ) )
|
: DlgRef_Skeleton_QTD( parent, name, modal, WStyle_Customize | WStyle_NormalBorder
|
||||||
|
| WStyle_Title | WStyle_SysMenu | WDestructiveClose ),
|
||||||
|
GEOMBase_Helper( dynamic_cast<SUIT_Desktop*>( parent ) ),
|
||||||
|
myGeomGUI( theGeometryGUI )
|
||||||
{
|
{
|
||||||
if (!name)
|
if (!name)
|
||||||
setName("GEOMBase_Skeleton");
|
setName("GEOMBase_Skeleton");
|
||||||
@ -82,13 +86,11 @@ GEOMBase_Skeleton::~GEOMBase_Skeleton()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void GEOMBase_Skeleton::Init()
|
void GEOMBase_Skeleton::Init()
|
||||||
{
|
{
|
||||||
myGeomGUI = 0;
|
|
||||||
SalomeApp_Application* app = (SalomeApp_Application*)(SUIT_Session::session()->activeApplication());
|
SalomeApp_Application* app = (SalomeApp_Application*)(SUIT_Session::session()->activeApplication());
|
||||||
if( app )
|
if (!myGeomGUI && app)
|
||||||
myGeomGUI = dynamic_cast<GeometryGUI*>( app->module( "Geometry" ) );
|
myGeomGUI = dynamic_cast<GeometryGUI*>( app->module( "Geometry" ) );
|
||||||
|
|
||||||
/* init variables */
|
/* init variables */
|
||||||
myGeomBase = new GEOMBase(); // SAN -- TO BE REMOVED !!!
|
|
||||||
myGeomGUI->SetActiveDialogBox(this);
|
myGeomGUI->SetActiveDialogBox(this);
|
||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
@ -102,10 +104,6 @@ void GEOMBase_Skeleton::Init()
|
|||||||
// connect help button on a private slot that displays help information
|
// connect help button on a private slot that displays help information
|
||||||
connect( buttonHelp, SIGNAL( clicked() ), this, SLOT( ClickOnHelp() ) );
|
connect( buttonHelp, SIGNAL( clicked() ), this, SLOT( ClickOnHelp() ) );
|
||||||
|
|
||||||
/* Move widget on the botton right corner of main widget */
|
|
||||||
// int x, y;
|
|
||||||
// myGeomBase->DefineDlgPosition( this, x, y );
|
|
||||||
|
|
||||||
/* displays Dialog */
|
/* displays Dialog */
|
||||||
RadioButton1->setChecked(TRUE);
|
RadioButton1->setChecked(TRUE);
|
||||||
RadioButton4->hide();
|
RadioButton4->hide();
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : GEOMBase_Skeleton.h
|
// File : GEOMBase_Skeleton.h
|
||||||
// Author : Damine COQUERET
|
// Author : Damine COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef GEOMBASE_SKELETON_H
|
#ifndef GEOMBASE_SKELETON_H
|
||||||
#define GEOMBASE_SKELETON_H
|
#define GEOMBASE_SKELETON_H
|
||||||
@ -58,9 +57,9 @@ class GEOMBASE_WNT_EXPORT GEOMBase_Skeleton : public DlgRef_Skeleton_QTD, public
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
GEOMBase_Skeleton(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
GEOMBase_Skeleton(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~GEOMBase_Skeleton();
|
~GEOMBase_Skeleton();
|
||||||
// int getConstructorId() const; // returns id of a selected "constructor" radio button or '-1' in case of error
|
|
||||||
|
|
||||||
private:
|
private:
|
||||||
void Init();
|
void Init();
|
||||||
@ -68,15 +67,22 @@ private :
|
|||||||
protected:
|
protected:
|
||||||
void closeEvent(QCloseEvent* e);
|
void closeEvent(QCloseEvent* e);
|
||||||
|
|
||||||
void initName( const char* thePrefix = 0 ); // initialize "Name" field with a string "thePrefix_X" (Vertex_3)
|
/*! initialize "Name" field with a string "thePrefix_X" (Vertex_3)
|
||||||
virtual const char* getNewObjectName() const; // returns contents of "Name" field
|
*/
|
||||||
int getConstructorId() const; // returns id of a selected "constructor" radio button or '-1' in case of error
|
void initName( const char* thePrefix = 0 );
|
||||||
|
|
||||||
|
/*! returns contents of "Name" field
|
||||||
|
*/
|
||||||
|
virtual const char* getNewObjectName() const;
|
||||||
|
|
||||||
|
/*! returns id of a selected "constructor" radio button or '-1' in case of error
|
||||||
|
*/
|
||||||
|
int getConstructorId() const;
|
||||||
|
|
||||||
void setHelpFileName( const QString& );
|
void setHelpFileName( const QString& );
|
||||||
|
|
||||||
QLineEdit* myEditCurrentArgument; /* Current LineEdit */
|
QLineEdit* myEditCurrentArgument; //!< Current LineEdit
|
||||||
GEOMBase* myGeomBase; // SAN -- TO BE REMOVED !!!
|
GeometryGUI* myGeomGUI; //!< reference GEOM GUI
|
||||||
GeometryGUI* myGeomGUI; /* reference GEOM GUI */
|
|
||||||
QString myHelpFileName;
|
QString myHelpFileName;
|
||||||
|
|
||||||
protected slots:
|
protected slots:
|
||||||
@ -85,7 +91,6 @@ protected slots:
|
|||||||
void DeactivateActiveDialog();
|
void DeactivateActiveDialog();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void ClickOnHelp();
|
void ClickOnHelp();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // GEOMBASE_SKELETON_H
|
#endif // GEOMBASE_SKELETON_H
|
||||||
|
@ -85,7 +85,7 @@ bool GenerationGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
case 4031: aDlg = new GenerationGUI_PrismDlg ( getGeometryGUI(), parent, ""); break;
|
case 4031: aDlg = new GenerationGUI_PrismDlg ( getGeometryGUI(), parent, ""); break;
|
||||||
case 4032: aDlg = new GenerationGUI_RevolDlg ( getGeometryGUI(), parent, ""); break;
|
case 4032: aDlg = new GenerationGUI_RevolDlg ( getGeometryGUI(), parent, ""); break;
|
||||||
case 4033: aDlg = new GenerationGUI_FillingDlg ( getGeometryGUI(), parent, ""); break;
|
case 4033: aDlg = new GenerationGUI_FillingDlg ( getGeometryGUI(), parent, ""); break;
|
||||||
case 4034: aDlg = new GenerationGUI_PipeDlg ( parent, ""); break;
|
case 4034: aDlg = new GenerationGUI_PipeDlg ( getGeometryGUI(), parent, ""); break;
|
||||||
|
|
||||||
default: SUIT_Session::session()->activeApplication()->putInfo( tr( "GEOM_PRP_COMMAND" ).arg( theCommandID ) ); break;
|
default: SUIT_Session::session()->activeApplication()->putInfo( tr( "GEOM_PRP_COMMAND" ).arg( theCommandID ) ); break;
|
||||||
}
|
}
|
||||||
|
@ -59,9 +59,8 @@
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
GenerationGUI_FillingDlg::GenerationGUI_FillingDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
GenerationGUI_FillingDlg::GenerationGUI_FillingDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
const char* name, bool modal, WFlags fl)
|
const char* name, bool modal, WFlags fl)
|
||||||
:GEOMBase_Skeleton(parent, name, modal,
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal,
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
myGeometryGUI(theGeometryGUI)
|
|
||||||
{
|
{
|
||||||
QPixmap image0 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_FILLING")));
|
QPixmap image0 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_FILLING")));
|
||||||
QPixmap image1 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_SELECT")));
|
QPixmap image1 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_SELECT")));
|
||||||
@ -150,11 +149,11 @@ void GenerationGUI_FillingDlg::Init()
|
|||||||
connect(GroupPoints->SpinBox_4, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupPoints->SpinBox_4, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
connect(GroupPoints->SpinBox_5, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(GroupPoints->SpinBox_5, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_1, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_1, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_2, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_2, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_3, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_3, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_4, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_4, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_5, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_5, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : GenerationGUI_FillingDlg.h
|
// File : GenerationGUI_FillingDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_FILLING_H
|
#ifndef DIALOGBOX_FILLING_H
|
||||||
#define DIALOGBOX_FILLING_H
|
#define DIALOGBOX_FILLING_H
|
||||||
@ -41,7 +40,8 @@ class GenerationGUI_FillingDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
GenerationGUI_FillingDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
GenerationGUI_FillingDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~GenerationGUI_FillingDlg();
|
~GenerationGUI_FillingDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -54,8 +54,6 @@ private:
|
|||||||
void Init();
|
void Init();
|
||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myCompound; /* compound of curves */
|
GEOM::GEOM_Object_var myCompound; /* compound of curves */
|
||||||
Standard_Integer myMinDeg;
|
Standard_Integer myMinDeg;
|
||||||
Standard_Integer myMaxDeg;
|
Standard_Integer myMaxDeg;
|
||||||
@ -74,7 +72,6 @@ private slots:
|
|||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
void ValueChangedInSpinBox(double newValue);
|
void ValueChangedInSpinBox(double newValue);
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_FILLING_H
|
#endif // DIALOGBOX_FILLING_H
|
||||||
|
@ -55,8 +55,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
GenerationGUI_PipeDlg::GenerationGUI_PipeDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
GenerationGUI_PipeDlg::GenerationGUI_PipeDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PIPE")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PIPE")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : GenerationGUI_PipeDlg.h
|
// File : GenerationGUI_PipeDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_PIPE_H
|
#ifndef DIALOGBOX_PIPE_H
|
||||||
#define DIALOGBOX_PIPE_H
|
#define DIALOGBOX_PIPE_H
|
||||||
@ -41,7 +40,8 @@ class GenerationGUI_PipeDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
GenerationGUI_PipeDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
GenerationGUI_PipeDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~GenerationGUI_PipeDlg();
|
~GenerationGUI_PipeDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -68,7 +68,6 @@ private slots:
|
|||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_PIPE_H
|
#endif // DIALOGBOX_PIPE_H
|
||||||
|
@ -50,8 +50,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
GenerationGUI_PrismDlg::GenerationGUI_PrismDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
GenerationGUI_PrismDlg::GenerationGUI_PrismDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PRISM")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PRISM")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
@ -128,7 +130,7 @@ void GenerationGUI_PrismDlg::Init()
|
|||||||
connect(GroupPoints->LineEdit2, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
connect(GroupPoints->LineEdit2, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
||||||
|
|
||||||
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(GroupPoints->CheckButton2, SIGNAL(toggled(bool)), this, SLOT(onReverse()));
|
connect(GroupPoints->CheckButton2, SIGNAL(toggled(bool)), this, SLOT(onReverse()));
|
||||||
|
|
||||||
@ -175,8 +177,7 @@ void GenerationGUI_PrismDlg::SelectionIntoArgument()
|
|||||||
erasePreview();
|
erasePreview();
|
||||||
myEditCurrentArgument->setText("");
|
myEditCurrentArgument->setText("");
|
||||||
|
|
||||||
if(IObjectCount() != 1)
|
if (IObjectCount() != 1) {
|
||||||
{
|
|
||||||
if (myEditCurrentArgument == GroupPoints->LineEdit1)
|
if (myEditCurrentArgument == GroupPoints->LineEdit1)
|
||||||
myOkBase = false;
|
myOkBase = false;
|
||||||
else if (myEditCurrentArgument == GroupPoints->LineEdit2)
|
else if (myEditCurrentArgument == GroupPoints->LineEdit2)
|
||||||
@ -186,7 +187,8 @@ void GenerationGUI_PrismDlg::SelectionIntoArgument()
|
|||||||
|
|
||||||
// nbSel == 1
|
// nbSel == 1
|
||||||
Standard_Boolean testResult = Standard_False;
|
Standard_Boolean testResult = Standard_False;
|
||||||
GEOM::GEOM_Object_ptr aSelectedObject = GEOMBase::ConvertIOinGEOMObject( firstIObject(), testResult );
|
GEOM::GEOM_Object_ptr aSelectedObject =
|
||||||
|
GEOMBase::ConvertIOinGEOMObject( firstIObject(), testResult );
|
||||||
|
|
||||||
if (!testResult)
|
if (!testResult)
|
||||||
return;
|
return;
|
||||||
@ -201,8 +203,7 @@ void GenerationGUI_PrismDlg::SelectionIntoArgument()
|
|||||||
|
|
||||||
myBase = aSelectedObject;
|
myBase = aSelectedObject;
|
||||||
myOkBase = true;
|
myOkBase = true;
|
||||||
}
|
} else if (myEditCurrentArgument == GroupPoints->LineEdit2) {
|
||||||
else if(myEditCurrentArgument == GroupPoints->LineEdit2) {
|
|
||||||
myVec = aSelectedObject;
|
myVec = aSelectedObject;
|
||||||
myOkVec = true;
|
myOkVec = true;
|
||||||
}
|
}
|
||||||
@ -286,7 +287,6 @@ void GenerationGUI_PrismDlg::ValueChangedInSpinBox()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : getHeight()
|
// function : getHeight()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -322,7 +322,8 @@ bool GenerationGUI_PrismDlg::execute( ObjectList& objects )
|
|||||||
{
|
{
|
||||||
GEOM::GEOM_Object_var anObj;
|
GEOM::GEOM_Object_var anObj;
|
||||||
|
|
||||||
anObj = GEOM::GEOM_I3DPrimOperations::_narrow(getOperation() )->MakePrismVecH ( myBase, myVec, getHeight() );
|
anObj = GEOM::GEOM_I3DPrimOperations::_narrow(getOperation())->
|
||||||
|
MakePrismVecH(myBase, myVec, getHeight());
|
||||||
|
|
||||||
if ( !anObj->_is_nil() )
|
if ( !anObj->_is_nil() )
|
||||||
objects.push_back( anObj._retn() );
|
objects.push_back( anObj._retn() );
|
||||||
@ -340,6 +341,3 @@ void GenerationGUI_PrismDlg::onReverse()
|
|||||||
double anOldValue = GroupPoints->SpinBox_DX->GetValue();
|
double anOldValue = GroupPoints->SpinBox_DX->GetValue();
|
||||||
GroupPoints->SpinBox_DX->SetValue( -anOldValue );
|
GroupPoints->SpinBox_DX->SetValue( -anOldValue );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : GenerationGUI_PrismDlg.h
|
// File : GenerationGUI_PrismDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_PRISM_H
|
#ifndef DIALOGBOX_PRISM_H
|
||||||
#define DIALOGBOX_PRISM_H
|
#define DIALOGBOX_PRISM_H
|
||||||
@ -41,7 +40,8 @@ class GenerationGUI_PrismDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
GenerationGUI_PrismDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
GenerationGUI_PrismDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~GenerationGUI_PrismDlg();
|
~GenerationGUI_PrismDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -55,8 +55,6 @@ private :
|
|||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
double getHeight() const;
|
double getHeight() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myBase; /* Base shape */
|
GEOM::GEOM_Object_var myBase; /* Base shape */
|
||||||
GEOM::GEOM_Object_var myVec; /* Vector, defining the direction */
|
GEOM::GEOM_Object_var myVec; /* Vector, defining the direction */
|
||||||
|
|
||||||
|
@ -52,8 +52,10 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
GenerationGUI_RevolDlg::GenerationGUI_RevolDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
GenerationGUI_RevolDlg::GenerationGUI_RevolDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_REVOL")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_REVOL")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
@ -129,7 +131,7 @@ void GenerationGUI_RevolDlg::Init()
|
|||||||
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
connect(GroupPoints->CheckButton2, SIGNAL(toggled(bool)), this, SLOT(onReverse()));
|
connect(GroupPoints->CheckButton2, SIGNAL(toggled(bool)), this, SLOT(onReverse()));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : GenerationGUI_RevolDlg.h
|
// File : GenerationGUI_RevolDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_REVOLUTION_H
|
#ifndef DIALOGBOX_REVOLUTION_H
|
||||||
#define DIALOGBOX_REVOLUTION_H
|
#define DIALOGBOX_REVOLUTION_H
|
||||||
@ -43,7 +42,8 @@ class GenerationGUI_RevolDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
GenerationGUI_RevolDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
GenerationGUI_RevolDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~GenerationGUI_RevolDlg();
|
~GenerationGUI_RevolDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -57,8 +57,6 @@ private :
|
|||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
double getAngle() const;
|
double getAngle() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myBase; /* Base shape */
|
GEOM::GEOM_Object_var myBase; /* Base shape */
|
||||||
GEOM::GEOM_Object_var myAxis; /* Axis of the revolution */
|
GEOM::GEOM_Object_var myAxis; /* Axis of the revolution */
|
||||||
bool myOkBase;
|
bool myOkBase;
|
||||||
@ -75,7 +73,6 @@ private slots:
|
|||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
void ValueChangedInSpinBox();
|
void ValueChangedInSpinBox();
|
||||||
void onReverse();
|
void onReverse();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_REVOLUTION_H
|
#endif // DIALOGBOX_REVOLUTION_H
|
||||||
|
@ -61,7 +61,6 @@ GroupGUI::GroupGUI(GeometryGUI* parent)
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
// function : ~GroupGUI()
|
// function : ~GroupGUI()
|
||||||
// purpose : Destructor
|
// purpose : Destructor
|
||||||
@ -81,7 +80,8 @@ bool GroupGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
|
|
||||||
QDialog* aDlg = NULL;
|
QDialog* aDlg = NULL;
|
||||||
|
|
||||||
SalomeApp_Study* appStudy = dynamic_cast<SalomeApp_Study*>( SUIT_Session::session()->activeApplication()->activeStudy() );
|
SUIT_Application* suitApp = SUIT_Session::session()->activeApplication();
|
||||||
|
SalomeApp_Study* appStudy = dynamic_cast<SalomeApp_Study*>(suitApp->activeStudy());
|
||||||
if ( !appStudy ) return false;
|
if ( !appStudy ) return false;
|
||||||
_PTR(Study) aStudy = appStudy->studyDS();
|
_PTR(Study) aStudy = appStudy->studyDS();
|
||||||
|
|
||||||
@ -95,15 +95,15 @@ bool GroupGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
|
|
||||||
switch ( theCommandID ) {
|
switch ( theCommandID ) {
|
||||||
case 800:
|
case 800:
|
||||||
case 8001:
|
case 8001: // CREATE GROUP
|
||||||
aDlg = new GroupGUI_GroupDlg( GroupGUI_GroupDlg::CreateGroup, parent, "");
|
aDlg = new GroupGUI_GroupDlg (GroupGUI_GroupDlg::CreateGroup, getGeometryGUI(), parent);
|
||||||
break;
|
break;
|
||||||
case 801:
|
case 801: // EDIT GROUP
|
||||||
{
|
{
|
||||||
SALOME_ListIO aList;
|
SALOME_ListIO aList;
|
||||||
aList.Clear();
|
aList.Clear();
|
||||||
|
|
||||||
SalomeApp_Application* app = dynamic_cast< SalomeApp_Application* >( SUIT_Session::session()->activeApplication() );
|
SalomeApp_Application* app = dynamic_cast<SalomeApp_Application*>(suitApp);
|
||||||
if (app) {
|
if (app) {
|
||||||
LightApp_SelectionMgr* aSelMgr = app->selectionMgr();
|
LightApp_SelectionMgr* aSelMgr = app->selectionMgr();
|
||||||
if (aSelMgr)
|
if (aSelMgr)
|
||||||
@ -116,18 +116,15 @@ bool GroupGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
GEOMBase::ConvertIOinGEOMObject( aList.First(), aResult );
|
GEOMBase::ConvertIOinGEOMObject( aList.First(), aResult );
|
||||||
|
|
||||||
if (aResult && !CORBA::is_nil(anObj) && anObj->GetType() == GEOM_GROUP) {
|
if (aResult && !CORBA::is_nil(anObj) && anObj->GetType() == GEOM_GROUP) {
|
||||||
aDlg = new GroupGUI_GroupDlg( GroupGUI_GroupDlg::EditGroup, parent, "" );
|
aDlg = new GroupGUI_GroupDlg (GroupGUI_GroupDlg::EditGroup, getGeometryGUI(), parent);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
SUIT_MessageBox::warn1 ( parent,
|
SUIT_MessageBox::warn1(parent, tr("WRN_WARNING"), tr("NO_GROUP"), tr("BUT_OK") );
|
||||||
tr("WRN_WARNING"),
|
|
||||||
tr("NO_GROUP"),
|
|
||||||
tr("BUT_OK") );
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
SUIT_Session::session()->activeApplication()->putInfo( tr( "GEOM_PRP_COMMAND" ).arg( theCommandID ) );
|
suitApp->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -47,12 +47,8 @@
|
|||||||
#include <TColStd_MapOfInteger.hxx>
|
#include <TColStd_MapOfInteger.hxx>
|
||||||
|
|
||||||
|
|
||||||
GroupGUI_GroupDlg::GroupGUI_GroupDlg(Mode mode,
|
GroupGUI_GroupDlg::GroupGUI_GroupDlg(Mode mode, GeometryGUI* theGeometryGUI, QWidget* parent)
|
||||||
QWidget* parent,
|
:GEOMBase_Skeleton( theGeometryGUI, parent, "GroupGUI_GroupDlg", false,
|
||||||
const char* name,
|
|
||||||
bool modal,
|
|
||||||
WFlags fl)
|
|
||||||
:GEOMBase_Skeleton( parent, "GroupGUI_GroupDlg", false,
|
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu),
|
||||||
myMode( mode ),
|
myMode( mode ),
|
||||||
myBusy( false )
|
myBusy( false )
|
||||||
@ -207,7 +203,6 @@ void GroupGUI_GroupDlg::ClickOnOk()
|
|||||||
ClickOnCancel();
|
ClickOnCancel();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ClickOnApply()
|
// function : ClickOnApply()
|
||||||
// purpose :
|
// purpose :
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : GroupGUI_GroupDlg.h
|
// File : GroupGUI_GroupDlg.h
|
||||||
// Author : Sergey ANIKIN
|
// Author : Sergey ANIKIN
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef GROUPGUI_GROUPDLG_H
|
#ifndef GROUPGUI_GROUPDLG_H
|
||||||
#define GROUPGUI_GROUPDLG_H
|
#define GROUPGUI_GROUPDLG_H
|
||||||
@ -50,7 +49,7 @@ public:
|
|||||||
EditGroup
|
EditGroup
|
||||||
} Mode;
|
} Mode;
|
||||||
|
|
||||||
GroupGUI_GroupDlg(Mode mode, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
GroupGUI_GroupDlg(Mode mode, GeometryGUI*, QWidget* parent = 0);
|
||||||
~GroupGUI_GroupDlg();
|
~GroupGUI_GroupDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -60,7 +59,6 @@ protected:
|
|||||||
virtual bool execute( ObjectList& objects );
|
virtual bool execute( ObjectList& objects );
|
||||||
virtual GEOM::GEOM_Object_ptr getFather( GEOM::GEOM_Object_ptr theObj );
|
virtual GEOM::GEOM_Object_ptr getFather( GEOM::GEOM_Object_ptr theObj );
|
||||||
|
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
|
@ -88,7 +88,7 @@ bool MeasureGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
switch ( theCommandID )
|
switch ( theCommandID )
|
||||||
{
|
{
|
||||||
case 701 : new MeasureGUI_PropertiesDlg (getGeometryGUI(), parent); break; // LENGTH, AREA AND VOLUME
|
case 701 : new MeasureGUI_PropertiesDlg (getGeometryGUI(), parent); break; // LENGTH, AREA AND VOLUME
|
||||||
case 702 : new MeasureGUI_CenterMassDlg ( parent ); break; // CENTER MASS
|
case 702 : new MeasureGUI_CenterMassDlg (getGeometryGUI(), parent); break; // CENTER MASS
|
||||||
case 703 : new MeasureGUI_InertiaDlg (getGeometryGUI(), parent); break; // INERTIA
|
case 703 : new MeasureGUI_InertiaDlg (getGeometryGUI(), parent); break; // INERTIA
|
||||||
case 7041: new MeasureGUI_BndBoxDlg (getGeometryGUI(), parent); break; // BOUNDING BOX
|
case 7041: new MeasureGUI_BndBoxDlg (getGeometryGUI(), parent); break; // BOUNDING BOX
|
||||||
case 7042: new MeasureGUI_DistanceDlg (getGeometryGUI(), parent); break; // MIN DISTANCE
|
case 7042: new MeasureGUI_DistanceDlg (getGeometryGUI(), parent); break; // MIN DISTANCE
|
||||||
@ -106,33 +106,6 @@ bool MeasureGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=====================================================================================
|
|
||||||
// function : MakeCDGAndDisplay()
|
|
||||||
// purpose :
|
|
||||||
//=====================================================================================
|
|
||||||
/*void MeasureGUI::MakeCDGAndDisplay(GEOM::GEOM_Shape_ptr Shape)
|
|
||||||
{
|
|
||||||
QAD_Application::getDesktop()->putInfo("MakeCDGAndDisplay method from MeasureGUI should be reimplemented ...");
|
|
||||||
|
|
||||||
try {
|
|
||||||
GEOM::GEOM_Shape_var result = myGeom->MakeCDG(Shape);
|
|
||||||
if(result->_is_nil()) {
|
|
||||||
QAD_Application::getDesktop()->putInfo(tr("GEOM_PRP_ABORT"));
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
result->NameType(tr("GEOM_POINT"));
|
|
||||||
if(myGeomBase->Display(result))
|
|
||||||
QAD_Application::getDesktop()->putInfo(tr("GEOM_PRP_DONE"));
|
|
||||||
}
|
|
||||||
catch(const SALOME::SALOME_Exception& S_ex) {
|
|
||||||
SalomeApp_Tools::QtCatchCorbaException(S_ex);
|
|
||||||
}
|
|
||||||
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
//=====================================================================================
|
//=====================================================================================
|
||||||
// EXPORTED METHODS
|
// EXPORTED METHODS
|
||||||
//=====================================================================================
|
//=====================================================================================
|
||||||
|
@ -191,22 +191,3 @@ SALOME_Prs* MeasureGUI_BndBoxDlg::buildPrs()
|
|||||||
return !aShape.IsNull() ? getDisplayer()->BuildPrs( aShape ) : 0;
|
return !aShape.IsNull() ? getDisplayer()->BuildPrs( aShape ) : 0;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : MeasureGUI_BndBoxDlg.h
|
// File : MeasureGUI_BndBoxDlg.h
|
||||||
// Author : Nicolas REJNERI
|
// Author : Nicolas REJNERI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_BNDBOX_H
|
#ifndef DIALOGBOX_BNDBOX_H
|
||||||
#define DIALOGBOX_BNDBOX_H
|
#define DIALOGBOX_BNDBOX_H
|
||||||
@ -51,36 +50,20 @@ public:
|
|||||||
MeasureGUI_BndBoxDlg(GeometryGUI* GUI,
|
MeasureGUI_BndBoxDlg(GeometryGUI* GUI,
|
||||||
QWidget* parent);
|
QWidget* parent);
|
||||||
~MeasureGUI_BndBoxDlg();
|
~MeasureGUI_BndBoxDlg();
|
||||||
protected:
|
|
||||||
|
|
||||||
|
protected:
|
||||||
// redefined from GEOMBase_Helper and MeasureGUI_Skeleton
|
// redefined from GEOMBase_Helper and MeasureGUI_Skeleton
|
||||||
virtual void processObject();
|
virtual void processObject();
|
||||||
virtual SALOME_Prs* buildPrs();
|
virtual SALOME_Prs* buildPrs();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
void Init();
|
void Init();
|
||||||
bool getParameters( double& Xmin, double& Xmax,
|
bool getParameters( double& Xmin, double& Xmax,
|
||||||
double& Ymin, double& Ymax,
|
double& Ymin, double& Ymax,
|
||||||
double& Zmin, double& Zmax );
|
double& Zmin, double& Zmax );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
MeasureGUI_1Sel6LineEdit_QTD* myGrp;
|
MeasureGUI_1Sel6LineEdit_QTD* myGrp;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_BNDBOX_H
|
#endif // DIALOGBOX_BNDBOX_H
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -49,8 +49,8 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
MeasureGUI_CenterMassDlg::MeasureGUI_CenterMassDlg( QWidget* parent )
|
MeasureGUI_CenterMassDlg::MeasureGUI_CenterMassDlg( GeometryGUI* theGeometryGUI, QWidget* parent )
|
||||||
: GEOMBase_Skeleton( parent, "MeasureGUI_CenterMassDlg", false,
|
: GEOMBase_Skeleton(theGeometryGUI, parent, "MeasureGUI_CenterMassDlg", false,
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_CENTERMASS")));
|
QPixmap image0 (SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_CENTERMASS")));
|
||||||
@ -59,7 +59,6 @@ MeasureGUI_CenterMassDlg::MeasureGUI_CenterMassDlg( QWidget* parent )
|
|||||||
setCaption( tr( "GEOM_CMASS_TITLE" ) );
|
setCaption( tr( "GEOM_CMASS_TITLE" ) );
|
||||||
|
|
||||||
/***************************************************************/
|
/***************************************************************/
|
||||||
|
|
||||||
GroupConstructors->setTitle( tr( "GEOM_CMASS" ) );
|
GroupConstructors->setTitle( tr( "GEOM_CMASS" ) );
|
||||||
RadioButton1->setPixmap( image0 );
|
RadioButton1->setPixmap( image0 );
|
||||||
RadioButton2->close( TRUE );
|
RadioButton2->close( TRUE );
|
||||||
@ -339,5 +338,3 @@ bool MeasureGUI_CenterMassDlg::execute( ObjectList& objects )
|
|||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -47,11 +47,11 @@ class MEASUREGUI_EXPORT MeasureGUI_CenterMassDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
MeasureGUI_CenterMassDlg( QWidget* parent );
|
MeasureGUI_CenterMassDlg( GeometryGUI* GUI,
|
||||||
|
QWidget* parent );
|
||||||
~MeasureGUI_CenterMassDlg();
|
~MeasureGUI_CenterMassDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
// redefined from GEOMBase_Helper
|
// redefined from GEOMBase_Helper
|
||||||
virtual GEOM::GEOM_IOperations_ptr createOperation();
|
virtual GEOM::GEOM_IOperations_ptr createOperation();
|
||||||
virtual bool isValid( QString& msg );
|
virtual bool isValid( QString& msg );
|
||||||
@ -66,14 +66,12 @@ private slots:
|
|||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
void Init( );
|
void Init( );
|
||||||
void enterEvent( QEvent* e );
|
void enterEvent( QEvent* e );
|
||||||
void processObject();
|
void processObject();
|
||||||
bool getParameters( double&, double&, double& );
|
bool getParameters( double&, double&, double& );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myObj;
|
GEOM::GEOM_Object_var myObj;
|
||||||
MeasureGUI_1Sel3LineEdit_QTD* myGrp;
|
MeasureGUI_1Sel3LineEdit_QTD* myGrp;
|
||||||
};
|
};
|
||||||
|
@ -30,6 +30,7 @@
|
|||||||
|
|
||||||
#include "SUIT_Session.h"
|
#include "SUIT_Session.h"
|
||||||
#include "SUIT_Desktop.h"
|
#include "SUIT_Desktop.h"
|
||||||
|
#include "SalomeApp_Application.h"
|
||||||
|
|
||||||
#include <TopTools_MapOfShape.hxx>
|
#include <TopTools_MapOfShape.hxx>
|
||||||
#include <TopExp_Explorer.hxx>
|
#include <TopExp_Explorer.hxx>
|
||||||
@ -87,24 +88,13 @@ bool OperationGUI::OnGUIEvent( int theCommandID, SUIT_Desktop* parent )
|
|||||||
|
|
||||||
switch (theCommandID)
|
switch (theCommandID)
|
||||||
{
|
{
|
||||||
case 503: // PARTITION
|
case 503: (new OperationGUI_PartitionDlg(getGeometryGUI(), parent))->show(); break;
|
||||||
( new OperationGUI_PartitionDlg( parent, "" ) )->show();
|
case 504: (new OperationGUI_ArchimedeDlg(getGeometryGUI(), parent))->show(); break;
|
||||||
break;
|
case 505: (new OperationGUI_FilletDlg (getGeometryGUI(), parent))->show(); break;
|
||||||
case 504: // ARCHIMEDE
|
case 506: (new OperationGUI_ChamferDlg (getGeometryGUI(), parent))->show(); break;
|
||||||
new OperationGUI_ArchimedeDlg( getGeometryGUI(), parent );
|
case 507: (new OperationGUI_ClippingDlg (getGeometryGUI(), parent))->show(); break;
|
||||||
break;
|
|
||||||
case 505: // FILLET
|
|
||||||
new OperationGUI_FilletDlg( parent );
|
|
||||||
break;
|
|
||||||
case 506: // CHAMFER
|
|
||||||
new OperationGUI_ChamferDlg( parent );
|
|
||||||
break;
|
|
||||||
case 507: // CLIPPING RANGE
|
|
||||||
( new OperationGUI_ClippingDlg( parent, "" ) )->show();
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
SUIT_Session::session()->activeApplication()->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
getGeometryGUI()->getApp()->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
@ -44,8 +44,8 @@
|
|||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
OperationGUI_ArchimedeDlg::OperationGUI_ArchimedeDlg( GeometryGUI* theGeometryGUI, QWidget* parent )
|
OperationGUI_ArchimedeDlg::OperationGUI_ArchimedeDlg( GeometryGUI* theGeometryGUI, QWidget* parent )
|
||||||
: GEOMBase_Skeleton( parent, "ArchimedeDlg", false,
|
: GEOMBase_Skeleton(theGeometryGUI, parent, "ArchimedeDlg", false,
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_ARCHIMEDE")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_ARCHIMEDE")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
@ -117,22 +117,18 @@ void OperationGUI_ArchimedeDlg::Init()
|
|||||||
|
|
||||||
connect(GroupPoints->LineEdit1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
connect(GroupPoints->LineEdit1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DZ, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DZ, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
initName( tr( "GEOM_ARCHIMEDE" ) );
|
initName( tr( "GEOM_ARCHIMEDE" ) );
|
||||||
|
|
||||||
globalSelection( GEOM_ALLSHAPES );
|
globalSelection( GEOM_ALLSHAPES );
|
||||||
|
|
||||||
SelectionIntoArgument();
|
SelectionIntoArgument();
|
||||||
|
|
||||||
/* displays Dialog */
|
|
||||||
GroupPoints->show();
|
|
||||||
this->show();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -210,7 +206,7 @@ void OperationGUI_ArchimedeDlg::ActivateThisDialog()
|
|||||||
{
|
{
|
||||||
GEOMBase_Skeleton::ActivateThisDialog();
|
GEOMBase_Skeleton::ActivateThisDialog();
|
||||||
globalSelection( GEOM_ALLSHAPES );
|
globalSelection( GEOM_ALLSHAPES );
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : OperationGUI_ArchimedeDlg.h
|
// File : OperationGUI_ArchimedeDlg.h
|
||||||
// Author : Nicolas REJNERI
|
// Author : Nicolas REJNERI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_ARCHIMEDE_H
|
#ifndef DIALOGBOX_ARCHIMEDE_H
|
||||||
#define DIALOGBOX_ARCHIMEDE_H
|
#define DIALOGBOX_ARCHIMEDE_H
|
||||||
@ -46,9 +45,7 @@ public:
|
|||||||
~OperationGUI_ArchimedeDlg();
|
~OperationGUI_ArchimedeDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
|
|
||||||
// redefined from GEOMBase_Helper
|
// redefined from GEOMBase_Helper
|
||||||
|
|
||||||
virtual GEOM::GEOM_IOperations_ptr createOperation();
|
virtual GEOM::GEOM_IOperations_ptr createOperation();
|
||||||
virtual bool isValid( QString& msg );
|
virtual bool isValid( QString& msg );
|
||||||
virtual bool execute( ObjectList& objects );
|
virtual bool execute( ObjectList& objects );
|
||||||
@ -61,7 +58,6 @@ private:
|
|||||||
GEOM::GEOM_Object_var myShape;
|
GEOM::GEOM_Object_var myShape;
|
||||||
DlgRef_1Sel3Spin* GroupPoints;
|
DlgRef_1Sel3Spin* GroupPoints;
|
||||||
double myStep;
|
double myStep;
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : OperationGUI_ChamferDlg.cxx
|
// File : OperationGUI_ChamferDlg.cxx
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
|
|
||||||
// $Header$
|
// $Header$
|
||||||
|
|
||||||
#include "OperationGUI_ChamferDlg.h"
|
#include "OperationGUI_ChamferDlg.h"
|
||||||
@ -51,8 +50,8 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
OperationGUI_ChamferDlg::OperationGUI_ChamferDlg( QWidget* parent )
|
OperationGUI_ChamferDlg::OperationGUI_ChamferDlg(GeometryGUI* theGeometryGUI, QWidget* parent)
|
||||||
: GEOMBase_Skeleton(parent, "ChamferDlg", false,
|
: GEOMBase_Skeleton(theGeometryGUI, parent, "ChamferDlg", false,
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
myConstructorId = -1;
|
myConstructorId = -1;
|
||||||
@ -205,7 +204,7 @@ void OperationGUI_ChamferDlg::Init()
|
|||||||
this, SLOT( ValueChangedInSpinBox( double ) ) );
|
this, SLOT( ValueChangedInSpinBox( double ) ) );
|
||||||
|
|
||||||
// selection
|
// selection
|
||||||
connect( ((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
initName( tr( "GEOM_CHAMFER" ) );
|
initName( tr( "GEOM_CHAMFER" ) );
|
||||||
@ -213,8 +212,6 @@ void OperationGUI_ChamferDlg::Init()
|
|||||||
myGrp2->hide();
|
myGrp2->hide();
|
||||||
myGrp3->hide();
|
myGrp3->hide();
|
||||||
myGrp1->show();
|
myGrp1->show();
|
||||||
|
|
||||||
this->show();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -225,7 +222,7 @@ void OperationGUI_ChamferDlg::Init()
|
|||||||
void OperationGUI_ChamferDlg::ConstructorsClicked( int constructorId )
|
void OperationGUI_ChamferDlg::ConstructorsClicked( int constructorId )
|
||||||
{
|
{
|
||||||
// Activate next widget
|
// Activate next widget
|
||||||
if ( SUIT_Session::session()->activeApplication()->desktop()->activeWindow()->getViewManager()->getType()
|
if (myGeomGUI->getApp()->desktop()->activeWindow()->getViewManager()->getType()
|
||||||
!= OCCViewer_Viewer::Type())
|
!= OCCViewer_Viewer::Type())
|
||||||
{
|
{
|
||||||
RadioButton1->setChecked( true );
|
RadioButton1->setChecked( true );
|
||||||
@ -465,17 +462,6 @@ void OperationGUI_ChamferDlg::SetEditCurrentArgument()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : DeactivateActiveDialog()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
void OperationGUI_ChamferDlg::DeactivateActiveDialog()
|
|
||||||
{
|
|
||||||
// disconnect selection
|
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ActivateThisDialog()
|
// function : ActivateThisDialog()
|
||||||
// purpose :
|
// purpose :
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : OperationGUI_ChamferDlg.h
|
// File : OperationGUI_ChamferDlg.h
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_CHAMFER_H
|
#ifndef DIALOGBOX_CHAMFER_H
|
||||||
#define DIALOGBOX_CHAMFER_H
|
#define DIALOGBOX_CHAMFER_H
|
||||||
@ -46,7 +45,7 @@ class OperationGUI_ChamferDlg : public GEOMBase_Skeleton
|
|||||||
enum { SpinBox1, SpinBox21, SpinBox22, SpinBox31, SpinBox32 };
|
enum { SpinBox1, SpinBox21, SpinBox22, SpinBox31, SpinBox32 };
|
||||||
|
|
||||||
public:
|
public:
|
||||||
OperationGUI_ChamferDlg( QWidget* parent );
|
OperationGUI_ChamferDlg(GeometryGUI* theGeometryGUI, QWidget* parent);
|
||||||
virtual ~OperationGUI_ChamferDlg();
|
virtual ~OperationGUI_ChamferDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -56,11 +55,9 @@ protected:
|
|||||||
virtual bool execute( ObjectList& objects );
|
virtual bool execute( ObjectList& objects );
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
|
|
||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void DeactivateActiveDialog();
|
|
||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
@ -68,7 +65,6 @@ private slots:
|
|||||||
void ConstructorsClicked( int constructorId );
|
void ConstructorsClicked( int constructorId );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
void Init();
|
void Init();
|
||||||
void enterEvent( QEvent* e );
|
void enterEvent( QEvent* e );
|
||||||
void reset();
|
void reset();
|
||||||
@ -78,7 +74,6 @@ private :
|
|||||||
void enableWidgets();
|
void enableWidgets();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
int myConstructorId;
|
int myConstructorId;
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myShape;
|
GEOM::GEOM_Object_var myShape;
|
||||||
@ -95,4 +90,3 @@ private:
|
|||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_CHAMFER_H
|
#endif // DIALOGBOX_CHAMFER_H
|
||||||
|
|
||||||
|
@ -57,8 +57,8 @@
|
|||||||
// class : OperationGUI_ClippingDlg()
|
// class : OperationGUI_ClippingDlg()
|
||||||
// purpose :
|
// purpose :
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
OperationGUI_ClippingDlg::OperationGUI_ClippingDlg( QWidget* parent, const char* name, bool modal, WFlags fl )
|
OperationGUI_ClippingDlg::OperationGUI_ClippingDlg(GeometryGUI* theGeometryGUI, QWidget* parent)
|
||||||
: GEOMBase_Skeleton( parent, "OperationGUI_ClippingDlg", false,
|
: GEOMBase_Skeleton(theGeometryGUI, parent, "OperationGUI_ClippingDlg", false,
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
setCaption( tr( "Change clipping range" ) );
|
setCaption( tr( "Change clipping range" ) );
|
||||||
@ -110,18 +110,12 @@ OperationGUI_ClippingDlg::OperationGUI_ClippingDlg( QWidget* parent, const char*
|
|||||||
SpinBox_Near->RangeStepAndValidator( -999999.999, +999999.999, 10.0, 3 );
|
SpinBox_Near->RangeStepAndValidator( -999999.999, +999999.999, 10.0, 3 );
|
||||||
SpinBox_Far->RangeStepAndValidator( -999999.999, +999999.999, 10.0, 3 );
|
SpinBox_Far->RangeStepAndValidator( -999999.999, +999999.999, 10.0, 3 );
|
||||||
|
|
||||||
//GeometryGUI* aGeomGUI = GeometryGUI::GetGeomGUI();
|
|
||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect( buttonOk , SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) );
|
connect( buttonOk , SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) );
|
||||||
connect( buttonCancel, SIGNAL( clicked() ), this, SLOT( ClickOnCancel() ) ) ;
|
|
||||||
connect( buttonApply, SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) );
|
connect( buttonApply, SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) );
|
||||||
|
|
||||||
connect( resetButton, SIGNAL (clicked() ), this, SLOT( onReset() ) ) ;
|
connect( resetButton, SIGNAL (clicked() ), this, SLOT( onReset() ) ) ;
|
||||||
|
|
||||||
// connect( aGeomGUI, SIGNAL ( SignalDeactivateActiveDialog() ), this, SLOT( onDeactivate() ) ) ;
|
|
||||||
//connect( aGeomGUI, SIGNAL ( SignalCloseAllDialogs() ), this, SLOT( ClickOnCancel() ) ) ;
|
|
||||||
|
|
||||||
setHelpFileName("none.htm");
|
setHelpFileName("none.htm");
|
||||||
|
|
||||||
Init();
|
Init();
|
||||||
@ -136,7 +130,6 @@ OperationGUI_ClippingDlg::~ OperationGUI_ClippingDlg()
|
|||||||
// no need to delete child widgets, Qt does it all for us
|
// no need to delete child widgets, Qt does it all for us
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : Init()
|
// function : Init()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -276,17 +269,6 @@ void OperationGUI_ClippingDlg::ClickOnOk()
|
|||||||
ClickOnCancel();
|
ClickOnCancel();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : ClickOnCancel()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
void OperationGUI_ClippingDlg::ClickOnCancel()
|
|
||||||
{
|
|
||||||
GEOMBase_Skeleton::ClickOnCancel();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : onActivate()
|
// function : onActivate()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -296,27 +278,16 @@ void OperationGUI_ClippingDlg::onActivate()
|
|||||||
GEOMBase_Skeleton::ActivateThisDialog();
|
GEOMBase_Skeleton::ActivateThisDialog();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : onDeactivate()
|
|
||||||
// purpose : public slot to deactivate if active
|
|
||||||
//=================================================================================
|
|
||||||
void OperationGUI_ClippingDlg::DeactivateActiveDialog()
|
|
||||||
{
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : enterEvent()
|
// function : enterEvent()
|
||||||
// purpose :
|
// purpose :
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
void OperationGUI_ClippingDlg::enterEvent(QEvent* e)
|
void OperationGUI_ClippingDlg::enterEvent(QEvent*)
|
||||||
{
|
{
|
||||||
this->setEnabled(true);
|
this->setEnabled(true);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : closeEvent
|
// function : closeEvent
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -326,14 +297,14 @@ void OperationGUI_ClippingDlg::closeEvent( QCloseEvent* e )
|
|||||||
QDialog::closeEvent( e );
|
QDialog::closeEvent( e );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : onReset()
|
// function : onReset()
|
||||||
// purpose :
|
// purpose :
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
void OperationGUI_ClippingDlg::onReset()
|
void OperationGUI_ClippingDlg::onReset()
|
||||||
{
|
{
|
||||||
SUIT_ViewWindow* anActiveWindow = SUIT_Session::session()->activeApplication()->desktop()->activeWindow();
|
SUIT_ViewWindow* anActiveWindow =
|
||||||
|
SUIT_Session::session()->activeApplication()->desktop()->activeWindow();
|
||||||
if (!anActiveWindow)
|
if (!anActiveWindow)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
@ -399,7 +370,5 @@ void OperationGUI_ClippingDlg::onReset()
|
|||||||
TypeCB->setCurrentItem(ztype);
|
TypeCB->setCurrentItem(ztype);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : OperationGUI_ClippingDlg.h
|
// File : OperationGUI_ClippingDlg.h
|
||||||
// Author : Michael Zorin
|
// Author : Michael Zorin
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header:
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_CLIPPINGRANGE_H
|
#ifndef DIALOGBOX_CLIPPINGRANGE_H
|
||||||
#define DIALOGBOX_CLIPPING_H
|
#define DIALOGBOX_CLIPPING_H
|
||||||
@ -48,11 +47,10 @@ class OperationGUI_ClippingDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
OperationGUI_ClippingDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
OperationGUI_ClippingDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0);
|
||||||
~OperationGUI_ClippingDlg();
|
~OperationGUI_ClippingDlg();
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
void Init();
|
void Init();
|
||||||
|
|
||||||
ViewerTypes myViewerType;
|
ViewerTypes myViewerType;
|
||||||
@ -71,10 +69,7 @@ private :
|
|||||||
private slots:
|
private slots:
|
||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ClickOnCancel();
|
|
||||||
void onActivate();
|
void onActivate();
|
||||||
void DeactivateActiveDialog();
|
|
||||||
|
|
||||||
void onReset();
|
void onReset();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -51,17 +51,18 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
OperationGUI_FilletDlg::OperationGUI_FilletDlg( QWidget* parent )
|
OperationGUI_FilletDlg::OperationGUI_FilletDlg(GeometryGUI* theGeometryGUI, QWidget* parent)
|
||||||
:GEOMBase_Skeleton( parent, "OperationGUI_FilletDlg", false,
|
:GEOMBase_Skeleton(theGeometryGUI, parent, "OperationGUI_FilletDlg", false,
|
||||||
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
myConstructorId = -1;
|
myConstructorId = -1;
|
||||||
|
|
||||||
QPixmap image0( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_FILLET_ALL" ) ) );
|
SUIT_ResourceMgr* aResMgr = myGeomGUI->getApp()->resourceMgr();
|
||||||
QPixmap image1( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_FILLET_EDGE" ) ) );
|
QPixmap image0 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_FILLET_ALL")));
|
||||||
QPixmap image2( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_DLG_FILLET_FACE" ) ) );
|
QPixmap image1 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_FILLET_EDGE")));
|
||||||
|
QPixmap image2 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_FILLET_FACE")));
|
||||||
|
|
||||||
QPixmap iconSelect( SUIT_Session::session()->resourceMgr()->loadPixmap( "GEOM", tr( "ICON_SELECT" ) ) );
|
QPixmap iconSelect(aResMgr->loadPixmap("GEOM", tr("ICON_SELECT")));
|
||||||
|
|
||||||
setCaption(tr("GEOM_FILLET_TITLE"));
|
setCaption(tr("GEOM_FILLET_TITLE"));
|
||||||
|
|
||||||
@ -160,17 +161,14 @@ void OperationGUI_FilletDlg::Init()
|
|||||||
connect(Group3->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
connect(Group3->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox(double)));
|
||||||
|
|
||||||
// selection
|
// selection
|
||||||
connect( ((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
|
|
||||||
initName( tr( "GEOM_FILLET" ) );
|
initName( tr( "GEOM_FILLET" ) );
|
||||||
|
|
||||||
Group2->hide();
|
Group2->hide();
|
||||||
Group3->hide();
|
Group3->hide();
|
||||||
Group1->show();
|
Group1->show();
|
||||||
|
|
||||||
this->show();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -311,7 +309,7 @@ void OperationGUI_FilletDlg::SelectionIntoArgument()
|
|||||||
if ( aResult && !anObj->_is_nil() )
|
if ( aResult && !anObj->_is_nil() )
|
||||||
{
|
{
|
||||||
TColStd_IndexedMapOfInteger anIndexes;
|
TColStd_IndexedMapOfInteger anIndexes;
|
||||||
((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr()->GetIndexes( firstIObject(), anIndexes );
|
myGeomGUI->getApp()->selectionMgr()->GetIndexes( firstIObject(), anIndexes );
|
||||||
|
|
||||||
if ( anIndexes.Extent() > 0 )
|
if ( anIndexes.Extent() > 0 )
|
||||||
{
|
{
|
||||||
@ -402,17 +400,6 @@ void OperationGUI_FilletDlg::SetEditCurrentArgument()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : DeactivateActiveDialog()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
void OperationGUI_FilletDlg::DeactivateActiveDialog()
|
|
||||||
{
|
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ActivateThisDialog()
|
// function : ActivateThisDialog()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -421,7 +408,7 @@ void OperationGUI_FilletDlg::ActivateThisDialog()
|
|||||||
{
|
{
|
||||||
GEOMBase_Skeleton::ActivateThisDialog();
|
GEOMBase_Skeleton::ActivateThisDialog();
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
activateSelection();
|
activateSelection();
|
||||||
@ -628,10 +615,3 @@ double OperationGUI_FilletDlg::getRadius() const
|
|||||||
else if ( anId == 1 ) return Group2->SpinBox_DX->GetValue();
|
else if ( anId == 1 ) return Group2->SpinBox_DX->GetValue();
|
||||||
else return Group3->SpinBox_DX->GetValue();
|
else return Group3->SpinBox_DX->GetValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : OperationGUI_FilletDlg.h
|
// File : OperationGUI_FilletDlg.h
|
||||||
// Author : Damien COQUERET
|
// Author : Damien COQUERET
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_FILLET_H
|
#ifndef DIALOGBOX_FILLET_H
|
||||||
#define DIALOGBOX_FILLET_H
|
#define DIALOGBOX_FILLET_H
|
||||||
@ -45,7 +44,7 @@ class OperationGUI_FilletDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
OperationGUI_FilletDlg( QWidget* parent );
|
OperationGUI_FilletDlg(GeometryGUI* theGeometryGUI, QWidget* parent);
|
||||||
~OperationGUI_FilletDlg();
|
~OperationGUI_FilletDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -55,11 +54,9 @@ protected:
|
|||||||
virtual bool execute( ObjectList& objects );
|
virtual bool execute( ObjectList& objects );
|
||||||
|
|
||||||
private slots:
|
private slots:
|
||||||
|
|
||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void DeactivateActiveDialog();
|
|
||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
@ -67,7 +64,6 @@ private slots:
|
|||||||
void ConstructorsClicked( int constructorId );
|
void ConstructorsClicked( int constructorId );
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
void Init();
|
void Init();
|
||||||
void enterEvent( QEvent* e );
|
void enterEvent( QEvent* e );
|
||||||
void reset();
|
void reset();
|
||||||
@ -77,7 +73,6 @@ private :
|
|||||||
double getRadius() const;
|
double getRadius() const;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
||||||
int myConstructorId;
|
int myConstructorId;
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myShape;
|
GEOM::GEOM_Object_var myShape;
|
||||||
@ -90,4 +85,3 @@ private :
|
|||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_FILLET_H
|
#endif // DIALOGBOX_FILLET_H
|
||||||
|
|
||||||
|
@ -47,10 +47,11 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
OperationGUI_MaterialDlg::OperationGUI_MaterialDlg (QWidget* parent, const char* name,
|
OperationGUI_MaterialDlg::OperationGUI_MaterialDlg (GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
GEOM::ListOfGO ListShapes,
|
const char* name, GEOM::ListOfGO ListShapes,
|
||||||
bool modal, WFlags fl)
|
bool modal, WFlags fl)
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
myListShapes = ListShapes;
|
myListShapes = ListShapes;
|
||||||
myParentDlg = parent;
|
myParentDlg = parent;
|
||||||
@ -83,7 +84,6 @@ OperationGUI_MaterialDlg::OperationGUI_MaterialDlg (QWidget* parent, const char*
|
|||||||
Init();
|
Init();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ~OperationGUI_MaterialDlg()
|
// function : ~OperationGUI_MaterialDlg()
|
||||||
// purpose : Destroys the object and frees any allocated resources
|
// purpose : Destroys the object and frees any allocated resources
|
||||||
@ -93,7 +93,6 @@ OperationGUI_MaterialDlg::~OperationGUI_MaterialDlg()
|
|||||||
// no need to delete child widgets, Qt does it all for us
|
// no need to delete child widgets, Qt does it all for us
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : Init()
|
// function : Init()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -130,20 +129,8 @@ void OperationGUI_MaterialDlg::Init()
|
|||||||
|
|
||||||
connect(GroupPoints->PushButton1, SIGNAL(clicked()), this, SLOT(SetMaterial()));
|
connect(GroupPoints->PushButton1, SIGNAL(clicked()), this, SLOT(SetMaterial()));
|
||||||
|
|
||||||
// connect(GroupPoints->ListView1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
|
||||||
// connect(GroupPoints->SpinBox1, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
/* displays Dialog */
|
|
||||||
MESSAGE("GroupPoints->show() ...");
|
|
||||||
GroupPoints->show();
|
|
||||||
MESSAGE("this->show() ...");
|
|
||||||
this->show();
|
|
||||||
MESSAGE("return");
|
|
||||||
|
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -184,17 +171,17 @@ void OperationGUI_MaterialDlg::ClickOnOk()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void OperationGUI_MaterialDlg::SelectionIntoArgument()
|
void OperationGUI_MaterialDlg::SelectionIntoArgument()
|
||||||
{
|
{
|
||||||
QString aString = ""; /* name of selection */
|
/*QString aString = ""; // name of selection
|
||||||
|
|
||||||
int nbSel = myGeomBase->GetNameOfSelectedIObjects(selectedIO(), aString);
|
int nbSel = GEOMBase::GetNameOfSelectedIObjects(selectedIO(), aString);
|
||||||
if (nbSel < 1) {
|
if (nbSel < 1) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
//myGeomBase->ConvertListOfIOInListOfIOR(selectedIO(), myListShapes);
|
//myGeomBase->ConvertListOfIOInListOfIOR(selectedIO(), myListShapes);
|
||||||
|
|
||||||
/* no simulation */
|
// no simulation
|
||||||
return;
|
return;*/
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -23,7 +23,6 @@
|
|||||||
// File : OperationGUI_MaterialDlg.h
|
// File : OperationGUI_MaterialDlg.h
|
||||||
// Author : Julia DOROVSKIKH
|
// Author : Julia DOROVSKIKH
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_MATERIAL_H
|
#ifndef DIALOGBOX_MATERIAL_H
|
||||||
#define DIALOGBOX_MATERIAL_H
|
#define DIALOGBOX_MATERIAL_H
|
||||||
@ -41,8 +40,8 @@ class OperationGUI_MaterialDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
OperationGUI_MaterialDlg (QWidget* parent, const char* name,
|
OperationGUI_MaterialDlg (GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
GEOM::ListOfGO ListShapes,
|
const char* name, GEOM::ListOfGO ListShapes,
|
||||||
bool modal = FALSE, WFlags fl = 0);
|
bool modal = FALSE, WFlags fl = 0);
|
||||||
~OperationGUI_MaterialDlg();
|
~OperationGUI_MaterialDlg();
|
||||||
|
|
||||||
@ -65,7 +64,6 @@ private slots:
|
|||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetMaterial();
|
void SetMaterial();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_MATERIAL_H
|
#endif // DIALOGBOX_MATERIAL_H
|
||||||
|
@ -49,12 +49,14 @@
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
OperationGUI_PartitionDlg::OperationGUI_PartitionDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
OperationGUI_PartitionDlg::OperationGUI_PartitionDlg(GeometryGUI* theGeometryGUI, QWidget* parent)
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
:GEOMBase_Skeleton(theGeometryGUI, parent, "OperationGUI_PartitionDlg", false,
|
||||||
|
WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PARTITION")));
|
SUIT_ResourceMgr* aResMgr = myGeomGUI->getApp()->resourceMgr();
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_PARTITION_PLANE")));
|
QPixmap image0 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_PARTITION")));
|
||||||
QPixmap image2(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1 (aResMgr->loadPixmap("GEOM", tr("ICON_DLG_PARTITION_PLANE")));
|
||||||
|
QPixmap image2 (aResMgr->loadPixmap("GEOM", tr("ICON_SELECT")));
|
||||||
|
|
||||||
setCaption(tr("GEOM_PARTITION_TITLE"));
|
setCaption(tr("GEOM_PARTITION_TITLE"));
|
||||||
|
|
||||||
@ -137,7 +139,7 @@ void OperationGUI_PartitionDlg::Init()
|
|||||||
|
|
||||||
connect(GroupPoints->ComboBox1, SIGNAL(activated(int)), this, SLOT(ComboTextChanged()));
|
connect(GroupPoints->ComboBox1, SIGNAL(activated(int)), this, SLOT(ComboTextChanged()));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
initName( tr( "GEOM_PARTITION" ) );
|
initName( tr( "GEOM_PARTITION" ) );
|
||||||
@ -151,7 +153,7 @@ void OperationGUI_PartitionDlg::Init()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void OperationGUI_PartitionDlg::ConstructorsClicked(int constructorId)
|
void OperationGUI_PartitionDlg::ConstructorsClicked(int constructorId)
|
||||||
{
|
{
|
||||||
disconnect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(), 0, this, 0);
|
disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
|
||||||
globalSelection();
|
globalSelection();
|
||||||
|
|
||||||
myListShapes.length(0);
|
myListShapes.length(0);
|
||||||
@ -195,7 +197,7 @@ void OperationGUI_PartitionDlg::ConstructorsClicked(int constructorId)
|
|||||||
onRemoveWebs(false);
|
onRemoveWebs(false);
|
||||||
|
|
||||||
myEditCurrentArgument->setFocus();
|
myEditCurrentArgument->setFocus();
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
MESSAGE(width()<<" "<<height());
|
MESSAGE(width()<<" "<<height());
|
||||||
}
|
}
|
||||||
@ -227,16 +229,6 @@ bool OperationGUI_PartitionDlg::ClickOnApply()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=======================================================================
|
|
||||||
// function : ClickOnCancel()
|
|
||||||
// purpose :
|
|
||||||
//=======================================================================
|
|
||||||
void OperationGUI_PartitionDlg::ClickOnCancel()
|
|
||||||
{
|
|
||||||
GEOMBase_Skeleton::ClickOnCancel();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : SelectionIntoArgument()
|
// function : SelectionIntoArgument()
|
||||||
// purpose : Called when selection as changed or other case
|
// purpose : Called when selection as changed or other case
|
||||||
@ -355,23 +347,13 @@ void OperationGUI_PartitionDlg::LineEditReturnPressed()
|
|||||||
void OperationGUI_PartitionDlg::ActivateThisDialog()
|
void OperationGUI_PartitionDlg::ActivateThisDialog()
|
||||||
{
|
{
|
||||||
GEOMBase_Skeleton::ActivateThisDialog();
|
GEOMBase_Skeleton::ActivateThisDialog();
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
ConstructorsClicked( getConstructorId() );
|
ConstructorsClicked( getConstructorId() );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : DeactivateActiveDialog()
|
|
||||||
// purpose : public slot to deactivate if active
|
|
||||||
//=================================================================================
|
|
||||||
void OperationGUI_PartitionDlg::DeactivateActiveDialog()
|
|
||||||
{
|
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : enterEvent()
|
// function : enterEvent()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -421,19 +403,14 @@ bool OperationGUI_PartitionDlg::execute( ObjectList& objects )
|
|||||||
if (aConstructorId == 1)
|
if (aConstructorId == 1)
|
||||||
aLimit = GEOM::SHAPE;
|
aLimit = GEOM::SHAPE;
|
||||||
|
|
||||||
if (isValid( msg ))
|
if (isValid( msg )) {
|
||||||
{
|
|
||||||
|
|
||||||
if (aConstructorId == 0 && !toRemoveWebs())
|
if (aConstructorId == 0 && !toRemoveWebs())
|
||||||
myListMaterials.length(0);
|
myListMaterials.length(0);
|
||||||
|
|
||||||
anObj = GEOM::GEOM_IBooleanOperations::_narrow( getOperation() )->MakePartition(myListShapes,
|
anObj = GEOM::GEOM_IBooleanOperations::_narrow(getOperation())->
|
||||||
myListTools,
|
MakePartition(myListShapes, myListTools,
|
||||||
myListKeepInside,
|
myListKeepInside, myListRemoveInside,
|
||||||
myListRemoveInside,
|
aLimit, toRemoveWebs(), myListMaterials);
|
||||||
aLimit,
|
|
||||||
toRemoveWebs(),
|
|
||||||
myListMaterials);
|
|
||||||
res = true;
|
res = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -458,7 +435,6 @@ void OperationGUI_PartitionDlg::closeEvent( QCloseEvent* e )
|
|||||||
//function : ComboTextChanged
|
//function : ComboTextChanged
|
||||||
//purpose :
|
//purpose :
|
||||||
//=======================================================================
|
//=======================================================================
|
||||||
|
|
||||||
void OperationGUI_PartitionDlg::ComboTextChanged()
|
void OperationGUI_PartitionDlg::ComboTextChanged()
|
||||||
{
|
{
|
||||||
bool IsEnabled = GroupPoints->ComboBox1->currentItem() < 3;
|
bool IsEnabled = GroupPoints->ComboBox1->currentItem() < 3;
|
||||||
@ -477,11 +453,9 @@ void OperationGUI_PartitionDlg::ComboTextChanged()
|
|||||||
//=================================================================================
|
//=================================================================================
|
||||||
void OperationGUI_PartitionDlg::SetMaterials()
|
void OperationGUI_PartitionDlg::SetMaterials()
|
||||||
{
|
{
|
||||||
MESSAGE("OperationGUI_MaterialDlg ...");
|
|
||||||
OperationGUI_MaterialDlg* aDlg =
|
OperationGUI_MaterialDlg* aDlg =
|
||||||
new OperationGUI_MaterialDlg(this, "", myListShapes, true);
|
new OperationGUI_MaterialDlg(myGeomGUI, this, "", myListShapes, true);
|
||||||
MESSAGE("OperationGUI_MaterialDlg");
|
aDlg->show();
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -518,38 +492,13 @@ int OperationGUI_PartitionDlg::GetLimit() const
|
|||||||
|
|
||||||
switch(aLimit)
|
switch(aLimit)
|
||||||
{
|
{
|
||||||
case 0 :
|
case 0: aLimit = GEOM::SOLID ; break;
|
||||||
{
|
case 1: aLimit = GEOM::SHELL ; break;
|
||||||
aLimit = GEOM::SOLID;
|
case 2: aLimit = GEOM::FACE ; break;
|
||||||
break;
|
case 3: aLimit = GEOM::WIRE ; break;
|
||||||
}
|
case 4: aLimit = GEOM::EDGE ; break;
|
||||||
case 1 :
|
case 5: aLimit = GEOM::VERTEX; break;
|
||||||
{
|
default: aLimit = GEOM::SHAPE ;
|
||||||
aLimit = GEOM::SHELL;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 2 :
|
|
||||||
{
|
|
||||||
aLimit = GEOM::FACE;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 3 :
|
|
||||||
{
|
|
||||||
aLimit = GEOM::WIRE;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 4 :
|
|
||||||
{
|
|
||||||
aLimit = GEOM::EDGE;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
case 5 :
|
|
||||||
{
|
|
||||||
aLimit = GEOM::VERTEX;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
default :
|
|
||||||
aLimit = GEOM::SHAPE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return aLimit;
|
return aLimit;
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : OperationGUI_PartitionDlg.h
|
// File : OperationGUI_PartitionDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_PARTITION_H
|
#ifndef DIALOGBOX_PARTITION_H
|
||||||
#define DIALOGBOX_PARTITION_H
|
#define DIALOGBOX_PARTITION_H
|
||||||
@ -32,7 +31,6 @@
|
|||||||
#include "GEOMBase_Skeleton.h"
|
#include "GEOMBase_Skeleton.h"
|
||||||
#include "DlgRef_4Sel1List1Check_QTD.h"
|
#include "DlgRef_4Sel1List1Check_QTD.h"
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// class : OperationGUI_PartitionDlg
|
// class : OperationGUI_PartitionDlg
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -42,7 +40,7 @@ class OperationGUI_PartitionDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
OperationGUI_PartitionDlg(QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
OperationGUI_PartitionDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0);
|
||||||
~OperationGUI_PartitionDlg();
|
~OperationGUI_PartitionDlg();
|
||||||
|
|
||||||
void SetListMaterials(GEOM::ListOfLong ListMaterials)
|
void SetListMaterials(GEOM::ListOfLong ListMaterials)
|
||||||
@ -76,9 +74,7 @@ private:
|
|||||||
private slots:
|
private slots:
|
||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ClickOnCancel();
|
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void DeactivateActiveDialog();
|
|
||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
|
@ -49,8 +49,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
PrimitiveGUI_BoxDlg::PrimitiveGUI_BoxDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
PrimitiveGUI_BoxDlg::PrimitiveGUI_BoxDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BOX_2P")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BOX_2P")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BOX_DXYZ")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM", tr("ICON_DLG_BOX_DXYZ")));
|
||||||
@ -127,6 +129,7 @@ void PrimitiveGUI_BoxDlg::Init()
|
|||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
|
|
||||||
connect(GroupConstructors, SIGNAL(clicked(int)), this, SLOT(ConstructorsClicked(int)));
|
connect(GroupConstructors, SIGNAL(clicked(int)), this, SLOT(ConstructorsClicked(int)));
|
||||||
|
|
||||||
connect(GroupPoints->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
connect(GroupPoints->PushButton1, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
||||||
@ -139,9 +142,9 @@ void PrimitiveGUI_BoxDlg::Init()
|
|||||||
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
connect(GroupDimensions->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DZ, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DZ, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
@ -217,16 +220,6 @@ bool PrimitiveGUI_BoxDlg::ClickOnApply()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : ClickOnCancel()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
void PrimitiveGUI_BoxDlg::ClickOnCancel()
|
|
||||||
{
|
|
||||||
GEOMBase_Skeleton::ClickOnCancel();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : SelectionIntoArgument()
|
// function : SelectionIntoArgument()
|
||||||
// purpose : Called when selection as changed
|
// purpose : Called when selection as changed
|
||||||
@ -325,16 +318,6 @@ void PrimitiveGUI_BoxDlg::enterEvent(QEvent* e)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : DeactivateActiveDialog()
|
|
||||||
// purpose : public slot to deactivate if active
|
|
||||||
//=================================================================================
|
|
||||||
void PrimitiveGUI_BoxDlg::DeactivateActiveDialog()
|
|
||||||
{
|
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ValueChangedInSpinBox()
|
// function : ValueChangedInSpinBox()
|
||||||
// purpose :
|
// purpose :
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : PrimitiveGUI_BoxDlg.h
|
// File : PrimitiveGUI_BoxDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_BOX_H
|
#ifndef DIALOGBOX_BOX_H
|
||||||
#define DIALOGBOX_BOX_H
|
#define DIALOGBOX_BOX_H
|
||||||
@ -44,7 +43,8 @@ class PrimitiveGUI_BoxDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
PrimitiveGUI_BoxDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
PrimitiveGUI_BoxDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~PrimitiveGUI_BoxDlg();
|
~PrimitiveGUI_BoxDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -59,8 +59,6 @@ private :
|
|||||||
void Init();
|
void Init();
|
||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint1, myPoint2; /* Points containing the vector */
|
GEOM::GEOM_Object_var myPoint1, myPoint2; /* Points containing the vector */
|
||||||
|
|
||||||
DlgRef_2Sel_QTD* GroupPoints;
|
DlgRef_2Sel_QTD* GroupPoints;
|
||||||
@ -69,15 +67,12 @@ private :
|
|||||||
private slots:
|
private slots:
|
||||||
void ClickOnOk();
|
void ClickOnOk();
|
||||||
bool ClickOnApply();
|
bool ClickOnApply();
|
||||||
void ClickOnCancel();
|
|
||||||
void ActivateThisDialog();
|
void ActivateThisDialog();
|
||||||
void DeactivateActiveDialog();
|
|
||||||
void LineEditReturnPressed();
|
void LineEditReturnPressed();
|
||||||
void SelectionIntoArgument();
|
void SelectionIntoArgument();
|
||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
void ConstructorsClicked(int);
|
void ConstructorsClicked(int);
|
||||||
void ValueChangedInSpinBox();
|
void ValueChangedInSpinBox();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_BOX_H
|
#endif // DIALOGBOX_BOX_H
|
||||||
|
@ -48,8 +48,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
PrimitiveGUI_ConeDlg::PrimitiveGUI_ConeDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
PrimitiveGUI_ConeDlg::PrimitiveGUI_ConeDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CONE_PV")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CONE_PV")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CONE_DXYZ")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CONE_DXYZ")));
|
||||||
@ -150,12 +152,12 @@ void PrimitiveGUI_ConeDlg::Init()
|
|||||||
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
connect(GroupDimensions->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DZ, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DZ, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DZ, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DZ, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DZ, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : PrimitiveGUI_ConeDlg.h
|
// File : PrimitiveGUI_ConeDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_CONE_H
|
#ifndef DIALOGBOX_CONE_H
|
||||||
#define DIALOGBOX_CONE_H
|
#define DIALOGBOX_CONE_H
|
||||||
@ -42,7 +41,8 @@ class PrimitiveGUI_ConeDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
PrimitiveGUI_ConeDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
PrimitiveGUI_ConeDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~PrimitiveGUI_ConeDlg();
|
~PrimitiveGUI_ConeDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -60,8 +60,6 @@ private:
|
|||||||
double getRadius2() const;
|
double getRadius2() const;
|
||||||
double getHeight() const;
|
double getHeight() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint, myDir;
|
GEOM::GEOM_Object_var myPoint, myDir;
|
||||||
|
|
||||||
DlgRef_2Sel3Spin* GroupPoints;
|
DlgRef_2Sel3Spin* GroupPoints;
|
||||||
@ -78,7 +76,6 @@ private slots:
|
|||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
void ConstructorsClicked(int);
|
void ConstructorsClicked(int);
|
||||||
void ValueChangedInSpinBox();
|
void ValueChangedInSpinBox();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_CONE_H
|
#endif // DIALOGBOX_CONE_H
|
||||||
|
@ -48,8 +48,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
PrimitiveGUI_CylinderDlg::PrimitiveGUI_CylinderDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
PrimitiveGUI_CylinderDlg::PrimitiveGUI_CylinderDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CYLINDER_PV")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CYLINDER_PV")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CYLINDER_DXYZ")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CYLINDER_DXYZ")));
|
||||||
@ -145,10 +147,10 @@ void PrimitiveGUI_CylinderDlg::Init()
|
|||||||
connect(GroupDimensions->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : PrimitiveGUI_CylinderDlg.h
|
// File : PrimitiveGUI_CylinderDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_CYLINDER_H
|
#ifndef DIALOGBOX_CYLINDER_H
|
||||||
#define DIALOGBOX_CYLINDER_H
|
#define DIALOGBOX_CYLINDER_H
|
||||||
@ -43,7 +42,8 @@ class PrimitiveGUI_CylinderDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
PrimitiveGUI_CylinderDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
PrimitiveGUI_CylinderDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~PrimitiveGUI_CylinderDlg();
|
~PrimitiveGUI_CylinderDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -60,8 +60,6 @@ private:
|
|||||||
double getRadius() const;
|
double getRadius() const;
|
||||||
double getHeight() const;
|
double getHeight() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint, myDir;
|
GEOM::GEOM_Object_var myPoint, myDir;
|
||||||
|
|
||||||
DlgRef_2Sel2Spin* GroupPoints;
|
DlgRef_2Sel2Spin* GroupPoints;
|
||||||
|
@ -48,8 +48,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
PrimitiveGUI_SphereDlg::PrimitiveGUI_SphereDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
PrimitiveGUI_SphereDlg::PrimitiveGUI_SphereDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SPHERE_P")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SPHERE_P")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SPHERE_DXYZ")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_SPHERE_DXYZ")));
|
||||||
@ -126,8 +128,8 @@ void PrimitiveGUI_SphereDlg::Init()
|
|||||||
connect(GroupDimensions->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : PrimitiveGUI_SphereDlg.h
|
// File : PrimitiveGUI_SphereDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_SPHERE_H
|
#ifndef DIALOGBOX_SPHERE_H
|
||||||
#define DIALOGBOX_SPHERE_H
|
#define DIALOGBOX_SPHERE_H
|
||||||
@ -43,7 +42,8 @@ class PrimitiveGUI_SphereDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
PrimitiveGUI_SphereDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
PrimitiveGUI_SphereDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~PrimitiveGUI_SphereDlg();
|
~PrimitiveGUI_SphereDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -59,8 +59,6 @@ private :
|
|||||||
void enterEvent(QEvent* e);
|
void enterEvent(QEvent* e);
|
||||||
double getRadius() const;
|
double getRadius() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint; /* Center point */
|
GEOM::GEOM_Object_var myPoint; /* Center point */
|
||||||
|
|
||||||
DlgRef_1Sel1Spin* GroupPoints;
|
DlgRef_1Sel1Spin* GroupPoints;
|
||||||
|
@ -48,8 +48,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
PrimitiveGUI_TorusDlg::PrimitiveGUI_TorusDlg(GeometryGUI* theGeometryGUI, QWidget* parent, const char* name, bool modal, WFlags fl)
|
PrimitiveGUI_TorusDlg::PrimitiveGUI_TorusDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu), myGeometryGUI(theGeometryGUI)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_TORUS_PV")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_TORUS_PV")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_TORUS_DXYZ")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_TORUS_DXYZ")));
|
||||||
@ -141,10 +143,10 @@ void PrimitiveGUI_TorusDlg::Init()
|
|||||||
connect(GroupDimensions->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DX, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
connect(GroupDimensions->SpinBox_DY, SIGNAL(valueChanged(double)), this, SLOT(ValueChangedInSpinBox()));
|
||||||
|
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupPoints->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DX, SLOT(SetStep(double)));
|
||||||
connect(myGeometryGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
connect(myGeomGUI, SIGNAL(SignalDefaultStepValueChanged(double)), GroupDimensions->SpinBox_DY, SLOT(SetStep(double)));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument())) ;
|
||||||
@ -154,7 +156,6 @@ void PrimitiveGUI_TorusDlg::Init()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ConstructorsClicked()
|
// function : ConstructorsClicked()
|
||||||
// purpose : Radio button management
|
// purpose : Radio button management
|
||||||
|
@ -24,7 +24,6 @@
|
|||||||
// File : PrimitiveGUI_TorusDlg.h
|
// File : PrimitiveGUI_TorusDlg.h
|
||||||
// Author : Lucien PIGNOLONI
|
// Author : Lucien PIGNOLONI
|
||||||
// Module : GEOM
|
// Module : GEOM
|
||||||
// $Header$
|
|
||||||
|
|
||||||
#ifndef DIALOGBOX_TORUS_H
|
#ifndef DIALOGBOX_TORUS_H
|
||||||
#define DIALOGBOX_TORUS_H
|
#define DIALOGBOX_TORUS_H
|
||||||
@ -43,7 +42,8 @@ class PrimitiveGUI_TorusDlg : public GEOMBase_Skeleton
|
|||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
public:
|
public:
|
||||||
PrimitiveGUI_TorusDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0, const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
PrimitiveGUI_TorusDlg(GeometryGUI* theGeometryGUI, QWidget* parent = 0,
|
||||||
|
const char* name = 0, bool modal = FALSE, WFlags fl = 0);
|
||||||
~PrimitiveGUI_TorusDlg();
|
~PrimitiveGUI_TorusDlg();
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
@ -60,8 +60,6 @@ private:
|
|||||||
double getRadius1() const;
|
double getRadius1() const;
|
||||||
double getRadius2() const;
|
double getRadius2() const;
|
||||||
|
|
||||||
GeometryGUI* myGeometryGUI;
|
|
||||||
|
|
||||||
GEOM::GEOM_Object_var myPoint, myDir;
|
GEOM::GEOM_Object_var myPoint, myDir;
|
||||||
|
|
||||||
DlgRef_2Sel2Spin* GroupPoints;
|
DlgRef_2Sel2Spin* GroupPoints;
|
||||||
@ -78,7 +76,6 @@ private:
|
|||||||
void SetEditCurrentArgument();
|
void SetEditCurrentArgument();
|
||||||
void ConstructorsClicked(int);
|
void ConstructorsClicked(int);
|
||||||
void ValueChangedInSpinBox();
|
void ValueChangedInSpinBox();
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // DIALOGBOX_TORUS_H
|
#endif // DIALOGBOX_TORUS_H
|
||||||
|
@ -89,36 +89,16 @@ bool RepairGUI::OnGUIEvent(int theCommandID, SUIT_Desktop* parent)
|
|||||||
|
|
||||||
QDialog* aDlg = NULL;
|
QDialog* aDlg = NULL;
|
||||||
switch (theCommandID) {
|
switch (theCommandID) {
|
||||||
case 601: // SEWING
|
case 601: aDlg = new RepairGUI_SewingDlg (getGeometryGUI(), parent, ""); break;
|
||||||
aDlg = new RepairGUI_SewingDlg( parent, "" );
|
case 602: aDlg = new RepairGUI_GlueDlg (getGeometryGUI(), parent, ""); break;
|
||||||
break;
|
case 603: aDlg = new RepairGUI_SuppressFacesDlg (getGeometryGUI(), parent, ""); break;
|
||||||
case 602: // GLUE FACES
|
case 604: aDlg = new RepairGUI_RemoveHolesDlg (getGeometryGUI(), parent, ""); break;
|
||||||
aDlg = new RepairGUI_GlueDlg( parent, "" );
|
case 605: aDlg = new RepairGUI_ShapeProcessDlg (getGeometryGUI(), parent, ""); break;
|
||||||
break;
|
case 606: aDlg = new RepairGUI_CloseContourDlg (getGeometryGUI(), parent, ""); break;
|
||||||
case 603: // SUPPRESS FACES
|
case 607: aDlg = new RepairGUI_RemoveIntWiresDlg(getGeometryGUI(), parent, ""); break;
|
||||||
aDlg = new RepairGUI_SuppressFacesDlg( parent, "" );
|
case 608: aDlg = new RepairGUI_DivideEdgeDlg (getGeometryGUI(), parent, ""); break;
|
||||||
break;
|
case 609: aDlg = new RepairGUI_FreeBoundDlg (getGeometryGUI(), parent, ""); break;
|
||||||
case 604: // SUPPRESS HOLES
|
case 610: aDlg = new RepairGUI_FreeFacesDlg (getGeometryGUI(), parent, ""); break;
|
||||||
aDlg = new RepairGUI_RemoveHolesDlg( parent, "" );
|
|
||||||
break;
|
|
||||||
case 605: // SHAPE PROCESSING
|
|
||||||
aDlg = new RepairGUI_ShapeProcessDlg( parent, "" );
|
|
||||||
break;
|
|
||||||
case 606: // CLOSE CONTOUR
|
|
||||||
aDlg = new RepairGUI_CloseContourDlg( parent, "" );
|
|
||||||
break;
|
|
||||||
case 607: // REMOVE INTERNAL WIRES
|
|
||||||
aDlg = new RepairGUI_RemoveIntWiresDlg( parent, "" );
|
|
||||||
break;
|
|
||||||
case 608: // ADD POINT ON EDGE
|
|
||||||
aDlg = new RepairGUI_DivideEdgeDlg( getGeometryGUI(), parent, "" );
|
|
||||||
break;
|
|
||||||
case 609: // FREE BOUNDARIES
|
|
||||||
aDlg = new RepairGUI_FreeBoundDlg( getGeometryGUI(), parent );
|
|
||||||
break;
|
|
||||||
case 610: // FREE FACES
|
|
||||||
aDlg = new RepairGUI_FreeFacesDlg( getGeometryGUI(), parent, "" );
|
|
||||||
break;
|
|
||||||
default:
|
default:
|
||||||
SUIT_Session::session()->activeApplication()->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
SUIT_Session::session()->activeApplication()->putInfo(tr("GEOM_PRP_COMMAND").arg(theCommandID));
|
||||||
break;
|
break;
|
||||||
|
@ -50,8 +50,10 @@ using namespace std;
|
|||||||
// The dialog will by default be modeless, unless you set 'modal' to
|
// The dialog will by default be modeless, unless you set 'modal' to
|
||||||
// TRUE to construct a modal dialog.
|
// TRUE to construct a modal dialog.
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
RepairGUI_CloseContourDlg::RepairGUI_CloseContourDlg(QWidget* parent, const char* name, bool modal, WFlags fl)
|
RepairGUI_CloseContourDlg::RepairGUI_CloseContourDlg(GeometryGUI* theGeometryGUI, QWidget* parent,
|
||||||
:GEOMBase_Skeleton(parent, name, modal, WStyle_Customize | WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
const char* name, bool modal, WFlags fl)
|
||||||
|
:GEOMBase_Skeleton(theGeometryGUI, parent, name, modal, WStyle_Customize |
|
||||||
|
WStyle_NormalBorder | WStyle_Title | WStyle_SysMenu)
|
||||||
{
|
{
|
||||||
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CLOSECONTOUR")));
|
QPixmap image0(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_DLG_CLOSECONTOUR")));
|
||||||
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
QPixmap image1(SUIT_Session::session()->resourceMgr()->loadPixmap("GEOM",tr("ICON_SELECT")));
|
||||||
@ -133,10 +135,6 @@ void RepairGUI_CloseContourDlg::Init()
|
|||||||
initSelection();
|
initSelection();
|
||||||
|
|
||||||
/* signals and slots connections */
|
/* signals and slots connections */
|
||||||
connect(buttonCancel, SIGNAL(clicked()), this, SLOT(ClickOnCancel()));
|
|
||||||
connect(myGeomGUI, SIGNAL(SignalDeactivateActiveDialog()), this, SLOT(DeactivateActiveDialog()));
|
|
||||||
connect(myGeomGUI, SIGNAL(SignalCloseAllDialogs()), this, SLOT(ClickOnCancel()));
|
|
||||||
|
|
||||||
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
connect(buttonOk, SIGNAL(clicked()), this, SLOT(ClickOnOk()));
|
||||||
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
connect(buttonApply, SIGNAL(clicked()), this, SLOT(ClickOnApply()));
|
||||||
|
|
||||||
@ -145,7 +143,7 @@ void RepairGUI_CloseContourDlg::Init()
|
|||||||
connect(mySelectWiresBtn, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
connect(mySelectWiresBtn, SIGNAL(clicked()), this, SLOT(SetEditCurrentArgument()));
|
||||||
connect(mySelectWiresEdt, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
connect(mySelectWiresEdt, SIGNAL(returnPressed()), this, SLOT(LineEditReturnPressed()));
|
||||||
|
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
initName( tr( "CLOSE_CONTOUR_NEW_OBJ_NAME" ) );
|
initName( tr( "CLOSE_CONTOUR_NEW_OBJ_NAME" ) );
|
||||||
@ -185,16 +183,6 @@ bool RepairGUI_CloseContourDlg::ClickOnApply()
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : ClickOnCancel()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
void RepairGUI_CloseContourDlg::ClickOnCancel()
|
|
||||||
{
|
|
||||||
GEOMBase_Skeleton::ClickOnCancel();
|
|
||||||
}
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : SelectionIntoArgument()
|
// function : SelectionIntoArgument()
|
||||||
// purpose : Called when selection as changed or other case
|
// purpose : Called when selection as changed or other case
|
||||||
@ -223,7 +211,7 @@ void RepairGUI_CloseContourDlg::SelectionIntoArgument()
|
|||||||
{
|
{
|
||||||
myEditCurrentArgument->setText( GEOMBase::GetName( myObject ) );
|
myEditCurrentArgument->setText( GEOMBase::GetName( myObject ) );
|
||||||
TopoDS_Shape aShape;
|
TopoDS_Shape aShape;
|
||||||
if ( myGeomBase->GetShape( myObject, aShape, TopAbs_WIRE ) )
|
if ( GEOMBase::GetShape( myObject, aShape, TopAbs_WIRE ) )
|
||||||
mySelectWiresEdt->setText( myEditCurrentArgument->text() );
|
mySelectWiresEdt->setText( myEditCurrentArgument->text() );
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
@ -232,7 +220,7 @@ void RepairGUI_CloseContourDlg::SelectionIntoArgument()
|
|||||||
else if ( myEditCurrentArgument == mySelectWiresEdt )
|
else if ( myEditCurrentArgument == mySelectWiresEdt )
|
||||||
{
|
{
|
||||||
TColStd_IndexedMapOfInteger aMap;
|
TColStd_IndexedMapOfInteger aMap;
|
||||||
((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr()->GetIndexes( anIO, aMap );
|
myGeomGUI->getApp()->selectionMgr()->GetIndexes( anIO, aMap );
|
||||||
const int n = aMap.Extent();
|
const int n = aMap.Extent();
|
||||||
myWiresInd->length( n );
|
myWiresInd->length( n );
|
||||||
for ( int i = 1; i <= n; i++ )
|
for ( int i = 1; i <= n; i++ )
|
||||||
@ -278,17 +266,6 @@ void RepairGUI_CloseContourDlg::LineEditReturnPressed()
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
|
||||||
// function : DeactivateActiveDialog()
|
|
||||||
// purpose :
|
|
||||||
//=================================================================================
|
|
||||||
void RepairGUI_CloseContourDlg::DeactivateActiveDialog()
|
|
||||||
{
|
|
||||||
//myGeomGUI->SetState( -1 );
|
|
||||||
GEOMBase_Skeleton::DeactivateActiveDialog();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
// function : ActivateThisDialog()
|
// function : ActivateThisDialog()
|
||||||
// purpose :
|
// purpose :
|
||||||
@ -296,7 +273,7 @@ void RepairGUI_CloseContourDlg::DeactivateActiveDialog()
|
|||||||
void RepairGUI_CloseContourDlg::ActivateThisDialog()
|
void RepairGUI_CloseContourDlg::ActivateThisDialog()
|
||||||
{
|
{
|
||||||
GEOMBase_Skeleton::ActivateThisDialog();
|
GEOMBase_Skeleton::ActivateThisDialog();
|
||||||
connect(((SalomeApp_Application*)(SUIT_Session::session()->activeApplication()))->selectionMgr(),
|
connect(myGeomGUI->getApp()->selectionMgr(),
|
||||||
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
|
||||||
|
|
||||||
myEditCurrentArgument = GroupPoints->LineEdit1;
|
myEditCurrentArgument = GroupPoints->LineEdit1;
|
||||||
@ -347,7 +324,7 @@ GEOM::GEOM_IOperations_ptr RepairGUI_CloseContourDlg::createOperation()
|
|||||||
bool RepairGUI_CloseContourDlg::isValid( QString& msg )
|
bool RepairGUI_CloseContourDlg::isValid( QString& msg )
|
||||||
{
|
{
|
||||||
TopoDS_Shape aTmpShape;
|
TopoDS_Shape aTmpShape;
|
||||||
return !myObject->_is_nil() && ( myWiresInd->length() || myGeomBase->GetShape( myObject, aTmpShape, TopAbs_WIRE ) );
|
return !myObject->_is_nil() && ( myWiresInd->length() || GEOMBase::GetShape( myObject, aTmpShape, TopAbs_WIRE ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
//=================================================================================
|
//=================================================================================
|
||||||
@ -396,5 +373,3 @@ void RepairGUI_CloseContourDlg::initSelection()
|
|||||||
localSelection( myObject, TopAbs_WIRE );
|
localSelection( myObject, TopAbs_WIRE );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user