You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add a "preShow" callback, to conditionally show context menu or not. #669
In our case we want the jquery context menu to appear if the user right-clicks anywhere on the screen, but have the browsers native context menu to appear if they right-click on a textarea, input box, or some other special element of our choosing. One of the main reasons is that if you turn off right-click to get to browser native copy/cut/paste/translate/etc... actions, users seem to complain pretty loudly.
I realize there are ways to get this behavior right now, but from my understanding they are pretty difficult in our case, specifically when the selector is dynamic and where their may be multiple different context menus registered.
As an easy work around, if you could simply register a "preShow" callback (I think jQuery-ui tabs does something like this), that passes in the event, and the current contextmenu object, we could then make any decisions we want and either cause the context menu to appear, not appear, or show the browser native context menu based on the return value of that callback.
Activity
bbrala commentedon Oct 22, 2018
Yeah that is a great idea.
Pre-Show callback to display native menu
bshafiei-ir commentedon May 26, 2019
I need it too.
@bbrala
bbrala commentedon May 26, 2019
I will make some time this week to get going on issues, have been a bit swamped lately.