prevent parts from being dragged into parts
This commit is contained in:
@@ -72,6 +72,16 @@ bool ViewProviderPart::doubleClicked(void)
|
||||
return true;
|
||||
}
|
||||
|
||||
bool ViewProviderPart::canDropObject(App::DocumentObject* obj) const {
|
||||
|
||||
//it is not allowed to have any part or assembly object within a part, hence we exclude origin groups
|
||||
if(obj->isDerivedFrom(App::OriginGroup::getClassTypeId()))
|
||||
return false;
|
||||
|
||||
return Gui::ViewProvider::canDropObject(obj);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Returns the pixmap for the list item.
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user