PCBNEW favored module placed on OPPOSITE side selected layer become.
Now it select module from selected side if present. Especially handy in contrast view.
This commit is contained in:
parent
32526511de
commit
443b4a6fe1
|
@ -55,7 +55,8 @@ extern bool Magnetize( BOARD* m_Pcb, PCB_EDIT_FRAME* frame,
|
|||
*/
|
||||
static BOARD_ITEM* AllAreModulesAndReturnSmallestIfSo( GENERAL_COLLECTOR* aCollector )
|
||||
{
|
||||
int count = aCollector->GetCount();
|
||||
int count = aCollector->GetPrimaryCount(); // try to use preferred layer
|
||||
if( 0 == count ) count = aCollector->GetCount();
|
||||
|
||||
for( int i = 0; i<count; ++i )
|
||||
{
|
||||
|
@ -77,7 +78,7 @@ static BOARD_ITEM* AllAreModulesAndReturnSmallestIfSo( GENERAL_COLLECTOR* aColle
|
|||
|
||||
int lmin = MIN( lx, ly );
|
||||
|
||||
if( lmin <= minDim )
|
||||
if( lmin < minDim )
|
||||
{
|
||||
minDim = lmin;
|
||||
minNdx = i;
|
||||
|
|
Loading…
Reference in New Issue