eeschema: fix a crash when converting a old .sch file containing global labels.
This commit is contained in:
parent
6e1f075daa
commit
6b9c82c975
|
@ -346,6 +346,9 @@ void SCH_SHEET_PATH::UpdateAllScreenReferences() const
|
|||
else if( item->Type() == SCH_GLOBAL_LABEL_T )
|
||||
{
|
||||
SCH_GLOBALLABEL* label = static_cast<SCH_GLOBALLABEL*>( item );
|
||||
|
||||
if( label->GetFields().size() > 0 ) // Can be not the case when reading a old .sch schematic
|
||||
{
|
||||
SCH_FIELD& intersheetRefs = label->GetFields()[0];
|
||||
|
||||
intersheetRefs.SetVisible( label->Schematic()->Settings().m_IntersheetRefsShow );
|
||||
|
@ -353,6 +356,7 @@ void SCH_SHEET_PATH::UpdateAllScreenReferences() const
|
|||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue