This is a discussion on RightClick option for menu in Flash within the Flash Actionscript Programming forums, part of the Web Development category; Does anyone know about the RightClick option for menu in Flash...
| |||||||
| Register | FAQ | Members List | Calendar | Mark Forums Read |
|
#1
| |||
| |||
| Does anyone know about the RightClick option for menu in Flash Last edited by Booom : 08-13-2007 at 11:19 PM. |
|
#2
| |||
| |||
| Hi.. here is your answer.. Right Click menu in Falsh Goals: This project is used to create a right click menu. Steps: 1) Create a Flash document. 2) Create a movieclip and right click the movieclip and goto action. 3) Copy the following code: onClipEvent(load) { //MENU.customItems.push(Functioned2); MENU = new ContextMenu(); MENU.hideBuiltInItems(); Functioned = new ContextMenuItem("This movie is copyrighted by Your Company Name", doSomething); Functioned2 = new ContextMenuItem("Visite Our Website", doSomething2); MENU.customItems.push(Functioned); MENU.customItems.push(Functioned2); _root.menu = MENU; function doSomething() { } function doSomething2() { getURL("http://www.test.com", _blank); } } |
|
#3
| |||
| |||
| Hi try this logic it will be very usefull and simple function menuCallback(obj, menuObj) { menuObj.customItems = []; if ((obj instanceof MovieClip) && (obj != _level0)) { menuObj.customItems.push(cutItem); menuObj.customItems.push(copyItem); menuObj.customItems.push(pasteItem); } } function mnuCut_click() { trace("cut"); } function mnuCopy_click() { trace("copy"); } function mnuPaste_click() { trace("paste"); } var myMenu = new ContextMenu(menuCallback); var cutItem = new ContextMenuItem("Cut object", mnuCut_click); var copyItem = new ContextMenuItem("Copy object", mnuCopy_click); var pasteItem = new ContextMenuItem("Paste object", mnuPaste_click); MovieClip.prototype.menu = myMenu;
__________________ SeeSamJagan- Sky is not the "LIMIT", Death is not the END, There is still something beyond.... |
![]() |
| Thread Tools | |
| Display Modes | |
| |
Similar Threads | ||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| How to Populate menu using sitemap and asp .net menu control and c#: | Archer | C# Programming | 3 | 04-29-2008 09:23 PM |
| ONE SHOT option in Mysql | Murali | Database Support | 0 | 12-13-2007 04:00 AM |
| double clicking the option in drop down list menu | vijayanand | HTML, CSS and Javascript Coding Techniques | 3 | 08-06-2007 06:27 AM |
| How to disable right click option? | Sabari | HTML, CSS and Javascript Coding Techniques | 1 | 07-23-2007 09:55 PM |
| Vertical menu or horizontal menu? | capture | Web Design Help | 1 | 03-12-2007 06:25 PM |
Our Partners |