Use DP netclass values when custom or predefined are not selected.
Fixes: lp:1780670 * https://bugs.launchpad.net/kicad/+bug/1780670
This commit is contained in:
parent
8999f4604f
commit
9c708c6177
|
@ -298,6 +298,15 @@ public:
|
|||
return ( m_viaSizeIndex == 0 && !m_useCustomTrackVia );
|
||||
}
|
||||
|
||||
/**
|
||||
* Function UseNetClassDiffPair
|
||||
* returns true if netclass values should be used to obtain appropriate diff pair dimensions.
|
||||
*/
|
||||
inline bool UseNetClassDiffPair() const
|
||||
{
|
||||
return ( m_diffPairIndex == 0 && !m_useCustomDiffPair );
|
||||
}
|
||||
|
||||
/**
|
||||
* Function SetCurrentNetClass
|
||||
* Must be called after a netclass selection (or after a netclass parameter change
|
||||
|
|
|
@ -124,7 +124,13 @@ void SIZES_SETTINGS::Init( BOARD* aBoard, ITEM* aStartItem, int aNet )
|
|||
m_viaDrill = bds.GetCurrentViaDrill();
|
||||
}
|
||||
|
||||
if( bds.UseCustomDiffPairDimensions() )
|
||||
if( bds.UseNetClassDiffPair() && netClass != NULL )
|
||||
{
|
||||
m_diffPairWidth = netClass->GetDiffPairWidth();
|
||||
m_diffPairGap = netClass->GetDiffPairGap();
|
||||
m_diffPairViaGap = netClass->GetDiffPairViaGap();
|
||||
}
|
||||
else if( bds.UseCustomDiffPairDimensions() )
|
||||
{
|
||||
m_diffPairWidth = bds.GetCustomDiffPairWidth();
|
||||
m_diffPairGap = bds.GetCustomDiffPairGap();
|
||||
|
|
Loading…
Reference in New Issue