Eeschema: fix bug in load_one_schematic_file.cpp: error about files version, that create errors for hierarchical labels.

Pcbnew: cleaning code in block.cpp, and modifye previous way to calculate block size in block command, because old way creates unexpected behavior in block rotate and block flip.
Pcbnew: Fix a bug in plot silkscreen layers.
Cvpcb: Fix compilation issue under MACOX
This commit is contained in:
jean-pierre charras 2010-11-12 19:38:48 +01:00
parent 25df2772db
commit bc9d521738
8 changed files with 1011 additions and 291 deletions

View File

@ -15,6 +15,7 @@
#include "protos.h"
#include "cvstruct.h"
#include "colors_selection.h"
#include "cvpcb_id.h"
#include "build_version.h"

View File

@ -71,10 +71,14 @@ bool WinEDA_SchematicFrame::LoadOneEEFile( SCH_SCREEN* screen, const wxString& F
return FALSE;
}
// get the file version here. TODO: Support version numbers > 9
char version = line[9 + sizeof(SCHEMATIC_HEAD_STRING)];
int ver = version - '0';
if( ver > EESCHEMA_VERSION )
// get the file version here.
char *strversion = line + 9 + sizeof(SCHEMATIC_HEAD_STRING);
// Skip blanks
while( *strversion && *strversion < '0' )
strversion++;
int version = atoi(strversion);
if( version > EESCHEMA_VERSION )
{
MsgDiag = FullFileName + _( " was created by a more recent \
version of EESchema and may not load correctly. Please consider updating!" );
@ -83,7 +87,7 @@ version of EESchema and may not load correctly. Please consider updating!" );
#if 0
// Compile it if the new version is unreadable by previous eeschema versions
else if( ver < EESCHEMA_VERSION )
else if( version < EESCHEMA_VERSION )
{
MsgDiag = FullFileName + _( " was created by an older version of \
EESchema. It will be stored in the new file format when you save this file \
@ -159,9 +163,9 @@ again." );
}
else if( Name1[0] == 'L' )
item = new SCH_LABEL();
else if( Name1[0] == 'G' && ver > '1' )
else if( Name1[0] == 'G' && version > 1 )
item = new SCH_GLOBALLABEL();
else if( (Name1[0] == 'H') || (Name1[0] == 'G' && ver == '1') )
else if( (Name1[0] == 'H') || (Name1[0] == 'G' && version == 1) )
item = new SCH_HIERLABEL();
else
item = new SCH_TEXT();

View File

@ -4,6 +4,7 @@ add_definitions(-DPCBNEW)
# Includes
###
include_directories(${CMAKE_CURRENT_SOURCE_DIR}
${CMAKE_CURRENT_SOURCE_DIR}/dialogs
${Boost_INCLUDE_DIR}
../3d-viewer
../common
@ -41,6 +42,7 @@ set(PCBNEW_SRCS
cross-probing.cpp
debug_kbool_key_file_fct.cpp
deltrack.cpp
dialogs/dialog_block_options_base.cpp
dialog_copper_zones.cpp
dialog_copper_zones_base.cpp
dialog_design_rules.cpp

View File

@ -16,6 +16,8 @@
#include "pcbplot.h"
#include "trigo.h"
#include "dialog_block_options_base.h"
#include "protos.h"
#define BLOCK_OUTLINE_COLOR YELLOW
@ -29,6 +31,7 @@
**/
static void drawPickedItems( WinEDA_DrawPanel* aPanel, wxDC* aDC,
wxPoint aOffset );
/**
* Function drawMovingBlock
* handles drawing of a moving block
@ -40,184 +43,89 @@ static void drawMovingBlock( WinEDA_DrawPanel* aPanel, wxDC* aDC,
bool aErase );
static bool Block_Include_Modules = TRUE;
static bool BlockIncludeLockedModules = TRUE;
static bool Block_Include_Tracks = TRUE;
static bool Block_Include_Zones = TRUE;
static bool Block_Include_Draw_Items = TRUE;
static bool Block_Include_Edges_Items = TRUE;
static bool Block_Include_PcbTextes = TRUE;
static bool BlockDrawItems = TRUE;
static bool Block_Include_Modules = true;
static bool BlockIncludeLockedModules = true;
static bool Block_Include_Tracks = true;
static bool Block_Include_Zones = true;
static bool Block_Include_Draw_Items = true;
static bool Block_Include_Edges_Items = true;
static bool Block_Include_PcbTextes = true;
static bool BlockDrawItems = true;
/************************************/
/* class WinEDA_ExecBlockCmdFrame */
/* class DIALOG_BLOCK_OPTIONS */
/************************************/
class WinEDA_ExecBlockCmdFrame : public wxDialog
class DIALOG_BLOCK_OPTIONS : public DIALOG_BLOCK_OPTIONS_BASE
{
private:
WinEDA_BasePcbFrame* m_Parent;
wxCheckBox* m_Include_Modules;
wxCheckBox* m_IncludeLockedModules;
wxCheckBox* m_Include_Tracks;
wxCheckBox* m_Include_Zones;
wxCheckBox* m_Include_Draw_Items;
wxCheckBox* m_Include_Edges_Items;
wxCheckBox* m_Include_PcbTextes;
wxCheckBox* m_DrawBlockItems;
public:
WinEDA_ExecBlockCmdFrame( WinEDA_BasePcbFrame* parent,
const wxString& title );
~WinEDA_ExecBlockCmdFrame()
DIALOG_BLOCK_OPTIONS( WinEDA_BasePcbFrame* parent,
const wxString& title );
~DIALOG_BLOCK_OPTIONS()
{
}
private:
void ExecuteCommand( wxCommandEvent& event );
void Cancel( wxCommandEvent& event );
void OnCancel( wxCommandEvent& event );
void checkBoxClicked( wxCommandEvent& aEvent );
DECLARE_EVENT_TABLE()
};
BEGIN_EVENT_TABLE( WinEDA_ExecBlockCmdFrame, wxDialog )
EVT_BUTTON( wxID_OK, WinEDA_ExecBlockCmdFrame::ExecuteCommand )
EVT_BUTTON( wxID_CANCEL, WinEDA_ExecBlockCmdFrame::Cancel )
EVT_CHECKBOX( wxID_ANY, WinEDA_ExecBlockCmdFrame::checkBoxClicked )
END_EVENT_TABLE()
static bool InstallBlockCmdFrame( WinEDA_BasePcbFrame* parent,
const wxString& title )
static bool InstallBlockCmdFrame( WinEDA_BasePcbFrame* parent, const wxString& title )
{
int nocmd;
wxPoint oldpos = parent->GetScreen()->m_Curseur;
parent->DrawPanel->m_IgnoreMouseEvents = TRUE;
WinEDA_ExecBlockCmdFrame* frame =
new WinEDA_ExecBlockCmdFrame( parent, title );
parent->DrawPanel->m_IgnoreMouseEvents = true;
DIALOG_BLOCK_OPTIONS dlg( parent, title );
nocmd = frame->ShowModal();
frame->Destroy();
nocmd = dlg.ShowModal();
parent->GetScreen()->m_Curseur = oldpos;
parent->DrawPanel->MouseToCursorSchema();
parent->DrawPanel->m_IgnoreMouseEvents = FALSE;
parent->DrawPanel->m_IgnoreMouseEvents = false;
parent->DrawPanel->SetCursor( parent->DrawPanel->m_PanelCursor =
parent->DrawPanel->m_PanelDefaultCursor );
parent->DrawPanel->m_PanelDefaultCursor );
return nocmd ? FALSE : TRUE;
return nocmd ? false : true;
}
WinEDA_ExecBlockCmdFrame::WinEDA_ExecBlockCmdFrame( WinEDA_BasePcbFrame* parent,
const wxString& title ) :
wxDialog( parent, -1, title, wxPoint( -1, -1 ), wxDefaultSize,
DIALOG_STYLE )
DIALOG_BLOCK_OPTIONS::DIALOG_BLOCK_OPTIONS( WinEDA_BasePcbFrame* parent,
const wxString& title ) :
DIALOG_BLOCK_OPTIONS_BASE( parent, -1, title )
{
wxPoint pos;
wxButton* m_button1;
wxButton* m_button2;
m_Parent = parent;
Centre();
this->SetSizeHints( wxDefaultSize, wxDefaultSize );
this->SetFont( wxFont( wxNORMAL_FONT->GetPointSize(), 70, 90, 90,
false, wxEmptyString ) );
/* Sizer 1 creation */
wxFlexGridSizer* fgSizer1;
fgSizer1 = new wxFlexGridSizer( 7, 1, 0, 0 );
fgSizer1->SetFlexibleDirection( wxBOTH );
fgSizer1->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
m_Include_Modules = new wxCheckBox( this, -1, _( "Include Modules" ),
wxDefaultPosition, wxDefaultSize,
0 );
m_Include_Modules->SetValue( Block_Include_Modules );
fgSizer1->Add( m_Include_Modules, 0, wxALL, 5 );
m_IncludeLockedModules = new wxCheckBox( this, -1, _( "Include Locked Modules" ),
wxDefaultPosition, wxDefaultSize,
0 );
m_IncludeLockedModules->SetValue( BlockIncludeLockedModules );
if( m_Include_Modules->GetValue() )
m_IncludeLockedModules->Enable();
else
m_IncludeLockedModules->Disable();
fgSizer1->Add( m_IncludeLockedModules, 0, wxALL, 5 );
m_Include_Tracks = new wxCheckBox( this, -1, _( "Include Tracks" ),
wxDefaultPosition, wxDefaultSize, 0 );
m_Include_Tracks->SetValue( Block_Include_Tracks );
fgSizer1->Add( m_Include_Tracks, 0, wxALL, 5 );
m_Include_Zones = new wxCheckBox( this, -1, _( "Include Zones" ),
wxDefaultPosition, wxDefaultSize, 0 );
m_Include_Zones->SetValue( Block_Include_Zones );
fgSizer1->Add( m_Include_Zones, 0, wxALL, 5 );
m_Include_PcbTextes = new wxCheckBox( this, -1,
_( "Include Text Items" ),
wxDefaultPosition,
wxDefaultSize, 0 );
m_Include_PcbTextes->SetValue( Block_Include_PcbTextes );
fgSizer1->Add( m_Include_PcbTextes, 0, wxALL, 5 );
m_Include_Draw_Items = new wxCheckBox( this, -1, _( "Include Drawings" ),
wxDefaultPosition,
wxDefaultSize, 0 );
m_Include_Draw_Items->SetValue( Block_Include_Draw_Items );
fgSizer1->Add( m_Include_Draw_Items, 0, wxALL, 5 );
m_Include_Edges_Items = new wxCheckBox( this, -1,
_( "Include Board Outline Layer" ),
wxDefaultPosition,
wxDefaultSize, 0 );
m_Include_Edges_Items->SetValue( Block_Include_Edges_Items );
fgSizer1->Add( m_Include_Edges_Items, 0, wxALL, 5 );
m_DrawBlockItems = new wxCheckBox( this, -1,
_( "Draw Block Items" ),
wxDefaultPosition,
wxDefaultSize, 0 );
m_Include_PcbTextes->SetValue( Block_Include_PcbTextes );
m_DrawBlockItems->SetValue( BlockDrawItems );
fgSizer1->Add( m_DrawBlockItems, 0, wxALL, 5 );
/* Sizer 2 creation */
wxFlexGridSizer* fgSizer2;
fgSizer2 = new wxFlexGridSizer( 1, 2, 0, 0 );
fgSizer2->SetFlexibleDirection( wxBOTH );
fgSizer2->SetNonFlexibleGrowMode( wxFLEX_GROWMODE_SPECIFIED );
m_button2 = new wxButton( this, wxID_CANCEL, _( "Cancel" ),
wxDefaultPosition, wxDefaultSize, 0 );
fgSizer2->Add( m_button2, 0, wxALL, 5 );
m_button1 = new wxButton( this, wxID_OK, _( "OK" ), wxDefaultPosition,
wxDefaultSize, 0 );
m_button1->SetDefault();
fgSizer2->Add( m_button1, 0, wxALL, 5 );
fgSizer1->Add( fgSizer2, 1, wxALIGN_RIGHT, 5 );
this->SetSizer( fgSizer1 );
this->Layout();
fgSizer1->Fit( this );
SetFocus();
GetSizer()->SetSizeHints( this );
Centre();
}
void WinEDA_ExecBlockCmdFrame::Cancel( wxCommandEvent& WXUNUSED (event) )
void DIALOG_BLOCK_OPTIONS::OnCancel( wxCommandEvent& WXUNUSED (event) )
{
EndModal( -1 );
}
void WinEDA_ExecBlockCmdFrame::checkBoxClicked( wxCommandEvent& WXUNUSED (aEvent) )
void DIALOG_BLOCK_OPTIONS::checkBoxClicked( wxCommandEvent& WXUNUSED (aEvent) )
{
if( m_Include_Modules->GetValue() )
m_IncludeLockedModules->Enable();
@ -225,7 +133,8 @@ void WinEDA_ExecBlockCmdFrame::checkBoxClicked( wxCommandEvent& WXUNUSED (aEvent
m_IncludeLockedModules->Disable();
}
void WinEDA_ExecBlockCmdFrame::ExecuteCommand( wxCommandEvent& event )
void DIALOG_BLOCK_OPTIONS::ExecuteCommand( wxCommandEvent& event )
{
Block_Include_Modules = m_Include_Modules->GetValue();
BlockIncludeLockedModules = m_IncludeLockedModules->GetValue();
@ -234,7 +143,7 @@ void WinEDA_ExecBlockCmdFrame::ExecuteCommand( wxCommandEvent& event )
Block_Include_Draw_Items = m_Include_Draw_Items->GetValue();
Block_Include_Edges_Items = m_Include_Edges_Items->GetValue();
Block_Include_PcbTextes = m_Include_PcbTextes->GetValue();
BlockDrawItems = m_DrawBlockItems->GetValue();
BlockDrawItems = m_DrawBlockItems->GetValue();
EndModal( 0 );
}
@ -285,11 +194,11 @@ int WinEDA_PcbFrame::ReturnBlockCommand( int key )
/* Routine to handle the BLOCK PLACE command */
void WinEDA_PcbFrame::HandleBlockPlace( wxDC* DC )
{
bool err = FALSE;
bool err = false;
if( DrawPanel->ManageCurseur == NULL )
{
err = TRUE;
err = true;
DisplayError( this, wxT( "Error in HandleBlockPLace : ManageCurseur = NULL" ) );
}
GetScreen()->m_BlockLocate.m_State = STATE_BLOCK_STOP;
@ -297,21 +206,21 @@ void WinEDA_PcbFrame::HandleBlockPlace( wxDC* DC )
switch( GetScreen()->m_BlockLocate.m_Command )
{
case BLOCK_IDLE:
err = TRUE;
err = true;
break;
case BLOCK_DRAG: /* Drag */
case BLOCK_MOVE: /* Move */
case BLOCK_PRESELECT_MOVE: /* Move with preselection list*/
if( DrawPanel->ManageCurseur )
DrawPanel->ManageCurseur( DrawPanel, DC, FALSE );
DrawPanel->ManageCurseur( DrawPanel, DC, false );
Block_Move();
GetScreen()->m_BlockLocate.ClearItemsList();
break;
case BLOCK_COPY: /* Copy */
if( DrawPanel->ManageCurseur )
DrawPanel->ManageCurseur( DrawPanel, DC, FALSE );
DrawPanel->ManageCurseur( DrawPanel, DC, false );
Block_Duplicate();
GetScreen()->m_BlockLocate.ClearItemsList();
break;
@ -349,13 +258,13 @@ void WinEDA_PcbFrame::HandleBlockPlace( wxDC* DC )
*/
int WinEDA_PcbFrame::HandleBlockEnd( wxDC* DC )
{
int endcommande = TRUE;
int endcommande = true;
// If coming here after cancel block, clean up and exit
if( GetScreen()->m_BlockLocate.m_State == STATE_NO_BLOCK )
{
DrawPanel->ManageCurseur = NULL;
DrawPanel->ForceCloseManageCurseur = NULL;
DrawPanel->ForceCloseManageCurseur = NULL;
GetScreen()->m_BlockLocate.m_Flags = 0;
GetScreen()->m_BlockLocate.m_Command = BLOCK_IDLE;
GetScreen()->m_BlockLocate.ClearItemsList();
@ -365,29 +274,29 @@ int WinEDA_PcbFrame::HandleBlockEnd( wxDC* DC )
// Show dialog if there are no selected items and
// we're not zooming
if ( !GetScreen()->m_BlockLocate.GetCount() &&
GetScreen()->m_BlockLocate.m_Command != BLOCK_ZOOM )
if( !GetScreen()->m_BlockLocate.GetCount()
&& GetScreen()->m_BlockLocate.m_Command != BLOCK_ZOOM )
{
if( !InstallBlockCmdFrame( this, _( "Block Operation" ) ) )
{
DrawPanel->ManageCurseur = NULL;
DrawPanel->ForceCloseManageCurseur = NULL;
DrawPanel->ForceCloseManageCurseur = NULL;
GetScreen()->m_BlockLocate.m_Flags = 0;
GetScreen()->m_BlockLocate.m_State = STATE_NO_BLOCK;
GetScreen()->m_BlockLocate.m_Command = BLOCK_IDLE;
GetScreen()->m_BlockLocate.ClearItemsList();
DisplayToolMsg( wxEmptyString );
DrawAndSizingBlockOutlines( DrawPanel, DC, FALSE );
DrawAndSizingBlockOutlines( DrawPanel, DC, false );
return 0;
}
DrawAndSizingBlockOutlines( DrawPanel, DC, FALSE );
DrawAndSizingBlockOutlines( DrawPanel, DC, false );
Block_SelectItems();
// Exit if no items found
if( !GetScreen()->m_BlockLocate.GetCount() ) {
if( !GetScreen()->m_BlockLocate.GetCount() )
{
DrawPanel->ManageCurseur = NULL;
DrawPanel->ForceCloseManageCurseur = NULL;
DrawPanel->ForceCloseManageCurseur = NULL;
GetScreen()->m_BlockLocate.m_Flags = 0;
GetScreen()->m_BlockLocate.m_State = STATE_NO_BLOCK;
GetScreen()->m_BlockLocate.m_Command = BLOCK_IDLE;
@ -396,22 +305,26 @@ int WinEDA_PcbFrame::HandleBlockEnd( wxDC* DC )
return 0;
}
// Move cursor to the center of the smallest rectangle
wxPoint blockCenter;
// Move cursor to the best position in selected rect:
// can be the block locate rect or the the smallest rectangle
// containing the centers of all selected items.
// Unfortunately, this option gives unpredicatble results when flipping or mirroring blocks
#if 0 // set to 1 to use smallest rectangle center
// Move cursor to the center of
// Also set m_BlockLocate to the size of the rectangle.
PICKED_ITEMS_LIST* itemsList = &DrawPanel->GetScreen()->m_BlockLocate.m_ItemsSelection;
wxPoint blockCenter;
int minX, minY, maxX, maxY;
int tempX, tempY;
BOARD_ITEM* item = (BOARD_ITEM*) itemsList->GetPickedItem( 0 );
BOARD_ITEM* item = (BOARD_ITEM*) itemsList->GetPickedItem( 0 );
minX = item->GetPosition().x;
minY = item->GetPosition().y;
maxX = minX;
maxY = minY;
for( unsigned ii = 1; ii < itemsList->GetCount(); ii++ )
{
item = (BOARD_ITEM*) itemsList->GetPickedItem( ii );
item = (BOARD_ITEM*) itemsList->GetPickedItem( ii );
tempX = item->GetPosition().x;
tempY = item->GetPosition().y;
if( tempX > maxX )
@ -426,17 +339,19 @@ int WinEDA_PcbFrame::HandleBlockEnd( wxDC* DC )
blockCenter.x = ( minX + maxX ) / 2;
blockCenter.y = ( minY + maxY ) / 2;
GetScreen()->m_BlockLocate.SetOrigin( minX, minY );
GetScreen()->m_BlockLocate.SetEnd( maxX, maxY );
#else
blockCenter = GetScreen()->m_BlockLocate.Centre();
#endif
DrawPanel->CursorOff( DC );
GetScreen()->m_Curseur = blockCenter;
GetScreen()->m_BlockLocate.SetLastCursorPosition( blockCenter );
GetScreen()->m_BlockLocate.SetOrigin( minX, minY );
GetScreen()->m_BlockLocate.SetEnd( maxX, maxY );
DrawPanel->MouseToCursorSchema();
DrawPanel->CursorOn( DC );
}
if( DrawPanel->ManageCurseur )
{
switch( GetScreen()->m_BlockLocate.m_Command )
{
case BLOCK_IDLE:
@ -448,9 +363,9 @@ int WinEDA_PcbFrame::HandleBlockEnd( wxDC* DC )
case BLOCK_COPY: /* Copy */
case BLOCK_PRESELECT_MOVE: /* Move with preselection list*/
GetScreen()->m_BlockLocate.m_State = STATE_BLOCK_MOVE;
endcommande = FALSE;
endcommande = false;
DrawPanel->ManageCurseur = drawMovingBlock;
DrawPanel->ManageCurseur( DrawPanel, DC, FALSE );
DrawPanel->ManageCurseur( DrawPanel, DC, false );
break;
case BLOCK_DELETE: /* Delete */
@ -493,9 +408,8 @@ int WinEDA_PcbFrame::HandleBlockEnd( wxDC* DC )
default:
break;
}
}
if( endcommande == TRUE )
if( endcommande == true )
{
GetScreen()->m_BlockLocate.m_Flags = 0;
GetScreen()->m_BlockLocate.m_State = STATE_NO_BLOCK;
@ -521,7 +435,7 @@ int WinEDA_PcbFrame::HandleBlockEnd( wxDC* DC )
*/
void WinEDA_PcbFrame::Block_SelectItems()
{
int masque_layer;
int masque_layer;
GetScreen()->m_BlockLocate.Normalize();
@ -531,10 +445,10 @@ void WinEDA_PcbFrame::Block_SelectItems()
if( Block_Include_Modules )
{
for( MODULE* module = m_Pcb->m_Modules; module != NULL;
module = module->Next() )
module = module->Next() )
{
if( module->HitTest( GetScreen()->m_BlockLocate ) &&
( !module->IsLocked() || BlockIncludeLockedModules ) )
if( module->HitTest( GetScreen()->m_BlockLocate )
&& ( !module->IsLocked() || BlockIncludeLockedModules ) )
{
picker.m_PickedItem = module;
picker.m_PickedItemType = module->Type();
@ -547,7 +461,7 @@ void WinEDA_PcbFrame::Block_SelectItems()
if( Block_Include_Tracks )
{
for( TRACK* pt_segm = m_Pcb->m_Track; pt_segm != NULL;
pt_segm = pt_segm->Next() )
pt_segm = pt_segm->Next() )
{
if( pt_segm->HitTest( GetScreen()->m_BlockLocate ) )
{
@ -568,7 +482,7 @@ void WinEDA_PcbFrame::Block_SelectItems()
masque_layer &= ~EDGE_LAYER;
for( BOARD_ITEM* PtStruct = m_Pcb->m_Drawings; PtStruct != NULL;
PtStruct = PtStruct->Next() )
PtStruct = PtStruct->Next() )
{
bool select_me = false;
switch( PtStruct->Type() )
@ -621,13 +535,15 @@ void WinEDA_PcbFrame::Block_SelectItems()
if( Block_Include_Zones )
{
#if 0
/* This section can creates problems if selected:
* m_Pcb->m_Zone can have a *lot* of items (100 000 is easily possible)
* so it is not selected (and TODO: will be removed, one day)
*/
for( SEGZONE* pt_segm = m_Pcb->m_Zone; pt_segm != NULL;
pt_segm = pt_segm->Next() )
{ /* Segments used in Zone filling selection */
pt_segm = pt_segm->Next() )
{
/* Segments used in Zone filling selection */
if( pt_segm->HitTest( GetScreen()->m_BlockLocate ) )
{
@ -636,6 +552,7 @@ void WinEDA_PcbFrame::Block_SelectItems()
itemsList->PushItem( picker );
}
}
#endif
for( int ii = 0; ii < m_Pcb->GetAreaCount(); ii++ )
{
@ -650,13 +567,14 @@ void WinEDA_PcbFrame::Block_SelectItems()
}
}
static void drawPickedItems( WinEDA_DrawPanel* aPanel, wxDC* aDC,
wxPoint aOffset )
{
PICKED_ITEMS_LIST* itemsList = &aPanel->GetScreen()->m_BlockLocate.m_ItemsSelection;
WinEDA_BasePcbFrame* frame = (WinEDA_BasePcbFrame*) aPanel->GetParent();
g_Offset_Module = -aOffset;
PICKED_ITEMS_LIST* itemsList = &aPanel->GetScreen()->m_BlockLocate.m_ItemsSelection;
WinEDA_BasePcbFrame* frame = (WinEDA_BasePcbFrame*) aPanel->GetParent();
g_Offset_Module = -aOffset;
for( unsigned ii = 0; ii < itemsList->GetCount(); ii++ )
{
BOARD_ITEM* item = (BOARD_ITEM*) itemsList->GetPickedItem( ii );
@ -664,23 +582,26 @@ static void drawPickedItems( WinEDA_DrawPanel* aPanel, wxDC* aDC,
{
case TYPE_MODULE:
{
MODULE* module = (MODULE*) item;
MODULE* module = (MODULE*) item;
frame->GetBoard()->m_Status_Pcb &= ~RATSNEST_ITEM_LOCAL_OK;
DrawModuleOutlines( aPanel, aDC, module );
break;
}
case TYPE_DRAWSEGMENT:
{
DRAWSEGMENT* segment = (DRAWSEGMENT*) item;
segment->Draw( aPanel, aDC, GR_XOR, aOffset );
break;
}
case TYPE_TEXTE:
{
TEXTE_PCB* text = (TEXTE_PCB*) item;
text->Draw( aPanel, aDC, GR_XOR, aOffset );
break;
}
case TYPE_TRACK:
case TYPE_VIA:
{
@ -688,18 +609,21 @@ static void drawPickedItems( WinEDA_DrawPanel* aPanel, wxDC* aDC,
track->Draw( aPanel, aDC, GR_XOR, aOffset );
break;
}
case TYPE_MIRE:
{
MIREPCB* mire = (MIREPCB*) item;
mire->Draw( aPanel, aDC, GR_XOR, aOffset );
break;
}
case TYPE_DIMENSION:
{
DIMENSION* dimension = (DIMENSION*) item;
dimension->Draw( aPanel, aDC, GR_XOR, aOffset );
break;
}
case TYPE_ZONE_CONTAINER:
{
ZONE_CONTAINER* zoneContainer = (ZONE_CONTAINER*) item;
@ -707,6 +631,7 @@ static void drawPickedItems( WinEDA_DrawPanel* aPanel, wxDC* aDC,
zoneContainer->DrawFilledArea( aPanel, aDC, GR_XOR, aOffset );
break;
}
// Currently markers are not affected by block commands
case TYPE_MARKER_PCB:
{
@ -719,9 +644,11 @@ static void drawPickedItems( WinEDA_DrawPanel* aPanel, wxDC* aDC,
break;
}
}
g_Offset_Module = wxPoint( 0, 0 );
}
static void drawMovingBlock( WinEDA_DrawPanel* aPanel, wxDC* aDC,
bool aErase )
{
@ -732,30 +659,26 @@ static void drawMovingBlock( WinEDA_DrawPanel* aPanel, wxDC* aDC,
if( screen->m_BlockLocate.m_MoveVector.x
|| screen->m_BlockLocate.m_MoveVector.y )
{
if( !BlockDrawItems )
screen->m_BlockLocate.Draw( aPanel, aDC, screen->m_BlockLocate.m_MoveVector,
GR_XOR, BLOCK_OUTLINE_COLOR );
else
screen->m_BlockLocate.Draw( aPanel, aDC, screen->m_BlockLocate.m_MoveVector,
GR_XOR, BLOCK_OUTLINE_COLOR );
if( BlockDrawItems )
drawPickedItems( aPanel, aDC, screen->m_BlockLocate.m_MoveVector );
}
}
if( screen->m_BlockLocate.m_State != STATE_BLOCK_STOP )
{
screen->m_BlockLocate.m_MoveVector.x = screen->m_Curseur.x -
screen->m_BlockLocate.m_BlockLastCursorPosition.x;
screen->m_BlockLocate.m_MoveVector.y = screen->m_Curseur.y -
screen->m_BlockLocate.m_BlockLastCursorPosition.y;
screen->m_BlockLocate.m_MoveVector = screen->m_Curseur -
screen->m_BlockLocate.m_BlockLastCursorPosition;
}
if( screen->m_BlockLocate.m_MoveVector.x
|| screen->m_BlockLocate.m_MoveVector.y )
{
if( !BlockDrawItems )
screen->m_BlockLocate.Draw( aPanel, aDC, screen->m_BlockLocate.m_MoveVector,
GR_XOR, BLOCK_OUTLINE_COLOR );
else
drawPickedItems( aPanel, aDC, screen->m_BlockLocate.m_MoveVector );
screen->m_BlockLocate.Draw( aPanel, aDC, screen->m_BlockLocate.m_MoveVector,
GR_XOR, BLOCK_OUTLINE_COLOR );
if( BlockDrawItems )
drawPickedItems( aPanel, aDC, screen->m_BlockLocate.m_MoveVector );
}
}
@ -791,18 +714,18 @@ void WinEDA_PcbFrame::Block_Delete()
m_Pcb->Remove( item );
break;
case TYPE_DRAWSEGMENT: // a segment not on copper layers
case TYPE_TEXTE: // a text on a layer
case TYPE_TRACK: // a track segment (segment on a copper layer)
case TYPE_VIA: // a via (like atrack segment on a copper layer)
case TYPE_DIMENSION: // a dimension (graphic item)
case TYPE_MIRE: // a target (graphic item)
case TYPE_DRAWSEGMENT: // a segment not on copper layers
case TYPE_TEXTE: // a text on a layer
case TYPE_TRACK: // a track segment (segment on a copper layer)
case TYPE_VIA: // a via (like atrack segment on a copper layer)
case TYPE_DIMENSION: // a dimension (graphic item)
case TYPE_MIRE: // a target (graphic item)
item->UnLink();
break;
// These items are deleted, but not put in undo list
case TYPE_MARKER_PCB: // a marker used to show something
case TYPE_ZONE: // SEG_ZONE items are now deprecated
case TYPE_MARKER_PCB: // a marker used to show something
case TYPE_ZONE: // SEG_ZONE items are now deprecated
item->UnLink();
itemsList->RemovePicker( ii );
ii--;
@ -817,8 +740,8 @@ void WinEDA_PcbFrame::Block_Delete()
SaveCopyInUndoList( *itemsList, UR_DELETED );
Compile_Ratsnest( NULL, TRUE );
DrawPanel->Refresh( TRUE );
Compile_Ratsnest( NULL, true );
DrawPanel->Refresh( true );
}
@ -832,7 +755,7 @@ void WinEDA_PcbFrame::Block_Rotate()
{
wxPoint oldpos;
wxPoint centre; // rotation cent-re for the rotation transform
int rotAngle = 900; // rotation angle in 0.1 deg.
int rotAngle = 900; // rotation angle in 0.1 deg.
oldpos = GetScreen()->m_Curseur;
centre = GetScreen()->m_BlockLocate.Centre();
@ -845,22 +768,21 @@ void WinEDA_PcbFrame::Block_Rotate()
for( unsigned ii = 0; ii < itemsList->GetCount(); ii++ )
{
BOARD_ITEM* item = (BOARD_ITEM*) itemsList->GetPickedItem( ii );
wxASSERT(item);
wxASSERT( item );
itemsList->SetPickedItemStatus( UR_ROTATED, ii );
item->Rotate(centre, rotAngle);
item->Rotate( centre, rotAngle );
switch( item->Type() )
{
case TYPE_MODULE:
((MODULE*) item)->m_Flags = 0;
( (MODULE*) item )->m_Flags = 0;
m_Pcb->m_Status_Pcb = 0;
break;
break;
/* Move and rotate the track segments */
case TYPE_TRACK: // a track segment (segment on a copper layer)
case TYPE_VIA: // a via (like atrack segment on a copper layer)
case TYPE_TRACK: // a track segment (segment on a copper layer)
case TYPE_VIA: // a via (like atrack segment on a copper layer)
m_Pcb->m_Status_Pcb = 0;
break;
break;
case TYPE_ZONE_CONTAINER:
case TYPE_DRAWSEGMENT:
@ -883,14 +805,14 @@ void WinEDA_PcbFrame::Block_Rotate()
SaveCopyInUndoList( *itemsList, UR_ROTATED, centre );
Compile_Ratsnest( NULL, TRUE );
DrawPanel->Refresh( TRUE );
Compile_Ratsnest( NULL, true );
DrawPanel->Refresh( true );
}
/**
* Function Block_Flip
* flips items within the selected block.
* Flip items within the selected block.
* The flip center is the center of the block
* @param none
*/
@ -912,16 +834,15 @@ void WinEDA_PcbFrame::Block_Flip()
for( unsigned ii = 0; ii < itemsList->GetCount(); ii++ )
{
BOARD_ITEM* item = (BOARD_ITEM*) itemsList->GetPickedItem( ii );
wxASSERT(item);
wxASSERT( item );
itemsList->SetPickedItemStatus( UR_FLIPPED, ii );
item->Flip(center);
item->Flip( center );
switch( item->Type() )
{
case TYPE_MODULE:
((MODULE*) item)->m_Flags = 0;
( (MODULE*) item )->m_Flags = 0;
m_Pcb->m_Status_Pcb = 0;
break;
break;
/* Move and rotate the track segments */
case TYPE_TRACK: // a track segment (segment on a copper layer)
@ -950,8 +871,8 @@ void WinEDA_PcbFrame::Block_Flip()
}
SaveCopyInUndoList( *itemsList, UR_FLIPPED, center );
Compile_Ratsnest( NULL, TRUE );
DrawPanel->Refresh( TRUE );
Compile_Ratsnest( NULL, true );
DrawPanel->Refresh( true );
}
@ -966,7 +887,7 @@ void WinEDA_PcbFrame::Block_Move()
{
OnModify();
wxPoint MoveVector = GetScreen()->m_BlockLocate.m_MoveVector;
wxPoint MoveVector = GetScreen()->m_BlockLocate.m_MoveVector;
PICKED_ITEMS_LIST* itemsList = &GetScreen()->m_BlockLocate.m_ItemsSelection;
itemsList->m_Status = UR_MOVED;
@ -980,15 +901,15 @@ void WinEDA_PcbFrame::Block_Move()
switch( item->Type() )
{
case TYPE_MODULE:
m_Pcb->m_Status_Pcb = 0;
((MODULE*) item)->m_Flags = 0;
break;
m_Pcb->m_Status_Pcb = 0;
( (MODULE*) item )->m_Flags = 0;
break;
/* Move track segments */
case TYPE_TRACK: // a track segment (segment on a copper layer)
case TYPE_VIA: // a via (like a track segment on a copper layer)
case TYPE_TRACK: // a track segment (segment on a copper layer)
case TYPE_VIA: // a via (like a track segment on a copper layer)
m_Pcb->m_Status_Pcb = 0;
break;
break;
case TYPE_ZONE_CONTAINER:
case TYPE_DRAWSEGMENT:
@ -1011,14 +932,14 @@ void WinEDA_PcbFrame::Block_Move()
SaveCopyInUndoList( *itemsList, UR_MOVED, MoveVector );
Compile_Ratsnest( NULL, TRUE );
DrawPanel->Refresh( TRUE );
Compile_Ratsnest( NULL, true );
DrawPanel->Refresh( true );
}
/**
* Function Block_Duplicate
* duplicates all items within the selected block.
* Duplicate all items within the selected block.
* New location is determined by the current offset from the selected block's
* original location.
* @param none
@ -1031,11 +952,11 @@ void WinEDA_PcbFrame::Block_Duplicate()
PICKED_ITEMS_LIST* itemsList = &GetScreen()->m_BlockLocate.m_ItemsSelection;
PICKED_ITEMS_LIST newList;
PICKED_ITEMS_LIST newList;
newList.m_Status = UR_NEW;
ITEM_PICKER picker(NULL, UR_NEW);
BOARD_ITEM * newitem;
ITEM_PICKER picker( NULL, UR_NEW );
BOARD_ITEM* newitem;
for( unsigned ii = 0; ii < itemsList->GetCount(); ii++ )
{
@ -1044,78 +965,78 @@ void WinEDA_PcbFrame::Block_Duplicate()
switch( item->Type() )
{
case TYPE_MODULE:
{
MODULE* module = (MODULE*) item;
MODULE* new_module;
m_Pcb->m_Status_Pcb = 0;
module->m_Flags = 0;
newitem = new_module = new MODULE( m_Pcb );
new_module->Copy( module );
new_module->m_TimeStamp = GetTimeStamp();
m_Pcb->m_Modules.PushFront( new_module );
}
break;
{
MODULE* module = (MODULE*) item;
MODULE* new_module;
m_Pcb->m_Status_Pcb = 0;
module->m_Flags = 0;
newitem = new_module = new MODULE( m_Pcb );
new_module->Copy( module );
new_module->m_TimeStamp = GetTimeStamp();
m_Pcb->m_Modules.PushFront( new_module );
}
break;
case TYPE_TRACK:
case TYPE_VIA:
{
TRACK* track = (TRACK*) item;
m_Pcb->m_Status_Pcb = 0;
TRACK* new_track = track->Copy();
newitem = new_track;
m_Pcb->m_Track.PushFront( new_track );
}
break;
{
TRACK* track = (TRACK*) item;
m_Pcb->m_Status_Pcb = 0;
TRACK* new_track = track->Copy();
newitem = new_track;
m_Pcb->m_Track.PushFront( new_track );
}
break;
case TYPE_ZONE: // SEG_ZONE items are now deprecated
break;
case TYPE_ZONE_CONTAINER:
{
ZONE_CONTAINER* new_zone =
new ZONE_CONTAINER( (BOARD*) item->GetParent() );
new_zone->Copy( (ZONE_CONTAINER*) item );
new_zone->m_TimeStamp = GetTimeStamp();
newitem = new_zone;
m_Pcb->Add( new_zone );
}
break;
{
ZONE_CONTAINER* new_zone =
new ZONE_CONTAINER( (BOARD*) item->GetParent() );
new_zone->Copy( (ZONE_CONTAINER*) item );
new_zone->m_TimeStamp = GetTimeStamp();
newitem = new_zone;
m_Pcb->Add( new_zone );
}
break;
case TYPE_DRAWSEGMENT:
{
DRAWSEGMENT* new_drawsegment = new DRAWSEGMENT( m_Pcb );
new_drawsegment->Copy( (DRAWSEGMENT*) item );
m_Pcb->Add( new_drawsegment );
newitem = new_drawsegment;
}
break;
{
DRAWSEGMENT* new_drawsegment = new DRAWSEGMENT( m_Pcb );
new_drawsegment->Copy( (DRAWSEGMENT*) item );
m_Pcb->Add( new_drawsegment );
newitem = new_drawsegment;
}
break;
case TYPE_TEXTE:
{
TEXTE_PCB* new_pcbtext = new TEXTE_PCB( m_Pcb );
new_pcbtext->Copy( (TEXTE_PCB*) item );
m_Pcb->Add( new_pcbtext );
newitem = new_pcbtext;
}
break;
{
TEXTE_PCB* new_pcbtext = new TEXTE_PCB( m_Pcb );
new_pcbtext->Copy( (TEXTE_PCB*) item );
m_Pcb->Add( new_pcbtext );
newitem = new_pcbtext;
}
break;
case TYPE_MIRE:
{
MIREPCB* new_mire = new MIREPCB( m_Pcb );
new_mire->Copy( (MIREPCB*) item );
m_Pcb->Add( new_mire );
newitem = new_mire;
}
break;
{
MIREPCB* new_mire = new MIREPCB( m_Pcb );
new_mire->Copy( (MIREPCB*) item );
m_Pcb->Add( new_mire );
newitem = new_mire;
}
break;
case TYPE_DIMENSION:
{
DIMENSION* new_cotation = new DIMENSION( m_Pcb );
new_cotation->Copy( (DIMENSION*) item );
m_Pcb->Add( new_cotation );
newitem = new_cotation;
}
break;
{
DIMENSION* new_cotation = new DIMENSION( m_Pcb );
new_cotation->Copy( (DIMENSION*) item );
m_Pcb->Add( new_cotation );
newitem = new_cotation;
}
break;
default:
wxMessageBox( wxT( "WinEDA_PcbFrame::Block_Duplicate( ) error: unexpected type" ) );
@ -1125,15 +1046,15 @@ void WinEDA_PcbFrame::Block_Duplicate()
if( newitem )
{
newitem->Move( MoveVector );
picker.m_PickedItem = newitem;
picker.m_PickedItem = newitem;
picker.m_PickedItemType = newitem->Type();
newList.PushItem(picker);
newList.PushItem( picker );
}
}
if( newList.GetCount() )
SaveCopyInUndoList( newList, UR_NEW );
Compile_Ratsnest( NULL, TRUE );
DrawPanel->Refresh( TRUE );
Compile_Ratsnest( NULL, true );
DrawPanel->Refresh( true );
}

View File

@ -0,0 +1,91 @@
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Sep 8 2010)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
#include "dialog_block_options_base.h"
///////////////////////////////////////////////////////////////////////////
DIALOG_BLOCK_OPTIONS_BASE::DIALOG_BLOCK_OPTIONS_BASE( wxWindow* parent, wxWindowID id, const wxString& title, const wxPoint& pos, const wxSize& size, long style ) : wxDialog( parent, id, title, pos, size, style )
{
this->SetSizeHints( wxDefaultSize, wxDefaultSize );
wxBoxSizer* bSizerMain;
bSizerMain = new wxBoxSizer( wxVERTICAL );
wxGridSizer* gSizer1;
gSizer1 = new wxGridSizer( 4, 2, 0, 0 );
m_Include_Modules = new wxCheckBox( this, wxID_ANY, _("Include Modules"), wxDefaultPosition, wxDefaultSize, 0 );
gSizer1->Add( m_Include_Modules, 0, wxALL, 5 );
m_Include_PcbTextes = new wxCheckBox( this, wxID_ANY, _("Include Texts on Copper Layers"), wxDefaultPosition, wxDefaultSize, 0 );
gSizer1->Add( m_Include_PcbTextes, 0, wxALL, 5 );
m_IncludeLockedModules = new wxCheckBox( this, wxID_ANY, _("Include Locked Modules"), wxDefaultPosition, wxDefaultSize, 0 );
gSizer1->Add( m_IncludeLockedModules, 0, wxALL, 5 );
m_Include_Draw_Items = new wxCheckBox( this, wxID_ANY, _("Include Drawings"), wxDefaultPosition, wxDefaultSize, 0 );
gSizer1->Add( m_Include_Draw_Items, 0, wxALL, 5 );
m_Include_Tracks = new wxCheckBox( this, wxID_ANY, _("Include Tracks"), wxDefaultPosition, wxDefaultSize, 0 );
gSizer1->Add( m_Include_Tracks, 0, wxALL, 5 );
m_Include_Edges_Items = new wxCheckBox( this, wxID_ANY, _("Include Board Outline Layer"), wxDefaultPosition, wxDefaultSize, 0 );
gSizer1->Add( m_Include_Edges_Items, 0, wxALL, 5 );
m_Include_Zones = new wxCheckBox( this, wxID_ANY, _("Include Zones"), wxDefaultPosition, wxDefaultSize, 0 );
gSizer1->Add( m_Include_Zones, 0, wxALL, 5 );
m_DrawBlockItems = new wxCheckBox( this, wxID_ANY, _("Draw Block Items while Moving"), wxDefaultPosition, wxDefaultSize, 0 );
gSizer1->Add( m_DrawBlockItems, 0, wxALL, 5 );
bSizerMain->Add( gSizer1, 0, wxEXPAND, 5 );
m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL );
bSizerMain->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 );
m_sdbSizer1 = new wxStdDialogButtonSizer();
m_sdbSizer1OK = new wxButton( this, wxID_OK );
m_sdbSizer1->AddButton( m_sdbSizer1OK );
m_sdbSizer1Cancel = new wxButton( this, wxID_CANCEL );
m_sdbSizer1->AddButton( m_sdbSizer1Cancel );
m_sdbSizer1->Realize();
bSizerMain->Add( m_sdbSizer1, 0, wxALIGN_RIGHT|wxALL, 5 );
this->SetSizer( bSizerMain );
this->Layout();
this->Centre( wxBOTH );
// Connect Events
m_Include_Modules->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_PcbTextes->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_IncludeLockedModules->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_Draw_Items->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_Tracks->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_Edges_Items->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_Zones->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_DrawBlockItems->Connect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_sdbSizer1Cancel->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::OnCancel ), NULL, this );
m_sdbSizer1OK->Connect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::ExecuteCommand ), NULL, this );
}
DIALOG_BLOCK_OPTIONS_BASE::~DIALOG_BLOCK_OPTIONS_BASE()
{
// Disconnect Events
m_Include_Modules->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_PcbTextes->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_IncludeLockedModules->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_Draw_Items->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_Tracks->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_Edges_Items->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_Include_Zones->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_DrawBlockItems->Disconnect( wxEVT_COMMAND_CHECKBOX_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::checkBoxClicked ), NULL, this );
m_sdbSizer1Cancel->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::OnCancel ), NULL, this );
m_sdbSizer1OK->Disconnect( wxEVT_COMMAND_BUTTON_CLICKED, wxCommandEventHandler( DIALOG_BLOCK_OPTIONS_BASE::ExecuteCommand ), NULL, this );
}

View File

@ -0,0 +1,640 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<wxFormBuilder_Project>
<FileVersion major="1" minor="10" />
<object class="Project" expanded="1">
<property name="class_decoration"></property>
<property name="code_generation">C++</property>
<property name="disconnect_events">1</property>
<property name="disconnect_mode">source_name</property>
<property name="disconnect_python_events">0</property>
<property name="encoding">UTF-8</property>
<property name="event_generation">connect</property>
<property name="file">dialog_block_options_base</property>
<property name="first_id">1000</property>
<property name="help_provider">none</property>
<property name="internationalize">1</property>
<property name="name">dialog_block_options_base</property>
<property name="namespace"></property>
<property name="path">.</property>
<property name="precompiled_header"></property>
<property name="relative_path">1</property>
<property name="skip_python_events">1</property>
<property name="use_enum">0</property>
<property name="use_microsoft_bom">0</property>
<object class="Dialog" expanded="1">
<property name="bg"></property>
<property name="center">wxBOTH</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="event_handler">impl_virtual</property>
<property name="extra_style"></property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">DIALOG_BLOCK_OPTIONS_BASE</property>
<property name="pos"></property>
<property name="size">397,171</property>
<property name="style">wxDEFAULT_DIALOG_STYLE</property>
<property name="subclass"></property>
<property name="title"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnActivate"></event>
<event name="OnActivateApp"></event>
<event name="OnChar"></event>
<event name="OnClose"></event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnHibernate"></event>
<event name="OnIconize"></event>
<event name="OnIdle"></event>
<event name="OnInitDialog"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
<object class="wxBoxSizer" expanded="1">
<property name="minimum_size"></property>
<property name="name">bSizerMain</property>
<property name="orient">wxVERTICAL</property>
<property name="permission">none</property>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxEXPAND</property>
<property name="proportion">0</property>
<object class="wxGridSizer" expanded="1">
<property name="cols">2</property>
<property name="hgap">0</property>
<property name="minimum_size"></property>
<property name="name">gSizer1</property>
<property name="permission">none</property>
<property name="rows">4</property>
<property name="vgap">0</property>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxCheckBox" expanded="1">
<property name="bg"></property>
<property name="checked">0</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Include Modules</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_Include_Modules</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnCheckBox">checkBoxClicked</event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxCheckBox" expanded="1">
<property name="bg"></property>
<property name="checked">0</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Include Texts on Copper Layers</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_Include_PcbTextes</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnCheckBox">checkBoxClicked</event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxCheckBox" expanded="1">
<property name="bg"></property>
<property name="checked">0</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Include Locked Modules</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_IncludeLockedModules</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnCheckBox">checkBoxClicked</event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxCheckBox" expanded="1">
<property name="bg"></property>
<property name="checked">0</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Include Drawings</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_Include_Draw_Items</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnCheckBox">checkBoxClicked</event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxCheckBox" expanded="1">
<property name="bg"></property>
<property name="checked">0</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Include Tracks</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_Include_Tracks</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnCheckBox">checkBoxClicked</event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxCheckBox" expanded="1">
<property name="bg"></property>
<property name="checked">0</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Include Board Outline Layer</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_Include_Edges_Items</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnCheckBox">checkBoxClicked</event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxCheckBox" expanded="1">
<property name="bg"></property>
<property name="checked">0</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Include Zones</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_Include_Zones</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnCheckBox">checkBoxClicked</event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALL</property>
<property name="proportion">0</property>
<object class="wxCheckBox" expanded="1">
<property name="bg"></property>
<property name="checked">0</property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="label">Draw Block Items while Moving</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_DrawBlockItems</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style"></property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnCheckBox">checkBoxClicked</event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxEXPAND | wxALL</property>
<property name="proportion">0</property>
<object class="wxStaticLine" expanded="1">
<property name="bg"></property>
<property name="context_help"></property>
<property name="context_menu">1</property>
<property name="enabled">1</property>
<property name="fg"></property>
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_staticline1</property>
<property name="permission">protected</property>
<property name="pos"></property>
<property name="size"></property>
<property name="style">wxLI_HORIZONTAL</property>
<property name="subclass"></property>
<property name="tooltip"></property>
<property name="validator_data_type"></property>
<property name="validator_style">wxFILTER_NONE</property>
<property name="validator_type">wxDefaultValidator</property>
<property name="validator_variable"></property>
<property name="window_extra_style"></property>
<property name="window_name"></property>
<property name="window_style"></property>
<event name="OnChar"></event>
<event name="OnEnterWindow"></event>
<event name="OnEraseBackground"></event>
<event name="OnKeyDown"></event>
<event name="OnKeyUp"></event>
<event name="OnKillFocus"></event>
<event name="OnLeaveWindow"></event>
<event name="OnLeftDClick"></event>
<event name="OnLeftDown"></event>
<event name="OnLeftUp"></event>
<event name="OnMiddleDClick"></event>
<event name="OnMiddleDown"></event>
<event name="OnMiddleUp"></event>
<event name="OnMotion"></event>
<event name="OnMouseEvents"></event>
<event name="OnMouseWheel"></event>
<event name="OnPaint"></event>
<event name="OnRightDClick"></event>
<event name="OnRightDown"></event>
<event name="OnRightUp"></event>
<event name="OnSetFocus"></event>
<event name="OnSize"></event>
<event name="OnUpdateUI"></event>
</object>
</object>
<object class="sizeritem" expanded="1">
<property name="border">5</property>
<property name="flag">wxALIGN_RIGHT|wxALL</property>
<property name="proportion">0</property>
<object class="wxStdDialogButtonSizer" expanded="1">
<property name="Apply">0</property>
<property name="Cancel">1</property>
<property name="ContextHelp">0</property>
<property name="Help">0</property>
<property name="No">0</property>
<property name="OK">1</property>
<property name="Save">0</property>
<property name="Yes">0</property>
<property name="minimum_size"></property>
<property name="name">m_sdbSizer1</property>
<property name="permission">protected</property>
<event name="OnApplyButtonClick"></event>
<event name="OnCancelButtonClick">OnCancel</event>
<event name="OnContextHelpButtonClick"></event>
<event name="OnHelpButtonClick"></event>
<event name="OnNoButtonClick"></event>
<event name="OnOKButtonClick">ExecuteCommand</event>
<event name="OnSaveButtonClick"></event>
<event name="OnYesButtonClick"></event>
</object>
</object>
</object>
</object>
</object>
</wxFormBuilder_Project>

View File

@ -0,0 +1,61 @@
///////////////////////////////////////////////////////////////////////////
// C++ code generated with wxFormBuilder (version Sep 8 2010)
// http://www.wxformbuilder.org/
//
// PLEASE DO "NOT" EDIT THIS FILE!
///////////////////////////////////////////////////////////////////////////
#ifndef __dialog_block_options_base__
#define __dialog_block_options_base__
#include <wx/intl.h>
#include <wx/string.h>
#include <wx/checkbox.h>
#include <wx/gdicmn.h>
#include <wx/font.h>
#include <wx/colour.h>
#include <wx/settings.h>
#include <wx/sizer.h>
#include <wx/statline.h>
#include <wx/button.h>
#include <wx/dialog.h>
///////////////////////////////////////////////////////////////////////////
///////////////////////////////////////////////////////////////////////////////
/// Class DIALOG_BLOCK_OPTIONS_BASE
///////////////////////////////////////////////////////////////////////////////
class DIALOG_BLOCK_OPTIONS_BASE : public wxDialog
{
private:
protected:
wxCheckBox* m_Include_Modules;
wxCheckBox* m_Include_PcbTextes;
wxCheckBox* m_IncludeLockedModules;
wxCheckBox* m_Include_Draw_Items;
wxCheckBox* m_Include_Tracks;
wxCheckBox* m_Include_Edges_Items;
wxCheckBox* m_Include_Zones;
wxCheckBox* m_DrawBlockItems;
wxStaticLine* m_staticline1;
wxStdDialogButtonSizer* m_sdbSizer1;
wxButton* m_sdbSizer1OK;
wxButton* m_sdbSizer1Cancel;
// Virtual event handlers, overide them in your derived class
virtual void checkBoxClicked( wxCommandEvent& event ) { event.Skip(); }
virtual void OnCancel( wxCommandEvent& event ) { event.Skip(); }
virtual void ExecuteCommand( wxCommandEvent& event ) { event.Skip(); }
public:
DIALOG_BLOCK_OPTIONS_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = wxEmptyString, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 397,171 ), long style = wxDEFAULT_DIALOG_STYLE );
~DIALOG_BLOCK_OPTIONS_BASE();
};
#endif //__dialog_block_options_base__

View File

@ -67,8 +67,8 @@ void WinEDA_BasePcbFrame::Plot_Serigraphie( PLOTTER* plotter,
/* Plot pads (creates pads outlines, for pads on silkscreen layers) */
int layersmask_plotpads = masque_layer;
// Calculate the mask layers of allowed layers for pads
if( !g_pcb_plot_options.PlotPadsOnSilkLayer )
layersmask_plotpads &= ~(SILKSCREEN_LAYER_BACK || SILKSCREEN_LAYER_FRONT);
if( !g_pcb_plot_options.PlotPadsOnSilkLayer ) // Do not plot pads on silk screen layers
layersmask_plotpads &= ~(SILKSCREEN_LAYER_BACK | SILKSCREEN_LAYER_FRONT );
if( layersmask_plotpads )
{
for( MODULE* Module = m_Pcb->m_Modules; Module; Module = Module->Next() )