From 189a0c6e0d38a059546c86927ac36995087f8105 Mon Sep 17 00:00:00 2001 From: Ivan Savenko Date: Sat, 15 Jul 2023 13:05:06 +0300 Subject: [PATCH] Re-center map on active object after screen resize --- client/adventureMap/AdventureMapInterface.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/client/adventureMap/AdventureMapInterface.cpp b/client/adventureMap/AdventureMapInterface.cpp index 24242d2cc..7ee136edd 100644 --- a/client/adventureMap/AdventureMapInterface.cpp +++ b/client/adventureMap/AdventureMapInterface.cpp @@ -827,5 +827,8 @@ void AdventureMapInterface::onScreenResize() widget->getMinimap()->update(); widget->getInfoBar()->showSelection(); + if (LOCPLINT && LOCPLINT->localState->getCurrentArmy()) + widget->getMapView()->onCenteredObject(LOCPLINT->localState->getCurrentArmy()); + adjustActiveness(); }