From bc6ed9590d18359a4ce9886b44a60632c19ad1e6 Mon Sep 17 00:00:00 2001 From: uclaros Date: Sat, 19 Sep 2020 21:43:06 +0300 Subject: [PATCH] Extend extent history to 100 entries --- src/gui/qgsmapcanvas.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/gui/qgsmapcanvas.cpp b/src/gui/qgsmapcanvas.cpp index dab5ff0c425..6156c812e91 100644 --- a/src/gui/qgsmapcanvas.cpp +++ b/src/gui/qgsmapcanvas.cpp @@ -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 ); }