summaryrefslogtreecommitdiff
path: root/src/managers/AnimationManager.cpp
diff options
context:
space:
mode:
authorvaxerski <43317083+vaxerski@users.noreply.github.com>2022-05-14 17:23:46 +0200
committervaxerski <43317083+vaxerski@users.noreply.github.com>2022-05-14 17:23:46 +0200
commit109136af97547f35f767dae2e7908ab218dfea11 (patch)
tree806d931d2a3d7d04a9a5faecfcf46d5470f1633f /src/managers/AnimationManager.cpp
parent694f4433a2b6083cef5a4f43e974f9c70b9857af (diff)
Fadein/out now applies to layersurfaces too
Diffstat (limited to 'src/managers/AnimationManager.cpp')
-rw-r--r--src/managers/AnimationManager.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/managers/AnimationManager.cpp b/src/managers/AnimationManager.cpp
index a881b7d1..686d80dd 100644
--- a/src/managers/AnimationManager.cpp
+++ b/src/managers/AnimationManager.cpp
@@ -41,12 +41,16 @@ void CAnimationManager::tick() {
// window stuff
const auto PWINDOW = (CWindow*)av->m_pWindow;
const auto PWORKSPACE = (CWorkspace*)av->m_pWorkspace;
+ const auto PLAYER = (SLayerSurface*)av->m_pLayer;
+
wlr_box WLRBOXPREV = {0,0,0,0};
if (PWINDOW) {
WLRBOXPREV = {(int)PWINDOW->m_vRealPosition.vec().x - BORDERSIZE - 1, (int)PWINDOW->m_vRealPosition.vec().y - BORDERSIZE - 1, (int)PWINDOW->m_vRealSize.vec().x + 2 * BORDERSIZE + 2, (int)PWINDOW->m_vRealSize.vec().y + 2 * BORDERSIZE + 2};
} else if (PWORKSPACE) {
const auto PMONITOR = g_pCompositor->getMonitorFromID(PWORKSPACE->m_iMonitorID);
WLRBOXPREV = {(int)PMONITOR->vecPosition.x, (int)PMONITOR->vecPosition.y, (int)PMONITOR->vecSize.x, (int)PMONITOR->vecSize.y};
+ } else if (PLAYER) {
+ WLRBOXPREV = PLAYER->geometry;
}
// check if it's disabled, if so, warp