Browse Source

Avoided triggering an assertion when focus is returned by a popup menu to a hidden component

tags/2021-05-28
jules 8 years ago
parent
commit
31e454f284
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      modules/juce_gui_basics/menus/juce_PopupMenu.cpp

+ 1
- 1
modules/juce_gui_basics/menus/juce_PopupMenu.cpp View File

@@ -1621,7 +1621,7 @@ struct PopupMenuCompletionCallback : public ModalComponentManager::Callback
if (prevTopLevel != nullptr)
prevTopLevel->toFront (true);
if (prevFocused != nullptr)
if (prevFocused != nullptr && prevFocused->isShowing())
prevFocused->grabKeyboardFocus();
}
}


Loading…
Cancel
Save