pub fn release(py: Python<'_>)Expand description
An X11 capture stopped: the last one out stops and joins the monitor. Runs detached from the GIL — the thread may be blocked attaching to deliver a cursor — and the join is bounded: a thread that misses the wake (X server wedged mid-shutdown) is abandoned with a warning rather than hanging the caller; it exits on its own next event. A stop issued from inside the cursor callback runs on the monitor thread itself, where a join can only time out: it signals and detaches instead, and the loop observes the stop flag once the callback unwinds.