- boost::shared_ptr<SketchPlugin_Sketch> aSketch =
- boost::dynamic_pointer_cast<SketchPlugin_Sketch>(aObj);
- if (aSketch) // Activate sketcher for planes selection
- myModule->activateFeature(aSketch, false);
+ boost::shared_ptr<ModelAPI_Feature> aFeature =
+ boost::dynamic_pointer_cast<ModelAPI_Feature>(aObj);
+ if (aFeature && (aFeature->getKind() == "Sketch")) // Activate sketcher for planes selection
+ myModule->activateFeature(aFeature, false);