X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FModel%2FModel_Events.cpp;h=7847f99b10a4fca3e4a00a30ba3ed87f84637df6;hb=68a3f0934001109743353b6cc2ac42d8b92bd868;hp=13c4d256873c97719cc6a525c49006d26432cf13;hpb=38afbd899a8645c83e17f2c24a17a2b7414911b4;p=modules%2Fshaper.git diff --git a/src/Model/Model_Events.cpp b/src/Model/Model_Events.cpp index 13c4d2568..7847f99b1 100644 --- a/src/Model/Model_Events.cpp +++ b/src/Model/Model_Events.cpp @@ -27,6 +27,14 @@ void Model_EventCreator::sendDeleted(const std::shared_ptr& t Events_Loop::loop()->send(aMsg, true); } +void Model_EventCreator::sendReordered(const std::shared_ptr& theDoc, + const std::string& theGroup) const +{ + std::shared_ptr aMsg( + new Model_OrderUpdatedMessage(theDoc, theGroup)); + Events_Loop::loop()->send(aMsg, true); +} + Model_EventCreator::Model_EventCreator() { ModelAPI_EventCreator::set(this); @@ -94,3 +102,17 @@ void Model_ObjectDeletedMessage::Join(const std::shared_ptr myGroups.insert(*aGIter); } } + +/////////////////////// REORDERED MESSAGE ///////////////////////////// +Model_OrderUpdatedMessage::Model_OrderUpdatedMessage( + const std::shared_ptr& theDoc, const std::string& theGroup) + : ModelAPI_OrderUpdatedMessage(messageId(), 0), + myDoc(theDoc), myGroup(theGroup) +{ +} + +const Events_ID Model_OrderUpdatedMessage::messageId() +{ + static Events_ID MY_ID = Events_Loop::eventByName(EVENT_ORDER_UPDATED); + return MY_ID; +}