doyle@infonode.ingr.com (Doyle Davidson) (04/25/91)
Can someone give me a working example of how to pass a widget
as the user data to a callback function from UIL.
My attempts lead to the following error:
Widget resource invalid as callback tag value
This is part of what I do:
procedure PrintMyName(any);
...
callbacks
{
XmNactivateCallback = procedure PrintMyName(XmPushButton mypb);
};
where mypb is an XmPushButton object.
On a related note, I have seen code where callbacks are defined as:
XtCallbackProc mycB(...)
{
...
}
and this does not seem correct since XtCallbackProc is a pointer to a
function that returns void. My ANSI compiler doesn't like it either.
Shouldn't callbacks simply be defined as:
void myCB(...)
{
...
}
Doyle
-------------------------------------------------------------------
Doyle C. Davidson |
Intergraph Corp. | Intergraph - Everywhere you look!!
Third Party Software |
1 Madison Industrial Park |
Huntsville, AL 35806 | These comments are...
(205) 730-2000 |
| X-clusively my own.
..!uunet!ingr!doyle |
- or - doyle@ingr.com |
-------------------------------------------------------------------