focus: fix #1675 window not scrollable after movefocus (#2390)

This commit is contained in:
Jeremy Huang 2023-05-29 00:52:36 -07:00 committed by GitHub
parent 409ff027f8
commit b3a86952cf
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -981,6 +981,7 @@ void CKeybindManager::moveFocusTo(std::string args) {
g_pCompositor->focusWindow(PWINDOWTOCHANGETO); g_pCompositor->focusWindow(PWINDOWTOCHANGETO);
Vector2D middle = PWINDOWTOCHANGETO->m_vRealPosition.goalv() + PWINDOWTOCHANGETO->m_vRealSize.goalv() / 2.f; Vector2D middle = PWINDOWTOCHANGETO->m_vRealPosition.goalv() + PWINDOWTOCHANGETO->m_vRealSize.goalv() / 2.f;
g_pCompositor->warpCursorTo(middle); g_pCompositor->warpCursorTo(middle);
g_pInputManager->simulateMouseMovement();
if (PLASTWINDOW->m_iMonitorID != PWINDOWTOCHANGETO->m_iMonitorID) { if (PLASTWINDOW->m_iMonitorID != PWINDOWTOCHANGETO->m_iMonitorID) {
// event // event