X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=blobdiff_plain;f=lib%2FcpPlugins%2FInterface%2FProcessObject.cxx;h=6f3bd34e3d8e537e47282613974ae73f87548272;hb=24dc7fa44ff75dc9336d703b8243ce1e52ff3429;hp=9c3148d00fe9adf9abd0a7392bef5c60619a6add;hpb=c0627ed97baf80b6751379801fc4d5c377b45467;p=cpPlugins.git diff --git a/lib/cpPlugins/Interface/ProcessObject.cxx b/lib/cpPlugins/Interface/ProcessObject.cxx index 9c3148d..6f3bd34 100644 --- a/lib/cpPlugins/Interface/ProcessObject.cxx +++ b/lib/cpPlugins/Interface/ProcessObject.cxx @@ -17,6 +17,26 @@ Modified( ) const this->Superclass::Modified( ); } +// ------------------------------------------------------------------------- +bool cpPlugins::Interface::ProcessObject:: +IsInteractive( ) const +{ + std::vector< std::string > names; + this->m_Parameters->GetNames( names ); + bool res = false; + auto i = names.begin( ); + for( ; i != names.end( ); ++i ) + { + TParameters::Type t = this->m_Parameters->GetType( *i ); + res |= ( t == TParameters::Point ); + res |= ( t == TParameters::Index ); + res |= ( t == TParameters::PointList ); + res |= ( t == TParameters::IndexList ); + + } // rof + return( res ); +} + // ------------------------------------------------------------------------- cpPlugins::Interface::ProcessObject:: TParameters* cpPlugins::Interface::ProcessObject:: @@ -33,6 +53,29 @@ GetParameters( ) const return( this->m_Parameters.GetPointer( ) ); } +// ------------------------------------------------------------------------- +cpPlugins::Interface:: +Plugins* cpPlugins::Interface::ProcessObject:: +GetPlugins( ) +{ + return( this->m_Plugins ); +} + +// ------------------------------------------------------------------------- +const cpPlugins::Interface:: +Plugins* cpPlugins::Interface::ProcessObject:: +GetPlugins( ) const +{ + return( this->m_Plugins ); +} + +// ------------------------------------------------------------------------- +void cpPlugins::Interface::ProcessObject:: +SetPlugins( Plugins* p ) +{ + this->m_Plugins = p; +} + // ------------------------------------------------------------------------- unsigned int cpPlugins::Interface::ProcessObject:: GetNumberOfInputs( ) const @@ -161,9 +204,11 @@ cpPlugins::Interface::ProcessObject:: ProcessObject( ) : Superclass( ), m_ITKObject( NULL ), - m_VTKObject( NULL ) + m_VTKObject( NULL ), + m_Plugins( NULL ) { this->m_Parameters = TParameters::New( ); + this->m_Parameters->SetProcessObject( this ); this->m_ParametersDialog = new ParametersQtDialog( ); this->m_ParametersDialog->setTitle(