Expand description
Async (task, thread, timer) helper functions
Structs§
- Drop
Check - Simple struct that is used by Azul internally to determine when the thread has finished executing.
When this struct goes out of scope, Azul will call
.join()
on the thread (so in order to not block the main thread, simply let it go out of scope naturally. - Task
- A
Task
is a seperate thread that is owned by the framework. - Thread
- A
Thread
is a simple abstraction overstd::thread
that allows to offload a pure function to a different thread (essentially emulating async / await for older compilers). - Timer
- A
Timer
is a function that is run on every frame. - TimerId
- ID for uniquely identifying a timer
Enums§
- Block
Error - Error that can happen while calling
.block()
- Terminate
Timer - Should a timer terminate or not - used to remove active timers
Functions§
- clean_
up_ finished_ tasks - Remove all tasks that have finished executing
- run_
all_ timers - Run all currently registered timers