Skip to content
Permalink
Browse files
Add comments to explain why r5618 only partly works as expected under…
… Qt 4.1.0 (i.e. the branches are expanded but the selected item is not scrolled into view).

git-svn-id: http://svn.osgeo.org/qgis/trunk@5626 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
morb_au committed Jul 24, 2006
1 parent 46fc648 commit eb4fc907c2e6e07b300bb9ac50f7d5631677620f
Showing with 15 additions and 0 deletions.
  1. +15 −0 src/widgets/projectionselector/qgsprojectionselector.cpp
@@ -203,6 +203,11 @@ void QgsProjectionSelector::applySRSNameSelection()
if (nodes.count() > 0)
{
lstCoordinateSystems->setCurrentItem(nodes.first());

// The following seems to be broken in Qt 4.1.0:
// It only works if the widget is already visible.
// (Which makes it really hard to scroll to an
// item before you exec() the widget)
lstCoordinateSystems->scrollToItem(nodes.first());
}
else // unselect the selected item to avoid confusing the user
@@ -230,6 +235,11 @@ void QgsProjectionSelector::applySRSIDSelection()
if (nodes.count() > 0)
{
lstCoordinateSystems->setCurrentItem(nodes.first());

// The following seems to be broken in Qt 4.1.0:
// It only works if the widget is already visible.
// (Which makes it really hard to scroll to an
// item before you exec() the widget)
lstCoordinateSystems->scrollToItem(nodes.first());
}
else // unselect the selected item to avoid confusing the user
@@ -784,6 +794,11 @@ void QgsProjectionSelector::coordinateSystemSelected( QTreeWidgetItem * theItem)
{
myDescription+=(myProjString);
}

// The following seems to be broken in Qt 4.1.0:
// It only works if the widget is already visible.
// (Which makes it really hard to scroll to an
// item before you exec() the widget)
lstCoordinateSystems->scrollToItem(theItem);
teProjection->setText(myDescription);
}

0 comments on commit eb4fc90

Please sign in to comment.