Fix some layer id enum colliding warnings
C++20 under MSVC does not like seeing enum values between two enums getting operated on. static cast to int fixes it for what we are trying to do anyway
This commit is contained in:
parent
b2115445cc
commit
5e3396561d
|
@ -85,7 +85,7 @@ void GERBVIEW_PRINTOUT::setupViewLayers( KIGFX::VIEW& aView, const LSET& aLayerS
|
|||
BOARD_PRINTOUT::setupViewLayers( aView, aLayerSet );
|
||||
|
||||
for( LSEQ layerSeq = m_settings.m_LayerSet.Seq(); layerSeq; ++layerSeq )
|
||||
aView.SetLayerVisible( GERBVIEW_LAYER_ID_START + *layerSeq, true );
|
||||
aView.SetLayerVisible( static_cast<int>( GERBVIEW_LAYER_ID_START ) + *layerSeq, true );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
@ -173,7 +173,7 @@ enum NETNAMES_LAYER_ID: int
|
|||
};
|
||||
|
||||
/// Macro for obtaining netname layer for a given PCB layer
|
||||
#define NETNAMES_LAYER_INDEX( layer ) ( NETNAMES_LAYER_ID_START + layer )
|
||||
#define NETNAMES_LAYER_INDEX( layer ) ( static_cast<int>( NETNAMES_LAYER_ID_START ) + layer )
|
||||
|
||||
#define GAL_UI_LAYER_COUNT 10
|
||||
|
||||
|
@ -414,7 +414,7 @@ inline SCH_LAYER_ID operator++( SCH_LAYER_ID& a )
|
|||
}
|
||||
|
||||
// number of draw layers in Gerbview
|
||||
#define GERBER_DRAWLAYERS_COUNT PCB_LAYER_ID_COUNT
|
||||
#define GERBER_DRAWLAYERS_COUNT static_cast<int>( PCB_LAYER_ID_COUNT )
|
||||
|
||||
/// GerbView draw layers
|
||||
enum GERBVIEW_LAYER_ID: int
|
||||
|
|
Loading…
Reference in New Issue