Basically, you define the message in the class like this:
@class MyDoClass, GenProcessClass;
@message void MSG_DO_SOMETHING(int i, int j, char *someString);
/* more messages and instance data can go here */
@endc;
@classdecl MyDoClass;
Later you write the message handler like this:
@method MyDoClass, MSG_DO_SOMETHING /* parameters are already known */
{
/* code goes here */
}
Hope that helps,
- -Ed-
On Fri, 5 Jul 1996 tzz@acs.bu.edu wrote:
>
> I am sure this is very simply answered. I could not figure it out
> or find it in the docs on my own though.
>
> How do I declare a message which has parameters? Similar to the
> button1 down message where you get xPos and yPos, how can I
> have a message like MSG_DO_SOMETHING(5, 1, "Alpha") ?
>
> Just a pointer to the relevant section in the manuals would
> be enough.
>
> Ted
>