-
1. Re: ContextMenu on datatable or extendeddatatable via Right
wark2007 Sep 20, 2008 5:49 AM (in response to rbartl)Hey! There are some other guys looking for that feature too! I hope that it will be ready for 3.3.0. I started a thread some time ago: http://www.jboss.com/index.html?module=bb&op=viewtopic&t=142000
So please vote for it in JIRA. -
2. Re: ContextMenu on datatable or extendeddatatable via Right
rbartl Sep 22, 2008 5:05 AM (in response to rbartl)with a little hack (and no need for the doubleclick event) its possible to capture the right click event and reroute it to an event thats handled by the richfaces contextmenu
just put this under a datatable with a contextmenu activated by doubleclick.
<rich:jQuery selector="#datatable tr td" query="bind('contextmenu',function(e){
var event = 'dblclick';
if (document.createEventObject){
var evt = document.createEventObject();
return this.fireEvent('on'+event,evt)
}
else
{
var evt = document.createEvent('MouseEvents'); evt.initMouseEvent(event, true, true,window, 0, 0,0,e.pageX,e.pageY, false, false, false, false, 0, null );
this.dispatchEvent(evt);
}
})
" /> -
3. Re: ContextMenu on datatable or extendeddatatable via Right
ameo Sep 23, 2008 8:04 PM (in response to rbartl)Had no luck with this work around, could you please porst your xhtml ?