mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
Accessibility: Fixed some focus issues with modal components
This commit is contained in:
parent
75922cac38
commit
df4ff3b225
2 changed files with 3 additions and 5 deletions
|
|
@ -310,8 +310,9 @@ void AccessibilityHandler::giveAwayFocusInternal() const
|
|||
{
|
||||
currentlyFocusedHandler = nullptr;
|
||||
|
||||
if (auto* parent = getParent())
|
||||
notifyAccessibilityEventInternal (*parent, InternalAccessibilityEvent::focusChanged);
|
||||
if (auto* focusedComponent = Component::getCurrentlyFocusedComponent())
|
||||
if (auto* handler = focusedComponent->getAccessibilityHandler())
|
||||
handler->grabFocus();
|
||||
}
|
||||
|
||||
void AccessibilityHandler::takeFocus()
|
||||
|
|
|
|||
|
|
@ -1709,9 +1709,6 @@ void Component::enterModalState (bool shouldTakeKeyboardFocus,
|
|||
|
||||
if (shouldTakeKeyboardFocus)
|
||||
grabKeyboardFocus();
|
||||
|
||||
if (auto* handler = getAccessibilityHandler())
|
||||
notifyAccessibilityEventInternal (*handler, InternalAccessibilityEvent::focusChanged);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue