Re: [AD] al_acknowledge_display_disconnected |
[ Thread Index |
Date Index
| More lists.liballeg.org/allegro-developers Archives
]
On 2012-05-22, at 2:16 AM, Peter Wang wrote:
> What does al_acknowledge_display_disconnected do?
Just some housekeeping, but a display being disconnected is like a drawing halt, you can't do any opengl calls until it's handled. So you have:
gotDisconnectNotification() {
sendAllegroEvent(DISCONNECT);
waitForAcknowledge();
housekeeping();
}
> Can you put the ALLEGRO_DISPLAY into an no-op state and send an event?
> Then the user can call al_destroy_display on it as usual, or continue
> obliviously (probably uselessly).
>
> Peter
No, it has to be handled. Right now it waits up to 5 seconds, after that it just goes on as if the user acknowledged. Which will mean a crash in most cases.
Trent