Skip to content

Commit

Permalink
Show selected CRS. Fix #5563
Browse files Browse the repository at this point in the history
  • Loading branch information
NathanW2 committed May 26, 2013
1 parent 6164ace commit 8cbf901
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 19 deletions.
4 changes: 4 additions & 0 deletions src/gui/qgsprojectionselector.cpp
Expand Up @@ -273,6 +273,7 @@ void QgsProjectionSelector::applySelection( int column, QString value )
lstCoordinateSystems->clearSelection();
lstRecent->clearSelection();
teProjection->setText( "" );
teSelected->setText( "" );
}
}

Expand Down Expand Up @@ -720,6 +721,7 @@ void QgsProjectionSelector::on_lstCoordinateSystems_currentItemChanged( QTreeWid
emit sridSelected( QString::number( selectedCrsId() ) );

teProjection->setText( selectedProj4String() );
teSelected->setText( selectedName() );

QList<QTreeWidgetItem*> nodes = lstRecent->findItems( current->text( QGIS_CRS_ID_COLUMN ), Qt::MatchExactly, QGIS_CRS_ID_COLUMN );
if ( nodes.count() > 0 )
Expand All @@ -739,6 +741,7 @@ void QgsProjectionSelector::on_lstCoordinateSystems_currentItemChanged( QTreeWid
// Not an CRS - remove the highlight so the user doesn't get too confused
current->setSelected( false );
teProjection->setText( "" );
teSelected->setText( "" );
lstRecent->clearSelection();
}
}
Expand Down Expand Up @@ -775,6 +778,7 @@ void QgsProjectionSelector::hideDeprecated( QTreeWidgetItem *item )
{
item->setSelected( false );
teProjection->setText( "" );
teSelected->setText( "" );
}
}

Expand Down
62 changes: 43 additions & 19 deletions src/ui/qgsprojectionselectorbase.ui
Expand Up @@ -25,33 +25,30 @@
</iconset>
</property>
<layout class="QGridLayout" name="gridLayout_2">
<item row="0" column="0">
<layout class="QHBoxLayout" name="horizontalLayout">
<item row="3" column="0">
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QLabel" name="label_5">
<widget class="QLabel" name="label">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>Filter</string>
<string>Selected CRS:</string>
</property>
</widget>
</item>
<item>
<widget class="QgsFilterLineEdit" name="leSearch"/>
<widget class="QLineEdit" name="teSelected">
<property name="readOnly">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>Recently used coordinate reference systems</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QSplitter" name="splitter">
<property name="orientation">
Expand Down Expand Up @@ -189,7 +186,34 @@
</widget>
</widget>
</item>
<item row="3" column="0">
<item row="0" column="0">
<layout class="QHBoxLayout" name="horizontalLayout">
<item>
<widget class="QLabel" name="label_5">
<property name="text">
<string>Filter</string>
</property>
</widget>
</item>
<item>
<widget class="QgsFilterLineEdit" name="leSearch"/>
</item>
</layout>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="font">
<font>
<weight>75</weight>
<bold>true</bold>
</font>
</property>
<property name="text">
<string>Recently used coordinate reference systems</string>
</property>
</widget>
</item>
<item row="6" column="0">
<widget class="QTextEdit" name="teProjection">
<property name="minimumSize">
<size>
Expand Down

0 comments on commit 8cbf901

Please sign in to comment.