libcamera: event_dispatcher: Add interrupt() function
The new interrupt() function allows interrupting in-progress blocking processEvents() calls. This is useful to stop running event loops. Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Reviewed-by: Kieran Bingham <kieran.bingham@ideasonboard.com> Reviewed-by: Niklas Söderlund <niklas.soderlund@ragnatech.se>
This commit is contained in:
@@ -104,4 +104,14 @@ EventDispatcher::~EventDispatcher()
|
||||
* it before returning.
|
||||
*/
|
||||
|
||||
/**
|
||||
* \fn EventDispatcher::interrupt()
|
||||
* \brief Interrupt any running processEvents() call as soon as possible
|
||||
*
|
||||
* Calling this function interrupts any blocking processEvents() call in
|
||||
* progress. The processEvents() function will return as soon as possible,
|
||||
* after processing pending timers and events. If processEvents() isn't in
|
||||
* progress, it will be interrupted immediately the next time it gets called.
|
||||
*/
|
||||
|
||||
} /* namespace libcamera */
|
||||
|
||||
Reference in New Issue
Block a user