[Lazarus] Unable to use method AdvancedCustomDrawItem and, AdvancedCustomDrawSubItem

Benito van der Zander benito at benibela.de
Mon Mar 16 22:20:08 CET 2009


Michael Van Canneyt пишет:
> Hello,
> 
> Is there a reason why the default exception dialog has a cancel 
> button to kill the application ?
> 
> We often use an exception to signal wrong entry of data or so, 
> because it stops all further processing.
> 
> If the user then uses the cancel button, the program is simply 
> ended, which is not what we (or better: the users) want.
> And I imagine many others use this technique.
> 
> I have overridden the OnException handler of TApplication, 
> so it's no longer a problem, but I was curious as to why this
> is done like this by default ?
> 
I remember discussions on this topic long ago. It was like GTK (GTK 1 at 
that time) isn't tolerant to exceptions that occur in its signal 
handlers (read: in LCL and user's code), and it wasn't possible to 
expect program stability after an exception was raised. That explains 
the need for 'terminate' button.

The things may have changed since then, however.

Regards,
Sergei



More information about the Lazarus mailing list