Extend extent history to 100 entries

This commit is contained in:
uclaros 2020-09-19 21:43:06 +03:00 committed by Nyall Dawson
parent ae67b9e61e
commit bc6ed9590d

View File

@ -1090,8 +1090,6 @@ void QgsMapCanvas::setExtent( const QgsRectangle &r, bool magnified )
}
emit extentsChanged();
updateScale();
if ( mLastExtent.size() > 20 )
mLastExtent.removeAt( 0 );
//clear all extent items after current index
for ( int i = mLastExtent.size() - 1; i > mLastExtentIndex; i-- )
@ -1101,8 +1099,8 @@ void QgsMapCanvas::setExtent( const QgsRectangle &r, bool magnified )
mLastExtent.append( extent() );
// adjust history to no more than 20
if ( mLastExtent.size() > 20 )
// adjust history to no more than 100
if ( mLastExtent.size() > 100 )
{
mLastExtent.removeAt( 0 );
}