• Post Reply Bookmark Topic Watch Topic
  • New Topic

JTabel and JMenuItem accelerators

 
Sebastiaan Kortleven
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi there,

I've got a editable JTable. When one of the cells has focus and I press an accelerator (bound to a JMenuItem, eg CTRL-M), the action connected to that JMenuItem is executed, but the cell which had focus starts his CellEditor.
This happens for all my accelerators.

This is the behaviour I would like if I'm not using an accelerator..
Is there a way for the JTabel to distinguise the difference between an pressed accelerator and a normal pressed key.

A bit less nice, but would work: is there a way I could let the JTable ignore keys pressed while the CTRL key is pressed?

Thanks!

Sebastiaan.
 
Ryan Smith
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Do you have any MouseListener interfaces implemented in your cells?
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!