DCQ: New archi...

This commit is contained in:
dcq 2003-12-11 09:22:18 +00:00
parent 423b12af2e
commit b17dbbdb0b
4 changed files with 32 additions and 75 deletions

View File

@ -39,9 +39,6 @@ static GEOMContext* GeomGUI = 0;
GEOMContext::GEOMContext() : GEOMContext::GEOMContext() :
QObject() QObject()
{ {
// mySettings_AddInStudy = false;
// mySettings_Copy = false;
myFatherior = "";
} }
@ -73,26 +70,19 @@ GEOMContext* GEOMContext::GetOrCreateGeomGUI(QAD_Desktop* desktop)
{ {
if(GeomGUI == 0) { if(GeomGUI == 0) {
GeomGUI = new GEOMContext(); GeomGUI = new GEOMContext();
// GeomGUI->myDesktop = desktop;
// GeomGUI->myActiveStudy = desktop->getActiveStudy();
Engines::Component_var comp = desktop->getEngine("FactoryServer", "GEOM"); Engines::Component_var comp = desktop->getEngine("FactoryServer", "GEOM");
GeomGUI->myComponentGeom = GEOM::GEOM_Gen::_narrow(comp); GeomGUI->myComponentGeom = GEOM::GEOM_Gen::_narrow(comp);
GeomGUI->myState = -1; GeomGUI->myState = -1;
GeomGUI->myActiveDialogBox = 0; GeomGUI->myActiveDialogBox = 0;
GeomGUI->myFatherior = "";
GeomGUI->myGUILibrary = OSD_SharedLibrary(); GeomGUI->myGUILibrary = OSD_SharedLibrary();
// GeomGUI->mySimulationShape = new AIS_Shape(TopoDS_Shape());
// GeomGUI->myShadingColor = Quantity_Color(Quantity_NOC_GOLDENROD);
/* GetCurrentStudy */ /* GetCurrentStudy */
int studyId = desktop->getActiveStudy()->getStudyId(); int studyId = desktop->getActiveStudy()->getStudyId();
GeomGUI->myComponentGeom->GetCurrentStudy(studyId); GeomGUI->myComponentGeom->GetCurrentStudy(studyId);
GeomGUI->myNbGeom = GeomGUI->myComponentGeom->NbLabels(); GeomGUI->myNbGeom = GeomGUI->myComponentGeom->NbLabels();
} }
// else {
// /* study may have changed */
// GeomGUI->myActiveStudy = desktop->getActiveStudy();
// }
return GeomGUI; return GeomGUI;
} }
@ -129,28 +119,6 @@ bool GEOMContext::LoadLibrary(QString GUILibrary)
} }
//=======================================================================
// function : SetState()
// purpose : Sets myState = aState a private field indicating which methode is active
//=======================================================================
// void GEOMContext::SetState(int aState)
// {
// myState = aState;
// return;
// }
//=======================================================================
// function : ResetState()
// purpose : Sets myState = -1 a private field indicating which methode is active
//=======================================================================
// void GEOMContext::ResetState()
// {
// myState = -1;
// return;
// }
//======================================================================= //=======================================================================
// function : SetActiveDialogBox() // function : SetActiveDialogBox()
// purpose : // purpose :

View File

@ -29,27 +29,11 @@
#ifndef GEOMCONTEXT_H #ifndef GEOMCONTEXT_H
#define GEOMCONTEXT_H #define GEOMCONTEXT_H
// SALOME Includes
#include "QAD_Desktop.h" #include "QAD_Desktop.h"
#include "GEOM_Client.hxx" #include "GEOM_Client.hxx"
//#include "GEOM_AISShape.hxx"
//#include "GEOM_InteractiveObject.hxx"
//#include "GEOM_Actor.h"
// Open CASCADE Includes
//#include <Quantity_Color.hxx>
//#include <AIS_ListOfInteractive.hxx>
#include <OSD_SharedLibrary.hxx> #include <OSD_SharedLibrary.hxx>
// QT Includes
#include <qapplication.h> #include <qapplication.h>
// IDL Headers
//#include <SALOMEconfig.h>
//#include CORBA_SERVER_HEADER(GEOM_Gen)
//#include CORBA_SERVER_HEADER(SALOMEDS)
//#include CORBA_SERVER_HEADER(SALOMEDS_Attributes)
//================================================================================= //=================================================================================
// class : GEOMContext // class : GEOMContext
// purpose : // purpose :
@ -63,20 +47,10 @@ public :
~GEOMContext(); ~GEOMContext();
private : private :
// QAD_Desktop* myDesktop;
// QAD_Study* myActiveStudy;
QDialog* myActiveDialogBox; /* Unique active dialog box */ QDialog* myActiveDialogBox; /* Unique active dialog box */
int myNbGeom; /* Unique name for a geom entity */ int myNbGeom; /* Unique name for a geom entity */
// int myState; /* Identify a method */
GEOM_Client myShapeReader; GEOM_Client myShapeReader;
Standard_CString myFatherior; Standard_CString myFatherior;
// AIS_ListOfInteractive myListDisplayedObject;
// Quantity_Color myShadingColor;
// bool mySettings_AddInStudy;
// bool mySettings_Copy;
public : public :
static GEOMContext* GetOrCreateGeomGUI(QAD_Desktop* desktop); static GEOMContext* GetOrCreateGeomGUI(QAD_Desktop* desktop);
@ -85,28 +59,17 @@ public :
OSD_SharedLibrary myGUILibrary; OSD_SharedLibrary myGUILibrary;
GEOM::GEOM_Gen_var myComponentGeom; GEOM::GEOM_Gen_var myComponentGeom;
int myState; /* Identify a method */ int myState; /* Identify a method */
// Handle(AIS_Shape) mySimulationShape; /* AIS shape used only during topo/geom simulations */
// QAD_Desktop* GetDesktop(){return myDesktop;};
// QAD_Study* GetActiveStudy(){return myActiveStudy;};
QDialog* GetActiveDialogBox(){return myActiveDialogBox ;}; /* Returns the active DialogBox */
/* Returns the active DialogBox */
QDialog* GetActiveDialogBox(){return myActiveDialogBox ;};
int& GetNbGeom(){return myNbGeom;}; int& GetNbGeom(){return myNbGeom;};
// int& GetState(){return myState;};
GEOM_Client& GetShapeReader(){return myShapeReader;}; GEOM_Client& GetShapeReader(){return myShapeReader;};
Standard_CString& GetFatherior(){return myFatherior;}; Standard_CString& GetFatherior(){return myFatherior;};
// AIS_ListOfInteractive& GetListDisplayedObject(){return myListDisplayedObject;};
// Quantity_Color& GetShadingColor(){return myShadingColor;};
// bool& GetSettings_AddInStudy(){return mySettings_AddInStudy;};
// bool& GetSettings_Copy(){return mySettings_Copy;};
bool LoadLibrary(QString GUILibrary); bool LoadLibrary(QString GUILibrary);
// void SetState(int aState); /* Sets 'myActiveDialogBox' a pointer to the active Dialog Box */
// void ResetState(); /* Sets myState = -1 a private field to indicate wich method is active */ void SetActiveDialogBox(QDialog* aDlg);
void SetActiveDialogBox(QDialog* aDlg); /* Sets 'myActiveDialogBox' a pointer to the active Dialog Box */
/* Non modal dialog boxes magement */ /* Non modal dialog boxes magement */
void EmitSignalDeactivateDialog(); void EmitSignalDeactivateDialog();

View File

@ -346,4 +346,17 @@ msgstr "multirotationdouble.png"
msgid "ICON_DLG_ELLIPSE_PV" msgid "ICON_DLG_ELLIPSE_PV"
msgstr "ellipsepointvector.png" msgstr "ellipsepointvector.png"
#SplineDlg
msgid "ICON_DLG_SPLINE"
msgstr "spline.png"
#SplineDlg
msgid "ICON_DLG_BEZIER"
msgstr "bezier.png"
#SplineDlg
msgid "ICON_DLG_BSPLINE"
msgstr "bspline.png"

View File

@ -157,6 +157,10 @@ msgstr "IGES Files ( *.iges *.igs )"
msgid "GEOM_MEN_IMPORT_STEP" msgid "GEOM_MEN_IMPORT_STEP"
msgstr "STEP Files ( *.step *.stp )" msgstr "STEP Files ( *.step *.stp )"
#: GeometryGUI.cxx:3763
msgid "GEOM_MEN_LOAD_SCRIPT"
msgstr "PYTHON Files ( *.py )"
#: GeometryGUI.cxx:2931 #: GeometryGUI.cxx:2931
msgid "GEOM_MEN_ISOS" msgid "GEOM_MEN_ISOS"
msgstr "Select Number Of Isos" msgstr "Select Number Of Isos"
@ -1177,3 +1181,12 @@ msgid "GEOM_RECONSTRUCTION_LIMIT_EDGE"
msgstr "Edge" msgstr "Edge"
msgid "GEOM_RECONSTRUCTION_LIMIT_VERTEX" msgid "GEOM_RECONSTRUCTION_LIMIT_VERTEX"
msgstr "Vertex" msgstr "Vertex"
msgid "GEOM_SPLINE_TITLE"
msgstr "Spline Construction"
msgid "GEOM_SPLINE"
msgstr "Spline"
msgid "GEOM_BEZIER"
msgstr "Bezier"
msgid "GEOM_BSPLINE"
msgstr "BSpline"