| 583 | } |
| 584 | |
| 585 | void MapWidget::updateDrawingLater(const QRectF& map_rect, int pixel_border) |
| 586 | { |
| 587 | QRect viewport_rect = calculateViewportBoundingBox(map_rect, pixel_border); |
| 588 | |
| 589 | if (viewport_rect.intersects(rect())) |
| 590 | { |
| 591 | if (!cached_update_rect.isValid()) |
| 592 | { |
| 593 | // Start the update timer |
| 594 | QTimer::singleShot(15, this, &MapWidget::updateDrawingLaterSlot); |
| 595 | } |
| 596 | |
| 597 | // NOTE: this may require a mutex for concurrent access with updateDrawingLaterSlot()? |
| 598 | rectIncludeSafe(cached_update_rect, viewport_rect); |
| 599 | } |
| 600 | } |
| 601 | |
| 602 | void MapWidget::updateDrawingLaterSlot() |
| 603 | { |
no test coverage detected