sure you must add keyListener for all TextBox .
But if you create one method,it 's smart.

example for

private void addListeners(List<TextBox> textboxs ,Listener listener){
for(int i=0;i<textboxs.size;i++){
     textboxs.get(i).addKeyListener(listener);
}
}
2013/03/14 7:02 "membersound" <kodyreco...@gmail.com>:

> Hi,
>
> I have a popup with a bunch of TextBox and TextArea fields. Also 3 Buttons
> like Save, Cancel, Reset.
> For the TextBoxes I would like to trigger the Save action if ENTER is hit
> while inside a TextBox (not for the TextAreas).
>
> Would I have to register a KeyDownHandler for all the TextBoxes (which
> would be lots of boilerplate code)? Or is there anything native in GWT
> catching ENTER key in TextBoxes?
>
> --
> You received this message because you are subscribed to the Google Groups
> "Google Web Toolkit" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to google-web-toolkit+unsubscr...@googlegroups.com.
> To post to this group, send email to google-web-toolkit@googlegroups.com.
> Visit this group at
> http://groups.google.com/group/google-web-toolkit?hl=en.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to