🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.lang.java.programmer
Article #182

bug in Event class under IE

#182
From: aag
Date: Sun, 12 Nov 2000 00:00
49 lines
2185 bytes
hello all,
I am required to maintain some java code using the Event class and I have 
noticed that, under Internet Explorere (v5 & 5.5 at least), the TAB key does 
NOT register a KEY_PRESSED notice for the TextArea class. It, of course, works 
as expected under Netscape.

Is this a known bug or am I doing something wrong? Any help would be 
appreciated.


trying the following code results in KEY_RELEASE notices but no KEY_PRESSED 
notices under IE when TAB key is hit.


import java.awt.*;

public class TestTextArea extends TextArea
{
  public TestTextArea(String s)
  {
    super(s);
  }

  public boolean handleEvent(Event event)
  {

if (event.id == Event.ACTION_EVENT)
  System.out.println("ACTION_EVENT");
else if (event.id == Event.KEY_PRESS)
  System.out.println("KEY_PRESS  [key: "+event.key+"]");
else if (event.id == Event.KEY_RELEASE)
  System.out.println("KEY_RELEASE  [key: "+event.key+"]");
else if (event.id == Event.KEY_ACTION)
  System.out.println("KEY_ACTION");
else if (event.id == Event.KEY_ACTION_RELEASE)
  System.out.println("ACTION_RELEASE");
else if (event.id == Event.LOST_FOCUS)
  System.out.println("LOST_FOCUS");
else if (event.id == Event.GOT_FOCUS)
  System.out.println("GOT_FOCUS");
else
  System.out.println("UNKNOWN Action");

    return (super.handleEvent(event));
  }
}


Any help would be appreciated.
Technical Details
Message-ID: <8un5vr$iqm$1@perki.connect.com.au>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: 10a146,7f1123ae8318e20a,start
X-Google-Attributes: gid10a146,public
X-Google-Thread: 10d6db,7f1123ae8318e20a,start
X-Google-Attributes: gid10d6db,public
X-Google-Thread: 113ae9,7f1123ae8318e20a,start
X-Google-Attributes: gid113ae9,public
From: gaspa@anl.com.au (aag)
Subject: bug in Event class under IE
Date: 2000/11/12
Message-ID: <8un5vr$iqm$1@perki.connect.com.au>
X-Deja-AN: 692850808
Content-Type: Text/Plain; charset=US-ASCII
X-Complaints-To: abuse@connect.com.au
X-Trace: perki.connect.com.au 974068539 19286 210.8.200.2 (12 Nov 2000 22:35:39 GMT)
Organization: ANLCL
Mime-Version: 1.0
NNTP-Posting-Date: 12 Nov 2000 22:35:39 GMT
Newsgroups: comp.lang.java.programmer,comp.lang.java.help,aus.computers.java