aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/managers/XWaylandManager.cpp
diff options
context:
space:
mode:
authorvaxerski <[email protected]>2023-08-18 22:20:05 +0200
committervaxerski <[email protected]>2023-08-18 22:20:05 +0200
commit14f20a737221f09a601d846c2b37b969afe2e725 (patch)
treeeae03eb4f92b63c094778eb51c0d55c78fa08b9d /src/managers/XWaylandManager.cpp
parent3d9545d2e0aee9f6c67867b22cf3fb9b1f708bc6 (diff)
downloadHyprland-14f20a737221f09a601d846c2b37b969afe2e725.tar.gz
Hyprland-14f20a737221f09a601d846c2b37b969afe2e725.zip
xwayland: fix incorrect VECINRECT usage
Fixes #3002. VECINRECT uses x2 and y2 and not w / h.
Diffstat (limited to 'src/managers/XWaylandManager.cpp')
-rw-r--r--src/managers/XWaylandManager.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/managers/XWaylandManager.cpp b/src/managers/XWaylandManager.cpp
index 5820f9a3..76f979da 100644
--- a/src/managers/XWaylandManager.cpp
+++ b/src/managers/XWaylandManager.cpp
@@ -317,7 +317,7 @@ Vector2D CHyprXWaylandManager::xwaylandToWaylandCoords(const Vector2D& coord) {
CMonitor* pMonitor = nullptr;
for (auto& m : g_pCompositor->m_vMonitors) {
const auto SIZ = *PXWLFORCESCALEZERO ? m->vecTransformedSize : m->vecSize;
- if (VECINRECT(coord, m->vecXWaylandPosition.x, m->vecXWaylandPosition.y, SIZ.x, SIZ.y)) {
+ if (VECINRECT(coord, m->vecXWaylandPosition.x, m->vecXWaylandPosition.y, m->vecXWaylandPosition.x + SIZ.x, m->vecXWaylandPosition.y + SIZ.y)) {
pMonitor = m.get();
break;
}