United StatesChange Country, Oracle Worldwide Web Sites Communities I am a... I want to...
Bug ID: 4022670 Ambiguous key events are sent to application on TextComponent/TextFiled/TextArea
4022670 : Ambiguous key events are sent to application on TextComponent/TextFiled/TextArea

Details
Type:
Bug
Submit Date:
1996-12-18
Status:
Closed
Updated Date:
1998-05-21
Project Name:
JDK
Resolved Date:
1998-05-21
Component:
client-libs
OS:
solaris_2.5.1
Sub-Component:
java.awt
CPU:
generic
Priority:
P4
Resolution:
Not an Issue
Affected Versions:
1.1
Fixed Versions:

Related Reports
Relates:

Sub Tasks

Description
All of key events are sent to applications on Text components(TextComponent/
TextFiled/TextArea) without consuming those in text conponents. Application
now can get all key events when key listener is implemented.
Since text components get key events and dispatch text event instead,
text components should consume all of key event. Those shouldn't be sent to applications. This action confuses programmer.

I attached a sample program which gets KeyEvent on the TextField
and print its event type on the command line if it can be.

On runing a sample program, it can get all of key events
when a key is pressed and released. Since TextField dispatchs text events
instead as key input events, keyevent should be consumed and not sent to
its subclass. 

                                    

Comments
SUGGESTED FIX

 
                                     
2004-06-11
WORK AROUND

 
                                     
2004-06-11
EVALUATION

[aim 1/14/97]
The description in this bug report is much too vague - I do not at all
understand what the problem is.  If you wish something to be done on
this bug, please provide more detail on the problem (preferably with
sample code which displays the problem).

[koji 1/28/95]
I updated bug report. please review it.

Name: rrT76497			Date: 05/21/98

ECJohn/SIPtech May 18,98This does not seems to be a bug. In
the attached code the bug
submitter implements a key listener. So it is natural for events to go
to
this key event interested object and back to the peer.[since boolean
consume
is kept false otherwise] .Anyway TextEvent does not consume any
keyevents.
If a TextEvent happens ie a change on the data in the field, that wo'nt
go back to the peer.[since in AWTEvent constructor for textevent
consume=true]





======================================================================
                                     
2004-06-11
PUBLIC COMMENTS

 
                                     
2004-06-10



Hardware and Software, Engineered to Work Together