mirror of
https://github.com/hyprwm/Hyprland.git
synced 2025-08-17 21:13:48 -07:00
compositor: change monitor focus when no_warps is enabled (#6260)
fixes focus between monitors when moving using directions with no_warps = true
This commit is contained in:
@@ -2366,8 +2366,12 @@ void CCompositor::warpCursorTo(const Vector2D& pos, bool force) {
|
|||||||
|
|
||||||
static auto PNOWARPS = CConfigValue<Hyprlang::INT>("cursor:no_warps");
|
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;
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
g_pPointerManager->warpTo(pos);
|
g_pPointerManager->warpTo(pos);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user