| 351 | } |
| 352 | |
| 353 | void XWindow::iterateMappedChildrenBackToFront(std::function<bool(const XWindowPtr& child)> callback, bool includeTransients) { |
| 354 | BOXEDWINE_CRITICAL_SECTION_WITH_MUTEX(childrenMutex); |
| 355 | for (auto& child : zchildren) { |
| 356 | if (child->mapped() && (!includeTransients || !child->isTransient())) { |
| 357 | if (!callback(child)) { |
| 358 | return; |
| 359 | } |
| 360 | } |
| 361 | } |
| 362 | if (includeTransients) { |
| 363 | for (auto& child : transientChildren) { |
| 364 | if (child->mapped()) { |
| 365 | if (!callback(child)) { |
| 366 | break; |
| 367 | } |
| 368 | } |
| 369 | } |
| 370 | } |
| 371 | } |
| 372 | |
| 373 | void XWindow::windowToScreen(S32& x, S32& y) { |
| 374 | XWindowPtr p = shared_from_this(); |
no test coverage detected