Skip to content

Commit

Permalink
If user clicks cancel while browsing for file then don't clear
Browse files Browse the repository at this point in the history
the existing filename in the vector open file dialog
  • Loading branch information
nyalldawson committed Aug 10, 2015
1 parent b426162 commit 1a91ae8
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/app/ogr/qgsopenvectorlayerdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -271,7 +271,9 @@ void QgsOpenVectorLayerDialog::on_buttonSelectSrc_clicked()
{
if ( radioSrcFile->isChecked() )
{
inputSrcDataset->setText( openFile().join( ";" ) );
QStringList selected = openFile();
if ( selected.count() > 0 )
inputSrcDataset->setText( selected.join( ";" ) );
}
else if ( radioSrcDirectory->isChecked() )
{
Expand Down

0 comments on commit 1a91ae8

Please sign in to comment.