Switch to correct page when changing Link property target

This commit is contained in:
pavltom
2024-03-04 15:39:48 +01:00
parent a9b77de0be
commit 04335d4060

View File

@@ -525,7 +525,13 @@ void DlgPropertyLink::onItemSelectionChanged()
auto vp = Base::freecad_dynamic_cast<Gui::ViewProviderDocumentObject>(
doc->getViewProvider(obj));
if(vp) {
doc->setActiveView(vp, Gui::View3DInventor::getClassTypeId());
MDIView *view = vp->getMDIView();
if (view) {
doc->setActiveWindow(view);
}
else {
doc->setActiveView(vp, Gui::View3DInventor::getClassTypeId());
}
}
}
}