Skip to content

Commit 9ae7c94

Browse files
committed
Use zoom to mouse by default. Fixes #5054
1 parent 3bfbb59 commit 9ae7c94

File tree

4 files changed

+5
-5
lines changed

4 files changed

+5
-5
lines changed

src/app/qgisapp.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1719,7 +1719,7 @@ void QgisApp::createOverview()
17191719
mMapCanvas->enableAntiAliasing( mySettings.value( "/qgis/enable_anti_aliasing", true ).toBool() );
17201720
mMapCanvas->useImageToRender( mySettings.value( "/qgis/use_qimage_to_render", true ).toBool() );
17211721

1722-
int action = mySettings.value( "/qgis/wheel_action", 0 ).toInt();
1722+
int action = mySettings.value( "/qgis/wheel_action", 2 ).toInt();
17231723
double zoomFactor = mySettings.value( "/qgis/zoom_factor", 2 ).toDouble();
17241724
mMapCanvas->setWheelAction(( QgsMapCanvas::WheelAction ) action, zoomFactor );
17251725
}
@@ -4877,7 +4877,7 @@ void QgisApp::options()
48774877
mMapCanvas->enableAntiAliasing( mySettings.value( "/qgis/enable_anti_aliasing" ).toBool() );
48784878
mMapCanvas->useImageToRender( mySettings.value( "/qgis/use_qimage_to_render" ).toBool() );
48794879

4880-
int action = mySettings.value( "/qgis/wheel_action", 0 ).toInt();
4880+
int action = mySettings.value( "/qgis/wheel_action", 2 ).toInt();
48814881
double zoomFactor = mySettings.value( "/qgis/zoom_factor", 2 ).toDouble();
48824882
mMapCanvas->setWheelAction(( QgsMapCanvas::WheelAction ) action, zoomFactor );
48834883

src/app/qgsoptions.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,7 @@ QgsOptions::QgsOptions( QWidget *parent, Qt::WFlags fl ) :
339339
chbAskToSaveProjectChanges->setChecked( settings.value( "qgis/askToSaveProjectChanges", QVariant( true ) ).toBool() );
340340
chbWarnOldProjectVersion->setChecked( settings.value( "/qgis/warnOldProjectVersion", QVariant( true ) ).toBool() );
341341

342-
cmbWheelAction->setCurrentIndex( settings.value( "/qgis/wheel_action", 0 ).toInt() );
342+
cmbWheelAction->setCurrentIndex( settings.value( "/qgis/wheel_action", 2 ).toInt() );
343343
spinZoomFactor->setValue( settings.value( "/qgis/zoom_factor", 2 ).toDouble() );
344344

345345
//

src/core/composer/qgscomposermap.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -431,7 +431,7 @@ void QgsComposerMap::zoomContent( int delta, double x, double y )
431431

432432
//read zoom mode
433433
//0: zoom, 1: zoom and recenter, 2: zoom to cursor, 3: nothing
434-
int zoomMode = settings.value( "/qgis/wheel_action", 0 ).toInt();
434+
int zoomMode = settings.value( "/qgis/wheel_action", 2 ).toInt();
435435
if ( zoomMode == 3 ) //do nothing
436436
{
437437
return;

src/plugins/georeferencer/qgsgeorefplugingui.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -921,7 +921,7 @@ void QgsGeorefPluginGui::createMapCanvas()
921921
this, SLOT( releasePoint( const QPoint & ) ) );
922922

923923
QSettings s;
924-
int action = s.value( "/qgis/wheel_action", 0 ).toInt();
924+
int action = s.value( "/qgis/wheel_action", 2 ).toInt();
925925
double zoomFactor = s.value( "/qgis/zoom_factor", 2 ).toDouble();
926926
mCanvas->setWheelAction(( QgsMapCanvas::WheelAction ) action, zoomFactor );
927927

0 commit comments

Comments
 (0)