CADSTAR Sch: TERMATTR may have more than one attribute subnode
Fixes https://gitlab.com/kicad/code/kicad/-/issues/13526
This commit is contained in:
parent
604a7d69db
commit
fc04f5135f
|
@ -559,14 +559,14 @@ void CADSTAR_SCH_ARCHIVE_PARSER::TERMATTR::Parse( XNODE* aNode, PARSER_CONTEXT*
|
|||
TerminalID = GetXmlAttributeIDLong( aNode, 0 );
|
||||
|
||||
XNODE* cNode = aNode->GetChildren();
|
||||
bool attrParsed = false;
|
||||
|
||||
for( ; cNode; cNode = cNode->GetNext() )
|
||||
{
|
||||
if( !attrParsed && cNode->GetName() == wxT( "ATTR" ) )
|
||||
if( cNode->GetName() == wxT( "ATTR" ) )
|
||||
{
|
||||
Value.Parse( cNode, aContext );
|
||||
attrParsed = true;
|
||||
ATTRIBUTE_VALUE val;
|
||||
val.Parse( cNode, aContext );
|
||||
Attributes.push_back( val );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
@ -207,7 +207,7 @@ public:
|
|||
struct TERMATTR : PARSER
|
||||
{
|
||||
TERMINAL_ID TerminalID;
|
||||
ATTRIBUTE_VALUE Value;
|
||||
std::vector<ATTRIBUTE_VALUE> Attributes;
|
||||
|
||||
void Parse( XNODE* aNode, PARSER_CONTEXT* aContext ) override;
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue