PartDesign: fix showing base object on newly opened file, cleanup

This commit is contained in:
Sergo 2016-09-21 01:46:01 -04:00 committed by Yorik van Havre
parent 46a218ed24
commit ef14bbd88a
2 changed files with 6 additions and 2 deletions

View File

@ -616,7 +616,7 @@ TaskPrimitiveParameters::TaskPrimitiveParameters(ViewProviderPrimitive* Primitiv
ViewProviderDatumCoordinateSystem* vp = static_cast<ViewProviderDatumCoordinateSystem*>(
Gui::Application::Instance->activeDocument()->getViewProvider(cs));
assert(vp);
assert(vp);
//make sure the relevant things are visible
cs_visibility = vp->isVisible();

View File

@ -242,8 +242,12 @@ void ViewProvider::setBodyMode(bool bodymode) {
void ViewProvider::makeTemporaryVisible(bool onoff)
{
//make sure to not use the overridden versions, as they change proeprties
if(onoff)
if (onoff) {
if (VisualTouched) {
updateVisual(static_cast<Part::Feature*>(getObject())->Shape.getValue());
}
Gui::ViewProvider::show();
}
else
Gui::ViewProvider::hide();
}