diff options
| author | Maximilian Seidler <78690852+PaideiaDilemma@users.noreply.github.com> | 2025-09-10 10:22:45 +0000 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-09-10 12:22:45 +0200 |
| commit | b8cff8a4342fbb17367e21b95fafad8d6ec2960d (patch) | |
| tree | 187a8096cf9f0188326ce2ef875027601716b161 /src/managers/input/InputManager.cpp | |
| parent | 150d693fe794a01aab762a18d2d8a2c8bc54b43c (diff) | |
input: focus when first keyboard is added and m_lastFocus is set (#11645)
Diffstat (limited to 'src/managers/input/InputManager.cpp')
| -rw-r--r-- | src/managers/input/InputManager.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/managers/input/InputManager.cpp b/src/managers/input/InputManager.cpp index 5e844bec..6e975043 100644 --- a/src/managers/input/InputManager.cpp +++ b/src/managers/input/InputManager.cpp @@ -1031,6 +1031,10 @@ void CInputManager::setupKeyboard(SP<IKeyboard> keeb) { g_pSeatManager->setKeyboard(keeb); keeb->updateLEDs(); + + // in case m_lastFocus was set without a keyboard + if (m_keyboards.size() == 1 && g_pCompositor->m_lastFocus) + g_pSeatManager->setKeyboardFocus(g_pCompositor->m_lastFocus.lock()); } void CInputManager::setKeyboardLayout() { |
