Knowledge Base |
Important! All new questions are usually answered within the next business day.
Accordion (Tree) Menu V3
(views: 7215)
Accordion Menu V3 and Accordion Tree Menu V3 are xml flash accordion menus featuring customized states, customized transitions and tweens. Here are all known issues for Accordion Menu V3 and Accordion Tree Menu V3, they should be similar, since basically it is the same component. If you have any questions that you think we should discuss here please let us know.
Can I add a rollover sound?
(2007-11-26 - views: 1795)
Q: Is there a way to add a sound when the user positions the mouse over menu and submenu items? How do I go about adding this?
Thanks!
Thanks!
A: Here is an example of how to use sounds on mouse over and mouse click on menu's items using the rollOver and onClick events.
var soundOnOver:Sound = new Sound();
soundOnOver.attachSound("soundEffect");
var soundClick:Sound = new Sound();
soundClick.attachSound("soundClick");
onRollOverHandler = new Object();
onRollOverHandler.onRollOver = function(evt){
soundOnOver.setVolume(40);
soundOnOver.start();
}
accTreeMenu.addEventListener("onRollOver",onRollOverHandler);
onPressHandler = new Object();
onPressHandler.onPress = function(evt){
soundClick.setVolume(20);
soundClick.start();
}
accTreeMenu.addEventListener("onPress",onPressHandler);
Files: AccordionTreeMenu_With_Sound.zip
var soundOnOver:Sound = new Sound();
soundOnOver.attachSound("soundEffect");
var soundClick:Sound = new Sound();
soundClick.attachSound("soundClick");
onRollOverHandler = new Object();
onRollOverHandler.onRollOver = function(evt){
soundOnOver.setVolume(40);
soundOnOver.start();
}
accTreeMenu.addEventListener("onRollOver",onRollOverHandler);
onPressHandler = new Object();
onPressHandler.onPress = function(evt){
soundClick.setVolume(20);
soundClick.start();
}
accTreeMenu.addEventListener("onPress",onPressHandler);
Files: AccordionTreeMenu_With_Sound.zip
User Comments
Rollover sound code example for AS3 version?
I've benn trying to convert the as2 code example to as3 without any luck.
Do you have an as3 example to look at?
posted by sniperdog on 2008-04-23
I've benn trying to convert the as2 code example to as3 without any luck.
Do you have an as3 example to look at?
Login to post your comment
Other questions in this item:
Call JavaScript from XML Open menu item pages into target - "_self" Transparent background menu Use hand cursor on menu Item description from XML Go to different frames by pressing a menu item Scene navigation Referencing item's textfield in Accordion (Tree) Menu V3 Animated items Keep the Accordion (Tree) Menu V3 vertically aligned Disable-Enable Accordion (Tree) Menu V3 Adding icons Add different styles for each main items. Load movies on item select how to change fontsize Underline On Rollover Selected item level Add a fixed item under the menu Autoexpand on Start How do I add the AccordionTreeMenuV3AS3 from class file to stage Get the type of the selected item Children of a menu item How do I add the AccordionTreeMenuV3 on stage in runtime? acc.height not updated? Change Text Color on Rollover Automatic Collapse Letter kerning hotwo: submenus already expanded on activation? Align header text to right Insert a line break into label Go To First Child When Select Top Level Menu Item Reference to text fields within menu items Change the position of the menu icons Change the position of the folder icons Open menu upwards Spacing between menu items Step backwards and forwards through menu Rotated text for menu items Use hand cursor on menu Accordion Tree Menu expandAll() clickItem() and expandItem() do not execute actions of menu item Accordion menu accurate size Menu Item visibility / disable Letter kerningMenu |
|
|


I've benn trying to convert the as2 code example to as3 without any luck.
Do you have an as3 exmaple to look at?