layout: limit updates when mouse animate drag is enabled (#5838)

This commit is contained in:
thejch 2024-05-02 06:28:51 -07:00 committed by GitHub
parent 56de72f357
commit d0229d6e1e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -356,7 +356,7 @@ void IHyprLayout::onMouseMove(const Vector2D& mousePos) {
canSkipUpdate = std::clamp(MSMONITOR - TIMERDELTA, 0.0, MSMONITOR) > totalMs * 1.0 / m_iMouseMoveEventCount;
}
if ((abs(TICKDELTA.x) < 1.f && abs(TICKDELTA.y) < 1.f) || (TIMERDELTA < MSMONITOR && canSkipUpdate && g_pInputManager->dragMode != MBIND_MOVE))
if ((abs(TICKDELTA.x) < 1.f && abs(TICKDELTA.y) < 1.f) || (TIMERDELTA < MSMONITOR && canSkipUpdate && (g_pInputManager->dragMode != MBIND_MOVE || *PANIMATEMOUSE)))
return;
TIMER = std::chrono::high_resolution_clock::now();