Marker Right click event in Open Layers Map


Is there any way i can catch a right click event over a Marker?
i added a MouseEvents.ClickListener to the marker but it only catches the left clicks, the right ones are ignored.
I noticed that the OpenLayersMap have an action handler that can be used for right click events but it’s usuless for me as i need it on marker level.

Any Suggestions???


Hey did you find a solution for this ?

i Tried this but the event return a null point exception

marker.addClickListener(new ClickListener() {
		private static final long serialVersionUID = 1L;

		public void click(com.vaadin.event.MouseEvents.ClickEvent event) {
				if(event.getButton() == com.vaadin.event.MouseEvents.ClickEvent.BUTTON_RIGHT){
                                               //Do something


i just used the left mouse click.
if you debug your code nothing happens, coz only left mouse click is supported for markers.
you can always make a custom context menu with the left mouse click when the item is clicked.



[/center]Ok thanks , yes i tried the handler but the problem with the contextMenu is you can get just the position X and Y But me I want the Object Marker cause i save some beans at the Marker.