There are good examples in the docs for this.
I haven't tested this code but generally you can do something like ---

myItem.contextMenu=generateContextMenu();// set the context menu


// generate the context menu
public function generateContextMenu():ContextMenu{
     var menu:ContextMenu=new ContextMenu();
     menu.hideBuiltInItems();
     var item:ContextMenuItem=new ContextMenuItem("tester");
     menu.customItems.push(item);
     item.addEventListener(ContextMenuEvent.MENU_ITEM_SELECT,itemHandler)
     return(menu);

}
//handler to handle the press
private function itemHandler(event:ContextMenuEvent):void{
trace("the menu item was hit");
}

/////////////////////////////////////////

> speaking of sunday morning hangover, it's CONTEXT not CONTENT :D ...
> sorry
>
> dos dedos <[EMAIL PROTECTED]> wrote:
> Hi
>
> When I right-click on Flash/flex content I get the Adobe "About" context
> menu...
>
> It would be very nice to have a context menu that relates to the
> functionality of your application not the functionality of the Flash
> player.
>
> I believe I had heard it was possible ...
>
> How?
>
> Thanks a lot in advance
>
>
> dos
>
> ---------------------------------
> New Yahoo! Messenger with Voice. Call regular phones from your PC and
> save big.
>
>   --
>  Flexcoders Mailing List
>  FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
> Search Archives:
> http://www.mail-archive.com/flexcoders%40yahoogroups.com
>
>
>
> ---------------------------------
>    YAHOO! GROUPS LINKS
>
>
>     Visit your group "flexcoders" on the web.
>
>     To unsubscribe from this group, send an email to:
>  [EMAIL PROTECTED]
>
>     Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
>
>
>
> ---------------------------------
>
>
>
>
>
> ---------------------------------
> Yahoo! Messenger with Voice. PC-to-Phone calls for ridiculously low
> rates.





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to