As2:
[code]
var _amyflash = new ContextMenu();
//删除原始菜单状态!
_amyflash .hideBuiltInItems();
//自定义菜单项目!
_amyflash .customItems.push(new ContextMenuItem("copyright:amyflash", home));
//菜单子程序执行目标...
function home() {
getURL(";http://amyflash.duapp.com//", "_blank");
}
_root.menu = _amyflash;
[/code]
As3:
[code]
var myContextMenu:ContextMenu = new ContextMenu();
myContextMenu.hideBuiltInItems();
//声明菜单新项
var item:ContextMenuItem = new ContextMenuItem("@author amyflash");
//添加到菜单显示项目数组
myContextMenu.customItems.push (item);
root.contextMenu = myContextMenu;

//点击按钮引发该事件
item.addEventListener (ContextMenuEvent.MENU_ITEM_SELECT ,mouseRelease);
function mouseRelease (event:ContextMenuEvent):void
{
navigateToURL(new URLRequest("http://amyflash.duapp.com/"));
}
[/code]