Separate copper and graphical zone tools
Previously zone drawing tool was used to draw copper and graphical polygons, but now there is a dedicated tool for that.
This commit is contained in:
parent
dd97718a50
commit
fea71c9f8f
|
@ -61,9 +61,12 @@ std::unique_ptr<ZONE_CONTAINER> ZONE_CREATE_HELPER::createNewZone( bool aKeepout
|
|||
|
||||
// Get the current default settings for zones
|
||||
ZONE_SETTINGS zoneInfo = frame.GetZoneSettings();
|
||||
zoneInfo.m_CurrentZone_Layer = frame.GetScreen()->m_Active_Layer;
|
||||
zoneInfo.m_NetcodeSelection = board.GetHighLightNetCode();
|
||||
zoneInfo.SetIsKeepout( m_params.m_keepout );
|
||||
zoneInfo.m_CurrentZone_Layer = frame.GetScreen()->m_Active_Layer;
|
||||
|
||||
if( !IsCopperLayer( zoneInfo.m_CurrentZone_Layer ) )
|
||||
zoneInfo.m_CurrentZone_Layer = F_Cu;
|
||||
|
||||
if ( m_params.m_mode != DRAWING_TOOL::ZONE_MODE::GRAPHIC_POLYGON )
|
||||
{
|
||||
|
@ -75,17 +78,10 @@ std::unique_ptr<ZONE_CONTAINER> ZONE_CREATE_HELPER::createNewZone( bool aKeepout
|
|||
if( m_params.m_keepout )
|
||||
dialogResult = InvokeKeepoutAreaEditor( &frame, &zoneInfo );
|
||||
else
|
||||
{
|
||||
if( IsCopperLayer( zoneInfo.m_CurrentZone_Layer ) )
|
||||
dialogResult = InvokeCopperZonesEditor( &frame, &zoneInfo );
|
||||
else
|
||||
dialogResult = InvokeNonCopperZonesEditor( &frame, nullptr, &zoneInfo );
|
||||
}
|
||||
dialogResult = InvokeCopperZonesEditor( &frame, &zoneInfo );
|
||||
|
||||
if( dialogResult == ZONE_ABORT )
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
}
|
||||
|
||||
auto newZone = std::make_unique<ZONE_CONTAINER>( &board );
|
||||
|
|
Loading…
Reference in New Issue