Better type safety to DANGLING_END_ITEM (SCH_ITEM* instead of void*)

This commit is contained in:
Lorenzo Marcantonio 2013-04-01 07:26:53 +02:00
parent c32f56ffaa
commit 8175163296
1 changed files with 3 additions and 3 deletions

View File

@ -85,7 +85,7 @@ class DANGLING_END_ITEM
{ {
private: private:
/// A pointer to the connectable object. /// A pointer to the connectable object.
const void* m_item; const EDA_ITEM* m_item;
/// The position of the connection point. /// The position of the connection point.
wxPoint m_pos; wxPoint m_pos;
@ -94,7 +94,7 @@ private:
DANGLING_END_T m_type; DANGLING_END_T m_type;
public: public:
DANGLING_END_ITEM( DANGLING_END_T aType, const void* aItem, const wxPoint& aPosition ) DANGLING_END_ITEM( DANGLING_END_T aType, const EDA_ITEM* aItem, const wxPoint& aPosition )
{ {
m_item = aItem; m_item = aItem;
m_type = aType; m_type = aType;
@ -102,7 +102,7 @@ public:
} }
wxPoint GetPosition() const { return m_pos; } wxPoint GetPosition() const { return m_pos; }
const void* GetItem() const { return m_item; } const EDA_ITEM* GetItem() const { return m_item; }
DANGLING_END_T GetType() const { return m_type; } DANGLING_END_T GetType() const { return m_type; }
}; };