X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FSketchPlugin%2FSketchPlugin_ConstraintParallel.h;h=370ff6336997667535bae337433045080bb0af13;hb=93152527420704cf35e22b11d1de198e1710bd90;hp=9b0570fc04584699b1be36bd75fac931fb6f9189;hpb=300f40cc0945ce614f9c0af668ac2b3094ec0524;p=modules%2Fshaper.git diff --git a/src/SketchPlugin/SketchPlugin_ConstraintParallel.h b/src/SketchPlugin/SketchPlugin_ConstraintParallel.h index 9b0570fc0..370ff6336 100644 --- a/src/SketchPlugin/SketchPlugin_ConstraintParallel.h +++ b/src/SketchPlugin/SketchPlugin_ConstraintParallel.h @@ -7,21 +7,20 @@ #include "SketchPlugin.h" #include -#include "SketchPlugin_Constraint.h" +#include "SketchPlugin_ConstraintBase.h" - -#define PARALLEL_COLOR "255, 255, 0" +#define PARALLEL_COLOR "#ffff00" /** \class SketchPlugin_ConstraintParallel * \ingroup DataModel * \brief Feature for creation of a new constraint parallelism of two lines * - * These constraint has two attributes: + * This constraint has two attributes: * SketchPlugin_Constraint::ENTITY_A() and SketchPlugin_Constraint::ENTITY_B() */ -class SketchPlugin_ConstraintParallel: public SketchPlugin_Constraint +class SketchPlugin_ConstraintParallel : public SketchPlugin_ConstraintBase { -public: + public: /// Parallel constraint kind inline static const std::string& ID() { @@ -29,8 +28,11 @@ public: return MY_CONSTRAINT_PARALLEL_ID; } /// \brief Returns the kind of a feature - SKETCHPLUGIN_EXPORT virtual const std::string& getKind() - {static std::string MY_KIND = SketchPlugin_ConstraintParallel::ID(); return MY_KIND;} + SKETCHPLUGIN_EXPORT virtual const std::string& getKind() + { + static std::string MY_KIND = SketchPlugin_ConstraintParallel::ID(); + return MY_KIND; + } /// \brief Creates a new part document if needed SKETCHPLUGIN_EXPORT virtual void execute(); @@ -39,8 +41,7 @@ public: SKETCHPLUGIN_EXPORT virtual void initAttributes(); /// Returns the AIS preview - SKETCHPLUGIN_EXPORT virtual boost::shared_ptr getAISObject( - boost::shared_ptr thePrevious); + SKETCHPLUGIN_EXPORT virtual AISObjectPtr getAISObject(AISObjectPtr thePrevious); /// Moves the feature /// \param theDeltaX the delta for X coordinate is moved