Go Back   OXYLUS Flash Board > Support > Flash Menus > Sliding List

Reply
 
LinkBack Thread Tools Display Modes
Old 11-20-2008, 07:55 PM   #1 (permalink)
Junior Member
 
Join Date: Nov 2008
Posts: 4
Default loadMovie action clicking a category name

Hello Adrian,
I have to load a swf containing a voiceover that reads the title of the category when you click on it, but I don't find a category select handler. Could you help me find where to tweak this?
Thanks in advance.
javierdealfonso is offline   Reply With Quote
Old 11-21-2008, 09:55 PM   #2 (permalink)
Junior Member
 
Join Date: Nov 2008
Posts: 4
Default

Hi again,
I've found a solution that meets my needs.
To load a swf when clicking on a category, we can use the variable "lbl" that contains the current category name.
In Playlist.as I add a line to the function that starts in line 64:

private function setLabel(lbl:String) {
function xxx() {
this.text = lbl;
}
Tweener.addTween(Title, {_alpha:0, transition:"easeInQuad", time:.3, onComplete:xxx});
Tweener.addTween(Title, {_alpha:100, transition:"easeOutQuad", time:.3, delay:.5});
//HERE STARTS THE CODE LOADING THE SWF THAT READS THE CATEGORY NAME
_root.loaderVoices.loadMovie ("voices/"+lbl+".swf");
//HERE ENDS THE CODE LOADING THE SWF THAT READS THE CATEGORY NAME
}

I hope it's useful for someone else.
javierdealfonso is offline   Reply With Quote
Old 11-23-2008, 06:17 PM   #3 (permalink)
OYXLUSFlash.com Staff Member
 
Adrian's Avatar
 
Join Date: May 2008
Posts: 1,982
Send a message via Yahoo to Adrian Send a message via Skype™ to Adrian
Default

Why don't you use the handler function ?
You have the sample code in the help file:

Code:
<item title="New mayor to tone down glitz" clip="clips/contact.swf" />
....
PList_mc.onItemSelect= function(n:XMLNode){ 
	your_movie_clip.loadMovie(n.attributes.clip);
 }
Simply replace your_movie_clip with the instance name of the movie clip in which you want to load the external movie clip.
Adrian is offline   Reply With Quote
Old 12-16-2008, 11:56 AM   #4 (permalink)
Junior Member
 
Join Date: Nov 2008
Posts: 4
Default

Hi Adrian,
I'm sorry for the late response, I haven't connected lately.

I think the code you propose here, and that can be found in the help file, is for loading an external swf when clicking an "item" (page icon), but I needed to load an external swf containing a voiceover that reads the name of a "category" (folder icon) when clicking on it.

Anyway I have now the need to show in the textbox (result_txt) not only the name of the item clicked but the complete route (category1/category2/.../item), so I'm opening a new thread.

Thanks in advance.
javierdealfonso is offline   Reply With Quote
Reply

Bookmarks

Tags
category select handler

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



All times are GMT. The time now is 09:41 PM.