KiCad PCB EDA Suite
Loading...
Searching...
No Matches
dialog_select_3d_model_base.cpp
Go to the documentation of this file.
1
2// C++ code generated with wxFormBuilder (version 4.2.1-0-g80c4cb6)
3// http://www.wxformbuilder.org/
4//
5// PLEASE DO *NOT* EDIT THIS FILE!
7
9
11
12DIALOG_SELECT_3D_MODEL_BASE::DIALOG_SELECT_3D_MODEL_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : DIALOG_SHIM( parent, id, title, pos, size, style )
13{
14 this->SetSizeHints( wxDefaultSize, wxDefaultSize );
15
16 wxBoxSizer* bSizerMain;
17 bSizerMain = new wxBoxSizer( wxVERTICAL );
18
19 wxBoxSizer* bSizerUpper;
20 bSizerUpper = new wxBoxSizer( wxHORIZONTAL );
21
22 bSizerUpper->SetMinSize( wxSize( -1,400 ) );
23 m_splitterWin = new wxSplitterWindow( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_3D );
24 m_splitterWin->SetSashGravity( 0.35 );
25 m_splitterWin->Connect( wxEVT_IDLE, wxIdleEventHandler( DIALOG_SELECT_3D_MODEL_BASE::m_splitterWinOnIdle ), NULL, this );
26
27 m_panelLeft = new wxPanel( m_splitterWin, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
28 wxBoxSizer* bSizerLeft;
29 bSizerLeft = new wxBoxSizer( wxVERTICAL );
30
31 m_FileTree = new wxGenericDirCtrl( m_panelLeft, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, wxDIRCTRL_3D_INTERNAL|wxDIRCTRL_EDIT_LABELS|wxDIRCTRL_SHOW_FILTERS|wxBORDER_DEFAULT, wxEmptyString, 0 );
32
33 m_FileTree->ShowHidden( false );
34 m_FileTree->SetMinSize( wxSize( 300,-1 ) );
35
36 bSizerLeft->Add( m_FileTree, 1, wxALL|wxEXPAND, 5 );
37
38 wxBoxSizer* bSizer7;
39 bSizer7 = new wxBoxSizer( wxHORIZONTAL );
40
41
42 bSizerLeft->Add( bSizer7, 0, wxEXPAND, 5 );
43
44
45 m_panelLeft->SetSizer( bSizerLeft );
46 m_panelLeft->Layout();
47 bSizerLeft->Fit( m_panelLeft );
48 m_pane3Dviewer = new wxPanel( m_splitterWin, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL );
49 m_Sizer3Dviewer = new wxBoxSizer( wxVERTICAL );
50
51
53 m_pane3Dviewer->Layout();
55 m_splitterWin->SplitVertically( m_panelLeft, m_pane3Dviewer, 300 );
56 bSizerUpper->Add( m_splitterWin, 1, wxEXPAND, 5 );
57
58
59 bSizerMain->Add( bSizerUpper, 1, wxEXPAND, 5 );
60
61 wxBoxSizer* bSizerLower;
62 bSizerLower = new wxBoxSizer( wxHORIZONTAL );
63
64 m_stDirChoice = new wxStaticText( this, wxID_ANY, _("Available paths:"), wxDefaultPosition, wxDefaultSize, 0 );
65 m_stDirChoice->Wrap( -1 );
66 bSizerLower->Add( m_stDirChoice, 0, wxALIGN_CENTER_VERTICAL|wxBOTTOM|wxLEFT|wxRIGHT|wxTOP, 5 );
67
68 wxArrayString m_dirChoicesChoices;
69 m_dirChoices = new wxChoice( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, m_dirChoicesChoices, 0 );
70 m_dirChoices->SetSelection( 0 );
71 bSizerLower->Add( m_dirChoices, 1, wxTOP|wxBOTTOM|wxRIGHT, 5 );
72
73 m_cfgPathsButt = new wxButton( this, wxID_ANY, _("Configure Paths"), wxDefaultPosition, wxDefaultSize, 0 );
74 bSizerLower->Add( m_cfgPathsButt, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
75
76
77 bSizerMain->Add( bSizerLower, 0, wxEXPAND, 5 );
78
79 wxBoxSizer* bSizer6;
80 bSizer6 = new wxBoxSizer( wxHORIZONTAL );
81
82 m_EmbedModelCb = new wxCheckBox( this, wxID_ANY, _("Embed Model"), wxDefaultPosition, wxDefaultSize, 0 );
83 bSizer6->Add( m_EmbedModelCb, 0, wxALL, 5 );
84
85
86 bSizer6->Add( 0, 0, 1, wxEXPAND, 5 );
87
88 m_sdbSizer = new wxStdDialogButtonSizer();
89 m_sdbSizerOK = new wxButton( this, wxID_OK );
90 m_sdbSizer->AddButton( m_sdbSizerOK );
91 m_sdbSizerCancel = new wxButton( this, wxID_CANCEL );
92 m_sdbSizer->AddButton( m_sdbSizerCancel );
93 m_sdbSizer->Realize();
94
95 bSizer6->Add( m_sdbSizer, 0, wxEXPAND|wxALL, 5 );
96
97
98 bSizerMain->Add( bSizer6, 0, wxEXPAND, 5 );
99
100
101 this->SetSizer( bSizerMain );
102 this->Layout();
103 bSizerMain->Fit( this );
104
105 this->Centre( wxBOTH );
106
107 // Connect Events
108 m_FileTree->Connect( wxEVT_DIRCTRL_FILEACTIVATED, wxCommandEventHandler( DIALOG_SELECT_3D_MODEL_BASE::OnFileActivated ), NULL, this );
109 m_FileTree->Connect( wxEVT_DIRCTRL_SELECTIONCHANGED, wxCommandEventHandler( DIALOG_SELECT_3D_MODEL_BASE::OnSelectionChanged ), NULL, this );
110 m_dirChoices->Connect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( DIALOG_SELECT_3D_MODEL_BASE::SetRootDir ), NULL, this );
111 m_cfgPathsButt->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_3D_MODEL_BASE::Cfg3DPaths ), NULL, this );
112}
113
115{
116 // Disconnect Events
117 m_FileTree->Disconnect( wxEVT_DIRCTRL_FILEACTIVATED, wxCommandEventHandler( DIALOG_SELECT_3D_MODEL_BASE::OnFileActivated ), NULL, this );
118 m_FileTree->Disconnect( wxEVT_DIRCTRL_SELECTIONCHANGED, wxCommandEventHandler( DIALOG_SELECT_3D_MODEL_BASE::OnSelectionChanged ), NULL, this );
119 m_dirChoices->Disconnect( wxEVT_COMMAND_CHOICE_SELECTED, wxCommandEventHandler( DIALOG_SELECT_3D_MODEL_BASE::SetRootDir ), NULL, this );
120 m_cfgPathsButt->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_SELECT_3D_MODEL_BASE::Cfg3DPaths ), NULL, this );
121
122}
virtual void OnFileActivated(wxCommandEvent &event)
virtual void SetRootDir(wxCommandEvent &event)
virtual void Cfg3DPaths(wxCommandEvent &event)
DIALOG_SELECT_3D_MODEL_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Select 3D Model"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
virtual void OnSelectionChanged(wxCommandEvent &event)
Dialog helper object to sit in the inheritance tree between wxDialog and any class written by wxFormB...
Definition: dialog_shim.h:88
#define _(s)