Skip to content

Commit

Permalink
fix: center selected item in CRS selection
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk@15452 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
jef committed Mar 12, 2011
1 parent 242c315 commit c19e333
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions src/gui/qgsprojectionselector.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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
{
Expand Down Expand Up @@ -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
{
Expand All @@ -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
{
Expand Down Expand Up @@ -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();
Expand Down

0 comments on commit c19e333

Please sign in to comment.