Of course there is .
I made sample while ago but prior to typing please clarify whether is it
a projector or web based flash movie .
Regards
urami_*
<lsym>
There's no place like 127.0.0.1
</lsym>
It is an exported flashmovie in the swf format. In browser also i want to
hide the right click menu ? Is there any way to sense the right click in a
flash movie
Regards
Sure there is , catch right click and entirely hide the macromedia menu.
It was annoying me for years so I eventually found way to work around.
Especially that I do lots of flash work that require both flash buttons .
http://www.flashfugitive.com/ang-zhang/rightC/rightclick.html
NOTE !
Only IE on windows support that .
First we need to make few crucial setting in flash .
Add listener and set up appropriate Window Mode for that flash movie.
So , after you load your content, in case if you use preloader, on frame where your
movie start , please movie clip with instance name MENU , it will act on mouse right click,
and the following action to same frame where the MENU is :
this.mouseListener = new Object (this);
this.mouseListener.onMouseDown = function () {
if (this.menu.hitTest(_root._xmouse, _root._ymouse, true) != true) {
this.menu.gotoAndStop(1);
}
};
Mouse.addListener(this.mouseListener);
NOTE ! make the MENU with two frames , first frame stop action second frame your right click content.
Now go to File - Publish Setting - HTML ,
look for Window Mode and pick the Opaque Windowless
after you hit the PUBLISH it will add parameter in your html body
<PARAM NAME=wmode VALUE=opaque>
and
<EMBED quality=high wmode=opaque
We need it to work on the right click .
Now after you generated the HTML with all necessary tags , modify it by adding :
in the <head>
<script language="JavaScript">
<!--
function removeMenu(){
if (event.button == 2){
myMovie.TGotoFrame("/menu", 2);
parent.frames.location.replace('javascript: parent.dummy1');
}
}
//-->
</script>
Than add before flash movie tags which start with <OBJECT classid="
<div onMouseDown="removeMenu()">
and after the </object> where is end of the flash tags </div>
all :
<HTML>
<HEAD>
<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
<TITLE>rightclick</TITLE>
<script language="JavaScript">
<!--
function removeMenu(){
if (event.button == 2){
myMovie.TGotoFrame("/menu", 2);
parent.frames.location.replace('javascript: parent.dummy1');
}
}
//-->
</script>
</head>
<body leftmargin="0" topmargin="0">
<div onMouseDown="removeMenu()">
<OBJECT classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,0,0" name="myMovie"
WIDTH="900" HEIGHT="600" ALIGN="" id="rightclick">
<PARAM NAME=movie VALUE="rightclick.swf">
<PARAM NAME=quality VALUE=high>
<PARAM NAME=wmode VALUE=opaque>
<PARAM NAME=menu VALUE=false>
<PARAM NAME=bgcolor VALUE=#99CC00>
<EMBED src="rightclick.swf" quality=high wmode=opaque menu=false bgcolor=#99CC00 WIDTH=900" HEIGHT="600" NAME="myMovie"
ALIGN=""
TYPE="application/x-shockwave-flash" PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer"
swliveconnect="true"></EMBED>
</OBJECT></div>
</BODY>
</HTML>
That's pretty much it ....