/***********************
* Acciones de composición de Adobe Edge Animate
*
* Editar este archivo con precaución, teniendo cuidado de conservar 
* las firmas de función y los comentarios que comienzan con "Edge" para mantener la 
* capacidad de interactuar con estas acciones en Adobe Edge Animate
*
***********************/
(function($, Edge, compId){
var Composition = Edge.Composition, Symbol = Edge.Symbol; // los alias más comunes para las clases de Edge

   //Edge symbol: 'stage'
   (function(symbolName) {
      
      
      

      

      

      

      

      

      

      

      

      

      

      

      

      

      

      

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_clic}", "click", function(sym, e) {
         sym.$("brillo").fadeOut("slow");
         sym.$("hotspot_clic").hide();
         sym.getSymbol("pop_1").play(1);
         sym.$("pop_1").show();
         

      });
      //Edge binding end

   })("stage");
   //Edge symbol end:'stage'

   //=========================================================
   
   //Edge symbol: 'Precargador'
   (function(symbolName) {   
   
   })("Precargador");
   //Edge symbol end:'Precargador'

   //=========================================================
   
   //Edge symbol: 'flecha_bt'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         // introducir código aquí
         sym.stop();

      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 250, function(sym, e) {
         // introducir código aquí
         sym.stop();

      });
      //Edge binding end

   })("flecha_bt");
   //Edge symbol end:'flecha_bt'

   //=========================================================

   //=========================================================

   //=========================================================
   
   //Edge symbol: 'bt_audio'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         // introducir código aquí
         sym.stop();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_ht_spot}", "click", function(sym, e) {
         var soundId = sym.getSymbolElement().attr( "title" );
         var currentAudio=sym.getComposition().getStage().$(soundId)[0].currentTime;
         var duracion= sym.getComposition().getStage().$(soundId).duration;
         console.log("soundId="+soundId);
         if (duracion== currentAudio){
         sym.stop("up");
         }
         
         sym.getComposition().getStage().$(soundId).on('ended', function() {
         sym.stop("up");
            // enable button/link
         });
         
         console.log("currentAudio="+currentAudio);
         console.log("duracion="+duracion);
         // Definir un conmutador para reproducir o pausar una pista de audio 
         if (sym.getComposition().getStage().$(soundId)[0].paused) {
         	sym.getComposition().getStage().$(soundId)[0].play();
         	sym.getComposition().getStage().$(soundId)[0].volume=0.7;
         	sym.stop("down");
         
         } else {
         //activar para pausar en vez de reiniciar
         	sym.getComposition().getStage().$(soundId)[0].pause();
         	sym.stop("up");
         }

      });
      //Edge binding end

      

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 250, function(sym, e) {
         sym.stop();

      });
      //Edge binding end

      

   })("bt_audio");
   //Edge symbol end:'bt_audio'

   //=========================================================
   
   //Edge symbol: 'sky'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         // introducir código aquí
      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 10000, function(sym, e) {
         sym.playReverse();

      });
      //Edge binding end

   })("sky");
   //Edge symbol end:'sky'

   //=========================================================
   
   //Edge symbol: 'sol'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.play();

      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 1500, function(sym, e) {
         sym.playReverse();

      });
      //Edge binding end

   })("sol");
   //Edge symbol end:'sol'

   //=========================================================
   
   //Edge symbol: 'brillo'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.play();

      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 500, function(sym, e) {
         sym.playReverse();

      });
      //Edge binding end

   })("brillo");
   //Edge symbol end:'brillo'

   //=========================================================
   
   //Edge symbol: 'pop_1'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.stop();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_c}", "click", function(sym, e) {
         sym.getSymbol("Agua").play(0001);
         sym.$("hotspot_a").hide();
         sym.$("hotspot_b").hide();
         sym.$("hotspot_c").hide();
         sym.$("hotspot_d").hide();
         sym.$("hotspot_e").hide();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_b}", "click", function(sym, e) {
         sym.getSymbol("luz").play(0001);
         sym.$("hotspot_a").hide();
         sym.$("hotspot_b").hide();
         sym.$("hotspot_c").hide();
         sym.$("hotspot_d").hide();
         sym.$("hotspot_e").hide();
         

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_a}", "click", function(sym, e) {
         sym.getSymbol("temperatura").play(0001);
         sym.$("hotspot_a").hide();
         sym.$("hotspot_b").hide();
         sym.$("hotspot_c").hide();
         sym.$("hotspot_d").hide();
         sym.$("hotspot_e").hide();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_d}", "click", function(sym, e) {
         sym.getSymbol("aire").play(0001);
         sym.$("hotspot_a").hide();
         sym.$("hotspot_b").hide();
         sym.$("hotspot_c").hide();
         sym.$("hotspot_d").hide();
         sym.$("hotspot_e").hide();
         

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_e}", "click", function(sym, e) {
         sym.getSymbol("suelo").play(0001);
         sym.$("hotspot_a").hide();
         sym.$("hotspot_b").hide();
         sym.$("hotspot_c").hide();
         sym.$("hotspot_d").hide();
         sym.$("hotspot_e").hide();
         

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_bt_back}", "click", function(sym, e) {
         sym.getSymbolElement().hide();
         
         // Mostrar un elemento 
         sym.getComposition().getStage().$("hotspot_clic").show();
         

      });
      //Edge binding end

   })("pop_1");
   //Edge symbol end:'pop_1'

   //=========================================================
   
   //Edge symbol: 'brillo_a'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.play();

      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 500, function(sym, e) {
         sym.playReverse();

      });
      //Edge binding end

   })("brillo_a");
   //Edge symbol end:'brillo_a'

   //=========================================================
   
   //Edge symbol: 'text_1'
   (function(symbolName) {   
   
   })("text_1");
   //Edge symbol end:'text_1'

   //=========================================================
   
   //Edge symbol: 'text_2'
   (function(symbolName) {   
   
   })("text_2");
   //Edge symbol end:'text_2'

   //=========================================================
   
   //Edge symbol: 'text_3'
   (function(symbolName) {   
   
   })("text_3");
   //Edge symbol end:'text_3'

   //=========================================================
   
   //Edge symbol: 'Agua'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.stop();
         sym.$("text_1").hide();
         sym.$("text_2").hide();
         sym.$("text_3").hide();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_1}", "click", function(sym, e) {
         sym.$("text_1").fadeIn("slow");
         sym.$("text_2").fadeOut("slow");
         sym.$("text_3").fadeOut("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_2}", "click", function(sym, e) {
         sym.$("text_2").fadeIn("slow");
         sym.$("text_1").fadeOut("slow");
         sym.$("text_3").fadeOut("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_3}", "click", function(sym, e) {
         sym.$("text_3").fadeIn("slow");
         sym.$("text_2").fadeOut("slow");
         sym.$("text_1").fadeOut("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_bt_cerrar}", "click", function(sym, e) {
         sym.playReverse();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_a").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_b").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_c").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_d").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_e").show();

      });
      //Edge binding end

   })("Agua");
   //Edge symbol end:'Agua'

   //=========================================================
   
   //Edge symbol: 'bt_info_1'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         // introducir código aquí
         sym.stop();

      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 250, function(sym, e) {
         // introducir código aquí
         sym.stop();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hot_spot_1}", "click", function(sym, e) {
         sym.stop("down");
         
         // Mostrar un elemento 
         sym.getComposition().getStage().getSymbol("slide_2").getSymbol("contenido2").$("pop_info").show();
         sym.getComposition().getStage().getSymbol("slide_2").getSymbol("contenido2").getSymbol("pop_info").play("inicio");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hot_spot_2}", "click", function(sym, e) {
         sym.stop("up");
         

      });
      //Edge binding end

   })("bt_cerrar");
   //Edge symbol end:'bt_cerrar'

   //=========================================================
   
   //Edge symbol: 'luz'
   (function(symbolName) {   
   
      Symbol.bindElementAction(compId, symbolName, "${_bt_cerrar}", "click", function(sym, e) {
         sym.playReverse();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_a").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_b").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_c").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_d").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_e").show();

      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.stop();
         sym.$("text_5").hide();
         sym.$("text_4").hide();
         sym.$("text_6").hide();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_1}", "click", function(sym, e) {
         sym.$("text_4").fadeIn("slow");
         sym.$("hotspot_1").hide();
         

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_2}", "click", function(sym, e) {
         sym.$("text_5").fadeIn("slow");
         sym.$("hotspot_2").hide();
         

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_3}", "click", function(sym, e) {
         sym.$("text_6").fadeIn("slow");
         sym.$("hotspot_3").hide();
         

      });
      //Edge binding end

   })("luz");
   //Edge symbol end:'luz'

   //=========================================================
   
   //Edge symbol: 'text_6'
   (function(symbolName) {   
   
   })("text_6");
   //Edge symbol end:'text_6'

   //=========================================================
   
   //Edge symbol: 'text_5'
   (function(symbolName) {   
   
   })("text_5");
   //Edge symbol end:'text_5'

   //=========================================================
   
   //Edge symbol: 'text_4'
   (function(symbolName) {   
   
   })("text_4");
   //Edge symbol end:'text_4'

   //=========================================================
   
   //Edge symbol: 'temperatura'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.stop();
         sym.$("text_9").hide();
         sym.$("text_8").hide();
         sym.$("text_7").hide();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_1}", "click", function(sym, e) {
         sym.$("text_7").fadeIn("slow");
         sym.$("text_8").fadeOut("slow");
         sym.$("text_9").fadeOut("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_2}", "click", function(sym, e) {
         sym.$("text_8").fadeIn("slow");
         sym.$("text_7").fadeOut("slow");
         sym.$("text_9").fadeOut("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_3}", "click", function(sym, e) {
         sym.$("text_9").fadeIn("slow");
         sym.$("text_8").fadeOut("slow");
         sym.$("text_7").fadeOut("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_bt_cerrarCopy}", "click", function(sym, e) {
         sym.playReverse();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_a").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_b").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_c").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_d").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_e").show();

      });
      //Edge binding end

   })("temperatura");
   //Edge symbol end:'temperatura'

   //=========================================================
   
   //Edge symbol: 'Text_7'
   (function(symbolName) {   
   
   })("text_7");
   //Edge symbol end:'text_7'

   //=========================================================
   
   //Edge symbol: 'text_7'
   (function(symbolName) {   
   
   })("text_8");
   //Edge symbol end:'text_8'

   //=========================================================
   
   //Edge symbol: 'text_7'
   (function(symbolName) {   
   
   })("text_9");
   //Edge symbol end:'text_9'

   //=========================================================
   
   //Edge symbol: 'text_10'
   (function(symbolName) {   
   
   })("text_10");
   //Edge symbol end:'text_10'

   //=========================================================
   
   //Edge symbol: 'text_11'
   (function(symbolName) {   
   
   })("text_11");
   //Edge symbol end:'text_11'

   //=========================================================
   
   //Edge symbol: 'text_12'
   (function(symbolName) {   
   
   })("text_12");
   //Edge symbol end:'text_12'

   //=========================================================
   
   //Edge symbol: 'ringlete'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.play();

      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 2500, function(sym, e) {
         sym.play(0001);

      });
      //Edge binding end

   })("ringlete");
   //Edge symbol end:'ringlete'

   //=========================================================
   
   //Edge symbol: 'aire'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.stop();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_bt_cerrarCopy2}", "click", function(sym, e) {
         sym.playReverse(0500);
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_a").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_b").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_c").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_d").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_e").show();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_1}", "click", function(sym, e) {
         sym.$("text_11").fadeIn("slow");
         sym.$("text_12").fadeOut("slow");
         sym.$("text_13").fadeOut("slow");
         

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_2}", "click", function(sym, e) {
         sym.$("text_11").fadeOut("slow");
         sym.$("text_12").fadeIn("slow");
         sym.$("text_13").fadeOut("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_3}", "click", function(sym, e) {
         sym.$("text_11").fadeOut("slow");
         sym.$("text_12").fadeOut("slow");
         sym.$("text_13").fadeIn("slow");

      });
      //Edge binding end

   })("aire");
   //Edge symbol end:'aire'

   //=========================================================
   
   //Edge symbol: 'text_13'
   (function(symbolName) {   
   
   })("text_13");
   //Edge symbol end:'text_13'

   //=========================================================
   
   //Edge symbol: 'text_14'
   (function(symbolName) {   
   
   })("text_14");
   //Edge symbol end:'text_14'

   //=========================================================
   
   //Edge symbol: 'text_15'
   (function(symbolName) {   
   
   })("text_15");
   //Edge symbol end:'text_15'

   //=========================================================
   
   //Edge symbol: 'suelo'
   (function(symbolName) {   
   
      Symbol.bindElementAction(compId, symbolName, "${_bt_cerrar}", "click", function(sym, e) {
         sym.playReverse(0500);
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_a").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_b").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_c").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_d").show();
         sym.getComposition().getStage().getSymbol("pop_1").$("hotspot_e").show();
         sym.$("handmouse8").hide();

      });
      //Edge binding end

      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         sym.stop();
         sym.$("text_17").hide();
         sym.$("text_18").hide();
         sym.$("text_19").hide();

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_1}", "click", function(sym, e) {
         sym.$("text_17").fadeIn("slow");
         sym.$("text_16").fadeOut("slow");
         sym.$("text_18").fadeOut("slow");
         sym.$("text_19").fadeOut("slow");
         sym.$("handmouse8").fadeIn("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_2}", "click", function(sym, e) {
         sym.$("text_18").fadeIn("slow");
         sym.$("text_17").fadeOut("slow");
         sym.$("text_16").fadeOut("slow");
         sym.$("text_19").fadeOut("slow");

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_3}", "click", function(sym, e) {
         sym.$("text_19").fadeIn("slow");
         sym.$("text_17").fadeOut("slow");
         sym.$("text_18").fadeOut("slow");
         sym.$("text_16").fadeOut("slow");
         

      });
      //Edge binding end

      Symbol.bindElementAction(compId, symbolName, "${_hotspot_4}", "click", function(sym, e) {
         sym.$("text_16").fadeIn("slow");
         sym.$("text_17").fadeOut("slow");
         sym.$("text_18").fadeOut("slow");
         sym.$("text_19").fadeOut("slow");
         

      });
      //Edge binding end

   })("suelo");
   //Edge symbol end:'suelo'

   //=========================================================
   
   //Edge symbol: 'text_16'
   (function(symbolName) {   
   
   })("text_16");
   //Edge symbol end:'text_16'

   //=========================================================
   
   //Edge symbol: 'text_17'
   (function(symbolName) {   
   
   })("text_17");
   //Edge symbol end:'text_17'

   //=========================================================
   
   //Edge symbol: 'text_18'
   (function(symbolName) {   
   
   })("text_18");
   //Edge symbol end:'text_18'

   //=========================================================
   
   //Edge symbol: 'text_19'
   (function(symbolName) {   
   
   })("text_19");
   //Edge symbol end:'text_19'

   //=========================================================
   
   //Edge symbol: 'bt_back'
   (function(symbolName) {   
   
      Symbol.bindTriggerAction(compId, symbolName, "Default Timeline", 0, function(sym, e) {
         

      });
      //Edge binding end

   })("bt_back");
   //Edge symbol end:'bt_back'

})(jQuery, AdobeEdge, "EDGE-94063035");