Component library object encapsulation work.

This commit is contained in:
Wayne Stambaugh
2010-12-07 11:10:42 -05:00
parent a6a34f3509
commit 3fed7b9dd9
21 changed files with 500 additions and 426 deletions
+10 -6
View File
@@ -20,9 +20,7 @@ enum textbox {
};
/******************************************************************************/
EDA_BaseStruct::EDA_BaseStruct( EDA_BaseStruct* parent, KICAD_T idType )
/******************************************************************************/
{
InitVars();
m_StructType = idType;
@@ -30,9 +28,7 @@ EDA_BaseStruct::EDA_BaseStruct( EDA_BaseStruct* parent, KICAD_T idType )
}
/********************************************/
EDA_BaseStruct::EDA_BaseStruct( KICAD_T idType )
/********************************************/
{
InitVars();
m_StructType = idType;
@@ -51,9 +47,7 @@ EDA_BaseStruct::EDA_BaseStruct( const EDA_BaseStruct& base )
}
/********************************************/
void EDA_BaseStruct::InitVars()
/********************************************/
{
m_StructType = TYPE_NOT_INIT;
Pnext = NULL; // Linked list: Link (next struct)
@@ -69,6 +63,16 @@ void EDA_BaseStruct::InitVars()
}
void EDA_BaseStruct::SetModified()
{
m_Flags |= IS_CHANGED;
// If this a child object, then the parent modification state also needs to be set.
if( m_Parent )
m_Parent->SetModified();
}
// see base_struct.h
SEARCH_RESULT EDA_BaseStruct::IterateForward( EDA_BaseStruct* listStart,
INSPECTOR* inspector,