xwayland: Remove delta for real position with xwayland zero scaling (#6057)

This commit is contained in:
Daniil 2024-05-14 12:33:20 +00:00 committed by GitHub
parent ba69652193
commit 1584679004
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -1144,9 +1144,7 @@ void Events::listener_unmanagedSetGeometry(void* owner, void* data) {
if (*PXWLFORCESCALEZERO) {
if (const auto PMONITOR = g_pCompositor->getMonitorFromID(PWINDOW->m_iMonitorID); PMONITOR) {
const Vector2D DELTA = PWINDOW->m_vRealSize.goal() - PWINDOW->m_vRealSize.goal() / PMONITOR->scale;
PWINDOW->m_vRealSize.setValueAndWarp(PWINDOW->m_vRealSize.goal() / PMONITOR->scale);
PWINDOW->m_vRealPosition.setValueAndWarp(PWINDOW->m_vRealPosition.goal() + DELTA / 2.0);
}
}