Add missing IsMandatory() fn
This commit is contained in:
parent
41ebd3c560
commit
76a68b1f8d
|
@ -1295,6 +1295,15 @@ VECTOR2I SCH_FIELD::GetParentPosition() const
|
|||
}
|
||||
|
||||
|
||||
bool SCH_FIELD::IsMandatory() const
|
||||
{
|
||||
if( m_parent && m_parent->Type() == SCH_SHEET_T )
|
||||
return m_id >= 0 && m_id < SHEET_MANDATORY_FIELDS;
|
||||
else
|
||||
return m_id >= 0 && m_id < MANDATORY_FIELDS;
|
||||
}
|
||||
|
||||
|
||||
bool SCH_FIELD::operator <( const SCH_ITEM& aItem ) const
|
||||
{
|
||||
if( Type() != aItem.Type() )
|
||||
|
|
|
@ -209,6 +209,8 @@ public:
|
|||
*/
|
||||
void ImportValues( const LIB_FIELD& aSource );
|
||||
|
||||
bool IsMandatory() const;
|
||||
|
||||
int GetPenWidth() const override;
|
||||
|
||||
void ClearCaches() override;
|
||||
|
|
Loading…
Reference in New Issue