Re: [AD] Removing the default close button support |
[ Thread Index | Date Index | More lists.liballeg.org/allegro-developers Archives ]
> Therefore I propose to get rid of both set_window_close_button() (useless > now) and set_window_close_hook() (nasty name: Allegro uses callbacks, not > hooks) and add set_close_button_callback(). Patch attached. Tested under DOS, Windows and Linux. It is somewhat different from the last proposition I made: - the two 4.0.x-style functions are simply removed. Rationale: we can't provide backward compatibility because we don't support shutting down the program anymore, so there is no advantage in providing deprecated functions that don't behave as expected. - no second parameter. Rationale: (1) since we don't support shutting down the program anymore, there is no need for a built-in confirmation step, that is a confirmation step handled by the library; the user can provide its own code here. (2) we remove an artificial difference between platforms. This may appear too radical a change but, the more I think about the 4.0.x way of doing the things, the more broken I find it. Let's be simple and clean. -- Eric Botcazou
Attachment:
close_button_callback.zip
Description: Zip archive
Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |