X-Git-Url: https://bilbo.iut-bm.univ-fcomte.fr/and/gitweb/blast.git/blobdiff_plain/4327c2b8817b627249d98d889835726217c81a4e..bc5d59217a24b25c1b913bec4a41dd026d02720c:/InterfaceItem.cpp diff --git a/InterfaceItem.cpp b/InterfaceItem.cpp index 02b04ac..7ee68c6 100644 --- a/InterfaceItem.cpp +++ b/InterfaceItem.cpp @@ -4,6 +4,7 @@ #include "GroupInterface.h" #include "FunctionalInterface.h" #include "BoxItem.h" +#include "ReferenceInterface.h" int InterfaceItem::counter = 0; @@ -45,6 +46,15 @@ QString InterfaceItem::getName() { return refInter->getName(); } +QString InterfaceItem::getReferenceName() { + if (!refInter->isFunctionalInterface()) { + return "no_refname_for_groupiface"; + } + FunctionalInterface* iface = AI_TO_FUN(refInter); + ReferenceInterface* refIface = iface->getReference(); + return refIface->getName(); +} + void InterfaceItem::updateName(QString name) { QFontMetrics fmName(params->defaultIfaceFont); nameWidth = fmName.width(refInter->getName());