1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 11:18:11 +00:00

QuickShow: Add reset zoom action to toolbar

When zoom reset also reset pan origin
This commit is contained in:
Hüseyin ASLITÜRK 2020-06-15 11:17:56 +03:00 committed by Andreas Kling
parent bf3d98012a
commit ea1ebe8662
2 changed files with 5 additions and 1 deletions

View file

@ -127,6 +127,9 @@ void QSWidget::set_scale(int scale)
if (scale > 1000)
scale = 1000;
if (scale == 100)
m_pan_origin = { 0, 0 };
m_scale = scale;
relayout();
}