2018-03-28 17:14:04 +00:00
|
|
|
///////////////////////////////////////////////////////////////////////////
|
2020-07-24 19:17:58 +00:00
|
|
|
// C++ code generated with wxFormBuilder (version Oct 26 2018)
|
2018-03-28 17:14:04 +00:00
|
|
|
// http://www.wxformbuilder.org/
|
|
|
|
//
|
|
|
|
// PLEASE DO *NOT* EDIT THIS FILE!
|
|
|
|
///////////////////////////////////////////////////////////////////////////
|
|
|
|
|
2021-06-19 17:28:45 +00:00
|
|
|
#include "panel_preview_3d_model_base.h"
|
2018-03-28 17:14:04 +00:00
|
|
|
|
|
|
|
///////////////////////////////////////////////////////////////////////////
|
|
|
|
|
2021-06-19 17:28:45 +00:00
|
|
|
PANEL_PREVIEW_3D_MODEL_BASE::PANEL_PREVIEW_3D_MODEL_BASE( wxWindow* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, long style, const wxString& name ) : wxPanel( parent, id, pos, size, style, name )
|
2018-03-28 17:14:04 +00:00
|
|
|
{
|
|
|
|
wxBoxSizer* bSizermain;
|
|
|
|
bSizermain = new wxBoxSizer( wxHORIZONTAL );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxBoxSizer* bSizerLeft;
|
|
|
|
bSizerLeft = new wxBoxSizer( wxVERTICAL );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxStaticBoxSizer* sbSizerScale;
|
|
|
|
sbSizerScale = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Scale") ), wxVERTICAL );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxFlexGridSizer* fgSizerScale;
|
|
|
|
fgSizerScale = new wxFlexGridSizer( 0, 3, 0, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerScale->AddGrowableCol( 1 );
|
2018-03-28 17:14:04 +00:00
|
|
|
fgSizerScale->SetFlexibleDirection( wxBOTH );
|
|
|
|
fgSizerScale->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText1 = new wxStaticText( sbSizerScale->GetStaticBox(), wxID_ANY, _("X:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText1->Wrap( -1 );
|
|
|
|
fgSizerScale->Add( m_staticText1, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
xscale = new wxTextCtrl( sbSizerScale->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerScale->Add( xscale, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinXscale = new wxSpinButton( sbSizerScale->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
|
|
|
fgSizerScale->Add( m_spinXscale, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText2 = new wxStaticText( sbSizerScale->GetStaticBox(), wxID_ANY, _("Y:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText2->Wrap( -1 );
|
|
|
|
fgSizerScale->Add( m_staticText2, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
yscale = new wxTextCtrl( sbSizerScale->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerScale->Add( yscale, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinYscale = new wxSpinButton( sbSizerScale->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
|
|
|
fgSizerScale->Add( m_spinYscale, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText3 = new wxStaticText( sbSizerScale->GetStaticBox(), wxID_ANY, _("Z:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText3->Wrap( -1 );
|
2020-04-26 23:17:26 +00:00
|
|
|
fgSizerScale->Add( m_staticText3, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
zscale = new wxTextCtrl( sbSizerScale->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerScale->Add( zscale, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinZscale = new wxSpinButton( sbSizerScale->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
2020-04-26 23:17:26 +00:00
|
|
|
fgSizerScale->Add( m_spinZscale, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-05-03 15:44:46 +00:00
|
|
|
sbSizerScale->Add( fgSizerScale, 0, wxBOTTOM|wxEXPAND|wxRIGHT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-07-24 19:17:58 +00:00
|
|
|
bSizerLeft->Add( sbSizerScale, 0, wxLEFT|wxRIGHT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxStaticBoxSizer* sbSizerRotation;
|
|
|
|
sbSizerRotation = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Rotation") ), wxVERTICAL );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxFlexGridSizer* fgSizerRotate;
|
|
|
|
fgSizerRotate = new wxFlexGridSizer( 0, 3, 0, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerRotate->AddGrowableCol( 1 );
|
2018-03-28 17:14:04 +00:00
|
|
|
fgSizerRotate->SetFlexibleDirection( wxBOTH );
|
|
|
|
fgSizerRotate->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText11 = new wxStaticText( sbSizerRotation->GetStaticBox(), wxID_ANY, _("X:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText11->Wrap( -1 );
|
|
|
|
fgSizerRotate->Add( m_staticText11, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
xrot = new wxTextCtrl( sbSizerRotation->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerRotate->Add( xrot, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinXrot = new wxSpinButton( sbSizerRotation->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
|
|
|
fgSizerRotate->Add( m_spinXrot, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText21 = new wxStaticText( sbSizerRotation->GetStaticBox(), wxID_ANY, _("Y:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText21->Wrap( -1 );
|
|
|
|
fgSizerRotate->Add( m_staticText21, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
yrot = new wxTextCtrl( sbSizerRotation->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerRotate->Add( yrot, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinYrot = new wxSpinButton( sbSizerRotation->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
|
|
|
fgSizerRotate->Add( m_spinYrot, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText31 = new wxStaticText( sbSizerRotation->GetStaticBox(), wxID_ANY, _("Z:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText31->Wrap( -1 );
|
2020-04-26 23:17:26 +00:00
|
|
|
fgSizerRotate->Add( m_staticText31, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
zrot = new wxTextCtrl( sbSizerRotation->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerRotate->Add( zrot, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinZrot = new wxSpinButton( sbSizerRotation->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
2020-04-26 23:17:26 +00:00
|
|
|
fgSizerRotate->Add( m_spinZrot, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-07-24 19:17:58 +00:00
|
|
|
sbSizerRotation->Add( fgSizerRotate, 0, wxBOTTOM|wxRIGHT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-07-24 19:17:58 +00:00
|
|
|
bSizerLeft->Add( sbSizerRotation, 0, wxLEFT|wxRIGHT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxStaticBoxSizer* sbSizerOffset;
|
|
|
|
sbSizerOffset = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Offset") ), wxVERTICAL );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxFlexGridSizer* fgSizerOffset;
|
|
|
|
fgSizerOffset = new wxFlexGridSizer( 0, 3, 0, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerOffset->AddGrowableCol( 1 );
|
2018-03-28 17:14:04 +00:00
|
|
|
fgSizerOffset->SetFlexibleDirection( wxBOTH );
|
|
|
|
fgSizerOffset->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText12 = new wxStaticText( sbSizerOffset->GetStaticBox(), wxID_ANY, _("X:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText12->Wrap( -1 );
|
|
|
|
fgSizerOffset->Add( m_staticText12, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
xoff = new wxTextCtrl( sbSizerOffset->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerOffset->Add( xoff, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinXoffset = new wxSpinButton( sbSizerOffset->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
|
|
|
fgSizerOffset->Add( m_spinXoffset, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText22 = new wxStaticText( sbSizerOffset->GetStaticBox(), wxID_ANY, _("Y:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText22->Wrap( -1 );
|
|
|
|
fgSizerOffset->Add( m_staticText22, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
yoff = new wxTextCtrl( sbSizerOffset->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerOffset->Add( yoff, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinYoffset = new wxSpinButton( sbSizerOffset->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
|
|
|
fgSizerOffset->Add( m_spinYoffset, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_staticText32 = new wxStaticText( sbSizerOffset->GetStaticBox(), wxID_ANY, _("Z:"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
m_staticText32->Wrap( -1 );
|
2020-04-26 23:17:26 +00:00
|
|
|
fgSizerOffset->Add( m_staticText32, 0, wxALIGN_CENTER_VERTICAL|wxLEFT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
zoff = new wxTextCtrl( sbSizerOffset->GetStaticBox(), wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
|
2020-07-24 19:17:58 +00:00
|
|
|
fgSizerOffset->Add( zoff, 0, wxALIGN_CENTER_VERTICAL|wxLEFT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_spinZoffset = new wxSpinButton( sbSizerOffset->GetStaticBox(), wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSP_ARROW_KEYS|wxSP_VERTICAL );
|
2020-04-26 23:17:26 +00:00
|
|
|
fgSizerOffset->Add( m_spinZoffset, 0, wxALIGN_CENTER_VERTICAL, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-07-24 19:17:58 +00:00
|
|
|
sbSizerOffset->Add( fgSizerOffset, 0, wxBOTTOM|wxRIGHT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-07-24 19:17:58 +00:00
|
|
|
bSizerLeft->Add( sbSizerOffset, 0, wxLEFT|wxRIGHT|wxEXPAND, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
wxStaticBoxSizer* sbSizer4;
|
|
|
|
sbSizer4 = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Opacity") ), wxVERTICAL );
|
|
|
|
|
|
|
|
m_opacity = new wxSlider( sbSizer4->GetStaticBox(), wxID_ANY, 50, 0, 100, wxDefaultPosition, wxDefaultSize, wxSL_HORIZONTAL|wxSL_LABELS );
|
2020-07-24 19:17:58 +00:00
|
|
|
sbSizer4->Add( m_opacity, 0, wxEXPAND|wxBOTTOM, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizerLeft->Add( sbSizer4, 1, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
bSizermain->Add( bSizerLeft, 0, 0, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxBoxSizer* bSizerRight;
|
|
|
|
bSizerRight = new wxBoxSizer( wxVERTICAL );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxStaticText* staticPreviewLabel;
|
|
|
|
staticPreviewLabel = new wxStaticText( this, wxID_ANY, _("Preview"), wxDefaultPosition, wxDefaultSize, 0 );
|
|
|
|
staticPreviewLabel->Wrap( -1 );
|
|
|
|
staticPreviewLabel->SetFont( wxFont( 11, wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_NORMAL, false, wxEmptyString ) );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
bSizerRight->Add( staticPreviewLabel, 0, wxEXPAND|wxLEFT|wxRIGHT, 10 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
m_SizerPanelView = new wxBoxSizer( wxVERTICAL );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
bSizerRight->Add( m_SizerPanelView, 1, wxEXPAND|wxBOTTOM, 8 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizermain->Add( bSizerRight, 1, wxEXPAND|wxLEFT|wxRIGHT|wxTOP, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
wxBoxSizer* bSizer3DButtons;
|
|
|
|
bSizer3DButtons = new wxBoxSizer( wxVERTICAL );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizer3DButtons->Add( 0, 0, 0, wxEXPAND|wxTOP, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
m_bpvISO = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
|
2018-03-28 17:14:04 +00:00
|
|
|
m_bpvISO->SetToolTip( _("Change to isometric perspective") );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
bSizer3DButtons->Add( m_bpvISO, 0, wxTOP|wxBOTTOM, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
|
|
|
bSizer3DButtons->Add( 0, 0, 1, wxEXPAND, 5 );
|
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
m_bpvLeft = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizer3DButtons->Add( m_bpvLeft, 0, wxALIGN_LEFT|wxALIGN_RIGHT|wxBOTTOM, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
m_bpvRight = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizer3DButtons->Add( m_bpvRight, 0, wxBOTTOM, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
m_bpvFront = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizer3DButtons->Add( m_bpvFront, 0, wxBOTTOM, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
m_bpvBack = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizer3DButtons->Add( m_bpvBack, 0, wxBOTTOM, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
m_bpvTop = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizer3DButtons->Add( m_bpvTop, 0, wxBOTTOM, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
m_bpvBottom = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
|
2018-03-28 17:14:04 +00:00
|
|
|
bSizer3DButtons->Add( m_bpvBottom, 0, 0, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
|
|
|
bSizer3DButtons->Add( 0, 0, 1, wxEXPAND, 5 );
|
|
|
|
|
2020-06-03 17:46:50 +00:00
|
|
|
m_bpUpdate = new wxBitmapButton( this, wxID_ANY, wxNullBitmap, wxDefaultPosition, wxSize( -1,-1 ), wxBU_AUTODRAW|0 );
|
2018-03-28 17:14:04 +00:00
|
|
|
m_bpUpdate->SetToolTip( _("Reload board and 3D models") );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizer3DButtons->Add( m_bpUpdate, 0, wxBOTTOM, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2020-05-03 15:44:46 +00:00
|
|
|
bSizermain->Add( bSizer3DButtons, 0, wxBOTTOM|wxEXPAND|wxLEFT|wxRIGHT, 5 );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
this->SetSizer( bSizermain );
|
|
|
|
this->Layout();
|
|
|
|
bSizermain->Fit( this );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
// Connect Events
|
2021-06-19 17:28:45 +00:00
|
|
|
xscale->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelScale ), NULL, this );
|
|
|
|
xscale->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinXscale->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementScale ), NULL, this );
|
|
|
|
m_spinXscale->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementScale ), NULL, this );
|
|
|
|
yscale->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelScale ), NULL, this );
|
|
|
|
yscale->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinYscale->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementScale ), NULL, this );
|
|
|
|
m_spinYscale->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementScale ), NULL, this );
|
|
|
|
zscale->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelScale ), NULL, this );
|
|
|
|
zscale->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinZscale->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementScale ), NULL, this );
|
|
|
|
m_spinZscale->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementScale ), NULL, this );
|
|
|
|
xrot->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelRot ), NULL, this );
|
|
|
|
xrot->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinXrot->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementRot ), NULL, this );
|
|
|
|
m_spinXrot->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementRot ), NULL, this );
|
|
|
|
yrot->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelRot ), NULL, this );
|
|
|
|
yrot->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinYrot->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementRot ), NULL, this );
|
|
|
|
m_spinYrot->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementRot ), NULL, this );
|
|
|
|
zrot->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelRot ), NULL, this );
|
|
|
|
zrot->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinZrot->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementRot ), NULL, this );
|
|
|
|
m_spinZrot->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementRot ), NULL, this );
|
|
|
|
xoff->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelOffset ), NULL, this );
|
|
|
|
xoff->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinXoffset->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementOffset ), NULL, this );
|
|
|
|
m_spinXoffset->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementOffset ), NULL, this );
|
|
|
|
yoff->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelOffset ), NULL, this );
|
|
|
|
yoff->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinYoffset->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementOffset ), NULL, this );
|
|
|
|
m_spinYoffset->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementOffset ), NULL, this );
|
|
|
|
zoff->Connect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelOffset ), NULL, this );
|
|
|
|
zoff->Connect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinZoffset->Connect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementOffset ), NULL, this );
|
|
|
|
m_spinZoffset->Connect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementOffset ), NULL, this );
|
|
|
|
m_opacity->Connect( wxEVT_SLIDER, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onOpacitySlider ), NULL, this );
|
|
|
|
m_bpvISO->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DISO ), NULL, this );
|
|
|
|
m_bpvLeft->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DLeft ), NULL, this );
|
|
|
|
m_bpvRight->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DRight ), NULL, this );
|
|
|
|
m_bpvFront->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DFront ), NULL, this );
|
|
|
|
m_bpvBack->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DBack ), NULL, this );
|
|
|
|
m_bpvTop->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DTop ), NULL, this );
|
|
|
|
m_bpvBottom->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DBottom ), NULL, this );
|
|
|
|
m_bpUpdate->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DUpdate ), NULL, this );
|
2018-03-28 17:14:04 +00:00
|
|
|
}
|
|
|
|
|
2021-06-19 17:28:45 +00:00
|
|
|
PANEL_PREVIEW_3D_MODEL_BASE::~PANEL_PREVIEW_3D_MODEL_BASE()
|
2018-03-28 17:14:04 +00:00
|
|
|
{
|
|
|
|
// Disconnect Events
|
2021-06-19 17:28:45 +00:00
|
|
|
xscale->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelScale ), NULL, this );
|
|
|
|
xscale->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinXscale->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementScale ), NULL, this );
|
|
|
|
m_spinXscale->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementScale ), NULL, this );
|
|
|
|
yscale->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelScale ), NULL, this );
|
|
|
|
yscale->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinYscale->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementScale ), NULL, this );
|
|
|
|
m_spinYscale->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementScale ), NULL, this );
|
|
|
|
zscale->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelScale ), NULL, this );
|
|
|
|
zscale->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinZscale->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementScale ), NULL, this );
|
|
|
|
m_spinZscale->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementScale ), NULL, this );
|
|
|
|
xrot->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelRot ), NULL, this );
|
|
|
|
xrot->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinXrot->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementRot ), NULL, this );
|
|
|
|
m_spinXrot->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementRot ), NULL, this );
|
|
|
|
yrot->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelRot ), NULL, this );
|
|
|
|
yrot->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinYrot->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementRot ), NULL, this );
|
|
|
|
m_spinYrot->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementRot ), NULL, this );
|
|
|
|
zrot->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelRot ), NULL, this );
|
|
|
|
zrot->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinZrot->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementRot ), NULL, this );
|
|
|
|
m_spinZrot->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementRot ), NULL, this );
|
|
|
|
xoff->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelOffset ), NULL, this );
|
|
|
|
xoff->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinXoffset->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementOffset ), NULL, this );
|
|
|
|
m_spinXoffset->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementOffset ), NULL, this );
|
|
|
|
yoff->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelOffset ), NULL, this );
|
|
|
|
yoff->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinYoffset->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementOffset ), NULL, this );
|
|
|
|
m_spinYoffset->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementOffset ), NULL, this );
|
|
|
|
zoff->Disconnect( wxEVT_MOUSEWHEEL, wxMouseEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onMouseWheelOffset ), NULL, this );
|
|
|
|
zoff->Disconnect( wxEVT_COMMAND_TEXT_UPDATED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::updateOrientation ), NULL, this );
|
|
|
|
m_spinZoffset->Disconnect( wxEVT_SCROLL_LINEDOWN, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onDecrementOffset ), NULL, this );
|
|
|
|
m_spinZoffset->Disconnect( wxEVT_SCROLL_LINEUP, wxSpinEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onIncrementOffset ), NULL, this );
|
|
|
|
m_opacity->Disconnect( wxEVT_SLIDER, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::onOpacitySlider ), NULL, this );
|
|
|
|
m_bpvISO->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DISO ), NULL, this );
|
|
|
|
m_bpvLeft->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DLeft ), NULL, this );
|
|
|
|
m_bpvRight->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DRight ), NULL, this );
|
|
|
|
m_bpvFront->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DFront ), NULL, this );
|
|
|
|
m_bpvBack->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DBack ), NULL, this );
|
|
|
|
m_bpvTop->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DTop ), NULL, this );
|
|
|
|
m_bpvBottom->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DBottom ), NULL, this );
|
|
|
|
m_bpUpdate->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( PANEL_PREVIEW_3D_MODEL_BASE::View3DUpdate ), NULL, this );
|
2020-04-19 17:23:40 +00:00
|
|
|
|
2018-03-28 17:14:04 +00:00
|
|
|
}
|