Quantcast
Channel: Adobe Community : All Content - Edge Animate
Viewing all articles
Browse latest Browse all 9897

refer symbols in childsymbol on stage

$
0
0

Hello,

 

I apologize for my English, it's not very good. I'm trying to refer to a symbol in a childsymbol for a day now, but I can get it work only once. I've searched the forum, but can't find the same problem.

 

At the stage in compositionReady (this code works fine the first time):

     // Scene tour eiffel

        sym.getComposition().getStage().getSymbol("scene_home").$('mc_btn_tou r').click(function(){

            soundGroup.stop();

            tourEiffel.play();

 

        // show menu

        sym.$("menu2").show();

        });

 

        sym.getComposition().getStage().getSymbol("scene_home").$('mc_btn_tou r') (this path isn't working the second time; when it is a childsymbol. So the music in soundGroup is not stopping and the menu2 is not showing up.)

 

 

This is the onclick code of the symbol which replaces the second scene by the first scene. Works fine.

// Empty content container

sym.getComposition().getStage().$("content").empty();

 

var positieScene_home = sym.getComposition().getStage().createChildSymbol("scene_home", "content", 1);

// Set the position

positieScene_home.getSymbolElement().css("top", "0");

$('body').css("background", "#D9FBD3");

 

 

Scene_home is placed on the stage in an element called 'content'. The first time playing it, it isn't a childsymbol. Second time it is.

 

First time:

Schermafbeelding 2013-12-27 om 18.04.05.png

 

 

Second time:

Schermafbeelding 2013-12-27 om 18.04.53.png

 

Does anyone has a solution for this? Or do you need more information? Thank you!

 

 

------

 

I stil haven't got a preloader and only the Eiffeltower is clickable but here's a demo:

http://nieneke-elsjan.nl/parijs/

 

Start > Click on the Eifeltower > Click 'Back to overview' in the right menu > Click on the Eifeltower again.


As you can see, the menu and the music won't work when you click for the second time at the Eiffeltower.


Viewing all articles
Browse latest Browse all 9897

Trending Articles