From bc07c7da113c35fe6b0d04b5e1b808ecab17fabc Mon Sep 17 00:00:00 2001 From: Jeff Young Date: Fri, 9 Aug 2019 16:01:45 +0100 Subject: [PATCH] Use wxChoice instead of wxComboBox so we get menu highlighting. --- pcbnew/dialogs/dialog_set_grid.cpp | 14 +- pcbnew/dialogs/dialog_set_grid_base.cpp | 128 +++--- pcbnew/dialogs/dialog_set_grid_base.fbp | 579 ++++++++++++++++++++++-- pcbnew/dialogs/dialog_set_grid_base.h | 29 +- 4 files changed, 625 insertions(+), 125 deletions(-) diff --git a/pcbnew/dialogs/dialog_set_grid.cpp b/pcbnew/dialogs/dialog_set_grid.cpp index 5395639eae..122d69fd30 100644 --- a/pcbnew/dialogs/dialog_set_grid.cpp +++ b/pcbnew/dialogs/dialog_set_grid.cpp @@ -26,8 +26,6 @@ #include #include #include -#include -#include #include #include #include @@ -69,8 +67,8 @@ DIALOG_SET_GRID::DIALOG_SET_GRID( PCB_BASE_FRAME* aParent, const wxArrayString& m_userGridX( aParent, m_staticTextSizeX, m_OptGridSizeX, m_TextSizeXUnits ), m_userGridY( aParent, m_staticTextSizeY, m_OptGridSizeY, m_TextSizeYUnits ) { - m_comboBoxGrid1->Append( m_fast_grid_opts ); - m_comboBoxGrid2->Append( m_fast_grid_opts ); + m_grid1Ctrl->Append( m_fast_grid_opts ); + m_grid2Ctrl->Append( m_fast_grid_opts ); m_sdbSizerOK->SetDefault(); // set OK button as default response to 'Enter' key SetInitialFocus( m_GridOriginXCtrl ); @@ -97,8 +95,8 @@ bool DIALOG_SET_GRID::TransferDataFromWindow() m_parent->OnModify(); m_parent->SetGridOrigin( wxPoint( m_gridOriginX.GetValue(), m_gridOriginY.GetValue() ) ); m_parent->m_UserGridSize = wxPoint( m_userGridX.GetValue(), m_userGridY.GetValue() ); - m_parent->m_FastGrid1 = m_comboBoxGrid1->GetSelection(); - m_parent->m_FastGrid2 = m_comboBoxGrid2->GetSelection(); + m_parent->m_FastGrid1 = m_grid1Ctrl->GetSelection(); + m_parent->m_FastGrid2 = m_grid2Ctrl->GetSelection(); // User grid BASE_SCREEN* screen = m_parent->GetScreen(); @@ -128,8 +126,8 @@ bool DIALOG_SET_GRID::TransferDataToWindow() m_gridOriginX.SetValue( m_parent->GetGridOrigin().x ); m_gridOriginY.SetValue( m_parent->GetGridOrigin().y ); - m_comboBoxGrid1->SetSelection( m_parent->m_FastGrid1 ); - m_comboBoxGrid2->SetSelection( m_parent->m_FastGrid2 ); + m_grid1Ctrl->SetSelection( m_parent->m_FastGrid1 ); + m_grid2Ctrl->SetSelection( m_parent->m_FastGrid2 ); int hk1 = ACTIONS::gridFast1.GetHotKey(); int hk2 = ACTIONS::gridFast2.GetHotKey(); diff --git a/pcbnew/dialogs/dialog_set_grid_base.cpp b/pcbnew/dialogs/dialog_set_grid_base.cpp index 283402eac8..0f6442f139 100644 --- a/pcbnew/dialogs/dialog_set_grid_base.cpp +++ b/pcbnew/dialogs/dialog_set_grid_base.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Dec 1 2018) +// C++ code generated with wxFormBuilder (version Dec 30 2017) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! @@ -12,160 +12,164 @@ DIALOG_SET_GRID_BASE::DIALOG_SET_GRID_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style ) { this->SetSizeHints( wxDefaultSize, wxDefaultSize ); - + wxBoxSizer* bSizerMain; bSizerMain = new wxBoxSizer( wxVERTICAL ); - + wxBoxSizer* bUpperSizer; bUpperSizer = new wxBoxSizer( wxHORIZONTAL ); - + wxStaticBoxSizer* sbLeftSizer; sbLeftSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Grid Origin") ), wxVERTICAL ); - + wxFlexGridSizer* fgSizerGridOrigin; fgSizerGridOrigin = new wxFlexGridSizer( 2, 3, 0, 0 ); fgSizerGridOrigin->AddGrowableCol( 1 ); fgSizerGridOrigin->SetFlexibleDirection( wxBOTH ); fgSizerGridOrigin->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); - + m_staticTextGridPosX = new wxStaticText( sbLeftSizer->GetStaticBox(), wxID_ANY, _("X:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextGridPosX->Wrap( -1 ); fgSizerGridOrigin->Add( m_staticTextGridPosX, 0, wxALIGN_CENTER_VERTICAL, 5 ); - + m_GridOriginXCtrl = new wxTextCtrl( sbLeftSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); fgSizerGridOrigin->Add( m_GridOriginXCtrl, 0, wxEXPAND|wxLEFT, 5 ); - + m_TextPosXUnits = new wxStaticText( sbLeftSizer->GetStaticBox(), wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 ); m_TextPosXUnits->Wrap( -1 ); fgSizerGridOrigin->Add( m_TextPosXUnits, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_LEFT, 5 ); - + m_staticTextGridPosY = new wxStaticText( sbLeftSizer->GetStaticBox(), wxID_ANY, _("Y:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextGridPosY->Wrap( -1 ); fgSizerGridOrigin->Add( m_staticTextGridPosY, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5 ); - + m_GridOriginYCtrl = new wxTextCtrl( sbLeftSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); fgSizerGridOrigin->Add( m_GridOriginYCtrl, 0, wxEXPAND|wxTOP|wxBOTTOM|wxLEFT, 5 ); - + m_TextPosYUnits = new wxStaticText( sbLeftSizer->GetStaticBox(), wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 ); m_TextPosYUnits->Wrap( -1 ); fgSizerGridOrigin->Add( m_TextPosYUnits, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_LEFT, 5 ); - - + + sbLeftSizer->Add( fgSizerGridOrigin, 0, wxEXPAND|wxALL, 5 ); - - + + bUpperSizer->Add( sbLeftSizer, 1, wxEXPAND|wxALL, 5 ); - + wxStaticBoxSizer* sbUserGridSizer; sbUserGridSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("User Defined Grid") ), wxVERTICAL ); - + wxFlexGridSizer* fgSizer31; fgSizer31 = new wxFlexGridSizer( 2, 3, 0, 0 ); fgSizer31->AddGrowableCol( 1 ); fgSizer31->SetFlexibleDirection( wxBOTH ); fgSizer31->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); - + m_staticTextSizeX = new wxStaticText( sbUserGridSizer->GetStaticBox(), wxID_ANY, _("Size X:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextSizeX->Wrap( -1 ); fgSizer31->Add( m_staticTextSizeX, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxRIGHT, 5 ); - + m_OptGridSizeX = new wxTextCtrl( sbUserGridSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); fgSizer31->Add( m_OptGridSizeX, 0, wxEXPAND|wxBOTTOM|wxLEFT, 5 ); - + m_TextSizeXUnits = new wxStaticText( sbUserGridSizer->GetStaticBox(), wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 ); m_TextSizeXUnits->Wrap( -1 ); fgSizer31->Add( m_TextSizeXUnits, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM, 5 ); - + m_staticTextSizeY = new wxStaticText( sbUserGridSizer->GetStaticBox(), wxID_ANY, _("Size Y:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextSizeY->Wrap( -1 ); fgSizer31->Add( m_staticTextSizeY, 0, wxALIGN_CENTER_VERTICAL|wxRIGHT, 5 ); - + m_OptGridSizeY = new wxTextCtrl( sbUserGridSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); fgSizer31->Add( m_OptGridSizeY, 0, wxEXPAND|wxLEFT, 5 ); - + m_TextSizeYUnits = new wxStaticText( sbUserGridSizer->GetStaticBox(), wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 ); m_TextSizeYUnits->Wrap( -1 ); fgSizer31->Add( m_TextSizeYUnits, 0, wxALIGN_CENTER_VERTICAL, 5 ); - - + + sbUserGridSizer->Add( fgSizer31, 0, wxEXPAND|wxALL, 5 ); - - + + bUpperSizer->Add( sbUserGridSizer, 1, wxEXPAND|wxTOP|wxBOTTOM|wxLEFT, 5 ); - - + + bSizerMain->Add( bUpperSizer, 0, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 ); - + wxStaticBoxSizer* sbFastSwitchSizer; sbFastSwitchSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Fast Switching") ), wxVERTICAL ); - + wxFlexGridSizer* fgSizer3; fgSizer3 = new wxFlexGridSizer( 2, 3, 0, 5 ); fgSizer3->AddGrowableCol( 1 ); fgSizer3->SetFlexibleDirection( wxBOTH ); fgSizer3->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED ); - + m_staticTextGrid1 = new wxStaticText( sbFastSwitchSizer->GetStaticBox(), wxID_ANY, _("Grid 1:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextGrid1->Wrap( -1 ); fgSizer3->Add( m_staticTextGrid1, 0, wxALIGN_CENTER_VERTICAL, 5 ); - - m_comboBoxGrid1 = new wxComboBox( sbFastSwitchSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, wxCB_READONLY ); - m_comboBoxGrid1->SetMinSize( wxSize( 240,-1 ) ); - - fgSizer3->Add( m_comboBoxGrid1, 0, wxEXPAND, 5 ); - + + wxArrayString m_grid1CtrlChoices; + m_grid1Ctrl = new wxChoice( sbFastSwitchSizer->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_grid1CtrlChoices, 0 ); + m_grid1Ctrl->SetSelection( 0 ); + m_grid1Ctrl->SetMinSize( wxSize( 240,-1 ) ); + + fgSizer3->Add( m_grid1Ctrl, 1, wxALL, 5 ); + m_grid1HotKey = new wxStaticText( sbFastSwitchSizer->GetStaticBox(), wxID_ANY, _("(hotkey)"), wxDefaultPosition, wxDefaultSize, 0 ); m_grid1HotKey->Wrap( -1 ); fgSizer3->Add( m_grid1HotKey, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - + m_staticTextGrid2 = new wxStaticText( sbFastSwitchSizer->GetStaticBox(), wxID_ANY, _("Grid 2:"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextGrid2->Wrap( -1 ); fgSizer3->Add( m_staticTextGrid2, 0, wxALIGN_CENTER_VERTICAL|wxALIGN_RIGHT, 5 ); - - m_comboBoxGrid2 = new wxComboBox( sbFastSwitchSizer->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0, NULL, wxCB_READONLY ); - m_comboBoxGrid2->SetMinSize( wxSize( 240,-1 ) ); - - fgSizer3->Add( m_comboBoxGrid2, 0, wxEXPAND|wxTOP|wxBOTTOM, 5 ); - + + wxArrayString m_grid2CtrlChoices; + m_grid2Ctrl = new wxChoice( sbFastSwitchSizer->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, m_grid2CtrlChoices, 0 ); + m_grid2Ctrl->SetSelection( 0 ); + m_grid2Ctrl->SetMinSize( wxSize( 240,-1 ) ); + + fgSizer3->Add( m_grid2Ctrl, 1, wxALL, 5 ); + m_grid2HotKey = new wxStaticText( sbFastSwitchSizer->GetStaticBox(), wxID_ANY, _("(hotkey)"), wxDefaultPosition, wxDefaultSize, 0 ); m_grid2HotKey->Wrap( -1 ); fgSizer3->Add( m_grid2HotKey, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - + + sbFastSwitchSizer->Add( fgSizer3, 0, wxEXPAND|wxTOP|wxBOTTOM|wxLEFT, 5 ); - - + + bSizerMain->Add( sbFastSwitchSizer, 0, wxEXPAND|wxALL, 10 ); - + m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); bSizerMain->Add( m_staticline1, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 ); - + wxBoxSizer* bButtonSizer; bButtonSizer = new wxBoxSizer( wxHORIZONTAL ); - + m_buttonReset = new wxButton( this, wxID_ANY, _("Reset Grid Origin"), wxDefaultPosition, wxDefaultSize, 0 ); bButtonSizer->Add( m_buttonReset, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5 ); - - + + bButtonSizer->Add( 0, 0, 1, wxEXPAND, 5 ); - + m_sdbSizer = new wxStdDialogButtonSizer(); m_sdbSizerOK = new wxButton( this, wxID_OK ); m_sdbSizer->AddButton( m_sdbSizerOK ); m_sdbSizerCancel = new wxButton( this, wxID_CANCEL ); m_sdbSizer->AddButton( m_sdbSizerCancel ); m_sdbSizer->Realize(); - + bButtonSizer->Add( m_sdbSizer, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 ); - - + + bSizerMain->Add( bButtonSizer, 0, wxEXPAND|wxLEFT, 10 ); - - + + this->SetSizer( bSizerMain ); this->Layout(); bSizerMain->Fit( this ); - + // Connect Events this->Connect( wxEVT_INIT_DIALOG, wxInitDialogEventHandler( DIALOG_SET_GRID_BASE::OnInitDlg ) ); m_buttonReset->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SET_GRID_BASE::OnResetGridOrgClick ), NULL, this ); @@ -180,5 +184,5 @@ DIALOG_SET_GRID_BASE::~DIALOG_SET_GRID_BASE() m_buttonReset->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SET_GRID_BASE::OnResetGridOrgClick ), NULL, this ); m_sdbSizerCancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SET_GRID_BASE::OnCancelClick ), NULL, this ); m_sdbSizerOK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SET_GRID_BASE::OnOkClick ), NULL, this ); - + } diff --git a/pcbnew/dialogs/dialog_set_grid_base.fbp b/pcbnew/dialogs/dialog_set_grid_base.fbp index dab3774fa5..251c8a6ba5 100644 --- a/pcbnew/dialogs/dialog_set_grid_base.fbp +++ b/pcbnew/dialogs/dialog_set_grid_base.fbp @@ -1,6 +1,6 @@ - + C++ @@ -14,7 +14,6 @@ dialog_set_grid_base 1000 none - 1 dialog_set_grid @@ -53,7 +52,42 @@ + + + + + + + + + + + + + + + OnInitDlg + + + + + + + + + + + + + + + + + + + + bSizerMain @@ -80,6 +114,7 @@ wxVERTICAL 1 none + 5 wxEXPAND|wxALL @@ -129,7 +164,6 @@ 0 wxID_ANY X: - 0 0 @@ -155,6 +189,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -219,6 +276,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -254,7 +338,6 @@ 0 wxID_ANY mm - 0 0 @@ -280,6 +363,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -315,7 +421,6 @@ 0 wxID_ANY Y: - 0 0 @@ -341,6 +446,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -405,6 +533,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -440,7 +595,6 @@ 0 wxID_ANY mm - 0 0 @@ -466,6 +620,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -484,6 +661,7 @@ wxVERTICAL 1 none + 5 wxEXPAND|wxALL @@ -533,7 +711,6 @@ 0 wxID_ANY Size X: - 0 0 @@ -559,6 +736,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -623,6 +823,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -658,7 +885,6 @@ 0 wxID_ANY mm - 0 0 @@ -684,6 +910,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -719,7 +968,6 @@ 0 wxID_ANY Size Y: - 0 0 @@ -745,6 +993,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -809,6 +1080,33 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -844,7 +1142,6 @@ 0 wxID_ANY mm - 0 0 @@ -870,6 +1167,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -890,6 +1210,7 @@ wxVERTICAL 1 none + 5 wxEXPAND|wxTOP|wxBOTTOM|wxLEFT @@ -939,7 +1260,6 @@ 0 wxID_ANY Grid 1: - 0 0 @@ -965,13 +1285,36 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxEXPAND - 0 - + wxALL + 1 + 1 1 1 @@ -1007,7 +1350,7 @@ 0 240,-1 1 - m_comboBoxGrid1 + m_grid1Ctrl 1 @@ -1015,21 +1358,44 @@ 1 Resizable - -1 + 0 1 - wxCB_READONLY - + + ; forward_declare 0 wxFILTER_NONE wxDefaultValidator - + + + + + + + + + + + + + + + + + + + + + + + + @@ -1065,7 +1431,6 @@ 0 wxID_ANY (hotkey) - 0 0 @@ -1091,6 +1456,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -1126,7 +1514,6 @@ 0 wxID_ANY Grid 2: - 0 0 @@ -1152,13 +1539,36 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + - + 5 - wxEXPAND|wxTOP|wxBOTTOM - 0 - + wxALL + 1 + 1 1 1 @@ -1194,7 +1604,7 @@ 0 240,-1 1 - m_comboBoxGrid2 + m_grid2Ctrl 1 @@ -1202,21 +1612,44 @@ 1 Resizable - -1 + 0 1 - wxCB_READONLY - + + ; forward_declare 0 wxFILTER_NONE wxDefaultValidator - + + + + + + + + + + + + + + + + + + + + + + + + @@ -1252,7 +1685,6 @@ 0 wxID_ANY (hotkey) - 0 0 @@ -1278,6 +1710,29 @@ -1 + + + + + + + + + + + + + + + + + + + + + + + @@ -1340,6 +1795,29 @@ + + + + + + + + + + + + + + + + + + + + + + + @@ -1366,31 +1844,25 @@ - 1 0 1 1 - 0 0 - Dock 0 Left 1 1 - 0 0 wxID_ANY Reset Grid Origin - - 0 0 @@ -1405,8 +1877,6 @@ protected 1 - - Resizable 1 @@ -1422,6 +1892,29 @@ OnResetGridOrgClick + + + + + + + + + + + + + + + + + + + + + + + @@ -1450,8 +1943,14 @@ m_sdbSizer protected + OnCancelClick + + + OnOkClick + + diff --git a/pcbnew/dialogs/dialog_set_grid_base.h b/pcbnew/dialogs/dialog_set_grid_base.h index af743cc3c4..b561415b11 100644 --- a/pcbnew/dialogs/dialog_set_grid_base.h +++ b/pcbnew/dialogs/dialog_set_grid_base.h @@ -1,11 +1,12 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Dec 1 2018) +// C++ code generated with wxFormBuilder (version Dec 30 2017) // http://www.wxformbuilder.org/ // // PLEASE DO *NOT* EDIT THIS FILE! /////////////////////////////////////////////////////////////////////////// -#pragma once +#ifndef __DIALOG_SET_GRID_BASE_H__ +#define __DIALOG_SET_GRID_BASE_H__ #include #include @@ -20,11 +21,8 @@ #include #include #include -#include +#include #include -#include -#include -#include #include #include @@ -37,7 +35,7 @@ class DIALOG_SET_GRID_BASE : public DIALOG_SHIM { private: - + protected: wxStaticText* m_staticTextGridPosX; wxTextCtrl* m_GridOriginXCtrl; @@ -52,28 +50,29 @@ class DIALOG_SET_GRID_BASE : public DIALOG_SHIM wxTextCtrl* m_OptGridSizeY; wxStaticText* m_TextSizeYUnits; wxStaticText* m_staticTextGrid1; - wxComboBox* m_comboBoxGrid1; + wxChoice* m_grid1Ctrl; wxStaticText* m_grid1HotKey; wxStaticText* m_staticTextGrid2; - wxComboBox* m_comboBoxGrid2; + wxChoice* m_grid2Ctrl; wxStaticText* m_grid2HotKey; wxStaticLine* m_staticline1; wxButton* m_buttonReset; wxStdDialogButtonSizer* m_sdbSizer; wxButton* m_sdbSizerOK; wxButton* m_sdbSizerCancel; - + // Virtual event handlers, overide them in your derived class virtual void OnInitDlg( wxInitDialogEvent& event ) { event.Skip(); } virtual void OnResetGridOrgClick( wxCommandEvent& event ) { event.Skip(); } virtual void OnCancelClick( wxCommandEvent& event ) { event.Skip(); } virtual void OnOkClick( wxCommandEvent& event ) { event.Skip(); } - - + + public: - - DIALOG_SET_GRID_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Grid Settings"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); + + DIALOG_SET_GRID_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Grid Settings"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); ~DIALOG_SET_GRID_BASE(); - + }; +#endif //__DIALOG_SET_GRID_BASE_H__