Salome HOME
Issue #412: Crash on delete sketch line with constraints
[modules/shaper.git] / src / ModelAPI / ModelAPI_Result.cpp
index aa5ddd227c9933c95e37adfd09c0c5195d1f18aa..d435920149f5dc4e44a33c7421caae8750c59771 100644 (file)
@@ -5,6 +5,10 @@
 // Author:      Mikhail PONIKAROV
 
 #include "ModelAPI_Result.h"
+#include <ModelAPI_Events.h>
+#include <ModelAPI_Data.h>
+#include <ModelAPI_Attribute.h>
+#include <Events_Loop.h>
 
 ModelAPI_Result::~ModelAPI_Result()
 {
@@ -15,3 +19,11 @@ std::shared_ptr<GeomAPI_Shape> ModelAPI_Result::shape()
 {
   return std::shared_ptr<GeomAPI_Shape>();
 }
+
+void ModelAPI_Result::attributeChanged(const std::string& theID)
+{
+  static Events_Loop* aLoop = Events_Loop::loop();
+  static Events_ID EVENT_DISP = aLoop->eventByName(EVENT_OBJECT_TO_REDISPLAY);
+  static const ModelAPI_EventCreator* aECreator = ModelAPI_EventCreator::get();
+  aECreator->sendUpdated(data()->attribute(theID)->owner(), EVENT_DISP);
+}