Skip to content

Commit

Permalink
Do not add undo command if scale has not changed
Browse files Browse the repository at this point in the history
  • Loading branch information
wonder-sk committed Jun 18, 2014
1 parent 7cb2315 commit 045695a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/app/composer/qgscomposermapwidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,9 @@ void QgsComposerMapWidget::on_mScaleLineEdit_editingFinished()
return;
}

if ( qRound( scaleDenominator ) == qRound( mComposerMap->scale() ) )
return;

mComposerMap->beginCommand( tr( "Map scale changed" ) );
mComposerMap->setNewScale( scaleDenominator );
mComposerMap->endCommand();
Expand Down

0 comments on commit 045695a

Please sign in to comment.