首页 > web前端 > js教程 > 推荐:极酷右键菜单_典型特效

推荐:极酷右键菜单_典型特效

WBOY
发布: 2016-05-16 19:23:48
原创
971 人浏览过

复制代码 代码如下:

点击右键看看!


onmousedown="down=true;divleft=event.clientX-parseInt(plane.style.left);
divtop=event.clientY-parseInt(plane.style.top)" onmouseup="down=false">
height:19px; z-index:1;color:white;background:707888;cursor:default;" class="none" 
onmouseover="menuin();init()">右键菜单

height:19px; z-index:2; filter:alpha(opacity=0)" onmouseover="this.className='over';menuin()"
onmouseout="this.className='none';" class="none"
>网络学院

class=none onmouseover="this.className='over';menuin()"
onmouseout="this.className='none';">菜单项二

class=none onmouseover="this.className='over';menuin()"
onmouseout="this.className='none';">菜单项三

class=none onmouseover="this.className='over';menuin()"
onmouseout="this.className='none';">菜单项四
 
class=none onmouseover="this.className='over';menuin()"
onmouseout="this.className='none';">菜单项五


<script> <BR>dim down,divleft,divtop,timelinestart,timelinestop,tidone,tidtwo,tidtree <BR>down=false <BR>timelinestart=0 <BR>timelinestop=0 <BR>sub document_onmousedown <BR>if window.event.button=2 then <BR>plane.style.display="" <BR>plane.style.left=window.event.clientx-153 <BR>plane.style.top=window.event.clienty-35 <BR>end if <BR>end sub <BR>sub document_onmousemove <BR>if down then <BR>plane.style.left=window.event.clientx-divleft <BR>plane.style.top=window.event.clienty-divtop <BR>end if <BR>end sub <BR>sub document_ondargstart <BR>window.event.returnvalue=false <BR>end sub <BR>function menuin() <BR>cleartimeout(tidtree) <BR>end function <BR>sub document_onclick <BR>tidtree=settimeout("outit()",200) <BR>end sub <BR>function init() <BR>if timelinestart<>5 then <BR>cleartimeout(tidtwo) <BR>item1.style.pixelLeft=item1.style.pixelLeft+20 <BR>item1.filters.alpha.opacity=item1.filters.alpha.opacity+20 <BR>item2.style.pixelLeft=item2.style.pixelLeft-20 <BR>item2.filters.alpha.opacity=item2.filters.alpha.opacity+20 <BR>item3.style.pixelLeft=item3.style.pixelLeft+20 <BR>item3.filters.alpha.opacity=item3.filters.alpha.opacity+20 <BR>item4.style.pixelLeft=item4.style.pixelLeft-20 <BR>item4.filters.alpha.opacity=item4.filters.alpha.opacity+20 <BR>item5.style.pixelLeft=item5.style.pixelLeft+20 <BR>item5.filters.alpha.opacity=item5.filters.alpha.opacity+20 <BR>timelinestart=timelinestart+1 <BR>else <BR>cleartimeout(tidone) <BR>end if <BR>tidone=settimeout("init()",1) <BR>end function <BR>function outit() <BR>if timelinestart<>0 then <BR>cleartimeout(tidone) <BR>item1.style.pixelLeft=item1.style.pixelLeft-20 <BR>item1.filters.alpha.opacity=item1.filters.alpha.opacity-20 <BR>item2.style.pixelLeft=item2.style.pixelLeft+20 <BR>item2.filters.alpha.opacity=item2.filters.alpha.opacity-20 <BR>item3.style.pixelLeft=item3.style.pixelLeft-20 <BR>item3.filters.alpha.opacity=item3.filters.alpha.opacity-20 <BR>item4.style.pixelLeft=item4.style.pixelLeft+20 <BR>item4.filters.alpha.opacity=item4.filters.alpha.opacity-20 <BR>item5.style.pixelLeft=item5.style.pixelLeft-20 <BR>item5.filters.alpha.opacity=item5.filters.alpha.opacity-20 <BR>timelinestart=timelinestart-1 <BR>else <BR>cleartimeout(tidtwo) <BR>plane.style.display="none" <BR>exit function <BR>end if <BR>tidtwo=settimeout("outit()",1) <BR>end function <BR></script>
相关标签:
来源:php.cn
本站声明
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系admin@php.cn
热门教程
更多>
最新下载
更多>
网站特效
网站源码
网站素材
前端模板