I was working on unit selection in OpenYR when a regression test turned up a stray attack order. The test pressed over an enemy unit, dragged out a selection box, then came back to the starting point before releasing. The old handler looked at the release position and treated it as a fresh click.1
The fix remembers if the pointer ever moved more than six pixels along either axis during the press. That lets the release handler tell a collapsed drag from ordinary click jitter.
A box that expands again before release still selects units. A fresh click within the tolerance still takes the click path. The regression checks both cases across three window sizes and compares the saved match bytes.1
The Linux window capture used scripted pointer input. The selection outline appeared during the drag. Releasing at the start showed no order notice. A fresh click at the same spot showed the order notice.2