Question:

I have one small problem i.e. one textbox is their when click on the text box the popup is shows below the text box.The popup contains celltable

i write keypresslisner for textbox when i press Down And UP arrow the focus is set to be cellTable And also we still press down and up arrows its highlites the rows in celltable

Ans:

The question is a little bit unclear, but I think you may be helped by FocusPanel:

http://google-web-toolkit.googlecode.com/svn/javadoc/2.0/com/google/gwt/user/client/ui/FocusPanel.html

Wrap your CellTable in this FocusPanel and you can do setFocus() on that instead. TheFocusPanel has addKeyPressHandler(), so you can capture further keypress events there, also when your textbox has lost the focus.

資料來源:http://stackoverflow.com/questions/4303953/focus-key-board-listner-problem-in-cell-table-in-gwt 


    Frank 發表在 痞客邦 留言(0) 人氣()