Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Nebula » [Grid] ComboBoxCellEditor doesn't return focus to the Grid
[Grid] ComboBoxCellEditor doesn't return focus to the Grid [message #592379] Sat, 27 September 2008 23:03
Gregory Dyke is currently offline Gregory DykeFriend
Messages: 8
Registered: July 2009
Junior Member
This time I think I'm on a "real" problem.

I have two kinds of celleditors which I use in my Grid:

- TextCellEditor
- ComboBoxCellEditor

I'm currently implementing keyboard only input. The eclipse 3.3 editing
support stuff is very nice. When I validated/cancel a TextCellEditor
(through ret/esc) focus is returned to the cell and it has a thick black
rectangle around it indicating selection. I can then move to the next cell
with the arrow keys.

When I validate/cancel a ComboBoxCellEditor, the combobox disappears and
the cell appears to be back to normal, but the selection rectangle is
thin. The grid appears to no longer have keyboard focus.

I really don't understand GUI programming very well. I notice that
ComboBoxCellEditor has this snippet:

comboBox.addTraverseListener(new TraverseListener() {
public void keyTraversed(TraverseEvent e) {
if (e.detail == SWT.TRAVERSE_ESCAPE
|| e.detail == SWT.TRAVERSE_RETURN) {
e.doit = false;
}
}
});

Might this e.doit = false; be the culprit? What is this code there for? If
I understand correctly, it prevents the event from bubbling up?

Regards

Greg
Previous Topic:[Grid] DefaultCellRenderer and wordwrap
Next Topic:Grid - how do you provide image for row header?
Goto Forum:
  


Current Time: Fri Apr 26 18:29:48 GMT 2024

Powered by FUDForum. Page generated in 0.03110 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top