mirror of
https://github.com/hyprwm/Hyprland
synced 2024-11-07 18:45:59 +01:00
fix minor issues with floating windows and fullscreen
This commit is contained in:
parent
a7a3c0fc1d
commit
e6872bddf4
2 changed files with 14 additions and 3 deletions
|
@ -212,9 +212,23 @@ void IHyprLayout::changeWindowFloatingMode(CWindow* pWindow) {
|
|||
// fix pseudo leaving artifacts
|
||||
g_pHyprRenderer->damageMonitor(g_pCompositor->getMonitorFromID(pWindow->m_iMonitorID));
|
||||
} else {
|
||||
pWindow->m_vSize = pWindow->m_vRealSize.vec();
|
||||
pWindow->m_vPosition = pWindow->m_vRealPosition.vec();
|
||||
|
||||
onWindowRemovedTiling(pWindow);
|
||||
|
||||
g_pCompositor->moveWindowToTop(pWindow);
|
||||
|
||||
const auto POS = pWindow->m_vRealPosition.goalv();
|
||||
const auto SIZ = pWindow->m_vRealSize.goalv();
|
||||
|
||||
pWindow->m_vRealPosition.setValueAndWarp(POS + Vector2D(5, 5));
|
||||
pWindow->m_vRealSize.setValueAndWarp(SIZ - Vector2D(10, 10));
|
||||
|
||||
pWindow->m_vRealPosition = POS;
|
||||
pWindow->m_vRealSize = SIZ;
|
||||
|
||||
g_pHyprRenderer->damageMonitor(g_pCompositor->getMonitorFromID(pWindow->m_iMonitorID));
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -253,9 +253,6 @@ void CKeybindManager::toggleActiveFloating(std::string args) {
|
|||
moveActiveToWorkspace(std::to_string(g_pCompositor->getMonitorFromID(ACTIVEWINDOW->m_iMonitorID)->activeWorkspace));
|
||||
}
|
||||
|
||||
ACTIVEWINDOW->m_vRealPosition.setValue(ACTIVEWINDOW->m_vRealPosition.vec() + Vector2D(5, 5));
|
||||
ACTIVEWINDOW->m_vSize = ACTIVEWINDOW->m_vRealPosition.vec() - Vector2D(10, 10);
|
||||
|
||||
g_pLayoutManager->getCurrentLayout()->changeWindowFloatingMode(ACTIVEWINDOW);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue