2018-03-07 13:05:12 +00:00
|
|
|
///////////////////////////////////////////////////////////////////////////
|
2020-10-30 17:40:13 +00:00
|
|
|
// C++ code generated with wxFormBuilder (version 3.9.0 Jul 27 2020)
|
2018-03-07 13:05:12 +00:00
|
|
|
// http://www.wxformbuilder.org/
|
|
|
|
//
|
|
|
|
// PLEASE DO *NOT* EDIT THIS FILE!
|
|
|
|
///////////////////////////////////////////////////////////////////////////
|
|
|
|
|
2018-08-19 16:10:14 +00:00
|
|
|
#include "widgets/wx_grid.h"
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
#include "dialog_configure_paths_base.h"
|
|
|
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////
|
|
|
|
|
|
|
|
DIALOG_CONFIGURE_PATHS_BASE::DIALOG_CONFIGURE_PATHS_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( wxSize( -1,-1 ), wxDefaultSize );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
wxBoxSizer* bSizerMain;
|
|
|
|
bSizerMain = new wxBoxSizer( wxVERTICAL );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
wxStaticBoxSizer* sbEnvVars;
|
|
|
|
sbEnvVars = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Environment Variables") ), wxVERTICAL );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-08-19 16:10:14 +00:00
|
|
|
m_EnvVars = new WX_GRID( sbEnvVars->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Grid
|
|
|
|
m_EnvVars->CreateGrid( 1, 2 );
|
|
|
|
m_EnvVars->EnableEditing( true );
|
|
|
|
m_EnvVars->EnableGridLines( true );
|
|
|
|
m_EnvVars->EnableDragGridSize( false );
|
|
|
|
m_EnvVars->SetMargins( 0, 0 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Columns
|
|
|
|
m_EnvVars->SetColSize( 0, 150 );
|
|
|
|
m_EnvVars->SetColSize( 1, 454 );
|
|
|
|
m_EnvVars->EnableDragColMove( false );
|
|
|
|
m_EnvVars->EnableDragColSize( true );
|
|
|
|
m_EnvVars->SetColLabelSize( 22 );
|
|
|
|
m_EnvVars->SetColLabelValue( 0, _("Name") );
|
|
|
|
m_EnvVars->SetColLabelValue( 1, _("Path") );
|
2020-05-02 20:48:39 +00:00
|
|
|
m_EnvVars->SetColLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Rows
|
|
|
|
m_EnvVars->EnableDragRowSize( true );
|
|
|
|
m_EnvVars->SetRowLabelSize( 0 );
|
2020-05-02 20:48:39 +00:00
|
|
|
m_EnvVars->SetRowLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Label Appearance
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Cell Defaults
|
|
|
|
m_EnvVars->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_TOP );
|
2018-08-24 18:28:11 +00:00
|
|
|
m_EnvVars->SetMinSize( wxSize( 604,170 ) );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
sbEnvVars->Add( m_EnvVars, 1, wxALL|wxEXPAND, 5 );
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
wxBoxSizer* bSizerEnvVarBtns;
|
|
|
|
bSizerEnvVarBtns = new wxBoxSizer( wxHORIZONTAL );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
m_btnAddEnvVar = new wxBitmapButton( sbEnvVars->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
|
|
|
|
bSizerEnvVarBtns->Add( m_btnAddEnvVar, 0, wxBOTTOM|wxLEFT, 5 );
|
|
|
|
|
|
|
|
|
2018-08-19 16:05:48 +00:00
|
|
|
bSizerEnvVarBtns->Add( 0, 0, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
m_btnDeleteEnvVar = new wxBitmapButton( sbEnvVars->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
|
|
|
|
bSizerEnvVarBtns->Add( m_btnDeleteEnvVar, 0, wxBOTTOM, 5 );
|
|
|
|
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
sbEnvVars->Add( bSizerEnvVarBtns, 0, wxEXPAND, 5 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
bSizerMain->Add( sbEnvVars, 1, wxEXPAND|wxALL, 5 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
m_sb3DSearchPaths = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("3D Search Paths") ), wxVERTICAL );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-08-19 16:10:14 +00:00
|
|
|
m_SearchPaths = new WX_GRID( m_sb3DSearchPaths->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Grid
|
|
|
|
m_SearchPaths->CreateGrid( 1, 3 );
|
|
|
|
m_SearchPaths->EnableEditing( true );
|
|
|
|
m_SearchPaths->EnableGridLines( true );
|
|
|
|
m_SearchPaths->EnableDragGridSize( false );
|
|
|
|
m_SearchPaths->SetMargins( 0, 0 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Columns
|
|
|
|
m_SearchPaths->SetColSize( 0, 150 );
|
|
|
|
m_SearchPaths->SetColSize( 1, 300 );
|
|
|
|
m_SearchPaths->SetColSize( 2, 154 );
|
|
|
|
m_SearchPaths->EnableDragColMove( false );
|
|
|
|
m_SearchPaths->EnableDragColSize( true );
|
|
|
|
m_SearchPaths->SetColLabelSize( 22 );
|
|
|
|
m_SearchPaths->SetColLabelValue( 0, _("Alias") );
|
|
|
|
m_SearchPaths->SetColLabelValue( 1, _("Path") );
|
|
|
|
m_SearchPaths->SetColLabelValue( 2, _("Description") );
|
2020-05-02 20:48:39 +00:00
|
|
|
m_SearchPaths->SetColLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Rows
|
|
|
|
m_SearchPaths->AutoSizeRows();
|
|
|
|
m_SearchPaths->EnableDragRowSize( false );
|
|
|
|
m_SearchPaths->SetRowLabelSize( 0 );
|
2020-05-02 20:48:39 +00:00
|
|
|
m_SearchPaths->SetRowLabelAlignment( wxALIGN_CENTER, wxALIGN_CENTER );
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Label Appearance
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Cell Defaults
|
|
|
|
m_SearchPaths->SetDefaultCellAlignment( wxALIGN_LEFT, wxALIGN_TOP );
|
2018-07-17 21:14:02 +00:00
|
|
|
m_SearchPaths->SetMinSize( wxSize( 604,150 ) );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
m_sb3DSearchPaths->Add( m_SearchPaths, 1, wxALL|wxEXPAND, 5 );
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
wxBoxSizer* bSizerSearchPathBtns;
|
|
|
|
bSizerSearchPathBtns = new wxBoxSizer( wxHORIZONTAL );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
m_btnAddSearchPath = new wxBitmapButton( m_sb3DSearchPaths->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
|
|
|
|
bSizerSearchPathBtns->Add( m_btnAddSearchPath, 0, wxBOTTOM|wxLEFT|wxRIGHT, 5 );
|
|
|
|
|
|
|
|
m_btnMoveUp = new wxBitmapButton( m_sb3DSearchPaths->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
|
|
|
|
bSizerSearchPathBtns->Add( m_btnMoveUp, 0, wxBOTTOM|wxRIGHT, 5 );
|
|
|
|
|
|
|
|
m_btnMoveDown = new wxBitmapButton( m_sb3DSearchPaths->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
|
|
|
|
bSizerSearchPathBtns->Add( m_btnMoveDown, 0, wxBOTTOM|wxRIGHT, 5 );
|
|
|
|
|
|
|
|
|
2018-08-19 16:05:48 +00:00
|
|
|
bSizerSearchPathBtns->Add( 0, 0, 0, wxEXPAND|wxRIGHT|wxLEFT, 5 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
m_btnDeleteSearchPath = new wxBitmapButton( m_sb3DSearchPaths->GetStaticBox(), wxID_ANY, wxNullBitmap, wxDefaultPosition, wxDefaultSize, wxBU_AUTODRAW|0 );
|
|
|
|
bSizerSearchPathBtns->Add( m_btnDeleteSearchPath, 0, wxBOTTOM|wxRIGHT, 5 );
|
|
|
|
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
m_sb3DSearchPaths->Add( bSizerSearchPathBtns, 0, wxEXPAND, 5 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
bSizerMain->Add( m_sb3DSearchPaths, 1, wxEXPAND|wxTOP|wxRIGHT|wxLEFT, 5 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
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_sdbSizerHelp = new wxButton( this, wxID_HELP );
|
|
|
|
m_sdbSizer->AddButton( m_sdbSizerHelp );
|
|
|
|
m_sdbSizer->Realize();
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
bSizerMain->Add( m_sdbSizer, 0, wxALL|wxEXPAND, 5 );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
this->SetSizer( bSizerMain );
|
|
|
|
this->Layout();
|
|
|
|
bSizerMain->Fit( this );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
this->Centre( wxBOTH );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
// Connect Events
|
2018-09-12 13:00:32 +00:00
|
|
|
this->Connect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnUpdateUI ) );
|
2018-03-07 13:05:12 +00:00
|
|
|
m_EnvVars->Connect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnGridSize ), NULL, this );
|
|
|
|
m_btnAddEnvVar->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnAddEnvVar ), NULL, this );
|
|
|
|
m_btnDeleteEnvVar->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnRemoveEnvVar ), NULL, this );
|
2018-07-20 17:46:56 +00:00
|
|
|
m_SearchPaths->Connect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnGridCellChange ), NULL, this );
|
2018-03-07 13:05:12 +00:00
|
|
|
m_SearchPaths->Connect( wxEVT_GRID_CELL_RIGHT_CLICK, wxGridEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnGridCellRightClick ), NULL, this );
|
|
|
|
m_btnAddSearchPath->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnAddSearchPath ), NULL, this );
|
|
|
|
m_btnMoveUp->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnSearchPathMoveUp ), NULL, this );
|
|
|
|
m_btnMoveDown->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnSearchPathMoveDown ), NULL, this );
|
2018-08-19 16:05:48 +00:00
|
|
|
m_btnDeleteSearchPath->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnDeleteSearchPath ), NULL, this );
|
2018-03-07 13:05:12 +00:00
|
|
|
m_sdbSizerHelp->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnHelp ), NULL, this );
|
|
|
|
}
|
|
|
|
|
|
|
|
DIALOG_CONFIGURE_PATHS_BASE::~DIALOG_CONFIGURE_PATHS_BASE()
|
|
|
|
{
|
|
|
|
// Disconnect Events
|
2018-09-12 13:00:32 +00:00
|
|
|
this->Disconnect( wxEVT_UPDATE_UI, wxUpdateUIEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnUpdateUI ) );
|
2018-03-07 13:05:12 +00:00
|
|
|
m_EnvVars->Disconnect( wxEVT_SIZE, wxSizeEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnGridSize ), NULL, this );
|
|
|
|
m_btnAddEnvVar->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnAddEnvVar ), NULL, this );
|
|
|
|
m_btnDeleteEnvVar->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnRemoveEnvVar ), NULL, this );
|
2018-07-20 17:46:56 +00:00
|
|
|
m_SearchPaths->Disconnect( wxEVT_GRID_CELL_CHANGED, wxGridEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnGridCellChange ), NULL, this );
|
2018-03-07 13:05:12 +00:00
|
|
|
m_SearchPaths->Disconnect( wxEVT_GRID_CELL_RIGHT_CLICK, wxGridEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnGridCellRightClick ), NULL, this );
|
|
|
|
m_btnAddSearchPath->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnAddSearchPath ), NULL, this );
|
|
|
|
m_btnMoveUp->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnSearchPathMoveUp ), NULL, this );
|
|
|
|
m_btnMoveDown->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnSearchPathMoveDown ), NULL, this );
|
2018-08-19 16:05:48 +00:00
|
|
|
m_btnDeleteSearchPath->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnDeleteSearchPath ), NULL, this );
|
2018-03-07 13:05:12 +00:00
|
|
|
m_sdbSizerHelp->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_CONFIGURE_PATHS_BASE::OnHelp ), NULL, this );
|
2020-05-02 20:48:39 +00:00
|
|
|
|
2018-03-07 13:05:12 +00:00
|
|
|
}
|