From 3ada14dd063c375b5c153c65758f57eee2535a28 Mon Sep 17 00:00:00 2001 From: vsv Date: Wed, 21 Nov 2018 15:13:13 +0300 Subject: [PATCH] Fix a bug of tree with ExtrusionCut operation launched from a script --- src/XGUI/XGUI_DataModel.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/XGUI/XGUI_DataModel.cpp b/src/XGUI/XGUI_DataModel.cpp index 95c80678b..4980dd198 100644 --- a/src/XGUI/XGUI_DataModel.cpp +++ b/src/XGUI/XGUI_DataModel.cpp @@ -142,7 +142,10 @@ void XGUI_DataModel::processEvent(const std::shared_ptr& theMess foreach(ObjectPtr aObj, aCreated) { ModuleBase_ITreeNode* aNode = myRoot->subNode(aObj); if (aNode) { - aNode->update(); + if (aNode->parent()) + aNode->parent()->update(); + else + aNode->update(); rebuildDataTree(); QModelIndex aFirstIdx = getIndex(aNode, 0); QModelIndex aLastIdx = getIndex(aNode, 2); -- 2.39.2