Posted by ¹ÚÁ¾¿í on July 26, 1997 at 21:11:25:
In Reply to: TextField¿¡¼ Event¸¦ ´Ù·ç´Â ¹æ¹ýÀ» Á» ... posted by °¹®ÁÖ on July 23, 1997 at 16:03:32:
TextField ³ª TextArea¿¡¼ À̺¥Æ® 󸮴 ActionEvent
Ŭ·¡½º¸¦ »ç¿ëÇÕ´Ï´Ù.
enterÅ°°¡ ´·¯ Á³À»¶§ ¹ß»ýÇÏ´Â À̺¥Æ®ÀÌÁö¿ä
ÀÌ°ÍÀ» »ç¿ëÇÏ·Á¸é
public class TextFieldEventTest extends Frame
{
.....
TextField tf = new TestField("test",10);
....
public TextFieldEventTest()
{
.....
add(tf);
* ActionListener al = new ActionListener()
* {
* public void actionPerformed(ActionEvent ev)
* {
* À̺¥Æ® ¹ß»ý½Ã ó¸®ÇÒ ³»¿ë...
* }
* };//Listener »ý¼º
tf.addActionListener(al); //À̺¥Æ® µî·Ï
}
....
}
* -> À̺κÐÀÌ À̺¥Æ®Ã³¸®ºÎºÐÀÔ´Ï´Ù.
µµ¿òÀÌ ¿Ü¾ú´ÂÁö ¸ð¸£°Ú±º¿ä.
¿½ÉÈ÷ Çϼ¼¿ä.