Salome HOME
Issue #1834: Fix length of lines
[modules/shaper.git] / src / ParametersPlugin / ParametersPlugin_Plugin.cpp
index e82a5f67d87b20207d5e2e05aebd2f552813e594..cc1946413fd43bbd4c6bae302e0f0d0a552dbdc7 100644 (file)
@@ -4,7 +4,11 @@
 
 #include <ParametersPlugin_Plugin.h>
 #include <ParametersPlugin_Parameter.h>
+#include <ParametersPlugin_ParametersMgr.h>
 #include <ParametersPlugin_Validators.h>
+#include <ParametersPlugin_WidgetCreator.h>
+
+#include <ModuleBase_WidgetCreatorFactory.h>
 
 #include <ModelAPI_Session.h>
 #include <ModelAPI_Validator.h>
@@ -17,6 +21,10 @@ static ParametersPlugin_Plugin* MY_PARAMETERSPLUGIN_INSTANCE = new ParametersPlu
 ParametersPlugin_Plugin::ParametersPlugin_Plugin()
 {
   // register this plugin
+  WidgetCreatorFactoryPtr aWidgetCreatorFactory = ModuleBase_WidgetCreatorFactory::get();
+  aWidgetCreatorFactory->registerCreator(
+   std::shared_ptr<ParametersPlugin_WidgetCreator>(new ParametersPlugin_WidgetCreator()));
+
   SessionPtr aSession = ModelAPI_Session::get();
   aSession->registerPlugin(this);
 
@@ -26,7 +34,8 @@ ParametersPlugin_Plugin::ParametersPlugin_Plugin()
   aFactory->registerValidator("Parameters_ExpressionValidator",
                               new ParametersPlugin_ExpressionValidator);
 
-  myEvalListener = std::shared_ptr<ParametersPlugin_EvalListener>(new ParametersPlugin_EvalListener());
+  myEvalListener = 
+    std::shared_ptr<ParametersPlugin_EvalListener>(new ParametersPlugin_EvalListener());
 }
 
 FeaturePtr ParametersPlugin_Plugin::createFeature(std::string theFeatureID)
@@ -35,6 +44,9 @@ FeaturePtr ParametersPlugin_Plugin::createFeature(std::string theFeatureID)
   if (theFeatureID == ParametersPlugin_Parameter::ID()) {
     return FeaturePtr(new ParametersPlugin_Parameter);
   }
+  if (theFeatureID == ParametersPlugin_ParametersMgr::ID()) {
+    return FeaturePtr(new ParametersPlugin_ParametersMgr);
+  }
   return FeaturePtr();
 }