Browse Source

Add a SCH_ITEM::operator= so the connections caches don't get copied.

Fixes https://gitlab.com/kicad/code/kicad/issues/9710
6.0.7
Jeff Young 4 years ago
parent
commit
15f309c8a8
  1. 10
      eeschema/sch_item.cpp
  2. 2
      eeschema/sch_item.h

10
eeschema/sch_item.cpp

@ -62,6 +62,16 @@ SCH_ITEM::SCH_ITEM( const SCH_ITEM& aItem ) :
}
SCH_ITEM& SCH_ITEM::operator=( const SCH_ITEM& aItem )
{
m_layer = aItem.m_layer;
m_fieldsAutoplaced = aItem.m_fieldsAutoplaced;
m_connectivity_dirty = true;
return *this;
}
SCH_ITEM::~SCH_ITEM()
{
// Do not let the connections container go out of scope with any objects or they

2
eeschema/sch_item.h

@ -186,6 +186,8 @@ public:
SCH_ITEM( const SCH_ITEM& aItem );
SCH_ITEM& operator=( const SCH_ITEM& aPin );
virtual ~SCH_ITEM();
virtual wxString GetClass() const override

Loading…
Cancel
Save