+ QString aType = QString(theMessage->eventID().eventText());
+ if (aType == EVENT_FEATURE_UPDATED ||
+ aType == EVENT_FEATURE_CREATED)
+ {
+ const Model_FeatureUpdatedMessage* aUpdMsg = dynamic_cast<const Model_FeatureUpdatedMessage*>
+ (theMessage);
+ std::set<boost::shared_ptr<ModelAPI_Feature> > aFeatures = aUpdMsg->features();
+ std::set<boost::shared_ptr<ModelAPI_Feature> >::const_iterator anIt = aFeatures.begin(),
+ aLast = aFeatures.end();
+ for (; anIt != aLast; anIt++) {
+ boost::shared_ptr<ModelAPI_Feature> aFeature = *anIt;
+ if (myModule->workshop()->displayer()->IsVisible(aFeature) ||
+ aType == EVENT_FEATURE_CREATED) {
+ myModule->visualizePreview(aFeature, true, false);
+ myModule->activateFeature(aFeature, true);
+ }
+ }
+ myModule->workshop()->displayer()->UpdateViewer();
+ }
+ if (aType == EVENT_FEATURE_DELETED)