Can I holdup and activate the context-menu as a sub-menu?

M

Michel

I like to show a inbetween selfmade menu when rightclicking the page.
So on the first line I want to add "Default right-click menu".

So first I need to capture it, then I need to stop the context-menu
from showing up, then show a self designed pop-up menu and then I need
to be able to activate the real client-site context-menu from this
menu without clicking the right mouse button.

Any idee welcome, thanks!
 
R

Richard Cornford

Michel said:
I like to show a inbetween selfmade menu when rightclicking
the page. So on the first line I want to add "Default
right-click menu".

So first I need to capture it,

oncontextmenu events, where supported.
then I need to stop the context-menu
from showing up,

That just cannot always be done. Some browsers allow the context menu to
be cancelled and others don't (and others give the user the choice).
then show a self designed pop-up menu and then I need
to be able to activate the real client-site context-menu from this
menu without clicking the right mouse button.

I don't think that can be done at all. Once you have cancelled the
original context menu event that is the end of that so you would need to
induce the browser to re-open it. I am not sure if generating a
contextmenu event would result in the context menu appearing, but
support for creating and triggering your own events is distinctly patchy
anyway.

Richard.
 
M

Michel

Richard Cornford:
oncontextmenu events, where supported.


That just cannot always be done. Some browsers allow the context menu to
be cancelled and others don't (and others give the user the choice).


I don't think that can be done at all. Once you have cancelled the
original context menu event that is the end of that so you would need to
induce the browser to re-open it. I am not sure if generating a
contextmenu event would result in the context menu appearing, but
support for creating and triggering your own events is distinctly patchy
anyway.

Still I like to try it, if only I know how to generate a contextmenu
event from javascript?
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,755
Messages
2,569,537
Members
45,022
Latest member
MaybelleMa

Latest Threads

Top