Home » Eclipse Projects » Remote Application Platform (RAP) » Setting Focus on Table to enable UP/DOWN keys for selection
Setting Focus on Table to enable UP/DOWN keys for selection [message #1018263] |
Wed, 13 March 2013 14:18 |
|
Hi!
Maybe I'm doing something wrong, or miss something; I'm trying to setFocus() the focus on a Table, so that following key up/down presses will cause selection in the table. this however just does not work (we're using table in a custom drop down in another shell). When i add a key listener to the table, i get the according events correctly, just nobody evaluates them.
If i have a stand alone table, and manually focus it by clicking into it, up/down works as expected, but i noted that this is obviously handled on the client, not the server, because the selection happens even though i have a breakpoint in the event loop
Any ideas?
Thanks!
Markus
|
|
|
Re: Setting Focus on Table to enable UP/DOWN keys for selection [message #1018824 is a reply to message #1018263] |
Thu, 14 March 2013 14:32 |
Tim Buschtoens Messages: 396 Registered: July 2009 |
Senior Member |
|
|
Hi.
It would really help if you could post a snippet to reproduce the issue
and also tell us what RAP version and browser you are using.
Greetings,
Tim
Am 13.03.2013 15:18, schrieb Markus Duft:
> Hi!
>
> Maybe I'm doing something wrong, or miss something; I'm trying to
> setFocus() the focus on a Table, so that following key up/down presses
> will cause selection in the table. this however just does not work
> (we're using table in a custom drop down in another shell). When i add a
> key listener to the table, i get the according events correctly, just
> nobody evaluates them.
>
> If i have a stand alone table, and manually focus it by clicking into
> it, up/down works as expected, but i noted that this is obviously
> handled on the client, not the server, because the selection happens
> even though i have a breakpoint in the event loop :)
>
> Any ideas?
>
> Thanks!
> Markus
--
Tim Buschtöns
Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/
Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
|
|
| | | | |
Re: Setting Focus on Table to enable UP/DOWN keys for selection [message #1104390 is a reply to message #1103332] |
Sun, 08 September 2013 08:58 |
Ivan Furnadjiev Messages: 2426 Registered: July 2009 Location: Sofia, Bulgaria |
Senior Member |
|
|
Hi Arnaud,
in order to use the keyboard navigation you need the focused item to be
set. Focused item is set by using Table#setSelection, but not with
Table#select. If I remember correctly, depends on virtuality of the
Table (VIRTUAL is set or not), select is used by TableViewer instead
setSelection. Please try getTableViewer().getTable().setSelection( 0 ).
Of course you could step into getTableViewer().setSelection and ensure
that Table#setSelection is used internally.
HTH,
Ivan
On 9/6/2013 7:29 PM, Arnaud MERGEY wrote:
> Hello,
> I think I hit a similar issue.
>
> Even by setting focus on a table inside a dialog, it is not possible to use keyboard navigation, without clicking on the table.
>
> I attached a snippet that reproduces the issue.
>
> Best regards,
> Arnaud
--
Ivan Furnadjiev
Twitter: @EclipseRAP
Blog: http://eclipsesource.com/blogs/
Professional services for RAP and RCP?
http://eclipsesource.com/services/rap/
|
|
| |
Goto Forum:
Current Time: Fri Apr 26 19:34:50 GMT 2024
Powered by FUDForum. Page generated in 0.05884 seconds
|