Make offset-zone check multi-layer aware.
Fixes https://gitlab.com/kicad/code/kicad/-/issues/15916
(cherry picked from commit b97d8ddef4
)
This commit is contained in:
parent
eb7929ccb6
commit
5a51a6b179
|
@ -1428,9 +1428,7 @@ int BOARD_EDITOR_CONTROL::ZoneDuplicate( const TOOL_EVENT& aEvent )
|
|||
|
||||
// If the new zone is on the same layer(s) as the initial zone,
|
||||
// offset it a bit so it can more easily be picked.
|
||||
if( oldZone->GetIsRuleArea() && ( oldZone->GetLayerSet() == zoneSettings.m_Layers ) )
|
||||
newZone->Move( wxPoint( pcbIUScale.IU_PER_MM, pcbIUScale.IU_PER_MM ) );
|
||||
else if( !oldZone->GetIsRuleArea() && zoneSettings.m_Layers.test( oldZone->GetLayer() ) )
|
||||
if( oldZone->GetLayerSet() == zoneSettings.m_Layers )
|
||||
newZone->Move( wxPoint( pcbIUScale.IU_PER_MM, pcbIUScale.IU_PER_MM ) );
|
||||
|
||||
commit.Add( newZone.release() );
|
||||
|
|
Loading…
Reference in New Issue