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

Flash动画制作
FLASH8.0鼠绘实例(2):戴礼帽的美女
FLASH8.0鼠绘实例(3):Q版卡通可爱小女孩
FLASH8.0鼠绘实例(4):Q版卡通漫画女孩
FLASH8.0鼠绘(5):坐在凳子上的气质女孩
FLASH8.0鼠绘教程(7):窈窕淑女
NetConnection.Connect的几种错误
Flash动画角色绘画漫谈
Flash新手鼠绘(13):绘制飞翔的燕子
Flash新手鼠绘(14):燕语春风图
Flash鼠绘(15):触角细长腹部肥大的螳螂
Flash鼠绘(18):可爱的卡通拜年牛
flash钢笔工具的使用方法
Flash绘画技巧:熟练应用画笔工具
Flash绘画技巧:熟练应用钢笔工具
Flash中如何表现不同材质的层次感
分析flash mmorpg地图的实现
Flash cs3转换位图为矢量图
Flash cs3教程:熟练应用直线工具
Flash CS3教程:形状的应用
Flash CS3教程:绘制选择

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


出处:互联网   整理: 软晨网(RuanChen.com)   发布: 2009-11-22   浏览: 25 ::
收藏到网摘: 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;