From b6c0557634fe60a00e5ae9d44f958c1c289cd93d Mon Sep 17 00:00:00 2001 From: SONOLET Aymeric Date: Fri, 1 Dec 2023 12:05:25 +0100 Subject: [PATCH] feat PublishToStudy: Add steps for obj synchro with shaperstudy --- src/SHAPERGUI/SHAPERGUI.cpp | 13 +++++++++++++ src/SHAPERGUI/SHAPERGUI.h | 4 ++++ 2 files changed, 17 insertions(+) diff --git a/src/SHAPERGUI/SHAPERGUI.cpp b/src/SHAPERGUI/SHAPERGUI.cpp index bd9716b8b..47cd9d827 100644 --- a/src/SHAPERGUI/SHAPERGUI.cpp +++ b/src/SHAPERGUI/SHAPERGUI.cpp @@ -1401,6 +1401,8 @@ void SHAPERGUI::publishToStudy() { if (isActiveModule() && ModelAPI_Session::get()->hasModuleDocument()) { myWorkshop->module()->launchOperation("PublishToStudy", false); + hideDestroyedObjects(); + synchronizeObjectsVisibility(); // update SHAPERSTUDY objects in OCC and VTK viewers QStringList aVMList; @@ -1409,6 +1411,17 @@ void SHAPERGUI::publishToStudy() } } +// TODO: if SHAPERSTUDY obj does not have a corresponding SHAPER obj, make it +// hidden. +void SHAPERGUI::hideDestroyedObjects() +{ +} + +// TODO: synchronize SHAPER objects visibility with SHAPERSTUDY obj. +void SHAPERGUI::synchronizeObjectsVisibility() +{ +} + void SHAPERGUI::fillPartSetInfoPanel(QtxInfoPanel* theInfoPanel) { QIntList aShaperActions = shaperActions(); diff --git a/src/SHAPERGUI/SHAPERGUI.h b/src/SHAPERGUI/SHAPERGUI.h index 2a84accc3..777ef65ec 100644 --- a/src/SHAPERGUI/SHAPERGUI.h +++ b/src/SHAPERGUI/SHAPERGUI.h @@ -265,6 +265,10 @@ private slots: void hideInternalWindows(); + void hideDestroyedObjects(); + + void synchronizeObjectsVisibility(); + /// List of registered nested actions QStringList myNestedActionsList; -- 2.39.2