X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/blast.git/blobdiff_plain/cfe8322b50c9ef08ffbc3e52b0849bca4cd1d0bf..4cf57e6db08da791233d75237f62e74bc88dd427:/SourceItem.cpp diff --git a/SourceItem.cpp b/SourceItem.cpp index 27db2a3..6c2b30d 100644 --- a/SourceItem.cpp +++ b/SourceItem.cpp @@ -603,10 +603,9 @@ void SourceItem::load(QDomElement funcElement) throw(Exception) { else { reference = referenceMd5; } - - GroupBlock* parentGroupBlock = AB_TO_GRP(((GroupItem *)parentItem())->getRefBlock()); - FunctionalBlock* functionalBlock = params->getGraph()->createFunctionalBlock(parentGroupBlock, reference); - /* NB: addFunctionalBlock creates all interfaces from the reference, which is annoying when + + FunctionalBlock* functionalBlock = params->getGraph()->createSourceBlock(reference); + /* NB: createSourceBlock creates all interfaces from the reference, which is annoying when reading bif_iface tags. Thus interface are all removed. */ functionalBlock->setName(name); @@ -617,7 +616,7 @@ void SourceItem::load(QDomElement funcElement) throw(Exception) { setId(id); - QDomNodeList blockParamNodes = funcElement.elementsByTagName("bif_parameter"); + QDomNodeList blockParamNodes = funcElement.elementsByTagName("source_parameter"); // setting parameters value for(int i=0; igetParameterFromName(name); if (blockParam == NULL) throw(Exception(PROJECTFILE_CORRUPTED)); - blockParam->setValue(value); + blockParam->setValue(value); } // recreate all (non-control) interfaces because of some may have a multiplicity>1 with several examplars functionalBlock->removeAllInterfaces(); - QDomNodeList interfaceNodes = funcElement.elementsByTagName("bif_iface"); + QDomNodeList interfaceNodes = funcElement.elementsByTagName("source_iface"); // setting interfaces (user name, and for multiplicity>1 may be create some new ones) for(int i=0; i