X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=appli%2FcpPipelineEditor%2FQNodesEditor.cxx;h=590f8df610c632c2b77b5369aed1916246b74a0a;hb=9c75dcecf566cc567583caf4687ce523a2af586d;hp=91a5914b8248ad5115c96a394a868b395ce6c5fb;hpb=2c372f652bce67b347cd91737916504a054604a3;p=cpPlugins.git diff --git a/appli/cpPipelineEditor/QNodesEditor.cxx b/appli/cpPipelineEditor/QNodesEditor.cxx index 91a5914..590f8df 100644 --- a/appli/cpPipelineEditor/QNodesEditor.cxx +++ b/appli/cpPipelineEditor/QNodesEditor.cxx @@ -150,52 +150,8 @@ eventFilter( QObject* o, QEvent* e ) } break; } - } + } // hctiws return( this->Superclass::eventFilter( o, e ) ); } -// ------------------------------------------------------------------------- -void PipelineEditor::QNodesEditor:: -save( QDataStream& ds ) -{ - foreach( QGraphicsItem* item, this->m_Scene->items( ) ) - if( item->type( ) == QNEBlock::Type ) - { - ds << item->type( ); - ( ( QNEBlock* ) item )->save( ds ); - } - - foreach( QGraphicsItem* item, this->m_Scene->items( ) ) - if( item->type( ) == QNEConnection::Type ) - { - ds << item->type( ); - ( ( QNEConnection* ) item )->save( ds ); - } -} - -// ------------------------------------------------------------------------- -void PipelineEditor::QNodesEditor:: -load( QDataStream& ds ) -{ - this->m_Scene->clear( ); - - QMap portMap; - - while ( !ds.atEnd( ) ) - { - int type; - ds >> type; - if( type == QNEBlock::Type ) - { - QNEBlock* block = new QNEBlock( 0, this->m_Scene ); - block->load( ds, portMap ); - } - else if( type == QNEConnection::Type ) - { - this->m_Conn = new QNEConnection( 0, this->m_Scene ); - this->m_Conn->load( ds, portMap ); - } - } -} - // eof - $RCSfile$