draw selection rect only if mouse has moved

This commit is contained in:
2026-08-14 22:20:35 +02:00
parent d36e59fd26
commit 1cf7c264c1
5 changed files with 41 additions and 4 deletions

View File

@@ -1019,8 +1019,9 @@ void WorldRenderer::drawOverlays(QPainter& painter, const WorldCoordinates& coor
}
}
// Box-select rectangle
if (frame.isBoxSelecting)
// Box-select rectangle. Not drawn until the drag has moved far enough to read as
// one, so a plain click does not flash a rectangle (REQ-UI-MULTI-SELECT).
if (frame.isBoxSelecting && frame.isBoxDragMoved)
{
const QPoint tl(std::min(frame.boxStartTile.x(), frame.boxCurrentTile.x()),
std::min(frame.boxStartTile.y(), frame.boxCurrentTile.y()));