#include <LightApp_Application.h>
#include <LightApp_SelectionMgr.h>
#include <LightApp_OCCSelector.h>
+#include <LightApp_Study.h>
#include <OCCViewer_ViewModel.h>
#include <SUIT_Selector.h>
//******************************************************
CAM_DataModel* NewGeom_Module::createDataModel()
{
- return new NewGeom_DataModel(this);
+ NewGeom_DataModel* aDataModel = new NewGeom_DataModel(this);
+
+ // Calling addComponent() for persistent functionality work in the SalomeApp_Study
+ LightApp_Study* aStudy = dynamic_cast<LightApp_Study*>(application()->activeStudy() );
+ aStudy->addComponent(aDataModel);
+
+ return aDataModel;
}
//******************************************************