On 2016-05-25 12:18, Michael Van Canneyt wrote: > I am not sure this is safe to do, since an event handler exists of 2 > pointers: data and method. As far as I know, an interface does not have a > data pointer.
I don't fully understand your statement about 2 pointers? An event handler is simply a procedure of a object. When an event is triggered, that simply means the procedure is called and parameters are passed to it. So that explains why my code worked - I'm simply calling a method of that interface. This all works as long as the interface reference stays in scope of course - which it is in my case Regards, Graeme -- fpGUI Toolkit - a cross-platform GUI toolkit using Free Pascal http://fpgui.sourceforge.net/ My public PGP key: http://tinyurl.com/graeme-pgp _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal