var menu:ContextMenu = new ContextMenu();
menu.hideBuiltInItems();
var menuItem:ContextMenuItem = new ContextMenuItem("Go to google");
menuItem.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT, goToContextMenu);
menu.customItems.push(menuItem);
this.contextMenu = menu;
function goToContextMenu(event:ContextMenuEvent):void {
var link:URLRequest = new URLRequest("http://www.google.com");
navigateToURL(link,"_blank");
}
Welcome to my actionscript snippet library!
Actionscript Snips is a small repository of actionscript code that aims to save developers and designers time when developing a website.
Right-Click Context Menu
Posted by
admin
on Friday, October 23, 2009
Labels:
Objects
0 comments:
Post a Comment