X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;ds=sidebyside;f=lib%2FcpPipelineEditor%2FEditor.cxx;h=289ee46431d2e8e51dc0e5f51eb64a658396cd67;hb=e6bef8234ffd9030c68a6786466a08cf144b7871;hp=8388eddb123b3cbff209ed47542acab7ab7c67d4;hpb=bf4172934768034696b1c4b993b7e92e3808e083;p=cpPlugins.git diff --git a/lib/cpPipelineEditor/Editor.cxx b/lib/cpPipelineEditor/Editor.cxx index 8388edd..289ee46 100644 --- a/lib/cpPipelineEditor/Editor.cxx +++ b/lib/cpPipelineEditor/Editor.cxx @@ -119,12 +119,16 @@ setWorkspace( TWorkspace* ws ) // ------------------------------------------------------------------------- std::string cpPipelineEditor::Editor:: -createFilter( const std::string& filter, const QPointF& pnt ) +createFilter( + const std::string& category, + const std::string& filter, + const QPointF& pnt + ) { std::string name = filter; while( this->m_Workspace->HasFilter( name ) ) name += std::string( "_" ); - if( this->m_Workspace->CreateFilter( filter, name ) ) + if( this->m_Workspace->CreateFilter( category, filter, name ) ) { auto b = this->_createBlock( this->m_Workspace->GetFilter( name ), @@ -279,6 +283,24 @@ showOutputData( emit showFilterOutput( filter_name, output_name ); } +// ------------------------------------------------------------------------- +void cpPipelineEditor::Editor:: +hideOutputData( + const std::string& filter_name, const std::string& output_name + ) +{ + emit hideFilterOutput( filter_name, output_name ); +} + +// ------------------------------------------------------------------------- +void cpPipelineEditor::Editor:: +visualPropertiesOutputData( + const std::string& filter_name, const std::string& output_name + ) +{ + emit visualPropertiesFilterOutput( filter_name, output_name ); +} + // ------------------------------------------------------------------------- cpPipelineEditor_Editor_Callback_CODE( ContextMenu ) { @@ -358,15 +380,11 @@ cpPipelineEditor_Editor_Callback_CODE( MouseDoubleClick ) old_name.toStdString( ), new_name.toStdString( ) ); - if( ok ) - { - block->setNamePort( new_name ); - this->m_Workspace->RenameFilter( - old_name.toStdString( ), - new_name.toStdString( ) - ); - - } // fi + block->setNamePort( new_name ); + this->m_Workspace->RenameFilter( + old_name.toStdString( ), + new_name.toStdString( ) + ); } // fi }