diff options
| author | Vaxry <43317083+vaxerski@users.noreply.github.com> | 2025-08-28 11:20:29 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-08-28 11:20:29 +0200 |
| commit | 81bf4eccba449bfe2b6adfb51260108aec710d4f (patch) | |
| tree | 215c5b536cbcf1df9888081aadd3de16eb4b3ebe /src/events/Windows.cpp | |
| parent | 378e130f1426648d8d734049800128f9882805bf (diff) | |
input: Add fully configurable trackpad gestures (#11490)
Adds configurable trackpad gestures
Diffstat (limited to 'src/events/Windows.cpp')
| -rw-r--r-- | src/events/Windows.cpp | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/src/events/Windows.cpp b/src/events/Windows.cpp index 37982458..7d3eb3eb 100644 --- a/src/events/Windows.cpp +++ b/src/events/Windows.cpp @@ -15,12 +15,13 @@ #include "../protocols/ToplevelExport.hpp" #include "../protocols/types/ContentType.hpp" #include "../xwayland/XSurface.hpp" -#include "managers/AnimationManager.hpp" +#include "managers/animation/AnimationManager.hpp" +#include "managers/animation/DesktopAnimationManager.hpp" #include "managers/PointerManager.hpp" #include "../desktop/LayerSurface.hpp" #include "../managers/LayoutManager.hpp" #include "../managers/EventManager.hpp" -#include "../managers/AnimationManager.hpp" +#include "../managers/animation/AnimationManager.hpp" #include <hyprutils/string/String.hpp> using namespace Hyprutils::String; @@ -688,9 +689,7 @@ void Events::listener_mapWindow(void* owner, void* data) { g_pLayoutManager->getCurrentLayout()->recalculateWindow(PWINDOW); // do animations - g_pAnimationManager->onWindowPostCreateClose(PWINDOW, false); - PWINDOW->m_alpha->setValueAndWarp(0.f); - *PWINDOW->m_alpha = 1.f; + g_pDesktopAnimationManager->startAnimation(PWINDOW, CDesktopAnimationManager::ANIMATION_TYPE_IN); PWINDOW->m_realPosition->setCallbackOnEnd(setVector2DAnimToMove); PWINDOW->m_realSize->setCallbackOnEnd(setVector2DAnimToMove); @@ -838,11 +837,10 @@ void Events::listener_unmapWindow(void* owner, void* data) { g_pCompositor->addToFadingOutSafe(PWINDOW); if (!PWINDOW->m_X11DoesntWantBorders) // don't animate out if they weren't animated in. - *PWINDOW->m_realPosition = PWINDOW->m_realPosition->value() + Vector2D(0.01f, 0.01f); // it has to be animated, otherwise onWindowPostCreateClose will ignore it + *PWINDOW->m_realPosition = PWINDOW->m_realPosition->value() + Vector2D(0.01f, 0.01f); // it has to be animated, otherwise CesktopAnimationManager will ignore it // anims - g_pAnimationManager->onWindowPostCreateClose(PWINDOW, true); - *PWINDOW->m_alpha = 0.f; + g_pDesktopAnimationManager->startAnimation(PWINDOW, CDesktopAnimationManager::ANIMATION_TYPE_OUT); // recheck idle inhibitors g_pInputManager->recheckIdleInhibitorStatus(); |
