• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Jeanne Boyarsky
  • Ron McLeod
Sheriffs:
  • Paul Clapham
  • Liutauras Vilda
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
Bartenders:

JTabel and JMenuItem accelerators

 
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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.
 
Ranch Hand
Posts: 40
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Do you have any MouseListener interfaces implemented in your cells?
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic