From c19e333dd07e52418fd0e8592e48275ecced3e17 Mon Sep 17 00:00:00 2001 From: jef Date: Sat, 12 Mar 2011 18:57:10 +0000 Subject: [PATCH] fix: center selected item in CRS selection git-svn-id: http://svn.osgeo.org/qgis/trunk@15452 c8812cc2-4d05-0410-92ff-de0c093fc19c --- src/gui/qgsprojectionselector.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/gui/qgsprojectionselector.cpp b/src/gui/qgsprojectionselector.cpp index bf1a24ab4c95..1f61e186c39a 100644 --- a/src/gui/qgsprojectionselector.cpp +++ b/src/gui/qgsprojectionselector.cpp @@ -305,7 +305,6 @@ void QgsProjectionSelector::applyCRSNameSelection() if ( nodes.count() > 0 ) { lstCoordinateSystems->setCurrentItem( nodes.first() ); - lstCoordinateSystems->scrollToItem( nodes.first() ); } else // unselect the selected item to avoid confusing the user { @@ -344,7 +343,6 @@ void QgsProjectionSelector::applyAuthIDSelection() if ( nodes.count() > 0 ) { lstCoordinateSystems->setCurrentItem( nodes.first() ); - lstCoordinateSystems->scrollToItem( nodes.first() ); } else // unselect the selected item to avoid confusing the user { @@ -367,7 +365,6 @@ void QgsProjectionSelector::applyCRSIDSelection() if ( nodes.count() > 0 ) { lstCoordinateSystems->setCurrentItem( nodes.first() ); - lstCoordinateSystems->scrollToItem( nodes.first() ); } else // unselect the selected item to avoid confusing the user { @@ -851,7 +848,7 @@ void QgsProjectionSelector::coordinateSystemSelected( QTreeWidgetItem * theItem QString myDescription; emit sridSelected( QString::number( selectedCrsId() ) ); QString myProjString = selectedProj4String(); - lstCoordinateSystems->scrollToItem( theItem ); + lstCoordinateSystems->scrollToItem( theItem, QAbstractItemView::PositionAtCenter ); teProjection->setText( myProjString ); lstRecent->clearSelection();