Le 2011-12-14 à 12:49:00, Ivica Ico Bukvic a écrit :
So what part of the code specifically binds keyboard and mouse actions
to a canvas?
Look for the name as it appears in Tcl commands going to Pd. From what it
looks like in commands to/from Tcl, you can see that it is a ".x%lx"
format-string. You can find that this exact format string is used in
editor_new (whereas all other cases use longer format strings intended
directly for sys_vgui).
This string is used as an argument to guiconnect_new, which calls pd_bind.
Also, editor_free calls guiconnect_notarget which schedules
guiconnect_free which calls pd_unbind.
I thought this was never explicitly bound but is rather a result of
tcl/tk simply reporting events within a specific canvas whose name was
given to it by its memory allocation.
Implicit binding is a DesireData-only feature, in which binbuf_eval
handles a « no such object » error by reparsing the receive-symbol as a
t_pd*, after checking that it exists (object_table->exists(target)) and
that it's a non-zombie (object_table->get(target)). This allows for
deleting the whole guiconnect business, including deleting the bug that
we're talking about.
______________________________________________________________________
| Mathieu BOUCHARD ----- téléphone : +1.514.383.3801 ----- Montréal, QC
_______________________________________________
Pd-dev mailing list
Pd-dev@iem.at
http://lists.puredata.info/listinfo/pd-dev