diff options
| author | AERDU <nicke.piri@gmail.com> | 2024-05-27 20:45:14 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-05-27 22:45:14 +0200 |
| commit | 506d0c06e6fb280275311ea4baff8af73a84dbd2 (patch) | |
| tree | 91c7bb3832c94202ee8df73fb3323c44001db812 /src/Compositor.cpp | |
| parent | 546a486bab56af06fd95b23fb2ce231d00f671c9 (diff) | |
compositor: change monitor focus when no_warps is enabled (#6260)
fixes focus between monitors when moving using directions with no_warps = true
Diffstat (limited to 'src/Compositor.cpp')
| -rw-r--r-- | src/Compositor.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/Compositor.cpp b/src/Compositor.cpp index a14e91fd..254abd92 100644 --- a/src/Compositor.cpp +++ b/src/Compositor.cpp @@ -2366,8 +2366,12 @@ void CCompositor::warpCursorTo(const Vector2D& pos, bool force) { static auto PNOWARPS = CConfigValue<Hyprlang::INT>("cursor:no_warps"); - if (*PNOWARPS && !force) + if (*PNOWARPS && !force) { + const auto PMONITORNEW = getMonitorFromVector(pos); + if (PMONITORNEW != m_pLastMonitor.get()) + setActiveMonitor(PMONITORNEW); return; + } g_pPointerManager->warpTo(pos); |
