Skip to content

Commit

Permalink
[BUGFIX] fixes #20829 Snapping options in meters rounded to integers
Browse files Browse the repository at this point in the history
  • Loading branch information
lbartoletti authored and nyalldawson committed Feb 20, 2019
1 parent f071030 commit 50c9b23
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/app/qgssnappingwidget.cpp
Expand Up @@ -350,14 +350,14 @@ void QgsSnappingWidget::projectSnapSettingsChanged()
mTypeButton->setDefaultAction( mSegmentAction ); mTypeButton->setDefaultAction( mSegmentAction );
} }


if ( mToleranceSpinBox->value() != config.tolerance() ) if ( static_cast<QgsTolerance::UnitType>( mUnitsComboBox->currentData().toInt() ) != config.units() )
{ {
mToleranceSpinBox->setValue( config.tolerance() ); mUnitsComboBox->setCurrentIndex( mUnitsComboBox->findData( config.units() ) );
} }


if ( static_cast<QgsTolerance::UnitType>( mUnitsComboBox->currentData().toInt() ) != config.units() ) if ( mToleranceSpinBox->value() != config.tolerance() )
{ {
mUnitsComboBox->setCurrentIndex( mUnitsComboBox->findData( config.units() ) ); mToleranceSpinBox->setValue( config.tolerance() );
} }


if ( config.intersectionSnapping() != mIntersectionSnappingAction->isChecked() ) if ( config.intersectionSnapping() != mIntersectionSnappingAction->isChecked() )
Expand Down

0 comments on commit 50c9b23

Please sign in to comment.