views:

138

answers:

3

hey, I want to use jQuery.contextMenu (http://abeautifulsite.net/blog/2008/09/jquery-context-menu-plugin/) in jQuery.fullcalendar.. when i right-click on an event.. but how it works?

A: 

i don't know the contextmenu plugin but i think you can bind it on the evenRender event of fullcalendar. I have the problem with dblClick on an event.

This is a part of my solution:

eventRender: function(event, element) {

                        element.bind('dblclick', function() {
                        dopbClickFunction(event,element);           .......

hope this helps, kind regards

Sinderella_42
oh yes, EventRender.. that's it =) thank you!!
Franky
A: 

I am in the same case. Can you pliz supply us the result? I have make that:

eventRender: function(event, element) {
                element.contextMenu({
                menu: 'myMenu'
                },
                function(action, el, pos) {
                contextMenuWork(action, el, pos);

            });    
        }

but that does not work ! :(

diwa
A: 

Hi, I'm solving exactly the same problem. For me it worked doing the 2 following steps:

1 - code

eventRender: function(calEvent,element){
        element.bt({ ajaxPath: 'ajEvents.asp?opt=getExtendedEvent&valore=' +  calEvent.id,  trigger: 'hover', width: 200 });
        //only for tooltip
        element.contextMenu('myMenu',{bindings:{'idVoce': function(t){ alert('right click on ' + calEvent.id) } } })
    } 

I presume you already have defined the myMenu div...

2 - modify zindex in contextmenu, let's say from 500 to 2500 and from 499 to 2499. This is important if you have your calendar in a dialog window (like myself), otherwise it would go under the visible layer

2.Logic