summaryrefslogtreecommitdiff
path: root/src/managers/input/InputManager.cpp
diff options
context:
space:
mode:
authorvaxerski <vaxry@vaxry.net>2023-02-09 15:29:02 +0000
committervaxerski <vaxry@vaxry.net>2023-02-09 15:29:02 +0000
commit68f56130baeff33707fc44d4fc21c5f334ef7e41 (patch)
tree9c66e6398bdb040edbed0e2b9105484db103da9e /src/managers/input/InputManager.cpp
parent4ea4efb871997a245539cae9d966ec8f07d3e907 (diff)
add misc:mouse_move_focuses_monitor
Diffstat (limited to 'src/managers/input/InputManager.cpp')
-rw-r--r--src/managers/input/InputManager.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/managers/input/InputManager.cpp b/src/managers/input/InputManager.cpp
index caaece20..5a08c0cd 100644
--- a/src/managers/input/InputManager.cpp
+++ b/src/managers/input/InputManager.cpp
@@ -50,6 +50,7 @@ void CInputManager::mouseMoveUnified(uint32_t time, bool refocus) {
static auto* const PFOLLOWONDND = &g_pConfigManager->getConfigValuePtr("misc:always_follow_on_dnd")->intValue;
static auto* const PHOGFOCUS = &g_pConfigManager->getConfigValuePtr("misc:layers_hog_keyboard_focus")->intValue;
static auto* const PFLOATBEHAVIOR = &g_pConfigManager->getConfigValuePtr("input:float_switch_override_focus")->intValue;
+ static auto* const PMOUSEFOCUSMON = &g_pConfigManager->getConfigValuePtr("misc:mouse_move_focuses_monitor")->intValue;
m_pFoundSurfaceToFocus = nullptr;
m_pFoundLSToFocus = nullptr;
@@ -140,7 +141,7 @@ void CInputManager::mouseMoveUnified(uint32_t time, bool refocus) {
g_pLayoutManager->getCurrentLayout()->onMouseMove(getMouseCoordsInternal());
- if (PMONITOR && PMONITOR != g_pCompositor->m_pLastMonitor) {
+ if (PMONITOR && PMONITOR != g_pCompositor->m_pLastMonitor && *PMOUSEFOCUSMON) {
g_pCompositor->setActiveMonitor(PMONITOR);
// set active workspace and deactivate all other in wlr