mirror of
https://github.com/hyprwm/Hyprland
synced 2024-12-23 10:09:49 +01:00
set last monitor and dont refocus in some cases (changeworkspace)
This commit is contained in:
parent
2ba7cb2414
commit
94ca386a8c
1 changed files with 4 additions and 1 deletions
|
@ -658,9 +658,12 @@ void CKeybindManager::changeworkspace(std::string args) {
|
||||||
|
|
||||||
if (g_pCompositor->cursorOnReservedArea()) // fix focus on bars etc
|
if (g_pCompositor->cursorOnReservedArea()) // fix focus on bars etc
|
||||||
g_pInputManager->refocus();
|
g_pInputManager->refocus();
|
||||||
} else
|
} else if (g_pCompositor->getWindowsOnWorkspace(PWORKSPACETOCHANGETO->m_iID) > 0)
|
||||||
g_pInputManager->refocus();
|
g_pInputManager->refocus();
|
||||||
|
|
||||||
|
// set the new monitor as the last (no warps would bug otherwise)
|
||||||
|
g_pCompositor->m_pLastMonitor = g_pCompositor->getMonitorFromID(PWORKSPACETOCHANGETO->m_iMonitorID);
|
||||||
|
|
||||||
// mark the monitor dirty
|
// mark the monitor dirty
|
||||||
g_pHyprRenderer->damageMonitor(PMONITOR);
|
g_pHyprRenderer->damageMonitor(PMONITOR);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue