X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FConstructionPlugin%2FConstructionPlugin_Plugin.cpp;h=4731cc4c8c766fea1a5e00d6398838618711dd49;hb=26eb9df03b20bbec3ecafbda1a1b1fcfe5f06bbc;hp=4ce70ae037c789ce3e0e7aa0cf788c3589355543;hpb=3efd29f07fa128246690fd24a3439048b5e95878;p=modules%2Fshaper.git diff --git a/src/ConstructionPlugin/ConstructionPlugin_Plugin.cpp b/src/ConstructionPlugin/ConstructionPlugin_Plugin.cpp index 4ce70ae03..4731cc4c8 100644 --- a/src/ConstructionPlugin/ConstructionPlugin_Plugin.cpp +++ b/src/ConstructionPlugin/ConstructionPlugin_Plugin.cpp @@ -5,6 +5,8 @@ #include "ConstructionPlugin_Axis.h" #include "ConstructionPlugin_Plane.h" +#include + #include #include @@ -17,17 +19,25 @@ ConstructionPlugin_Plugin::ConstructionPlugin_Plugin() { // register this plugin ModelAPI_Session::get()->registerPlugin(this); + + // register construction properties + Config_PropManager::registerProp("Visualization", "construction_point_color", "Construction point color", + Config_Prop::Color, ConstructionPlugin_Point::DEFAULT_COLOR()); + Config_PropManager::registerProp("Visualization", "construction_axis_color", "Construction axis color", + Config_Prop::Color, ConstructionPlugin_Axis::DEFAULT_COLOR()); + Config_PropManager::registerProp("Visualization", "construction_plane_color", "Construction plane color", + Config_Prop::Color, ConstructionPlugin_Plane::DEFAULT_COLOR()); } FeaturePtr ConstructionPlugin_Plugin::createFeature(string theFeatureID) { - if (theFeatureID == CONSTRUCTION_POINT_KIND) { + if (theFeatureID == ConstructionPlugin_Point::ID()) { return FeaturePtr(new ConstructionPlugin_Point); } - else if (theFeatureID == CONSTRUCTION_AXIS_KIND) { + else if (theFeatureID == ConstructionPlugin_Axis::ID()) { return FeaturePtr(new ConstructionPlugin_Axis); } - else if (theFeatureID == CONSTRUCTION_PLANE_KIND) { + else if (theFeatureID == ConstructionPlugin_Plane::ID()) { return FeaturePtr(new ConstructionPlugin_Plane); } // feature of such kind is not found