chickadee » bb » bb:run

(bb:run [WAIT]) procedure

Processes events. If WAIT is true or not specified, bb:run does not return until the last window closes. If WAIT is a number, then bb:run returns after that many seconds, or earlier, if no events are queued.