mirror of
https://github.com/hyprwm/Hyprland.git
synced 2025-07-26 09:41:57 -07:00
damage: fix damage on moves / workspace changes
This commit is contained in:
@@ -522,6 +522,8 @@ void CMonitor::changeWorkspace(CWorkspace* const pWorkspace, bool internal) {
|
|||||||
g_pEventManager->postEvent(SHyprIPCEvent{"workspace", pWorkspace->m_szName});
|
g_pEventManager->postEvent(SHyprIPCEvent{"workspace", pWorkspace->m_szName});
|
||||||
EMIT_HOOK_EVENT("workspace", pWorkspace);
|
EMIT_HOOK_EVENT("workspace", pWorkspace);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
g_pHyprRenderer->damageMonitor(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CMonitor::changeWorkspace(const int& id, bool internal) {
|
void CMonitor::changeWorkspace(const int& id, bool internal) {
|
||||||
@@ -529,6 +531,8 @@ void CMonitor::changeWorkspace(const int& id, bool internal) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
void CMonitor::setSpecialWorkspace(CWorkspace* const pWorkspace) {
|
void CMonitor::setSpecialWorkspace(CWorkspace* const pWorkspace) {
|
||||||
|
g_pHyprRenderer->damageMonitor(this);
|
||||||
|
|
||||||
if (!pWorkspace) {
|
if (!pWorkspace) {
|
||||||
// remove special if exists
|
// remove special if exists
|
||||||
if (const auto EXISTINGSPECIAL = g_pCompositor->getWorkspaceByID(specialWorkspaceID); EXISTINGSPECIAL)
|
if (const auto EXISTINGSPECIAL = g_pCompositor->getWorkspaceByID(specialWorkspaceID); EXISTINGSPECIAL)
|
||||||
|
@@ -876,6 +876,8 @@ void CKeybindManager::moveActiveToWorkspace(std::string args) {
|
|||||||
|
|
||||||
auto pWorkspace = g_pCompositor->getWorkspaceByID(WORKSPACEID);
|
auto pWorkspace = g_pCompositor->getWorkspaceByID(WORKSPACEID);
|
||||||
|
|
||||||
|
g_pHyprRenderer->damageWindow(PWINDOW);
|
||||||
|
|
||||||
if (pWorkspace) {
|
if (pWorkspace) {
|
||||||
g_pCompositor->moveWindowToWorkspaceSafe(PWINDOW, pWorkspace);
|
g_pCompositor->moveWindowToWorkspaceSafe(PWINDOW, pWorkspace);
|
||||||
const auto PMONITOR = g_pCompositor->getMonitorFromID(pWorkspace->m_iMonitorID);
|
const auto PMONITOR = g_pCompositor->getMonitorFromID(pWorkspace->m_iMonitorID);
|
||||||
@@ -919,6 +921,8 @@ void CKeybindManager::moveActiveToWorkspaceSilent(std::string args) {
|
|||||||
if (WORKSPACEID == PWINDOW->m_iWorkspaceID)
|
if (WORKSPACEID == PWINDOW->m_iWorkspaceID)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
g_pHyprRenderer->damageWindow(PWINDOW);
|
||||||
|
|
||||||
auto pWorkspace = g_pCompositor->getWorkspaceByID(WORKSPACEID);
|
auto pWorkspace = g_pCompositor->getWorkspaceByID(WORKSPACEID);
|
||||||
const auto OLDMIDDLE = PWINDOW->middle();
|
const auto OLDMIDDLE = PWINDOW->middle();
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user