I'm working with Eclipse Standard Widget Toolkit (SWT), I have a TreeView object with items and an double click event (addDoubleClickListener) works fine, but I don't know how implement the right click for delete an item.
Asked
Active
Viewed 596 times
1 Answers
0
To listen to right clicks, use
addMenuListener
. Eclipse RCP has its own more advanced mechanisms, but this should be enough for your purposes.In
SelectionListener
for yourMenuItem
, remove the item from your model and refresh the viewer.

Community
- 1
- 1

Alexey Romanov
- 167,066
- 35
- 309
- 487