Commit 44861f58 authored by Maciej Suminski's avatar Maciej Suminski

Fixed tracks of 0 width causing division by 0 error.

parent 15bfac3f
...@@ -763,9 +763,9 @@ void TRACK::ViewGetLayers( int aLayers[], int& aCount ) const ...@@ -763,9 +763,9 @@ void TRACK::ViewGetLayers( int aLayers[], int& aCount ) const
unsigned int TRACK::ViewGetLOD( int aLayer ) const unsigned int TRACK::ViewGetLOD( int aLayer ) const
{ {
// Netnames will be shown only if zoom is appropriate // Netnames will be shown only if zoom is appropriate
if( aLayer == GetNetnameLayer( GetLayer() ) ) if( aLayer == ITEM_GAL_LAYER( TRACK_NETNAMES_VISIBLE ) )
{ {
return ( 20000000 / m_Width ); return ( 20000000 / ( m_Width + 1 ) );
} }
// Other layers are shown without any conditions // Other layers are shown without any conditions
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment