From f9abd0445930e78fef6c93b2a5938b8eca25c3da Mon Sep 17 00:00:00 2001 From: Vlad Zahorodnii Date: Tue, 8 Nov 2022 19:47:28 +0200 Subject: [PATCH] Port constraint constraints from Window::clientPos() --- src/pointer_input.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pointer_input.cpp b/src/pointer_input.cpp index f6c588fee8..20540466cc 100644 --- a/src/pointer_input.cpp +++ b/src/pointer_input.cpp @@ -596,7 +596,7 @@ static QRegion getConstraintRegion(Window *window, T *constraint) { const QRegion windowShape = window->inputShape(); const QRegion intersected = constraint->region().isEmpty() ? windowShape : windowShape.intersected(constraint->region()); - return intersected.translated(QPointF(window->pos() + window->clientPos()).toPoint()); + return intersected.translated(window->mapFromLocal(QPointF(0, 0)).toPoint()); } void PointerInputRedirection::setEnableConstraints(bool set)