Web Hosting Deals Holiday Logo Design Webcam Chat Website Header Templates Register domain Search Engine Optimisation Web Hosting
Go Back   Talk Mania Forum > Tutorials > Flash / Dreamweaver / Fireworks tutorials from Talk-Mania members

Flash / Dreamweaver / Fireworks tutorials from Talk-Mania members Please post your Flash / Dreamweaver / Fireworks in this area. Look here to the see the tutorials and methods outlined by other Talk-mania members.

 Image
Buy Sell Downloads

Reply
 
Submit Tools LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 10-18-2007, 11:14 AM
Junior Member
 
Join Date: May 2007
Posts: 14
smugl3r is on a distinguished road
Wink Custom right click menu in Flash

Today i´ll show you how to build custom right click menu in Flash. This is the 2nd tutorial in 20 tutorials marathon.

Step 1

Open a new flash document and create some button shape. After that take the Text Tool (T) and type Right click.



Step 2

Click on the first frame of layer 1, open the Action Script Panel (F9) and paste this script:

Code:
function menuChoiceOne()
{
 getURL("http://www.google.com");
}
function menuChoiceTwo()
{
 getURL("http://www.talk-mania.com");
}
function menuChoiceThree()
{
        getURL("http://www.pixel2life.com");
}
function menuChoiceFour()
{
       getURL("http://www.kirupa.com");
}
function menuChoiceFive()
{
       getURL("http://www.tutorialized.com");
}
 
NewMenu = new ContextMenu();
NewMenu.hideBuiltInItems();
NewMenu.customItems.push(new ContextMenuItem("Google", menuChoiceOne));
NewMenu.customItems.push(new ContextMenuItem("Talk-Mania", menuChoiceTwo));
NewMenu.customItems.push(new ContextMenuItem("Pixel2Life", menuChoiceThree)); 
NewMenu.customItems.push(new ContextMenuItem("Kirupa", menuChoiceFour)); 
NewMenu.customItems.push(new ContextMenuItem("Tutorialized", menuChoiceFive)); 
this.menu = NewMenu;
If you like to add a more choices to the right click menu, first you must to do is: define a new function named "menuChoicesix" and after that create another line.

NewMenu.customItems.push(new ContextMenuItem("Choice six", menuChoicesix));

We're done, test your movie (Ctrl+Enter).

Reply With Quote
  #2 (permalink)  
Old 12-12-2007, 11:52 AM
Junior Member
 
Join Date: Jan 2007
Posts: 8
darksky-bsd is on a distinguished road
thanks for this tutorial

Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


All times are GMT +2. The time now is 07:00 PM.


Fake ID

Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC8
Forums Copyright © Talk-Mania.com