Commit 51b3142c authored by daniel.bub's avatar daniel.bub
Browse files

[FIX] set default rename field, if selectedPdg is empty

parent c791bd16
......@@ -195,6 +195,12 @@ void WFilterPropertyHandler::createPropToSetParticleNames()
std::string WFilterPropertyHandler::setDefaultForRenameField()
{
WItemSelector selectedPdg = m_PdgForRenameSelection->get( true );
if( selectedPdg.empty() )
{
return "";
}
std::string particleName = selectedPdg.at( 0 )->getName();
return particleName.substr( 0, particleName.find( " (" ) );
}
......
......@@ -135,7 +135,7 @@ private:
fiberStartIndexes->push_back( fiberStartIndex );
//calculate fibers
for( int eID : *eventIDs )
for( size_t eID : *eventIDs )
{
if( currentEventID != eID )
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment