Commit f53dafd4 authored by Maciej Suminski's avatar Maciej Suminski
Browse files

Modules are marked to be on copper layer too.

parent 3d0753c9
Loading
Loading
Loading
Loading
+2 −1
Original line number Original line Diff line number Diff line
@@ -1027,6 +1027,7 @@ void MODULE::SetOrientation( double newangle )


void MODULE::ViewGetLayers( int aLayers[], int& aCount ) const
void MODULE::ViewGetLayers( int aLayers[], int& aCount ) const
{
{
    aCount = 1;
    aCount = 2;
    aLayers[0] = ITEM_GAL_LAYER( SELECTION );     // Selection box
    aLayers[0] = ITEM_GAL_LAYER( SELECTION );     // Selection box
    aLayers[1] = m_Layer;
}
}
+7 −4
Original line number Original line Diff line number Diff line
@@ -229,7 +229,7 @@ bool PCB_PAINTER::Draw( const VIEW_ITEM* aItem, int aLayer )
        break;
        break;


    case PCB_MODULE_T:
    case PCB_MODULE_T:
        draw( (MODULE*) aItem );
        draw( (MODULE*) aItem, aLayer );
        break;
        break;


    case PCB_TEXT_T:
    case PCB_TEXT_T:
@@ -700,12 +700,15 @@ void PCB_PAINTER::draw( const DRAWSEGMENT* aSegment )
}
}




void PCB_PAINTER::draw( const MODULE* aModule )
void PCB_PAINTER::draw( const MODULE* aModule, int aLayer )
{
{
    // For modules we have to draw a selection box if needed
    // For modules we have to draw a selection box if needed
    if( aLayer == ITEM_GAL_LAYER( SELECTION ) )
    {
        if( aModule->IsSelected() )
        if( aModule->IsSelected() )
            drawSelectionBox( aModule );
            drawSelectionBox( aModule );
    }
    }
}




void PCB_PAINTER::draw( const TEXTE_PCB* aText, int aLayer )
void PCB_PAINTER::draw( const TEXTE_PCB* aText, int aLayer )
+1 −1
Original line number Original line Diff line number Diff line
@@ -145,7 +145,7 @@ protected:
    void draw( const SEGVIA*, int );
    void draw( const SEGVIA*, int );
    void draw( const D_PAD*, int );
    void draw( const D_PAD*, int );
    void draw( const DRAWSEGMENT* );
    void draw( const DRAWSEGMENT* );
    void draw( const MODULE* );
    void draw( const MODULE*, int );
    void draw( const TEXTE_PCB*, int );
    void draw( const TEXTE_PCB*, int );
    void draw( const TEXTE_MODULE*, int );
    void draw( const TEXTE_MODULE*, int );
    void draw( const ZONE_CONTAINER* );
    void draw( const ZONE_CONTAINER* );