* Unfocuses the focused widget of the window, * if the focused widget is contained inside the container. * @param parent_window Window which contains this container. */
| 3519 | * @param parent_window Window which contains this container. |
| 3520 | */ |
| 3521 | void NWidgetContainer::UnfocusWidgets(Window *parent_window) |
| 3522 | { |
| 3523 | assert(parent_window != nullptr); |
| 3524 | if (parent_window->nested_focus != nullptr) { |
| 3525 | for (auto &widget : this->children) { |
| 3526 | if (parent_window->nested_focus == widget.get()) { |
| 3527 | parent_window->UnfocusFocusedWidget(); |
| 3528 | } |
| 3529 | } |
| 3530 | } |
| 3531 | } |
no test coverage detected