* Draws the given window and any other overlapping transparent windows. */
| 550 | * Draws the given window and any other overlapping transparent windows. |
| 551 | */ |
| 552 | static void WindowDrawCore( |
| 553 | Drawing::RenderTarget& rt, WindowBase& w, int32_t left, int32_t top, int32_t right, int32_t bottom) |
| 554 | { |
| 555 | // Clamp region |
| 556 | left = std::max<int32_t>(left, w.windowPos.x); |
| 557 | top = std::max<int32_t>(top, w.windowPos.y); |
| 558 | right = std::min<int32_t>(right, w.windowPos.x + w.width); |
| 559 | bottom = std::min<int32_t>(bottom, w.windowPos.y + w.height); |
| 560 | if (left >= right) |
| 561 | return; |
| 562 | if (top >= bottom) |
| 563 | return; |
| 564 | |
| 565 | // Draw the window and any other overlapping transparent windows |
| 566 | for (auto it = WindowGetIterator(&w); it != gWindowList.end(); it++) |
| 567 | { |
| 568 | auto* v = it->get(); |
| 569 | if (v->flags.has(WindowFlag::dead)) |
| 570 | continue; |
| 571 | if ((&w == v || v->flags.has(WindowFlag::transparent)) && v->isVisible) |
| 572 | { |
| 573 | WindowDrawSingle(rt, *v, left, top, right, bottom); |
| 574 | } |
| 575 | } |
| 576 | } |
| 577 | |
| 578 | static void WindowDrawSingle( |
| 579 | Drawing::RenderTarget& rt, WindowBase& w, int32_t left, int32_t top, int32_t right, int32_t bottom) |
no test coverage detected