Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Better reference item to zoom to in modeler
cherry-pick 01e391e
  • Loading branch information
DelazJ authored and m-kuhn committed Dec 27, 2021
1 parent a5240a9 commit 58becc5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/gui/processing/models/qgsmodeldesignerdialog.cpp
Expand Up @@ -832,7 +832,7 @@ void QgsModelDesignerDialog::populateZoomToMenu()
QAction *zoomAction = new QAction( box.description(), mGroupMenu );
connect( zoomAction, &QAction::triggered, this, [ = ]
{
QRectF groupRect = item->boundingRect();
QRectF groupRect = item->mapToScene( item->boundingRect() ).boundingRect();
groupRect.adjust( -10, -10, 10, 10 );
mView->fitInView( groupRect, Qt::KeepAspectRatio );
mView->centerOn( item );
Expand Down

0 comments on commit 58becc5

Please sign in to comment.