refactoring: make BOARD_COMMIT independent from pcbnew

This commit is contained in:
Tomasz Włostowski 2017-10-31 12:03:37 +01:00
parent ec61a00371
commit d0ef881a53
2 changed files with 6 additions and 4 deletions

View File

@ -44,7 +44,7 @@ BOARD_COMMIT::BOARD_COMMIT( PCB_TOOL* aTool )
} }
BOARD_COMMIT::BOARD_COMMIT( PCB_BASE_FRAME* aFrame ) BOARD_COMMIT::BOARD_COMMIT( EDA_DRAW_FRAME* aFrame )
{ {
m_toolMgr = aFrame->GetToolManager(); m_toolMgr = aFrame->GetToolManager();
m_editModules = aFrame->IsType( FRAME_PCB_MODULE_EDITOR ); m_editModules = aFrame->IsType( FRAME_PCB_MODULE_EDITOR );

View File

@ -30,14 +30,16 @@
class BOARD_ITEM; class BOARD_ITEM;
class PICKED_ITEMS_LIST; class PICKED_ITEMS_LIST;
class PCB_TOOL; class PCB_TOOL;
class PCB_BASE_FRAME;
class TOOL_MANAGER; class TOOL_MANAGER;
class EDA_DRAW_FRAME;
class TOOL_BASE;
class BOARD_COMMIT : public COMMIT class BOARD_COMMIT : public COMMIT
{ {
public: public:
BOARD_COMMIT( EDA_DRAW_FRAME* aFrame );
BOARD_COMMIT( PCB_TOOL *aTool ); BOARD_COMMIT( PCB_TOOL *aTool );
BOARD_COMMIT( PCB_BASE_FRAME* aFrame );
virtual ~BOARD_COMMIT(); virtual ~BOARD_COMMIT();
virtual void Push( const wxString& aMessage = wxT( "A commit" ), bool aCreateUndoEntry = true ) override; virtual void Push( const wxString& aMessage = wxT( "A commit" ), bool aCreateUndoEntry = true ) override;