callbacks in uil...

This forum is read only. No new submissions are accepted.

Questions about motif? Contact us

2 posts / 0 new
Last post
callbacks in uil...

Submitted by Anonymous (not verified) on Fri, 06/15/2012 - 12:07

I have defined a callback, called quit, and assigned to resource for a pushbutton in uil file. When the appications is launched, i get the following message:
Warning: Urm__CW_FixupCallback: Callback routine 'quit' not registered - MrmNOT_FOUND
Consequently, callback is not called when button is depressed.
Do I need to register this callback in the application code? :(
‹ XmScale Trough Color UIL dumps core for unknown reason ›

gray45

Thu, 10/13/2005 - 03:34#1

callbacks in uil...

Hope you haven't been waiting all this time for the answer, but yes, you do need to register callbacks in the application code. Assuming you're writing in C, here's what you would add to the application:

static MrmRegisterArg callback_list[] = {
{"quit", (XtPointer) quit},
/* Additional callbacks */
};

MrmRegisterNames(callback_list, (MrmCount) XtNumber(callback_list));

Note: Using the XtNumber function in the second argument above allows you to add new callbacks to the list without having to remember to change the count in the resgister call.