X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FEditorGraphicBBS%2FbbsWxGUIEditorGraphic%2FwxVtkSceneManager.cxx;h=95a2454c22ff447cf2ec8b5e21ee29bede39abf0;hb=8e6a8a638f2b03db8e34234b6e02d71cda913f9d;hp=599a26214478143bcc477bcf45d5b0cb87c0f804;hpb=36a0d24cb1d01a0f0c6010a18ec09874e6331fd5;p=bbtkGEditor.git diff --git a/lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/wxVtkSceneManager.cxx b/lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/wxVtkSceneManager.cxx index 599a262..95a2454 100644 --- a/lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/wxVtkSceneManager.cxx +++ b/lib/EditorGraphicBBS/bbsWxGUIEditorGraphic/wxVtkSceneManager.cxx @@ -280,6 +280,7 @@ int wxVtkSceneManager::createGBlackBox(int x, int y, std::string packageName,std //EED 15 oct 2012 BlackBoxDescriptor::Pointer descriptor = GObjectsMVCFactory::getInstance()->getBlackBoxDescriptor(packageName, boxType); + Package::Pointer k; std::map< std::string, BlackBoxDescriptor::Pointer> mapDesc; try{ @@ -332,7 +333,6 @@ int wxVtkSceneManager::createGBlackBox(int x, int y, std::string packageName,std std::map descriptorInMap = descriptor->GetInputDescriptorMap(); std::map::iterator itInput; - int i = 0; for (itInput = descriptorInMap.begin(); itInput != descriptorInMap.end(); ++itInput) { BlackBoxInputDescriptor *desc = itInput->second; @@ -344,7 +344,6 @@ int wxVtkSceneManager::createGBlackBox(int x, int y, std::string packageName,std std::map descriptorOutMap = descriptor->GetOutputDescriptorMap(); std::map::iterator itOutput; - i = 0; for (itOutput = descriptorOutMap.begin(); itOutput != descriptorOutMap.end(); ++itOutput) { @@ -357,6 +356,7 @@ int wxVtkSceneManager::createGBlackBox(int x, int y, std::string packageName,std //(NOTE: Refresh is only made by the view) view->setModel(model); view->setBaseView(_baseView); + view->initVtkObjects(); //Associates the controller with the correspondent model and view @@ -526,7 +526,11 @@ GPortController* wxVtkSceneManager::createGPort(int portType,std::string bbtkNam //(NOTE: Refresh is only made by the view) view->setModel(model); view->setBaseView(_baseView); - view->initVtkObjects(); + +//EED017 view->initVtkObjects(); + view->createVtkObjects(); +// view->addVtkActors(); + //Associates the controller with the correspondent model and view controller->setModelAndView(model, view); @@ -536,6 +540,7 @@ GPortController* wxVtkSceneManager::createGPort(int portType,std::string bbtkNam addObjectController(controller); return (GPortController*) controller; + } //========================================================================= @@ -570,7 +575,8 @@ int wxVtkSceneManager::createGConnector(GPortModel* startPort) * JGRR AND CM * Width increased from 2 to 3, it simplifies line handling and spline control :P * @param WidthLine - */ + */ + //EED2017 manContourView->SetWidthLine( 3 ) ; manContourView->SetShowText(false); @@ -2182,7 +2188,8 @@ void wxVtkSceneManager::loadDiagram(stringstream &inputStream) std::istringstream is(result); is >> numBoxes; - for (int i = 0; i < numBoxes; i++) { + for (int i = 0; i < numBoxes; i++) + { //---------- getCleanLine(inputStream, line);//BOX getCleanLine(inputStream, line);//package:type:name @@ -2254,7 +2261,8 @@ void wxVtkSceneManager::loadDiagram(stringstream &inputStream) bool boxExecutable = false; - if (isExec == "TRUE") { + if (isExec == "TRUE") + { boxExecutable = true; } @@ -2311,7 +2319,8 @@ void wxVtkSceneManager::loadDiagram(stringstream &inputStream) isCons >> numConns; - for (int i = 0; i < numConns; i++) { + for (int i = 0; i < numConns; i++) + { //---------- getCleanLine(inputStream, line);//CONNECTION getCleanLine(inputStream, line);//Startbox.PortName:EndBox.PortName @@ -2327,7 +2336,6 @@ void wxVtkSceneManager::loadDiagram(stringstream &inputStream) result = strtok(NULL, delims); std::string nameEndPort(result); - int idCon = configGConnetion(nameStartBox, nameStartPort,nameEndBox, nameEndPort); if (version != "1.0") {