/** * @brief elementName returns the title of the element. * @param elementType the type of the element can be NODE or EDGE * @param elementId the id of the element * @return */ QString elementName(ElementType elementType, unsigned int elementId) const override { if (hView->getDataLocation() == EDGE) { elementId = hView->getMappedId(elementId); return QString("Edge") + " #" + QString::number(elementId); } return MouseShowElementInfo::elementName(elementType, elementId); }
/** * @brief buildModel create and returns the model to visualize edit elements parameters. * @param elementType the type of the element can be NODE or EDGE * @param elementId elementId the id of the element * @param parent the parent for the model creation. * @return */ virtual QAbstractItemModel* buildModel(ElementType elementType, unsigned int elementId, QObject *parent) const { if (hView->getDataLocation() == EDGE) { elementId = hView->getMappedId(elementId); return new GraphEdgeElementModel(hView->graph(), elementId, parent); } return MouseShowElementInfos::buildModel(elementType, elementId, parent); }