core: move internal structures to monitor pointers (#8266)

This commit is contained in:
Vaxry
2024-10-27 18:45:38 +00:00
committed by GitHub
parent b6e226c320
commit 5d4b54b012
24 changed files with 226 additions and 215 deletions

View File

@@ -99,12 +99,12 @@ void CAnimationManager::tick() {
PDECO->damageEntire();
}
PMONITOR = g_pCompositor->getMonitorFromID(PWINDOW->m_iMonitorID);
PMONITOR = PWINDOW->m_pMonitor.lock();
if (!PMONITOR)
continue;
animationsDisabled = PWINDOW->m_sWindowData.noAnim.valueOr(animationsDisabled);
} else if (PWORKSPACE) {
PMONITOR = g_pCompositor->getMonitorFromID(PWORKSPACE->m_iMonitorID);
PMONITOR = PWORKSPACE->m_pMonitor.lock();
if (!PMONITOR)
continue;
@@ -325,7 +325,7 @@ void CAnimationManager::animationSlide(PHLWINDOW pWindow, std::string force, boo
const auto GOALPOS = pWindow->m_vRealPosition.goal();
const auto GOALSIZE = pWindow->m_vRealSize.goal();
const auto PMONITOR = g_pCompositor->getMonitorFromID(pWindow->m_iMonitorID);
const auto PMONITOR = pWindow->m_pMonitor.lock();
if (!PMONITOR)
return; // unsafe state most likely