Fix calculation of selection center

Fixes https://gitlab.com/kicad/code/kicad/issues/9998
This commit is contained in:
Mikolaj Wielgus 2021-12-16 08:13:14 +01:00
parent 1610195a09
commit 2ecd5ac909
1 changed files with 1 additions and 1 deletions

View File

@ -95,7 +95,7 @@ VECTOR2I SELECTION::GetCenter() const
for( EDA_ITEM* item : m_items )
center += item->GetPosition();
center = center / static_cast<unsigned>( m_items.size() );
center = center / static_cast<int>( m_items.size() );
return static_cast<VECTOR2I>( center );
}