Salome HOME
Merge branch 'master' of newgeom:newgeom.git into BR_PORTING_CENTOS_6_3
[modules/shaper.git] / src / Config / Config_FeatureReader.cpp
index 71ecc7afa1048de5b59b77b81cf2548b6c20dbb4..ddefe6df2dec201355a7337d6c4d19822e2ed85f 100644 (file)
 
 
 Config_FeatureReader::Config_FeatureReader(const std::string& theXmlFile,
-                                           const std::string& theLibraryName)
+                                           const std::string& theLibraryName,
+                                           const char* theEventGenerated)
     : Config_XMLReader(theXmlFile),
-      myLibraryName(theLibraryName)
+      myLibraryName(theLibraryName),
+      myEventGenerated(theEventGenerated ? theEventGenerated : "FeatureEvent")
 {
 }
 
@@ -35,7 +37,7 @@ Config_FeatureReader::~Config_FeatureReader()
 
 void Config_FeatureReader::processNode(xmlNodePtr theNode)
 {
-  static Event_ID aMenuItemEvent = Event_Loop::eventByName("FeatureEvent");
+  Event_ID aMenuItemEvent = Event_Loop::eventByName(myEventGenerated);
   if (isNode(theNode, NODE_FEATURE, NULL)) {
     Event_Loop* aEvLoop = Event_Loop::loop();
     Config_FeatureMessage aMessage(aMenuItemEvent, this);