Jeff Young 3 years ago
parent
commit
e64b356d93
  1. 18
      eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp

18
eeschema/sch_plugins/kicad/sch_sexpr_parser.cpp

@ -3839,19 +3839,19 @@ SCH_TEXT* SCH_SEXPR_PARSER::parseSchText()
SCH_FIELD* field = parseSchField( text.get() );
if( text->Type() == SCH_GLOBAL_LABEL_T )
// If the field is a Intersheetrefs it is not handled like other fields:
// It always exists and is the first in list
if( text->Type() == SCH_GLOBAL_LABEL_T
&& ( field->GetInternalName() == wxT( "Intersheet References" ) // old name in V6.0
|| field->GetInternalName() == wxT( "Intersheetrefs" ) ) ) // Current name
{
// If the field is a Intersheetrefs it is not handled like other fields:
// It always exists and is the first in list
if( field->GetInternalName() == wxT( "Intersheetrefs") || // Current name
field->GetInternalName() == wxT( "Intersheet References") ) // old name in V6.0
{
SCH_GLOBALLABEL* label = static_cast<SCH_GLOBALLABEL*>( text.get() );
label->GetFields()[0] = *field;
}
SCH_GLOBALLABEL* label = static_cast<SCH_GLOBALLABEL*>( text.get() );
label->GetFields()[0] = *field;
}
else
{
static_cast<SCH_LABEL_BASE*>( text.get() )->GetFields().emplace_back( *field );
}
delete field;
break;

Loading…
Cancel
Save