KiCad PCB EDA Suite
dialog_edit_module_for_BoardEditor.cpp File Reference
#include <fctsys.h>
#include <kiface_i.h>
#include <gr_basic.h>
#include <class_drawpanel.h>
#include <confirm.h>
#include <pcbnew.h>
#include <pgm_base.h>
#include <gestfich.h>
#include <3d_viewer.h>
#include <wxPcbStruct.h>
#include <base_units.h>
#include <project.h>
#include <board_commit.h>
#include <bitmaps.h>
#include <class_module.h>
#include <class_text_mod.h>
#include <validators.h>
#include <dialog_edit_module_for_BoardEditor.h>
#include <wildcards_and_files_ext.h>
#include "3d_cache/dialogs/panel_prev_model.h"
#include "3d_cache/dialogs/3d_cache_dialogs.h"
#include "3d_cache/3d_cache.h"
#include "3d_cache/3d_filename_resolver.h"

Go to the source code of this file.

Functions

 wxBEGIN_EVENT_TABLE (DIALOG_MODULE_BOARD_EDITOR, wxDialog) wxEND_EVENT_TABLE() DIALOG_MODULE_BOARD_EDITOR
 

Function Documentation

wxBEGIN_EVENT_TABLE ( DIALOG_MODULE_BOARD_EDITOR  ,
wxDialog   
)

Definition at line 60 of file dialog_edit_module_for_BoardEditor.cpp.

References KiBitmap(), and Pgm().

66  :
68  m_OrientValidator( 1, &m_OrientValue )
69 {
70  wxASSERT( aParent != NULL );
71  wxASSERT( aModule != NULL );
72 
73  m_Parent = aParent;
74  m_DC = aDC;
75  m_CurrentModule = aModule;
76 
77  m_currentModuleCopy = new MODULE( *aModule );
78 
79  // Give an icon
80  wxIcon icon;
81  icon.CopyFromBitmap( KiBitmap( icon_modedit_xpm ) );
82  SetIcon( icon );
83 
84  m_OrientValidator.SetRange( -360.0, 360.0 );
85  m_OrientValueCtrl->SetValidator( m_OrientValidator );
86  m_OrientValidator.SetWindow( m_OrientValueCtrl );
87 
88  aParent->Prj().Get3DCacheManager()->GetResolver()->SetProgramBase( &Pgm() );
89 
90  m_PreviewPane = new PANEL_PREV_3D( m_Panel3D,
91  aParent->Prj().Get3DCacheManager(),
92  m_currentModuleCopy,
93  &m_shapes3D_list );
94 
95  bLowerSizer3D->Add( m_PreviewPane, 1, wxEXPAND, 5 );
96 
97  m_NoteBook->SetSelection( m_page );
98  m_sdbSizerStdButtonsOK->SetDefault();
99 
100  m_ReferenceCopy = NULL;
101  m_ValueCopy = NULL;
102  m_LastSelected3DShapeIndex = 0;
103  m_OrientValue = 0;
104 
105  Layout();
106 
107 }
PGM_BASE & Pgm()
The global Program "get" accessor.
Definition: kicad.cpp:65
Class DIALOG_MODULE_BOARD_EDITOR_BASE.
wxBitmap KiBitmap(BITMAP_DEF aBitmap)
Function KiBitmap constructs a wxBitmap from a memory record, held in a BITMAP_DEF.
Definition: bitmap.cpp:36