0 Replies Latest reply on Sep 28, 2015 2:39 PM by asifkabani

    Click event not working properly

    asifkabani

      I have an element when you mouseover it an image slides in, if you mouseout it slides out basically working as a rollover.


      mouseover

      sym.$("icon2-over").css({"left" : "700px",

      "-webkit-transition" : "all 1s ease" });

       

      mouseout

      sym.$("icon2-over").css({"left" : "800px",

      "-webkit-transition" : "all 1s ease" });

       

      When you click on the rollover image which slides in, it opens and plays a symbol on click.


      click

      sym.$("icon1-over").css({"left" : "700px" });

      sym.$('map1').show();

      sym.getSymbol("map1").play(0);

       

       

      // Play an audio track

      sym.$("snap2")[0].play();

       

      Inside the symbol I have an X so when you click on the X it reverses the animation out and tells the main stage element to go back and slide out.


      click

      // insert code for mouse click here

      sym.playReverse();

       

       

      // Hide an element

      sym.$("close-x").hide();

       

       

      sym.getComposition().getStage().$("icon1-over").css({ "margin-left": "700","-webkit-transition" : "all 1s ease"});

      sym.getComposition().getStage().play();


      The problem I am having is that once I run this through it works fine. After the element slides out, my mouseover stops working.