Re: Callback-problems

From: Hilmar Lapp <hili_at_al-bundy.biologie.uni-freiburg.de>
Date: Wed, 15 Feb 1995 20:36:25 +0000

On Tue, 14 Feb 1995, Hilmar Lapp wrote:

>
> seems like I'm running into the same problem as some other people in
> these days.
>
> [... stuff deleted ...]
>
> My implementation can be seen in the appendix; the binding is done using
> a local lambda expression (bound to a variable) and the address-of
> function (thanks for your hint a few days ago, Erick; I wouldn't have had
> this idea on my own). If you try this, everything will seem to work fine,
> but be a little patient and click around through various directories.
> As you will see, after the 9th to 12th (this varies) directory change
> there's nothing fine any more:
>
> *** Read from string error:
> eval: bad function in : "(#[unknown 18 b0068])"
> **** Tk error ("") ""
>
> After this point, the callbacks of both listboxes seem to be screwed up.
>

I've found a solution today (may be it's better called a "workaround").
Now I'm doing the binding of the mouse button in the same function, where
the callbacks are defined and bound. Seems as if that variant works fine.

So, it seems like one should remember that it's probably not a good idea
to call functions in a callback, which were once given as arguments in a
call to the surrounding function (that had established the key binding of
the callback).

I hope most of you are able to understand, what I wanted to say :-] . My
English is far from being as good as I wish it to be. :^)

        Hilmar

-----------------------------------------------------------------------------
Hilmar Lapp e-mail: hlapp_at_deep-thought.biologie.uni-freiburg.de
Institut f. Biologie II http://www.biologie.uni-freiburg.de/~hili/hili.html
Universitaet Freiburg phone : +49 761 203 2656
-----------------------------------------------------------------------------
Received on Wed Feb 15 1995 - 20:30:29 CET

This archive was generated by hypermail 2.3.0 : Mon Jul 21 2014 - 19:38:59 CEST