From: Leonardo Florez Valencia Date: Wed, 4 Mar 2015 02:50:04 +0000 (+0100) Subject: Parameters given as lists were corrected to avoid conflicts with the MSWin file system. X-Git-Tag: v0.1~411 X-Git-Url: https://git.creatis.insa-lyon.fr/pubgit/?a=commitdiff_plain;h=bd25303e6df8698b696a61975d9a1aff40c7231d;p=cpPlugins.git Parameters given as lists were corrected to avoid conflicts with the MSWin file system. --- diff --git a/lib/cpPlugins/Interface/Parameters.cxx b/lib/cpPlugins/Interface/Parameters.cxx index 54eab8d..603aca9 100644 --- a/lib/cpPlugins/Interface/Parameters.cxx +++ b/lib/cpPlugins/Interface/Parameters.cxx @@ -57,7 +57,7 @@ cpPlugins_Interface_Parameters_SetArrayMacro( Point, double ); if( pIt->second.first != Self::TYPE##List ) \ return; \ std::stringstream ss; \ - ss << pIt->second.second << v << ":"; \ + ss << pIt->second.second << v << "#"; \ pIt->second.second = ss.str( ); \ } @@ -84,7 +84,7 @@ cpPlugins_Interface_Parameters_SetListMacro( Real ); for( TUint i = 0; i < n; ++i ) \ ss << va_arg( v_lst, ATYPE ) << ","; \ va_end( v_lst ); \ - ss << ":"; \ + ss << "#"; \ pIt->second.second = ss.str( ); \ } @@ -273,7 +273,7 @@ GetValueAsStringList( std::istringstream ss( pIt->second.second ); std::string token; - while( std::getline( ss, token, ':' ) ) + while( std::getline( ss, token, '#' ) ) if( token != "" ) lst.push_back( token ); } @@ -291,7 +291,7 @@ GetValueAsBoolList( std::vector< TBool >& lst, const TString& name ) const std::istringstream ss( pIt->second.second ); std::string token; - while( std::getline( ss, token, ':' ) ) + while( std::getline( ss, token, '#' ) ) if( token != "" ) lst.push_back( TBool( std::atoi( token.c_str( ) ) == 1 ) ); } @@ -309,7 +309,7 @@ GetValueAsIntList( std::vector< TInt >& lst, const TString& name ) const std::istringstream ss( pIt->second.second ); std::string token; - while( std::getline( ss, token, ':' ) ) + while( std::getline( ss, token, '#' ) ) if( token != "" ) lst.push_back( TInt( std::atoi( token.c_str( ) ) ) ); } @@ -327,7 +327,7 @@ GetValueAsUintList( std::vector< TUint >& lst, const TString& name ) const std::istringstream ss( pIt->second.second ); std::string token; - while( std::getline( ss, token, ':' ) ) + while( std::getline( ss, token, '#' ) ) if( token != "" ) lst.push_back( TUint( std::atoi( token.c_str( ) ) ) ); } @@ -345,7 +345,7 @@ GetValueAsRealList( std::vector< TReal >& lst, const TString& name ) const std::istringstream ss( pIt->second.second ); std::string token; - while( std::getline( ss, token, ':' ) ) + while( std::getline( ss, token, '#' ) ) if( token != "" ) lst.push_back( TReal( std::atof( token.c_str( ) ) ) ); }