Commit 9b57038c authored by charras's avatar charras

fix 2 minor problems

parent dc4bfd8f
...@@ -111,6 +111,8 @@ BEGIN_EVENT_TABLE( WinEDA_GerberFrame, WinEDA_BasePcbFrame ) ...@@ -111,6 +111,8 @@ BEGIN_EVENT_TABLE( WinEDA_GerberFrame, WinEDA_BasePcbFrame )
WinEDA_GerberFrame::OnSelectOptionToolbar ) WinEDA_GerberFrame::OnSelectOptionToolbar )
EVT_TOOL( ID_TB_OPTIONS_SHOW_LAYERS_MANAGER_VERTICAL_TOOLBAR, EVT_TOOL( ID_TB_OPTIONS_SHOW_LAYERS_MANAGER_VERTICAL_TOOLBAR,
WinEDA_GerberFrame::OnSelectOptionToolbar ) WinEDA_GerberFrame::OnSelectOptionToolbar )
EVT_TOOL( ID_TB_OPTIONS_SHOW_DCODES,
WinEDA_GerberFrame::OnSelectOptionToolbar )
END_EVENT_TABLE() END_EVENT_TABLE()
......
...@@ -26,7 +26,6 @@ void WinEDA_GerberFrame::OnSelectOptionToolbar( wxCommandEvent& event ) ...@@ -26,7 +26,6 @@ void WinEDA_GerberFrame::OnSelectOptionToolbar( wxCommandEvent& event )
{ {
int id = event.GetId(); int id = event.GetId();
bool state; bool state;
switch( id ) switch( id )
{ {
case ID_MENU_GERBVIEW_SHOW_HIDE_LAYERS_MANAGER_DIALOG: case ID_MENU_GERBVIEW_SHOW_HIDE_LAYERS_MANAGER_DIALOG:
......
...@@ -324,7 +324,7 @@ void WinEDA_GerberFrame::ReCreateOptToolbar( void ) ...@@ -324,7 +324,7 @@ void WinEDA_GerberFrame::ReCreateOptToolbar( void )
_( _(
"Show/hide the layers manager toolbar" ), "Show/hide the layers manager toolbar" ),
wxITEM_CHECK ); wxITEM_CHECK );
m_OptionsToolBar->Realize(); m_OptionsToolBar->Realize();
SetToolbars(); SetToolbars();
......
...@@ -6,10 +6,6 @@ ...@@ -6,10 +6,6 @@
/// Licence: GNU License /// Licence: GNU License
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
#pragma implementation "zones.h"
#endif
#include "fctsys.h" #include "fctsys.h"
#include "appl_wxstruct.h" #include "appl_wxstruct.h"
#include "common.h" #include "common.h"
...@@ -41,17 +37,16 @@ dialog_copper_zone::dialog_copper_zone( WinEDA_PcbFrame* parent, ZONE_SETTING* z ...@@ -41,17 +37,16 @@ dialog_copper_zone::dialog_copper_zone( WinEDA_PcbFrame* parent, ZONE_SETTING* z
} }
SetReturnCode( ZONE_ABORT ); // Will be changed on buttons click SetReturnCode( ZONE_ABORT ); // Will be changed on buttons click
initDialog();
if( GetSizer() ) GetSizer()->SetSizeHints( this );
{
GetSizer()->SetSizeHints( this );
}
Center(); Center();
} }
/*****************************************************************/ /*****************************************************************/
void dialog_copper_zone::OnInitDialog( wxInitDialogEvent& event ) void dialog_copper_zone::initDialog( )
/*****************************************************************/ /*****************************************************************/
// Initialise all dialog options and values in wxTextCtrl // Initialise all dialog options and values in wxTextCtrl
......
...@@ -9,7 +9,7 @@ ...@@ -9,7 +9,7 @@
*/ */
class dialog_copper_zone : public dialog_copper_zone_base class dialog_copper_zone : public dialog_copper_zone_base
{ {
public: private:
WinEDA_PcbFrame* m_Parent; WinEDA_PcbFrame* m_Parent;
wxConfig* m_Config; // Current config wxConfig* m_Config; // Current config
int m_OnExitCode; /* exit code: ZONE_ABORT if no change, int m_OnExitCode; /* exit code: ZONE_ABORT if no change,
...@@ -23,7 +23,8 @@ public: ...@@ -23,7 +23,8 @@ public:
public: public:
dialog_copper_zone( WinEDA_PcbFrame* parent, ZONE_SETTING* zone_setting ); dialog_copper_zone( WinEDA_PcbFrame* parent, ZONE_SETTING* zone_setting );
void OnInitDialog( wxInitDialogEvent& event ); private:
void initDialog( );
void OnButtonOkClick( wxCommandEvent& event ); void OnButtonOkClick( wxCommandEvent& event );
void OnButtonCancelClick( wxCommandEvent& event ); void OnButtonCancelClick( wxCommandEvent& event );
bool AcceptOptions( bool aPromptForErrors, bool aUseExportableSetupOnly = false ); bool AcceptOptions( bool aPromptForErrors, bool aUseExportableSetupOnly = false );
......
...@@ -10,7 +10,6 @@ ...@@ -10,7 +10,6 @@
/////////////////////////////////////////////////////////////////////////// ///////////////////////////////////////////////////////////////////////////
BEGIN_EVENT_TABLE( dialog_copper_zone_base, wxDialog ) BEGIN_EVENT_TABLE( dialog_copper_zone_base, wxDialog )
EVT_INIT_DIALOG( dialog_copper_zone_base::_wxFB_OnInitDialog )
EVT_RADIOBOX( wxID_PADS_IN_ZONE_OPTIONS, dialog_copper_zone_base::_wxFB_OnPadsInZoneClick ) EVT_RADIOBOX( wxID_PADS_IN_ZONE_OPTIONS, dialog_copper_zone_base::_wxFB_OnPadsInZoneClick )
EVT_BUTTON( wxID_BUTTON_EXPORT, dialog_copper_zone_base::_wxFB_ExportSetupToOtherCopperZones ) EVT_BUTTON( wxID_BUTTON_EXPORT, dialog_copper_zone_base::_wxFB_ExportSetupToOtherCopperZones )
EVT_BUTTON( wxID_OK, dialog_copper_zone_base::_wxFB_OnButtonOkClick ) EVT_BUTTON( wxID_OK, dialog_copper_zone_base::_wxFB_OnButtonOkClick )
......
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
<event name="OnHibernate"></event> <event name="OnHibernate"></event>
<event name="OnIconize"></event> <event name="OnIconize"></event>
<event name="OnIdle"></event> <event name="OnIdle"></event>
<event name="OnInitDialog">OnInitDialog</event> <event name="OnInitDialog"></event>
<event name="OnKeyDown"></event> <event name="OnKeyDown"></event>
<event name="OnKeyUp"></event> <event name="OnKeyUp"></event>
<event name="OnKillFocus"></event> <event name="OnKillFocus"></event>
......
...@@ -35,7 +35,6 @@ class dialog_copper_zone_base : public wxDialog ...@@ -35,7 +35,6 @@ class dialog_copper_zone_base : public wxDialog
private: private:
// Private event handlers // Private event handlers
void _wxFB_OnInitDialog( wxInitDialogEvent& event ){ OnInitDialog( event ); }
void _wxFB_OnPadsInZoneClick( wxCommandEvent& event ){ OnPadsInZoneClick( event ); } void _wxFB_OnPadsInZoneClick( wxCommandEvent& event ){ OnPadsInZoneClick( event ); }
void _wxFB_ExportSetupToOtherCopperZones( wxCommandEvent& event ){ ExportSetupToOtherCopperZones( event ); } void _wxFB_ExportSetupToOtherCopperZones( wxCommandEvent& event ){ ExportSetupToOtherCopperZones( event ); }
void _wxFB_OnButtonOkClick( wxCommandEvent& event ){ OnButtonOkClick( event ); } void _wxFB_OnButtonOkClick( wxCommandEvent& event ){ OnButtonOkClick( event ); }
...@@ -87,7 +86,6 @@ class dialog_copper_zone_base : public wxDialog ...@@ -87,7 +86,6 @@ class dialog_copper_zone_base : public wxDialog
wxListBox* m_LayerSelectionCtrl; wxListBox* m_LayerSelectionCtrl;
// Virtual event handlers, overide them in your derived class // Virtual event handlers, overide them in your derived class
virtual void OnInitDialog( wxInitDialogEvent& event ){ event.Skip(); }
virtual void OnPadsInZoneClick( wxCommandEvent& event ){ event.Skip(); } virtual void OnPadsInZoneClick( wxCommandEvent& event ){ event.Skip(); }
virtual void ExportSetupToOtherCopperZones( wxCommandEvent& event ){ event.Skip(); } virtual void ExportSetupToOtherCopperZones( wxCommandEvent& event ){ event.Skip(); }
virtual void OnButtonOkClick( wxCommandEvent& event ){ event.Skip(); } virtual void OnButtonOkClick( wxCommandEvent& event ){ event.Skip(); }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment