X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcpPipelineEditor%2FPort.cxx;h=1eb2c78c637ee0b99dbdb220caa1ed23dfe485d1;hb=8b6eaedb25048704cb0a1a3fa1dd751c4fb25db4;hp=a2125f7383330bf2082ece043a3b8ec03339fb1b;hpb=19a9e1774044cc32c415ad38695800c1d169820d;p=cpPlugins.git diff --git a/lib/cpPipelineEditor/Port.cxx b/lib/cpPipelineEditor/Port.cxx index a2125f7..1eb2c78 100644 --- a/lib/cpPipelineEditor/Port.cxx +++ b/lib/cpPipelineEditor/Port.cxx @@ -124,37 +124,6 @@ isConnected( Port* other ) return( false ); } -// ------------------------------------------------------------------------- -cpPipelineEditor::TypePort:: -TypePort( QGraphicsItem* parent, QGraphicsScene* scene ) - : Superclass( parent, scene ) -{ -} - -// ------------------------------------------------------------------------- -cpPipelineEditor::TypePort:: -~TypePort( ) -{ -} - -// ------------------------------------------------------------------------- -void cpPipelineEditor::TypePort:: -_updateLabels( ) -{ - QFont font( this->scene( )->font( ) ); - font.setItalic( true ); - this->m_Label->setFont( font ); - this->m_ExtendedLabel->setFont( font ); - this->setPath( QPainterPath( ) ); -} - -// ------------------------------------------------------------------------- -bool cpPipelineEditor::TypePort:: -isConnected( Port* other ) -{ - return( false ); -} - // ------------------------------------------------------------------------- cpPipelineEditor::InputPort:: InputPort( QGraphicsItem* parent, QGraphicsScene* scene ) @@ -306,6 +275,7 @@ contextMenuEvent( QGraphicsSceneContextMenuEvent* evt ) QMenu menu; QAction* showAction = menu.addAction( "Show" ); QAction* hideAction = menu.addAction( "Hide" ); + QAction* propertiesAction = menu.addAction( "Properties" ); QAction* selectedAction = menu.exec( evt->screenPos( ) ); if( selectedAction == showAction ) @@ -317,6 +287,18 @@ contextMenuEvent( QGraphicsSceneContextMenuEvent* evt ) } else if( selectedAction == hideAction ) { + this->m_Block->editor( )->hideOutputData( + this->m_Block->namePort( ).toStdString( ), + this->name( ).toStdString( ) + ); + } + else if( selectedAction == propertiesAction ) + { + this->m_Block->editor( )->visualPropertiesOutputData( + this->m_Block->namePort( ).toStdString( ), + this->name( ).toStdString( ) + ); + } // fi }