Skip to content

Commit

Permalink
[delimited] Don't reset geometry type from "No geometry" when
Browse files Browse the repository at this point in the history
changing other settings

Fixes #17971
  • Loading branch information
nyalldawson committed Feb 9, 2018
1 parent 9da5fd3 commit f340eec
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions src/providers/delimitedtext/qgsdelimitedtextsourceselect.cpp
Expand Up @@ -539,11 +539,14 @@ void QgsDelimitedTextSourceSelect::updateFieldLists()

bool haveFields = fieldNo > 0;

bool isXY = cmbWktField->currentIndex() < 0 ||
( geomTypeXY->isChecked() &&
( cmbXField->currentIndex() >= 0 && cmbYField->currentIndex() >= 0 ) );
geomTypeXY->setChecked( isXY );
geomTypeWKT->setChecked( ! isXY );
if ( !geomTypeNone->isChecked() )
{
bool isXY = cmbWktField->currentIndex() < 0 ||
( geomTypeXY->isChecked() &&
( cmbXField->currentIndex() >= 0 && cmbYField->currentIndex() >= 0 ) );
geomTypeXY->setChecked( isXY );
geomTypeWKT->setChecked( ! isXY );
}
swGeomType->setCurrentIndex( bgGeomType->checkedId() );

if ( haveFields )
Expand Down

0 comments on commit f340eec

Please sign in to comment.