Minor build and compiler warning fixes.
* Fix build errors for ambiguous wxDialog constructor using gcc 3.4.5 on MinGW/MSYS. * Fix compiler warnings in VRML export.
This commit is contained in:
parent
492c75bd90
commit
80bc0ad65a
|
@ -19,7 +19,7 @@
|
|||
|
||||
#include "dialog_copper_zones.h"
|
||||
|
||||
wxString dialog_copper_zone::m_netNameShowFilter("*"); /* the filter to show nets (default * "*").
|
||||
wxString dialog_copper_zone::m_netNameShowFilter( wxT( "*" ) ); /* the filter to show nets (default * "*").
|
||||
* static to keep this pattern for an entire pcbnew session
|
||||
*/
|
||||
|
||||
|
|
|
@ -67,15 +67,15 @@ private:
|
|||
};
|
||||
|
||||
BEGIN_EVENT_TABLE( DIMENSION_EDITOR_DIALOG, wxDialog )
|
||||
EVT_BUTTON( wxID_OK, DIMENSION_EDITOR_DIALOG::OnOkClick )
|
||||
EVT_BUTTON( wxID_CANCEL, DIMENSION_EDITOR_DIALOG::OnCancelClick )
|
||||
EVT_BUTTON( wxID_OK, DIMENSION_EDITOR_DIALOG::OnOkClick )
|
||||
EVT_BUTTON( wxID_CANCEL, DIMENSION_EDITOR_DIALOG::OnCancelClick )
|
||||
END_EVENT_TABLE()
|
||||
|
||||
|
||||
DIMENSION_EDITOR_DIALOG::DIMENSION_EDITOR_DIALOG( WinEDA_PcbFrame* parent,
|
||||
DIMENSION* Dimension, wxDC* DC
|
||||
) :
|
||||
wxDialog( parent, -1, _( "Dimension properties" ) )
|
||||
wxDialog( parent, -1, wxString( _( "Dimension properties" ) ) )
|
||||
{
|
||||
wxButton* Button;
|
||||
|
||||
|
@ -163,15 +163,16 @@ void DIMENSION_EDITOR_DIALOG::OnOkClick( wxCommandEvent& event )
|
|||
CurrentDimension->m_Text->m_Size = m_TxtSizeCtrl->GetValue();
|
||||
|
||||
int width = m_TxtWidthCtrl->GetValue();
|
||||
int maxthickness = Clamp_Text_PenSize(width, CurrentDimension->m_Text->m_Size );
|
||||
int maxthickness = Clamp_Text_PenSize( width, CurrentDimension->m_Text->m_Size );
|
||||
if( width > maxthickness )
|
||||
{
|
||||
DisplayError(NULL, _("The text thickness is too large for the text size. It will be clamped"));
|
||||
DisplayError( NULL,
|
||||
_( "The text thickness is too large for the text size. It will be clamped") );
|
||||
width = maxthickness;
|
||||
}
|
||||
CurrentDimension->m_Text->m_Width = CurrentDimension->m_Width = width ;
|
||||
|
||||
CurrentDimension->m_Text->m_Mirror = (m_Mirror->GetSelection() == 1) ? true : false;
|
||||
CurrentDimension->m_Text->m_Mirror = ( m_Mirror->GetSelection() == 1 ) ? true : false;
|
||||
|
||||
CurrentDimension->SetLayer( m_SelLayerBox->GetChoice() + FIRST_NO_COPPER_LAYER );
|
||||
|
||||
|
|
|
@ -926,17 +926,17 @@ static void export_vrml_pad( BOARD* pcb, D_PAD* pad ) /*{{{*/
|
|||
{
|
||||
int coord[8] =
|
||||
{
|
||||
-pad_w - pad_dy, +pad_h + pad_dx,
|
||||
-pad_w + pad_dy, -pad_h - pad_dx,
|
||||
+pad_w - pad_dy, +pad_h - pad_dx,
|
||||
+pad_w + pad_dy, -pad_h + pad_dx,
|
||||
wxRound(-pad_w - pad_dy), wxRound(+pad_h + pad_dx),
|
||||
wxRound(-pad_w + pad_dy), wxRound(-pad_h - pad_dx),
|
||||
wxRound(+pad_w - pad_dy), wxRound(+pad_h - pad_dx),
|
||||
wxRound(+pad_w + pad_dy), wxRound(-pad_h + pad_dx),
|
||||
};
|
||||
|
||||
for( int i = 0; i < 4; i++ )
|
||||
{
|
||||
RotatePoint( &coord[i * 2], &coord[i * 2 + 1], pad->m_Orient );
|
||||
coord[i * 2] += pad_x;
|
||||
coord[i * 2 + 1] += pad_y;
|
||||
coord[i * 2] += wxRound( pad_x );
|
||||
coord[i * 2 + 1] += wxRound( pad_y );
|
||||
}
|
||||
|
||||
bag_flat_quad( layer, coord[0], coord[1],
|
||||
|
@ -1054,7 +1054,7 @@ static void export_vrml_module( BOARD* aPcb, MODULE* aModule,
|
|||
* for footprints that are flipped
|
||||
* When flipped, axis rotation is the horizontal axis (X axis)
|
||||
*/
|
||||
int rotx = vrmlm->m_MatRotation.x;
|
||||
int rotx = wxRound( vrmlm->m_MatRotation.x );
|
||||
if ( isFlipped )
|
||||
rotx += 1800;
|
||||
|
||||
|
|
|
@ -42,9 +42,8 @@ private:
|
|||
WinEDA_ValueCtrl* m_MireSizeCtrl;
|
||||
wxRadioBox* m_MireShape;
|
||||
|
||||
public: TARGET_PROPERTIES_DIALOG_EDITOR( WinEDA_PcbFrame* parent,
|
||||
MIREPCB* Mire,
|
||||
wxDC* DC );
|
||||
public:
|
||||
TARGET_PROPERTIES_DIALOG_EDITOR( WinEDA_PcbFrame* parent, MIREPCB* Mire, wxDC* DC );
|
||||
~TARGET_PROPERTIES_DIALOG_EDITOR() { }
|
||||
|
||||
private:
|
||||
|
@ -73,7 +72,7 @@ void WinEDA_PcbFrame::InstallMireOptionsFrame( MIREPCB* MirePcb, wxDC* DC )
|
|||
TARGET_PROPERTIES_DIALOG_EDITOR::TARGET_PROPERTIES_DIALOG_EDITOR(
|
||||
WinEDA_PcbFrame* parent,
|
||||
MIREPCB* Mire, wxDC* DC ) :
|
||||
wxDialog( parent, wxID_ANY, _( "Target Properties" ) )
|
||||
wxDialog( parent, wxID_ANY, wxString( _( "Target Properties" ) ) )
|
||||
{
|
||||
wxString number;
|
||||
wxButton* Button;
|
||||
|
@ -124,8 +123,7 @@ TARGET_PROPERTIES_DIALOG_EDITOR::TARGET_PROPERTIES_DIALOG_EDITOR(
|
|||
}
|
||||
|
||||
|
||||
void TARGET_PROPERTIES_DIALOG_EDITOR::OnCancelClick( wxCommandEvent& WXUNUSED(
|
||||
event ) )
|
||||
void TARGET_PROPERTIES_DIALOG_EDITOR::OnCancelClick( wxCommandEvent& WXUNUSED( event ) )
|
||||
{
|
||||
EndModal( -1 );
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue