Salome HOME
#1112 tab key doesn't work on the last field of left panels
[modules/shaper.git] / src / Events / Events_Loop.cpp
index 83091a254d4971b0432960bd1be432f2fc1a766f..d2d96de532ceda5a4c43bb051fadad2a3ebb7f21 100644 (file)
@@ -129,10 +129,23 @@ void Events_Loop::flush(const Events_ID& theID)
     send(aGroup, false);
 
     if (!aWasFlushed)
-      myFlushed.erase(myFlushed.find(theID.myID));
+      // TODO: Stabilization fix. Check later.
+      if(myFlushed.find(theID.myID) != myFlushed.end()) {
+        myFlushed.erase(myFlushed.find(theID.myID));
+      }
+  }
+}
+
+void Events_Loop::eraseMessages(const Events_ID& theID)
+{
+  std::map<char*, std::shared_ptr<Events_Message> >::iterator aMyGroup =
+    myGroups.find(theID.eventText());
+  if (aMyGroup != myGroups.end()) {
+    myGroups.erase(aMyGroup);
   }
 }
 
+
 bool Events_Loop::activateFlushes(const bool theActivate)
 {
   bool isActive = myFlushActive;