summaryrefslogtreecommitdiff
path: root/src/managers/input/InputManager.cpp
diff options
context:
space:
mode:
authorvaxerski <43317083+vaxerski@users.noreply.github.com>2022-11-19 16:41:36 +0000
committervaxerski <43317083+vaxerski@users.noreply.github.com>2022-11-19 16:41:41 +0000
commite427d9f622d852c20d0f24966dbe35a34f600de4 (patch)
tree1e578faff6773b5d0d35c03f25214a298a73b982 /src/managers/input/InputManager.cpp
parentf88feec02b362fd1a43c6760ef37af1e1c58cafd (diff)
unify setting of the active monitor
Diffstat (limited to 'src/managers/input/InputManager.cpp')
-rw-r--r--src/managers/input/InputManager.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/managers/input/InputManager.cpp b/src/managers/input/InputManager.cpp
index c95fd910..ed96cb64 100644
--- a/src/managers/input/InputManager.cpp
+++ b/src/managers/input/InputManager.cpp
@@ -123,15 +123,12 @@ void CInputManager::mouseMoveUnified(uint32_t time, bool refocus) {
g_pLayoutManager->getCurrentLayout()->onMouseMove(getMouseCoordsInternal());
if (PMONITOR && PMONITOR != g_pCompositor->m_pLastMonitor) {
- g_pCompositor->m_pLastMonitor = PMONITOR;
+ g_pCompositor->setActiveMonitor(PMONITOR);
// set active workspace and deactivate all other in wlr
const auto ACTIVEWORKSPACE = g_pCompositor->getWorkspaceByID(PMONITOR->activeWorkspace);
g_pCompositor->deactivateAllWLRWorkspaces(ACTIVEWORKSPACE->m_pWlrHandle);
ACTIVEWORKSPACE->setActive(true);
-
- // event
- g_pEventManager->postEvent(SHyprIPCEvent{"focusedmon", PMONITOR->szName + "," + ACTIVEWORKSPACE->m_szName});
}
// overlay is above fullscreen