1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Accessibility: Don't give focus to currently keyboard focused component in AccessibilityHandler::giveAwayFocusInternal()

This commit is contained in:
ed 2021-07-21 17:16:59 +01:00
parent 1028b6e5d1
commit 17ca903aaa

View file

@ -319,10 +319,7 @@ void AccessibilityHandler::grabFocusInternal (bool canTryParent)
void AccessibilityHandler::giveAwayFocusInternal() const
{
currentlyFocusedHandler = nullptr;
if (auto* focusedComponent = Component::getCurrentlyFocusedComponent())
if (auto* handler = focusedComponent->getAccessibilityHandler())
handler->grabFocus();
notifyAccessibilityEventInternal (*this, InternalAccessibilityEvent::focusChanged);
}
void AccessibilityHandler::takeFocus()