Hi!

THIS means that you add an event listener to the group of event listeners of
the event handling method of the class who has the scope there.

In other words: the same way you add the button - add(button) - you have to
add the actionListener to be handled by actionPerformed method of THIS
class.


Best regards,
Maxx [EMAIL PROTECTED]

----- Original Message -----
From: Nicolas Raitman <[EMAIL PROTECTED]>
To: Java <[EMAIL PROTECTED]>
Sent: Thursday, October 05, 2000 7:38 PM
Subject: Events


> Hi to all. I am very lost with handling events in Java, so I have some
> questions, suppose I have this:
> It is an applet. Of course, most of the code has been omitted.
>
> public void init()
> {
>
> Button button1;
> button1 = new Button("OK")
>
> add(button1);
> button1.addActionListener(this); // in the first place, what does this
> 'THIS' mean ?
> }
>
>
>
>
> ----------------------------------------------------------------------
> To UNSUBSCRIBE, email to [EMAIL PROTECTED]
> with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]
>


----------------------------------------------------------------------
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to