Set grid color for module editor and viewer (closes #1167884)

Also removed EDA_DRAW_FRAME::OnGrid which was totally dead (empty and unused)
This commit is contained in:
Lorenzo Marcantonio 2013-04-11 20:29:56 +02:00
parent d5fff4a6da
commit 65b7f23d46
6 changed files with 17 additions and 6 deletions

View File

@ -489,11 +489,6 @@ void EDA_DRAW_FRAME::SetToolID( int aId, int aCursor, const wxString& aToolMsg )
}
void EDA_DRAW_FRAME::OnGrid( int grid_type )
{
}
wxPoint EDA_DRAW_FRAME::GetGridPosition( const wxPoint& aPosition ) const
{
wxPoint pos = aPosition;

View File

@ -665,7 +665,6 @@ public:
void OnEraseBackground( wxEraseEvent& SizeEvent );
virtual void OnZoom( wxCommandEvent& event );
void OnGrid( int grid_type );
/**
* Function RedrawScreen

View File

@ -30,6 +30,7 @@
#include <wildcards_and_files_ext.h>
#include <menus_helpers.h>
#include <footprint_wizard_frame.h>
#include <pcbnew_config.h>
// Functions defined in block_module_editor, but used here
@ -877,3 +878,9 @@ void FOOTPRINT_EDIT_FRAME::OnVerticalToolbar( wxCommandEvent& aEvent )
SetToolID( ID_NO_TOOL_SELECTED, m_canvas->GetDefaultCursor(), wxEmptyString );
}
}
EDA_COLOR_T FOOTPRINT_EDIT_FRAME::GetGridColor() const
{
return g_ColorsSettings.GetItemColor( GRID_VISIBLE );
}

View File

@ -375,6 +375,8 @@ public:
void Select_Active_Library();
virtual EDA_COLOR_T GetGridColor( void ) const;
DECLARE_EVENT_TABLE()
protected:

View File

@ -45,6 +45,7 @@
#include <hotkeys.h>
#include <wildcards_and_files_ext.h>
#include <pcbnew_config.h>
/**
@ -697,3 +698,9 @@ void FOOTPRINT_VIEWER_FRAME::Update3D_Frame( bool aForceReloadFootprint )
m_Draw3DFrame->NewDisplay();
}
}
EDA_COLOR_T FOOTPRINT_VIEWER_FRAME::GetGridColor() const
{
return g_ColorsSettings.GetItemColor( GRID_VISIBLE );
}

View File

@ -86,6 +86,7 @@ public:
wxString& GetSelectedFootprint( void ) const { return m_selectedFootprintName; }
const wxString GetSelectedLibraryFullName( void );
virtual EDA_COLOR_T GetGridColor( void ) const;
private:
void OnSize( wxSizeEvent& event );