当前位置: 首页 > 图文教程 > Flash动画 > Flash动画制作 > FLASH右键菜单的应用

Flash动画制作
实用Flash应用程序—打字练习(2)
实用Flash应用程序—打字练习(4)
有趣的Flash鼠标跟随效果(1)
Flash实例:地下室的幽灵火焰(3)
Flash矢量绘画实例(1)
Flash矢量绘画实例(3)
用Flash MX制作MOV短片(1)
用Flash MX制作MOV短片(2)
实用Flash应用程序—打字练习(1)
Flash实例:地下室的幽灵火焰(2)
教程/dreamweaver/提高 DW MX 2004的Flash Element
教程/FLASH/插件 课件应用:制作弹簧的阻尼振荡效果
教程/flash/技巧 FLASH中响应键盘事件的四种方法
教程/flash/技巧 创建一个Flash站点的注意事项
教程/Flash/实例 用Flash制作互动的小人
教程/FLASH/插件 文字特效制作工具—SwiSHmax
这种相册你有吗?
Flash引领互动动画潮流
简单实用的电影杂点效果
javascript和Flash的通信

Flash动画制作 中的 FLASH右键菜单的应用


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-11-22   浏览: 54 ::
收藏到网摘: n/a

看到别人作了一个右键菜单.感觉不错.其它大家可以多多应用他.所以作个小例子出来. 大家可以应用于演示等地方.

核心代码如下:

var empiremue = new ContextMenu();//删除原始菜单状态!empiremue.hideBuiltInItems();//自定义菜单项目!empiremue.customItems.push(new ContextMenuItem("返回首界面", home));empiremue.customItems.push(new ContextMenuItem("返回到一副", h1));empiremue.customItems.push(new ContextMenuItem("返回到二副", h2));empiremue.customItems.push(new ContextMenuItem("返回到三副", h3));empiremue.customItems.push(new ContextMenuItem("返回到四副", h4));empiremue.customItems.push(new ContextMenuItem("返回到五副", h5));empiremue.customItems.push(new ContextMenuItem("返回到六副", h6));empiremue.customItems.push(new ContextMenuItem("去[闪客帝国]学习", gotoempire));//菜单子程序执行目标...function home() { _root.gotoAndStop(1);}function h1() { _root.gotoAndStop(2);}function h2() { _root.gotoAndStop(3);}function h3() { _root.gotoAndStop(4);}function h4() { _root.gotoAndStop(5);}function h5() { _root.gotoAndStop(6);}function h6() { _root.gotoAndStop(7);}function gotoempire() { getURL("http://www.flashempire.com/school/", "_blank");}_root.menu = empiremue;