| 458 | }; |
| 459 | |
| 460 | BOOL CALLBACK PiuViewAdjustAux(HWND window, LPARAM lParam) |
| 461 | { |
| 462 | PiuView* self = (PiuView*)lParam; |
| 463 | if (GetParent(window) == (*self)->window) { |
| 464 | PiuContent* content = (PiuContent*)GetWindowLongPtr(window, 0); |
| 465 | PiuRectangleRecord bounds = (*content)->bounds; |
| 466 | PiuRectangleRecord clipBounds = bounds; |
| 467 | PiuContainer* container = (*content)->container; |
| 468 | while (container) { |
| 469 | bounds.x += (*container)->bounds.x; |
| 470 | bounds.y += (*container)->bounds.y; |
| 471 | clipBounds.x += (*container)->bounds.x; |
| 472 | clipBounds.y += (*container)->bounds.y; |
| 473 | if ((*container)->flags & piuClip) |
| 474 | PiuRectangleIntersect(&clipBounds, &clipBounds, &(*container)->bounds); |
| 475 | container = (*container)->container; |
| 476 | } |
| 477 | MoveWindow(window, clipBounds.x, clipBounds.y, clipBounds.width, clipBounds.height, TRUE); |
| 478 | window = GetWindow(window, GW_CHILD); |
| 479 | MoveWindow(window, bounds.x - clipBounds.x, bounds.y - clipBounds.y, bounds.width, bounds.height, TRUE); |
| 480 | } |
| 481 | return TRUE; |
| 482 | } |
| 483 | |
| 484 | void PiuViewAdjust(PiuView* self) |
| 485 | { |
nothing calls this directly
no test coverage detected