+ code cleanup: remove deprecated class ViewProviderPartBase
This commit is contained in:
parent
58b54aa729
commit
f6c25f94de
|
@ -105,7 +105,6 @@ void PartGuiExport initPartGui()
|
|||
PartGui::SoBrepEdgeSet ::initClass();
|
||||
PartGui::SoBrepPointSet ::initClass();
|
||||
PartGui::SoFCControlPoints ::initClass();
|
||||
PartGui::ViewProviderPartBase ::init();
|
||||
PartGui::ViewProviderPartExt ::init();
|
||||
PartGui::ViewProviderPart ::init();
|
||||
PartGui::ViewProviderEllipsoid ::init();
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -30,25 +30,8 @@
|
|||
#include <Gui/ViewProviderGeometryObject.h>
|
||||
#include <Gui/ViewProviderBuilder.h>
|
||||
#include <Mod/Part/Gui/ViewProviderExt.h>
|
||||
#include <map>
|
||||
|
||||
class TopoDS_Shape;
|
||||
class TopoDS_Edge;
|
||||
class TopoDS_Wire;
|
||||
class TopoDS_Face;
|
||||
class SoSeparator;
|
||||
class SoGroup;
|
||||
class SoSwitch;
|
||||
class SoVertexShape;
|
||||
class SoPickedPoint;
|
||||
class SoShapeHints;
|
||||
class SoEventCallback;
|
||||
class SbVec3f;
|
||||
class SoSphere;
|
||||
class SoScale;
|
||||
|
||||
// Set this to use the fast rendering of shapes
|
||||
#define FC_USE_FAST_SHAPE_RENDERING
|
||||
|
||||
namespace Part { struct ShapeHistory; }
|
||||
|
||||
|
@ -63,76 +46,6 @@ public:
|
|||
void createShape(const App::Property*, SoSeparator*) const;
|
||||
};
|
||||
|
||||
class PartGuiExport ViewProviderPartBase : public Gui::ViewProviderGeometryObject
|
||||
{
|
||||
PROPERTY_HEADER(PartGui::ViewProviderPartBase);
|
||||
|
||||
public:
|
||||
/// constructor
|
||||
ViewProviderPartBase();
|
||||
/// destructor
|
||||
virtual ~ViewProviderPartBase();
|
||||
|
||||
// Display properties
|
||||
App::PropertyFloatConstraint LineWidth;
|
||||
App::PropertyFloatConstraint PointSize;
|
||||
App::PropertyColor LineColor;
|
||||
App::PropertyColor PointColor;
|
||||
App::PropertyMaterial LineMaterial;
|
||||
App::PropertyMaterial PointMaterial;
|
||||
App::PropertyBool ControlPoints;
|
||||
App::PropertyEnumeration Lighting;
|
||||
|
||||
|
||||
virtual void attach(App::DocumentObject *);
|
||||
virtual void setDisplayMode(const char* ModeName);
|
||||
/// returns a list of all possible modes
|
||||
virtual std::vector<std::string> getDisplayModes(void) const;
|
||||
/// Update the view representation
|
||||
void reload();
|
||||
|
||||
virtual void updateData(const App::Property*);
|
||||
TopoDS_Shape getShape(const SoPickedPoint*) const;
|
||||
static void shapeInfoCallback(void * ud, SoEventCallback * n);
|
||||
|
||||
protected:
|
||||
/// get called by the container whenever a property has been changed
|
||||
virtual void onChanged(const App::Property* prop);
|
||||
bool loadParameter();
|
||||
Standard_Boolean computeFaces (SoGroup* root, const TopoDS_Shape &myShape, double defl);
|
||||
Standard_Boolean computeEdges (SoGroup* root, const TopoDS_Shape &myShape);
|
||||
Standard_Boolean computeVertices(SoGroup* root, const TopoDS_Shape &myShape);
|
||||
|
||||
void transferToArray(const TopoDS_Face& aFace,SbVec3f** vertices,SbVec3f** vertexnormals,
|
||||
int32_t** cons,int &nbNodesInFace,int &nbTriInFace );
|
||||
void showControlPoints(bool, const App::Property* prop);
|
||||
void showControlPointsOfEdge(const TopoDS_Edge&);
|
||||
void showControlPointsOfWire(const TopoDS_Wire&);
|
||||
void showControlPointsOfFace(const TopoDS_Face&);
|
||||
|
||||
// nodes for the data representation
|
||||
SoGroup *EdgeRoot;
|
||||
SoGroup *FaceRoot;
|
||||
SoGroup *VertexRoot;
|
||||
SoMaterial *pcLineMaterial;
|
||||
SoMaterial *pcPointMaterial;
|
||||
SoDrawStyle *pcLineStyle;
|
||||
SoDrawStyle *pcPointStyle;
|
||||
SoSwitch *pcControlPoints;
|
||||
SoShapeHints *pShapeHints;
|
||||
|
||||
private:
|
||||
// settings stuff
|
||||
float meshDeviation;
|
||||
float angularDeflection;
|
||||
bool noPerVertexNormals;
|
||||
bool qualityNormals;
|
||||
static App::PropertyFloatConstraint::Constraints floatRange;
|
||||
static const char* LightingEnums[];
|
||||
std::map<SoVertexShape*, TopoDS_Shape> vertexShapeMap;
|
||||
};
|
||||
|
||||
#if defined(FC_USE_FAST_SHAPE_RENDERING)
|
||||
class PartGuiExport ViewProviderPart : public ViewProviderPartExt
|
||||
{
|
||||
PROPERTY_HEADER(PartGui::ViewProviderPart);
|
||||
|
@ -149,18 +62,6 @@ protected:
|
|||
const std::vector<App::Color>& colBase,
|
||||
std::vector<App::Color>& colBool);
|
||||
};
|
||||
#else
|
||||
class PartGuiExport ViewProviderPart : public ViewProviderPartBase
|
||||
{
|
||||
PROPERTY_HEADER(PartGui::ViewProviderPart);
|
||||
|
||||
public:
|
||||
/// constructor
|
||||
ViewProviderPart();
|
||||
/// destructor
|
||||
virtual ~ViewProviderPart();
|
||||
};
|
||||
#endif
|
||||
|
||||
} // namespace PartGui
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user