lose request focus  
Author Message
ypox13p





PostPosted: 2006-2-10 18:28:00 Top

java-programmer, lose request focus hello
I have some buttons on my UI and a textfield.
when the user dont click one of my buttons the focus from the textfiled
is lost
how solve this?

in onEvent(Event event)
{
if(event.target==button1)
do something
else if(event.target==button)
..........

like this is going......


what should I add to the method to catch the event(click somewhere in
UI,but not in my object(buttons......)) properly?

 
Andrey Kuznetsov





PostPosted: 2006-2-14 10:05:00 Top

java-programmer >> lose request focus > I have some buttons on my UI and a textfield.
> when the user dont click one of my buttons the focus from the textfiled

you mean surely "do click"

> what should I add to the method to catch the event(click somewhere in
> UI,but not in my object(buttons......)) properly?

just make your buttons nonfocusable

--
Andrey Kuznetsov
http://uio.imagero.com Unified I/O for Java
http://reader.imagero.com Java image reader
http://jgui.imagero.com Java GUI components and utilities