Moved bottom netnames layer over bottom tracks & pads. Changed int to LAYER_NUM where applicable.

This commit is contained in:
Maciej Suminski 2013-07-16 15:45:21 +02:00
parent fef47b0b67
commit aa6a5ab671
2 changed files with 8 additions and 6 deletions

View File

@ -254,7 +254,7 @@ enum PCB_VISIBLE
/// Rendering order of layers on GAL-based canvas (lower index in the array
/// means that layer is displayed closer to the user, ie. on the top).
const int GalLayerOrder[] =
const LAYER_NUM GalLayerOrder[] =
{
DRAW_N, COMMENT_N, ECO1_N, ECO2_N, EDGE_N,
UNUSED_LAYER_29, UNUSED_LAYER_30, UNUSED_LAYER_31,
@ -282,8 +282,8 @@ const int GalLayerOrder[] =
ITEM_GAL_LAYER( LAYER_4_NETNAMES_VISIBLE ), LAYER_N_4,
ITEM_GAL_LAYER( LAYER_3_NETNAMES_VISIBLE ), LAYER_N_3,
ITEM_GAL_LAYER( LAYER_2_NETNAMES_VISIBLE ), LAYER_N_2,
ITEM_GAL_LAYER( LAYER_1_NETNAMES_VISIBLE ), LAYER_N_BACK,
ITEM_GAL_LAYER( PAD_BK_NETNAMES_VISIBLE ), ITEM_GAL_LAYER( PAD_BK_VISIBLE ),
ITEM_GAL_LAYER( LAYER_1_NETNAMES_VISIBLE ), LAYER_N_BACK,
SOLDERMASK_N_BACK, ADHESIVE_N_BACK, SOLDERPASTE_N_BACK, SILKSCREEN_N_BACK,
ITEM_GAL_LAYER( MOD_TEXT_BK_VISIBLE )

View File

@ -196,8 +196,10 @@ void PCB_BASE_FRAME::SetBoard( BOARD* aBoard )
}
// Set rendering order of layers
for( unsigned int i = 0; i < sizeof( GalLayerOrder ) / sizeof( int ); ++i )
for( LAYER_NUM i = 0; i < sizeof(GalLayerOrder) / sizeof(LAYER_NUM); ++i )
{
wxASSERT( i < KiGfx::VIEW::VIEW_MAX_LAYERS );
view->SetLayerOrder( GalLayerOrder[i], i );
}
@ -209,12 +211,12 @@ void PCB_BASE_FRAME::SetBoard( BOARD* aBoard )
}
// Load layer & elements visibility settings
for( unsigned int i = 0; i < NB_LAYERS; ++i )
for( LAYER_NUM i = 0; i < NB_LAYERS; ++i )
{
view->SetLayerVisible( i, m_Pcb->IsLayerVisible( i ) );
}
for( unsigned int i = 0; i < END_PCB_VISIBLE_LIST; ++i )
for( LAYER_NUM i = 0; i < END_PCB_VISIBLE_LIST; ++i )
{
view->SetLayerVisible( ITEM_GAL_LAYER( i ), m_Pcb->IsElementVisible( i ) );
}