I am trying to setup a context menu on a list item which is draggable.
Problem is the mousedown event is triggered in onBeforeDrag before the contextmenu() event and therefore I cannot prevent the drag, and fire the menu;
$('ul.ulbar li').on('contextmenu', function(e){
e.preventDefault();
e.stopPropagation();
do something else .....
});
('ul.ulbar li ').draggable({
onBeforeDrag: function(e){
if(e.type != 'contextmenu') return true;
e.preventDefault();
e.stopPropagation();
}
})