diff --git a/pcbnew/pcb_layer_box_selector.cpp b/pcbnew/pcb_layer_box_selector.cpp index b2428f2df7..cf7f729e08 100644 --- a/pcbnew/pcb_layer_box_selector.cpp +++ b/pcbnew/pcb_layer_box_selector.cpp @@ -150,7 +150,7 @@ COLOR4D PCB_LAYER_BOX_SELECTOR::GetLayerColor( LAYER_NUM aLayer ) const { wxASSERT( m_boardFrame ); - return m_boardFrame->Settings().Colors().GetLayerColor( ToLAYER_ID( aLayer ) ); + return m_boardFrame->Settings().Colors().GetLayerColor( aLayer ); } diff --git a/pcbnew/pcb_layer_widget.cpp b/pcbnew/pcb_layer_widget.cpp index 2142e38349..ffcdd796d0 100644 --- a/pcbnew/pcb_layer_widget.cpp +++ b/pcbnew/pcb_layer_widget.cpp @@ -584,11 +584,11 @@ void PCB_LAYER_WIDGET::OnLayerColorChange( int aLayer, COLOR4D aColor ) // destroys the GAL color setup if( !myframe->IsGalCanvasActive() ) { - COLOR4D oldColor = myframe->Settings().Colors().GetLayerColor( ToLAYER_ID( aLayer ) ); + COLOR4D oldColor = myframe->Settings().Colors().GetLayerColor( aLayer ); aColor.a = oldColor.a; } - myframe->Settings().Colors().SetLayerColor( ToLAYER_ID( aLayer ), aColor ); + myframe->Settings().Colors().SetLayerColor( aLayer, aColor ); if( myframe->IsGalCanvasActive() ) { diff --git a/pcbnew/plot_brditems_plotter.cpp b/pcbnew/plot_brditems_plotter.cpp index 3c3316982a..b3ba678290 100644 --- a/pcbnew/plot_brditems_plotter.cpp +++ b/pcbnew/plot_brditems_plotter.cpp @@ -56,7 +56,7 @@ COLOR4D BRDITEMS_PLOTTER::getColor( LAYER_NUM aLayer ) { - COLOR4D color = m_board->Colors().GetLayerColor( ToLAYER_ID( aLayer ) ); + COLOR4D color = m_board->Colors().GetLayerColor( aLayer ); // A hack to avoid plotting ahite itmen in white color, expecting the paper // is also white: use a non white color: diff --git a/pcbnew/sel_layer.cpp b/pcbnew/sel_layer.cpp index 312013a1da..5fc59ec35a 100644 --- a/pcbnew/sel_layer.cpp +++ b/pcbnew/sel_layer.cpp @@ -61,7 +61,7 @@ protected: // Virtual function COLOR4D GetLayerColor( LAYER_NUM aLayer ) const override { - return m_frame->Settings().Colors().GetLayerColor( ToLAYER_ID( aLayer ) ); + return m_frame->Settings().Colors().GetLayerColor( aLayer ); } // Returns the name of the layer id