From 8254637d39365d581b0f09a582a2fef3a58232a3 Mon Sep 17 00:00:00 2001 From: mpv Date: Fri, 22 May 2015 16:43:45 +0300 Subject: [PATCH] Make several parts created in the correct order --- src/Model/Model_Document.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Model/Model_Document.cpp b/src/Model/Model_Document.cpp index df85c6e4b..90e577c05 100644 --- a/src/Model/Model_Document.cpp +++ b/src/Model/Model_Document.cpp @@ -544,10 +544,10 @@ FeaturePtr Model_Document::addFeature(std::string theID, const bool theMakeCurre aDocToAdd = this; } if (aFeature) { - aDocToAdd->myObjs->addFeature(aFeature, currentFeature(false)); + aDocToAdd->myObjs->addFeature(aFeature, aDocToAdd->currentFeature(false)); if (!aFeature->isAction()) { // do not add action to the data model if (theMakeCurrent) // after all this feature stays in the document, so make it current - setCurrentFeature(aFeature, false); + aDocToAdd->setCurrentFeature(aFeature, false); } else { // feature must be executed // no creation event => updater not working, problem with remove part aFeature->execute(); -- 2.39.2