AnonSec Shell
Server IP : 213.186.33.4  /  Your IP : 216.73.216.193
Web Server : Apache
System : Linux webm006.cluster103.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64
User : awebpaca ( 35430)
PHP Version : 8.5.0
Disable Function : _dyuweyrj4,_dyuweyrj4r,dl
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : ON  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /home/awebpaca/360/fort-sainte-agathe-2018/indexdata/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/awebpaca/360/fort-sainte-agathe-2018/indexdata/index_skin.xml
<?xml version="1.0" encoding="UTF-8"?>
<krpano version="1.19">

    
  <!-- Spot Style - Déplacement par défaut -->


  <style name="IconDéplacementpardéfaut"
         url="%FIRSTXML%/spots/hotspot_direction_user_defaultpoint0.png"
         visible="false"
         edge="center"
         rotate="270"
         onhover="onhoverIconDéplacementpardéfaut"
         onover="onoverIconDéplacementpardéfaut"
         onout="onoutIconDéplacementpardéfaut"


         />
  <action name="onhoverIconDéplacementpardéfaut">
    showtooltip('hotspot');
  </action>
  <action name="onoverIconDéplacementpardéfaut">
tween(scale, 1.2);


  </action>
  <action name="onoutIconDéplacementpardéfaut">
    hideTooltip();
    tween(scale, 1);


  </action>



  <!-- unsupported kind of display : PointMap -->


      
  <!-- Picture Spot Style - PI sans description -->

  <style name="RectPicturePIsansdescription"
         distorted="true"
         visible="false"
         scale="1.0" 
         onhover="onhoverRectPicturePIsansdescription"
         onout="onoutRectPicturePIsansdescription"
         />
  <action name="onhoverRectPicturePIsansdescription">
    showTooltip('hotspot');
  </action>
  <action name="onoutRectPicturePIsansdescription">
    hideTooltip();
    
  </action>
<action name="hotspotParallaxRectPicturePIsansdescription">

	if(view.fov LT 150,
		sub(hdistance, view.hlookat, hotspot[%1].ath);
		mod(hdistance,hdistance,360);
		if(hdistance GT 180, sub(hdistance,hdistance,360));
		if(hdistance LT -180, add(hdistance,hdistance,360));
		mul(hdistance, 0.25);
		mul(hdistance, -1);
		set(hotspot[%1].ox, get(hdistance));
	,
		set(hotspot[%1].ox, 0);
	);
</action>



        
  <!-- Video Spot Style - Default Video Spot Style -->
  <style name="RectVideoDefaultVideoSpotStyleLoader" url="%FIRSTXML%/spots/loadanimation.png" crop="0|0|64|64" ypos="0" frame="0" distorted="true" visible="false" />
  <style name="RectVideoDefaultVideoSpotStyle"
         capture="false"
         visible="false"
         distorted="true"
         scale="1.0"
         url="%FIRSTXML%/graphics/videoplayer.js"
         loop="false"
         autoresume="true"
         pausedonstart="true"
         pausedonstart.android="false"
         pauseothersounds="true"
         canstart="false"
         onvideocomplete="tween(alpha, 0, 0.5, easeOutQuad, if(device.html5,stop();,delayedcall(0.01,play();pause();););set(hotspot[get(videocontrolplay)].visible, true);set(hotspot[get(videocontrolpause)].visible, false);set(stateVideo,'startplaying');dec(videospots_playing);resumeTourSoundsActions(true,true,true,true,true););"
         onhover="onhoverRectVideoDefaultVideoSpotStyle"
         onout="onoutRectVideoDefaultVideoSpotStyle"
         onvideoready="onvideoreadyRectVideoDefaultVideoSpotStyle"
         />
  <style name="RectVideoDefaultVideoSpotStyle" 
    directionalsound="false"
  />
  <style name="RectVideoDefaultVideoSpotStyle" stateVideo="startplaying" devices="no-ios"/>
  <style name="RectVideoDefaultVideoSpotStyle" stateVideo="startpaused"  devices="ios"   />
  <style name="RectVideoDefaultVideoSpotStyle" stateVideo="startplaying" devices="ios10" />
  <action name="onhoverRectVideoDefaultVideoSpotStyle">
    showTooltip('hotspot');
    if(hotspot[get(videocontrolpause)].visible == false,
      if(hotspot[get(videocontrolplay)].visible == false,
        set(hotspot[get(videocontrolpause)].visible, true);
      );
    );
  </action>
  <action name="onoutRectVideoDefaultVideoSpotStyle">
    hideTooltip();
    ifnot(ispaused,
      if(hotspot[get(videocontrolpause)].visible,
        set(hotspot[get(videocontrolpause)].visible, false);
      );
    );
  </action>
  <action name="onvideoreadyRectVideoDefaultVideoSpotStyle">
    set(isVideoReadyForPlaying, false);
    if (isvideoready,
      if(panovideospotsstate,set(canstart, true););
      if (canstart,
        set(isVideoReadyForPlaying, true);
      );
    );
    if(isVideoReadyForPlaying,
    ifnot(device.ios,
      inc(videospots_playing);
      pauseTourSoundsActions(true,true,true,true,true);
    );

    if(tour_displayspots,
      if(ispaused,
        if(stateVideo == "startplaying",
          set(stateVideo, "playing");
          play();
        );
      );
    );
    if(device.flash OR (device.webgl AND !device.ios),
      if (tour_soundson,
        div(volume, tour_soundsvolume, 100);
      ,
        set(volume, 0);
      );
    ,
      ifnot(device.ios,
        if (tour_soundson,
          js(kpanotour.Sounds.startVideosSounds(get(volume)));
        ,
          js(kpanotour.Sounds.stopVideosSounds());
        );
      ,
        if (tour_soundson,
          set(muted, false);
        ,
          set(muted, true);
        );
      );
    );
    onvideoreadyspecific();
    onvideoreadycontrols();
    ,

      delayedcall(0.5,onvideoreadyRectVideoDefaultVideoSpotStyle());
    );
  </action>
  <action name="animatevideospotloaderRectVideoDefaultVideoSpotStyle">
    if(hotspot[%1],
      if(hotspot[%1].activated,
        set(hotspot[%1].visible, true);
      );
      inc(hotspot[%1].frame,1, 11,0);
      mul(hotspot[%1].ypos, hotspot[%1].frame, 64);
      txtadd(hotspot[%1].crop, '0|', get(hotspot[%1].ypos),'|64|64');
      delayedcall(%2, 0.1, animatevideospotloaderRectVideoDefaultVideoSpotStyle(%1, %2) );
    ,
      stopdelayedcall(%2);
    );
  </action>
  <action name="stopvideospotloaderanimationRectVideoDefaultVideoSpotStyle">
    removehotspot(%1);
  </action>



    
  <!-- Spot Style - Son -->


  <style name="IconSon"
         url="%FIRSTXML%/spots/hotspot_information_user_defaultpoint1.png"
         visible="false"
         edge="center"
         onhover="onhoverIconSon"
         onover="onoverIconSon"
         onout="onoutIconSon"


         />
  <action name="onhoverIconSon">
    showtooltip('hotspot');
  </action>
  <action name="onoverIconSon">
tween(scale, 1.2);

pauseautorotation(forcehotspot);

  </action>
  <action name="onoutIconSon">
    hideTooltip();
    tween(scale, 1);

resumeautorotation(forcehotspot);

  </action>



    
  <!-- Spot Style - Vidéo -->


  <style name="IconVidéo"
         url="%FIRSTXML%/spots/hotspot_video_black_user_defaultpoint4.png"
         visible="false"
         edge="center"
         onhover="onhoverIconVidéo"
         onover="onoverIconVidéo"
         onout="onoutIconVidéo"


         />
  <action name="onhoverIconVidéo">
    showtooltip('hotspot');
  </action>
  <action name="onoverIconVidéo">
tween(scale, 1.2);


  </action>
  <action name="onoutIconVidéo">
    hideTooltip();
    tween(scale, 1);


  </action>



      
  <!-- Picture Spot Style - PI avec galerie photo -->

  <style name="RectPicturePIavecgaleriephoto"
         distorted="true"
         visible="false"
         scale="1.0" 
         onhover="onhoverRectPicturePIavecgaleriephoto"
         onout="onoutRectPicturePIavecgaleriephoto"
         />
  <action name="onhoverRectPicturePIavecgaleriephoto">
    showTooltip('hotspot');
  </action>
  <action name="onoutRectPicturePIavecgaleriephoto">
    hideTooltip();
    
  </action>
<action name="hotspotParallaxRectPicturePIavecgaleriephoto">

	if(view.fov LT 150,
		sub(hdistance, view.hlookat, hotspot[%1].ath);
		mod(hdistance,hdistance,360);
		if(hdistance GT 180, sub(hdistance,hdistance,360));
		if(hdistance LT -180, add(hdistance,hdistance,360));
		mul(hdistance, 0.25);
		mul(hdistance, -1);
		set(hotspot[%1].ox, get(hdistance));
	,
		set(hotspot[%1].ox, 0);
	);
</action>



    
  <!-- Spot Style - Déplacement flêche vers la gauche -->


  <style name="IconDéplacementflêcheverslagauche"
         url="%FIRSTXML%/spots/hotspot_direction_user_defaultpoint5.png"
         visible="false"
         edge="center"
         rotate="180"
         onhover="onhoverIconDéplacementflêcheverslagauche"
         onout="onoutIconDéplacementflêcheverslagauche"


         />
  <action name="onhoverIconDéplacementflêcheverslagauche">
    showtooltip('hotspot');
  </action>
  <action name="onoutIconDéplacementflêcheverslagauche">
    hideTooltip();



  </action>



    
  <!-- Spot Style - Déplacement flêche vers la droite -->


  <style name="IconDéplacementflêcheversladroite"
         url="%FIRSTXML%/spots/hotspot_direction_user_defaultpoint6.png"
         visible="false"
         edge="center"
         onhover="onhoverIconDéplacementflêcheversladroite"
         onout="onoutIconDéplacementflêcheversladroite"


         />
  <action name="onhoverIconDéplacementflêcheversladroite">
    showtooltip('hotspot');
  </action>
  <action name="onoutIconDéplacementflêcheversladroite">
    hideTooltip();



  </action>



    
  <!-- Spot Style - Vidéo interne -->


  <style name="IconVidéointerne"
         url="%FIRSTXML%/spots/hotspot_video_black_user_defaultpoint7.png"
         visible="false"
         edge="center"
         onhover="onhoverIconVidéointerne"
         onover="onoverIconVidéointerne"
         onout="onoutIconVidéointerne"


         />
  <action name="onhoverIconVidéointerne">
    showtooltip('hotspot');
  </action>
  <action name="onoverIconVidéointerne">
tween(scale, 1.2);


  </action>
  <action name="onoutIconVidéointerne">
    hideTooltip();
    tween(scale, 1);


  </action>



    
  <!-- Spot Style - Description -->


  <style name="IconDescription"
         url="%FIRSTXML%/spots/hotspot_information_user_defaultpoint8.png"
         visible="false"
         edge="center"
         onhover="onhoverIconDescription"
         onover="onoverIconDescription"
         onout="onoutIconDescription"


         />
  <action name="onhoverIconDescription">
    showtooltip('hotspot');
  </action>
  <action name="onoverIconDescription">
tween(scale, 1.2);

pauseautorotation(forcehotspot);

  </action>
  <action name="onoutIconDescription">
    hideTooltip();
    tween(scale, 1);

resumeautorotation(forcehotspot);

  </action>



    
  <!-- Spot Style - Lecteur PDF -->


  <style name="IconLecteurPDF"
         url="%FIRSTXML%/spots/hotspot_information_user_defaultpoint9.png"
         visible="false"
         edge="center"
         onhover="onhoverIconLecteurPDF"
         onover="onoverIconLecteurPDF"
         onout="onoutIconLecteurPDF"


         />
  <action name="onhoverIconLecteurPDF">
    showtooltip('hotspot');
  </action>
  <action name="onoverIconLecteurPDF">
tween(scale, 1.2);

pauseautorotation(forcehotspot);

  </action>
  <action name="onoutIconLecteurPDF">
    hideTooltip();
    tween(scale, 1);

resumeautorotation(forcehotspot);

  </action>



      
  <!-- Picture Spot Style - PI avec description PDF -->

  <style name="RectPicturePIavecdescriptionPDF"
         distorted="true"
         visible="false"
         scale="1.0" 
         onhover="onhoverRectPicturePIavecdescriptionPDF"
         onout="onoutRectPicturePIavecdescriptionPDF"
         />
  <action name="onhoverRectPicturePIavecdescriptionPDF">
    showTooltip('hotspot');
  </action>
  <action name="onoutRectPicturePIavecdescriptionPDF">
    hideTooltip();
    
  </action>
<action name="hotspotParallaxRectPicturePIavecdescriptionPDF">

	if(view.fov LT 150,
		sub(hdistance, view.hlookat, hotspot[%1].ath);
		mod(hdistance,hdistance,360);
		if(hdistance GT 180, sub(hdistance,hdistance,360));
		if(hdistance LT -180, add(hdistance,hdistance,360));
		mul(hdistance, 0.25);
		mul(hdistance, -1);
		set(hotspot[%1].ox, get(hdistance));
	,
		set(hotspot[%1].ox, 0);
	);
</action>



<!-- ********** -->
<!-- Call actions on tour events -->
<!-- id : eventsPlugin -->
<!-- ********** -->

  <events name="eventsPluginevents" keep="true"/>

<!-- ********* -->
<!-- Gyroscope -->
<!-- ********* -->



<plugin name="gyroscope"
        url="%FIRSTXML%/graphics/gyro2.js"
        keep="true"
        devices="no-desktop.and.html5"

        onunavailable="checkGyroUnavailable();"
        sensor_mode="1"
        friction="auto"
        autocalibration="true"
        touch_mode="full"
        onavailable="delayedcall(1, checkGyroAvailability(););"
        enabled="false"
        activated="false"
        />

<events name="gyroscopeEvents" onnewpano="planarGyroscopeTest();" keep="true" />

<action name="planarGyroscopeTest">
  if(plugin[gyroscope],
          if(scene[get(xml.scene)].full360,
            set(sceneisfull360, false);
            sub(viewhfov, panoview.hmax, panoview.hmin);
            if (viewhfov == 360,
              sub(viewvfov, panoview.vmax, panoview.vmin);
              if (viewvfov == 180,
                set(sceneisfull360, true);
              );
            );
            if (sceneisfull360,
              set(plugin[gyroscope].camroll, true);
            ,
              set(plugin[gyroscope].camroll, false);
            );
          ,
            set(plugin[gyroscope].camroll, false);
          );
  );
</action>

<action name="changeGyroscopeState">
  if(plugin[gyroscope],
    if (plugin[gyroscope].isavailable,
        if(%1,
          set(plugin[gyroscope].activated,true);
        ,
          set(plugin[gyroscope].activated,false);
        );
        if (%1 != plugin[gyroscope].enabled,
          if(plugin[gyroscope].activated,
            switch(plugin[gyroscope].enabled);
          ,
            set(plugin[gyroscope].enabled, false);
          );
          if (plugin[gyroscope].enabled, events.dispatch(ongyroscopeon);, events.dispatch(ongyroscopeoff););
        );
    );
  );
</action>

<action name="checkGyroAvailability">
  if(plugin[gyroscope],
    if (plugin[gyroscope].isavailable,

      
      set(sceneisfull360, false);
      if (scene[get(xml.scene)].full360,
        sub(viewhfov, panoview.hmax, panoview.hmin);
        if (viewhfov == 360,
          sub(viewvfov, panoview.vmax, panoview.vmin);
          if (viewvfov == 180,
            set(sceneisfull360, true);
          );
        );
      );
      set(delaythegyrocheck, false);
      if (sceneisfull360 AND tour_firstlittleplanet, set(delaythegyrocheck, true));

      ifnot(delaythegyrocheck,
        
        switch(plugin[gyroscope].enabled);
        set(plugin[gyroscope].activated,true);
        
        set(tour_gyroscopedevices, true);
        events.dispatch(ongyroscopeavailable);
      ,
        delayedcall(1, checkGyroAvailability(););
      );
    ,
      set(tour_gyroscopedevices, false);
    );
    if (plugin[gyroscope].enabled, events.dispatch(ongyroscopeon);, events.dispatch(ongyroscopeoff););
  ,
    checkGyroUnavailable();
  );
</action>

<action name="checkGyroUnavailable">
  set(plugin[gyroscope].activated, false);
  set(plugin[gyroscope].enabled, false);
  set(tour_gyroscopedevices, false);
  events.dispatch(ongyroscopeunavailable);
</action>

<!-- ********** -->
<!-- Barre de contrôle classique -->
<!-- id : controlBar_classic -->
<!-- ********** -->

  <krpano controlBar_classicbarbuilt="false" controlBar_classicbackgroundwidthwhenclosed="0" controlBar_classicbackgroundwidthwhenopened="0" controlBar_classicIsOpened="false" />
  <events name="controlBar_classicevents" 
    onxmlcomplete="controlBar_classicbuildMenuBar();" 

    openvideointerface="controlBar_classicOpenVideoplayer();" 
    closevideointerface="controlBar_classicCloseVideoplayer();" 

    keep="true" />



  <action name="controlBar_classicbuildMenuBar">
    ifnot (controlBar_classicbarbuilt, controlBar_classicbuildMenu(); set(controlBar_classicbarbuilt, true););
  </action>

  <action name="controlBar_classicbuildMenu">
    
    set(controlBar_classicbutton_pos, 20);

    set(layer[controlBar_classicbtn_hidecontrols].x, get(controlBar_classicbutton_pos));
    set(layer[controlBar_classicbtn_showcontrols].x, get(controlBar_classicbutton_pos));
    inc(controlBar_classicbutton_pos, 36);
    add(controlBar_classicbackgroundwidthwhenclosed, get(controlBar_classicbutton_pos), 20);



    if (device.desktop,
      set(layer[controlBar_classicbtn_display_help].x, get(controlBar_classicbutton_pos));
      set(layer[controlBar_classicbtn_close_help  ].x, get(controlBar_classicbutton_pos));
      inc(controlBar_classicbutton_pos, 36);
    );

    if (device.fullscreensupport,
      set(layer[controlBar_classicbtn_openfs ].x, get(controlBar_classicbutton_pos));
      set(layer[controlBar_classicbtn_closefs].x, get(controlBar_classicbutton_pos));
      inc(controlBar_classicbutton_pos, 36);
    );


    set(layer[controlBar_classicbtn_share].x, get(controlBar_classicbutton_pos));
    inc(controlBar_classicbutton_pos, 36);



    set(layer[controlBar_classicbtn_sound_on ].x, get(controlBar_classicbutton_pos));
    set(layer[controlBar_classicbtn_sound_off].x, get(controlBar_classicbutton_pos));
    inc(controlBar_classicbutton_pos, 36);





    if(plugin[gyroscope],
      set(controlBar_classicDisplayGyroscopeButton, false);
      if (device.tablet, set(controlBar_classicDisplayGyroscopeButton, true););
      if (device.mobile, set(controlBar_classicDisplayGyroscopeButton, true););
      if(controlBar_classicDisplayGyroscopeButton,
        set(layer[controlBar_classicbtn_gyroscope_on ].x, get(controlBar_classicbutton_pos));
        set(layer[controlBar_classicbtn_gyroscope_off].x, get(controlBar_classicbutton_pos));
        set(layer[controlBar_classicbtn_gyroscope_not].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
      );
    );


    if (device.desktop,
        set(layer[controlBar_classicbtn_right].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
        set(layer[controlBar_classicbtn_left].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
    );
    if (device.desktop,
        set(layer[controlBar_classicbtn_down].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
        set(layer[controlBar_classicbtn_up].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
    );
    if (device.desktop,
        set(layer[controlBar_classicbtn_out].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
        set(layer[controlBar_classicbtn_in].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
    );
    if (scene.count GT 1,
        set(layer[controlBar_classicbtn_next_pano].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
        set(layer[controlBar_classicbtn_prev_pano].x, get(controlBar_classicbutton_pos));
        inc(controlBar_classicbutton_pos, 36);
      );


    set(layer[controlBar_classicbtn_play_video].x, get(controlBar_classicbutton_pos));
    set(layer[controlBar_classicbtn_pause_video].x, get(controlBar_classicbutton_pos));
    inc(controlBar_classicbutton_pos, 36);

    inc(controlBar_classicbutton_pos, 20);

    set(controlBar_classicbackgroundwidthwhenopened, get(controlBar_classicbutton_pos));

    sub(controlBar_classicbackgroundwidthwhenopenedwithoutvideo, controlBar_classicbackgroundwidthwhenopened, 36);


    
    add(controlBar_classicVerifyVisibility, 20, 20);
    if(controlBar_classicbackgroundwidthwhenopened == controlBar_classicVerifyVisibility,
      set(controlBar_classicbackgroundwidthwhenopened, 0);

      set(controlBar_classicbackgroundwidthwhenopenedwithoutvideo, 0);

    );

	
	
  </action>

	<events name="controlBar_classicStartTourEvents" onTourStart="controlBar_classicCallOnStartTour();" keep="true" />

	<action name="controlBar_classicCallOnStartTour">
		
		set(layer[controlBar_classicmenu_controlbar_bg_img].width, get(controlBar_classicbutton_pos));
		set(layer[controlBar_classicmenu_controlbar_bg].width, get(controlBar_classicbutton_pos));
		showTourControls();

	</action>

	<action name="controlBar_classicOpenVideoplayer">
		set(controlBar_classic_use_videoplayer_interface, true);
		
		controlBar_classicupdateHideShowVideoplayerButtons();
	</action>
	<action name="controlBar_classicCloseVideoplayer">
		set(controlBar_classic_use_videoplayer_interface, false);
		
		controlBar_classicupdateHideShowVideoplayerButtons();
	</action>


  <style name="controlBar_classic_btn_style"
         keep="true"
         alpha="0.8"
         edge="right" align="right"
         width="36" height="36"
         zorder="5"
         onover="controlBar_classicctrlbaronoveraction();"
         onout="controlBar_classicctrlbaronoutaction();"
         onhover="showTooltip('plugin', controlBar_classicmenuTooltipStyle, bottom);"
         />
  <action name="controlBar_classicctrlbaronoveraction">
    tween(alpha,1,0.1,easeoutquad);
    tween(y,-2,0.1,easeoutquad);
  </action>  
  <action name="controlBar_classicctrlbaronoutaction">
    tween(alpha,0.8);
    tween(y,0,0.1,easeoutquad);
    hideTooltip();
  </action>

  <layer name="controlBar_classicmenu_controlbar_bg_img"
         keep="true"
         align="bottom"
         x="0" y="10"
         url="%FIRSTXML%/graphics/classiccontrolbar/footer.png"
         zorder="3"
         width="40"
         height="40"
         scale9grid="10|10|80|80"
         visible="false"
         />
  <layer name="controlBar_classicmenu_controlbar_bg"
         keep="true"
         align="bottom"
         x="0" y="10"
         type="container"
         zorder="4"
         width="40"
         height="40"
         visible="false"
         alpha="1.0"
         >


    <layer name="controlBar_classicbtn_gyroscope_off"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_gyroscope.png"
            style="controlBar_classic_btn_style"
            onclick="disableGyroscope();
"
            devices="html5"
            tooltip="controlBar_classicgyroOffTip"
            visible="false"
            />
    <layer name="controlBar_classicbtn_gyroscope_on"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_gyroscope.png"
            style="controlBar_classic_btn_style"
            onclick="enableGyroscope();
"
            devices="html5"
            tooltip="controlBar_classicgyroOnTip"
            visible="false"
            />
    <layer name="controlBar_classicbtn_gyroscope_not"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_gyroscope_off.png"
            style="controlBar_classic_btn_style"
            enabled="true"
            capture="false"
            devices="html5"
            tooltip="controlBar_classicgyroNotTip"
            visible="false"
            />


    <layer name="controlBar_classicbtn_in"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_zoom_in.png"
            ondown="viewControlZoomIn(false);"
            onup="viewControlZoomStop();
"
            style="controlBar_classic_btn_style"
            tooltip="controlBar_classiczoomInTip"
            devices="desktop"
            visible="false"
            />
    <layer name="controlBar_classicbtn_out"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_zoom_out.png"
            ondown="viewControlZoomOut(false);
"
            onup="viewControlZoomStop();
"
            style="controlBar_classic_btn_style"
            tooltip="controlBar_classiczoomOutTip"
            devices="desktop"
            visible="false"
            />

    <layer name="controlBar_classicbtn_left"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_move_left.png"
            ondown="viewControlMoveLeft(false);
"
            onup="viewControlMoveHoriStop();
"
            style="controlBar_classic_btn_style"
            tooltip="controlBar_classicmoveLeftTip"
            devices="desktop"
            visible="false"
            />
    <layer name="controlBar_classicbtn_right"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_move_right.png"
            ondown="viewControlMoveRight(false);
"
            onup="viewControlMoveHoriStop();
"
            style="controlBar_classic_btn_style"
            tooltip="controlBar_classicmoveRightTip"
            devices="desktop"
            visible="false"
            />

    <layer name="controlBar_classicbtn_up"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_move_up.png"
            ondown="viewControlMoveUp(false);
"
            onup="viewControlMoveVertStop();
"
            style="controlBar_classic_btn_style"
            tooltip="controlBar_classicmoveUpTip"
            devices="desktop"
            visible="false"
            />
    <layer name="controlBar_classicbtn_down"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_move_down.png"
            ondown="viewControlMoveDown(false);
"
            onup="viewControlMoveVertStop();
"
            style="controlBar_classic_btn_style"
            tooltip="controlBar_classicmoveDownTip"
            devices="desktop"
            visible="false"
            />


    <layer name="controlBar_classicbtn_sound_on"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_start_sound.png"
            onclick="playTourSounds();
"
            style="controlBar_classic_btn_style"
            visible="false"
            tooltip="controlBar_classicsoundsOnTip"
            />
    <layer name="controlBar_classicbtn_sound_off"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_stop_sound.png"
            onclick="stopTourSounds();
"
            style="controlBar_classic_btn_style"
            visible="false"
            tooltip="controlBar_classicsoundsOffTip"
            />


    <layer name="controlBar_classicbtn_prev_pano"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_previous_scene.png"
            onclick="loadPreviousScene();
"
            style="controlBar_classic_btn_style"
            tooltip="controlBar_classicprevSceneTip"
            visible="false"
            />
    <layer name="controlBar_classicbtn_next_pano"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_next_scene.png"
            onclick="loadNextScene();
"
            style="controlBar_classic_btn_style"
            tooltip="controlBar_classicnextSceneTip"
            visible="false"
            />


    <layer name="controlBar_classicbtn_share"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_share.png"
            onclick="shareTour();
"
            style="controlBar_classic_btn_style"
            visible="false"
            tooltip="controlBar_classicshareTip"
            />


    <layer name="controlBar_classicbtn_openfs"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_enter_fs.png"
            onclick="enterFullscreen();
"
            style="controlBar_classic_btn_style"
            devices="fullscreensupport"
            visible="false"
            tooltip="controlBar_classicopenFsTip"
            />
    <layer name="controlBar_classicbtn_closefs"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_close_fs.png"
            onclick="exitFullscreen();
"
            style="controlBar_classic_btn_style"
            visible="false"
            devices="fullscreensupport"
            tooltip="controlBar_classiccloseFsTip"
            />


    <layer name="controlBar_classicbtn_play_video"
           url="%FIRSTXML%/graphics/classiccontrolbar/btn_start_videoplayer.png"
           onclick="videointerface_togglepause();"
           style="controlBar_classic_btn_style"
           visible="false"
           tooltip="controlBar_classicplayVideoTip"
           />
    <layer name="controlBar_classicbtn_pause_video"
           url="%FIRSTXML%/graphics/classiccontrolbar/btn_pause_videoplayer.png"
           onclick="videointerface_togglepause();"
           style="controlBar_classic_btn_style"
           visible="false"
           tooltip="controlBar_classicpauseVideoTip"
           />


    <layer name="controlBar_classicbtn_display_help"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_help.png"
            onclick="controlBar_classicdisplayHelp();"
            style="controlBar_classic_btn_style"
            devices="desktop"
            visible="false"
            tooltip="controlBar_classicdisplayHelpTip"
            />
    <layer name="controlBar_classicbtn_close_help"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_help.png"
            onclick="controlBar_classiccloseHelp();"
            style="controlBar_classic_btn_style"
            visible="false"
            devices="desktop"
            tooltip="controlBar_classichideHelpTip"
            />



    <layer name="controlBar_classicbtn_hidecontrols"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_hide_controls.png"
            style="controlBar_classic_btn_style"
            onclick="hideTourControls();
"
            visible="false"
            tooltip="controlBar_classichideControlsTip"
            />
    <layer name="controlBar_classicbtn_showcontrols"
            url="%FIRSTXML%/graphics/classiccontrolbar/btn_show_controls.png"
            style="controlBar_classic_btn_style"
            onclick="showTourControls();
"
            tooltip="controlBar_classicdisplayControlsTip"
            visible="false"
            />
  </layer>



	<events name="controlBar_classicgyroscopeavailableevent"
		ongyroscopeavailable="controlBar_classicupdateGyroscopeButtonsAvailability();"
		ongyroscopeunavailable="controlBar_classicupdateGyroscopeButtonsAvailability();"
		ongyroscopeon="controlBar_classicenableGyroscopeButtons(true);"
		ongyroscopeoff="controlBar_classicenableGyroscopeButtons(false);"
		keep="true" devices="html5" />
	<krpano controlBar_classicmenugyroscopeavailable="false" controlBar_classicmenugyroscopeenabled="false" />
	<action name="controlBar_classicupdateGyroscopeButtonsAvailability">
		if (tour_gyroscopedevices,
			set(controlBar_classicmenugyroscopeavailable, true);
			controlBar_classicupdateGyroscopeButtons();
		,
			set(controlBar_classicmenugyroscopeavailable, false);
			controlBar_classicupdateGyroscopeButtons();
		);
	</action>
	<action name="controlBar_classicenableGyroscopeButtons">
		if (tour_gyroscopedevices,
			set(controlBar_classicmenugyroscopeenabled, %1);
			controlBar_classicupdateGyroscopeButtons();
		);
	</action>
	<action name="controlBar_classicHideGyroscopeButtons">
		set(layer[controlBar_classicbtn_gyroscope_off].visible, false);
		set(layer[controlBar_classicbtn_gyroscope_on].visible, false);
		if('%1' == 'true' AND plugin[gyroscope],
			set(layer[controlBar_classicbtn_gyroscope_not].visible, true);
		,
			set(layer[controlBar_classicbtn_gyroscope_not].visible, false);
		);
	</action>
	<action name="controlBar_classicShowGyroscopeButtons">
		if (controlBar_classicmenugyroscopeavailable,
			if (controlBar_classicmenugyroscopeenabled,
				set(layer[controlBar_classicbtn_gyroscope_off].visible, true);
				set(layer[controlBar_classicbtn_gyroscope_on].visible, false);
			,
				set(layer[controlBar_classicbtn_gyroscope_off].visible, false);
				set(layer[controlBar_classicbtn_gyroscope_on].visible, true);
			);
			set(layer[controlBar_classicbtn_gyroscope_not].visible, false);
		,
			controlBar_classicHideGyroscopeButtons(true);
		);
	</action>
	<action name="controlBar_classicupdateGyroscopeButtons">
	if (tour_gyroscopedevices,
		if (tour_displaycontrols,
			controlBar_classicShowGyroscopeButtons();
		,
			controlBar_classicHideGyroscopeButtons();
		);
	,
		if (tour_displaycontrols,
			controlBar_classicHideGyroscopeButtons(true);
		,
			controlBar_classicHideGyroscopeButtons();
		);
	);
	</action>


  <events name="controlBar_classichideshowcontrolsevent" 
    hidetourcontrols="controlBar_classichideMenuControls();" 
    showtourcontrols="controlBar_classicshowMenuControls();" 
    keep="true" />

  <action name="controlBar_classichideMenuControls">
    set(controlBar_classicIsOpened, false);
    set(layer[controlBar_classicbtn_hidecontrols].visible, false);
    set(layer[controlBar_classicbtn_showcontrols].visible, true);
    controlBar_classicupdateFullscreenButtons();

    set(layer[controlBar_classicbtn_share].visible, false);
    controlBar_classicupdateSoundButtons();

    if (scene.count GT 1,
    set(layer[controlBar_classicbtn_prev_pano].visible, false);
    set(layer[controlBar_classicbtn_next_pano].visible, false);
    );

    controlBar_classicupdateHideShowVideoplayerButtons();

    set(layer[controlBar_classicbtn_up].visible  , false);
    set(layer[controlBar_classicbtn_down].visible, false);
    set(layer[controlBar_classicbtn_right].visible, false);
    set(layer[controlBar_classicbtn_left].visible , false);
    set(layer[controlBar_classicbtn_in].visible , false);
    set(layer[controlBar_classicbtn_out].visible, false);



    controlBar_classicupdateGyroscopeButtons();

    controlBar_classicupdateHelpButtons();


    if(controlBar_classicbackgroundwidthwhenclosed == 0,
      set(layer[controlBar_classicmenu_controlbar_bg_img].visible, false);
      set(layer[controlBar_classicmenu_controlbar_bg].visible, false);
    ,
      set(layer[controlBar_classicmenu_controlbar_bg_img].visible, true);
      set(layer[controlBar_classicmenu_controlbar_bg].visible, true);
    );
    tween(layer[controlBar_classicmenu_controlbar_bg_img].width,get(controlBar_classicbackgroundwidthwhenclosed),0.5,easeOutQuad);
    tween(layer[controlBar_classicmenu_controlbar_bg].width,get(controlBar_classicbackgroundwidthwhenclosed),0.5,easeOutQuad);
    tween(layer[controlBar_classicmenu_controlbar_bg_img].alpha,1.0,0.5,easeOutQuad);
  </action>
  <action name="controlBar_classicshowMenuControls">
    set(controlBar_classicIsOpened, true);
    set(layer[controlBar_classicbtn_hidecontrols].visible, true);
    set(layer[controlBar_classicbtn_showcontrols].visible, false);
    if(controlBar_classicbackgroundwidthwhenopened == 0,
      set(layer[controlBar_classicmenu_controlbar_bg_img].visible, false);
      set(layer[controlBar_classicmenu_controlbar_bg].visible, false);
    ,
      set(layer[controlBar_classicmenu_controlbar_bg_img].visible, true);
      set(layer[controlBar_classicmenu_controlbar_bg].visible, true);
    );
    tween(layer[controlBar_classicmenu_controlbar_bg_img].alpha,1.0,0.5,easeOutQuad);
    controlBar_classicshowMenuButtons();

    if(scene[get(xml.scene)].video,

      tween(layer[controlBar_classicmenu_controlbar_bg_img].width, get(controlBar_classicbackgroundwidthwhenopened),0.5,easeOutQuad);
      tween(layer[controlBar_classicmenu_controlbar_bg].width, get(controlBar_classicbackgroundwidthwhenopened),0.5,easeOutQuad);

    ,
      tween(layer[controlBar_classicmenu_controlbar_bg_img].width, get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo),0.5,easeOutQuad);
      tween(layer[controlBar_classicmenu_controlbar_bg].width, get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo),0.5,easeOutQuad);
    );

  </action>
  <action name="controlBar_classicshowMenuButtons">
    if (device.desktop,
    set(layer[controlBar_classicbtn_up].visible  , true);
    set(layer[controlBar_classicbtn_down].visible, true);
    );
    if (device.desktop,
    set(layer[controlBar_classicbtn_right].visible, true);
    set(layer[controlBar_classicbtn_left].visible , true);
    );
    if (device.desktop,
    set(layer[controlBar_classicbtn_in].visible , true);
    set(layer[controlBar_classicbtn_out].visible, true);
    );



    controlBar_classicupdateGyroscopeButtons();

    controlBar_classicupdateHelpButtons();


    controlBar_classicupdateFullscreenButtons();

    set(layer[controlBar_classicbtn_share].visible, true);
    controlBar_classicupdateSoundButtons();

    if (scene.count GT 1,
      set(layer[controlBar_classicbtn_prev_pano].visible, true);
      set(layer[controlBar_classicbtn_next_pano].visible, true);
    );

    controlBar_classicupdateHideShowVideoplayerButtons();

  </action>

  <layer name="controlBar_classichelpScreen" align="center" keep="true" onclick="controlBar_classiccloseHelp();" url="%FIRSTXML%/graphics/classiccontrolbar/help_screen_bg.png" visible="false" zorder="97" height="10%" width="prop" />

  <layer name="controlBar_classichelpScreenFg" align="center" keep="true" onclick="controlBar_classiccloseHelp();" displayed="false" 
         url="%FIRSTXML%/graphics/classiccontrolbar/help_screen_fg.png" 
         alpha="0.8" 
         height="50%" 
         width="prop" 
         zorder="98"
         visible="false" />
  <action name="controlBar_classicdisplayHelp">
    set(layer[controlBar_classichelpScreenFg].displayed,true);
    set(layer[controlBar_classichelpScreen].visible,true);
    tween(layer[controlBar_classichelpScreen].height, 50%, 1, easeOutQuad,
      set(layer[controlBar_classichelpScreenFg].visible,true);
    );
    controlBar_classicupdateHelpButtons();
  </action>
  <action name="controlBar_classiccloseHelp">
    set(layer[controlBar_classichelpScreenFg].displayed,false);
    set(layer[controlBar_classichelpScreenFg].visible,false);
    tween(layer[controlBar_classichelpScreen].height, 10%, 1, easeOutQuad,
      set(layer[controlBar_classichelpScreen].visible,false);
    );
    controlBar_classicupdateHelpButtons();
  </action>
	<action name="controlBar_classicHideHelpButtons">
		set(layer[controlBar_classicbtn_display_help].visible, false);
		set(layer[controlBar_classicbtn_close_help].visible, false);
	</action>
	<action name="controlBar_classicShowHelpButtons">
		if (layer[controlBar_classichelpScreenFg].displayed,
			set(layer[controlBar_classicbtn_close_help].visible, true);
			set(layer[controlBar_classicbtn_display_help].visible, false);
		,
			set(layer[controlBar_classicbtn_display_help].visible, true);
			set(layer[controlBar_classicbtn_close_help].visible, false);
		);
	</action>
	<action name="controlBar_classicupdateHelpButtons">
	if (device.desktop,
		if (tour_displaycontrols,
			controlBar_classicShowHelpButtons();
		,
			controlBar_classicHideHelpButtons();
		);
	,
		controlBar_classicHideHelpButtons();
	);
	</action>



	<events name="controlBar_classicmenufullscreenchangeevent"
		onenterfullscreen="controlBar_classicupdateFullscreenButtons();"
		onexitfullscreen="controlBar_classicupdateFullscreenButtons();"
		keep="true"/>
	<action name="controlBar_classicHideFullscreenButtons">
		set(layer[controlBar_classicbtn_openfs].visible , false);
		set(layer[controlBar_classicbtn_closefs].visible, false);
	</action>
	<action name="controlBar_classicShowFullscreenButtons">
		if (device.fullscreensupport,
			if(tour_fullscreen,
				set(layer[controlBar_classicbtn_openfs].visible , false);
				set(layer[controlBar_classicbtn_closefs].visible, true);
			,
				set(layer[controlBar_classicbtn_openfs].visible ,true);
				set(layer[controlBar_classicbtn_closefs].visible,false);
			);
		,
			controlBar_classicHideFullscreenButtons();
		);
	</action>
	<action name="controlBar_classicupdateFullscreenButtons">
		if (tour_displaycontrols,
			controlBar_classicShowFullscreenButtons();
		,
			controlBar_classicHideFullscreenButtons();
		);
	</action>


    <events name="controlBar_classichideshowvideoplayerevent" onplayvideointerface="controlBar_classicupdateHideShowVideoplayerButtons();" onpausevideointerface="controlBar_classicupdateHideShowVideoplayerButtons();" keep="true"/>
    <action name="controlBar_classicHideHideShowVideoplayerButtons">
      if(controlBar_classicbackgroundwidthwhenopened GT 0,
        add(controlBar_classicVerifyVisibility, 20, 20);
        if(controlBar_classicbackgroundwidthwhenopenedwithoutvideo LE controlBar_classicVerifyVisibility,
          set(layer[controlBar_classicmenu_controlbar_bg_img].visible,false);
          set(layer[controlBar_classicmenu_controlbar_bg].visible,false);
        );
        if (controlBar_classicIsOpened,
          tween(layer[controlBar_classicmenu_controlbar_bg_img].width,get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo),0.5,easeOutQuad);
          tween(layer[controlBar_classicmenu_controlbar_bg].width,get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo),0.5,easeOutQuad);
        );
      ,
        set(layer[controlBar_classicmenu_controlbar_bg_img].width, get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo));
        set(layer[controlBar_classicmenu_controlbar_bg].width, get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo));
      );
      set(layer[controlBar_classicbtn_play_video].visible, false);
      set(layer[controlBar_classicbtn_pause_video].visible, false);
    </action>
    <action name="controlBar_classicShowHideShowVideoplayerButtons">
      if(controlBar_classic_use_videoplayer_interface,
        if (plugin[get(videointerface_video)],
        add(controlBar_classicVerifyVisibility, 20, 20);
        if(controlBar_classicbackgroundwidthwhenopenedwithoutvideo LE controlBar_classicVerifyVisibility,
          set(layer[controlBar_classicmenu_controlbar_bg_img].visible,true);
          set(layer[controlBar_classicmenu_controlbar_bg].visible,true);
        );
        if (plugin[get(videointerface_video)].ispaused,
          if(controlBar_classicbackgroundwidthwhenopened GT 0,
            tween(layer[controlBar_classicmenu_controlbar_bg_img].width,get(controlBar_classicbackgroundwidthwhenopened),0.5,easeOutQuad);
            tween(layer[controlBar_classicmenu_controlbar_bg].width,get(controlBar_classicbackgroundwidthwhenopened),0.5,easeOutQuad);
          ,
            set(layer[controlBar_classicmenu_controlbar_bg_img].width, get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo));
            set(layer[controlBar_classicmenu_controlbar_bg].width, get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo));
          );
          set(layer[controlBar_classicbtn_play_video].visible, true);
          set(layer[controlBar_classicbtn_pause_video].visible, false);
        ,
          if(controlBar_classicbackgroundwidthwhenopened GT 0,
            tween(layer[controlBar_classicmenu_controlbar_bg_img].width,get(controlBar_classicbackgroundwidthwhenopened),0.5,easeOutQuad);
            tween(layer[controlBar_classicmenu_controlbar_bg].width,get(controlBar_classicbackgroundwidthwhenopened),0.5,easeOutQuad);
          ,
            set(layer[controlBar_classicmenu_controlbar_bg_img].width, get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo));
            set(layer[controlBar_classicmenu_controlbar_bg].width, get(controlBar_classicbackgroundwidthwhenopenedwithoutvideo));
          );
          set(layer[controlBar_classicbtn_play_video].visible, false);
          set(layer[controlBar_classicbtn_pause_video].visible, true);
        ););
      ,
        controlBar_classicHideHideShowVideoplayerButtons();
      );
    </action>
    <action name="controlBar_classicupdateHideShowVideoplayerButtons">
      if (tour_displaycontrols,
        controlBar_classicShowHideShowVideoplayerButtons();
      ,
        controlBar_classicHideHideShowVideoplayerButtons();
      );
    </action>
    
	<events name="controlBar_classicplaystopsoundsevent" 
		playtoursoundsevent="controlBar_classicupdateSoundButtons();" 
		stoptoursoundsevent="controlBar_classicupdateSoundButtons();" 
		keep="true" />
	<action name="controlBar_classicHideSoundButtons">
		set(layer[controlBar_classicbtn_sound_off].visible, false);
		set(layer[controlBar_classicbtn_sound_on].visible , false);
	</action>
	<action name="controlBar_classicShowSoundButtons">
		if (tour_soundson == false,
			set(layer[controlBar_classicbtn_sound_off].visible, false);
			set(layer[controlBar_classicbtn_sound_on].visible , true);
		,
			set(layer[controlBar_classicbtn_sound_off].visible, true);
			set(layer[controlBar_classicbtn_sound_on].visible , false);
		);
	</action>
	<action name="controlBar_classicupdateSoundButtons">
		if (tour_displaycontrols,
			controlBar_classicShowSoundButtons();
		,
			controlBar_classicHideSoundButtons();
		);
	</action>



<layer name="controlBar_classicmenuTooltipStyle"
	keep="true"
	enabled="false"
	capture="false"
	type="text"
	align="center"
	bg="false"
	bgborder="0"
	txtshadow="1.0 1.0 4.0 0x000000 1"
	css="color:#e6e6e6;font-family:Helvetica;font-weight:bold;font-size:14px;text-align:left;"
	interactivecontent="false"
	zorder="0"
	visible="false"
	html=""
	padding="2"
	xoffset="0"
	yoffset="0"
	edge="bottom"
	/>



<!-- ********** -->
<!-- Menu contextuel -->
<!-- id : contextmenu -->
<!-- ********** -->
  <contextmenu fullscreen="false" versioninfo="false" touch="true">
    <item name="author" onclick="getmessage(urltoopen,project_author_url);openurl(get(urltoopen),_blank);" />
    <item name="fullscreenentry" onclick="enterFullscreen();
" separator="true"/>
  </contextmenu>

  <events name="contextmenuevents" keep="true" 
    onenterfullscreen="updateContextMenu" onexitfullscreen="updateContextMenu" 
    onxmlcomplete="updateContextMenu" 
    changetourlanguage="updateContextMenu" 
    />
  <events name="contextmenuvrevents" keep="true" 
    onvravailable="updateContextMenu();" onvrunavailable="updateContextMenu();"
    devices="html5"
    />
  <action name="updateContextMenu">
    getmessage(contextmenu.item[author].caption, project_author_name);
    if (device.fullscreensupport,
      if(tour_fullscreen,
        getmessage(contextmenu.item[fullscreenentry].caption, contextmenucloseFsLabel);
        set(contextmenu.item[fullscreenentry].onclick, exitFullscreen();
);
       ,
        getmessage(contextmenu.item[fullscreenentry].caption, contextmenuopenFsLabel);
        set(contextmenu.item[fullscreenentry].onclick, enterFullscreen();
);
      );
     ,
      set(contextmenu.item[fullscreenentry].visible, false);
    );
  </action>


  <events name="Bootstrap_External_Commandsevents" onnewpano="Bootstrap_External_Commandsonp();" keep="true"/>
  <action name="Bootstrap_External_Commandsonp">
  	js(updatePanorama(get(xml.scene)););
  </action>

<!-- ********** -->
<!-- Partage Social -->
<!-- id : socialShare -->
<!-- ********** -->


<ptplugin name="socialShare" engine="kolorBox">
	<settings>
		<option name="position" value="center" type="string" />
		<option name="margin_x" value="50" type="int" />
		<option name="margin_y" value="50" type="int" />
		<option name="external_padding" value="15" type="int" />
		<option name="animate" value="false" type="bool" />
		<option name="draggable_box" value="false" type="bool" />
		<option name="container_auto_size" value="true" type="bool" />
		<option name="container_color" value="ffffff" type="string" />
		<option name="container_alpha" value="0" type="float" />
		<option name="container_topleft_border_radius" value="15" type="int" />
		<option name="container_topright_border_radius" value="15" type="int" />
		<option name="container_bottomleft_border_radius" value="15" type="int" />
		<option name="container_bottomright_border_radius" value="15" type="int" />
		<option name="container_border_width" value="0" type="int" />
		<option name="container_border_color" value="ffffff" type="string" />
		<option name="container_border_alpha" value="1" type="float" />
		<option name="overlay_displayed" value="true" type="bool" />
		<option name="overlay_color" value="000000" type="string" />
		<option name="overlay_alpha" value="0.50000762951094835" type="float" />

		<option name="social_btn" value="facebook#twitter#google#linkedin#email" type="string" />
		<option name="social_btn_icons" value="iconset1" type="string" />

		<option name="social_orientation" value="horizontal" type="string" />
		<option name="social_btn_size" value="64" type="int" />
		<option name="inner_margin" value="10" type="int" />
		
		
		<option name="title_displayed" value="false" type="bool" />
		<option name="caption_displayed" value="false" type="bool" />
		<option name="close_displayed" value="true" type="bool" />
		<option name="close_position" value="topright" type="string" />
		<option name="close_text" value="socialShareclose_text" type="string" />

		<option name="close_callback" value="invokeKrFunction('closeKolorBoxCallback_socialShare')" type="string" />
		<option name="zorder" value="8" type="int" />
		<option name="use_i18n" value="true" type="bool" />
	</settings>
	<internaldata>

	</internaldata>
</ptplugin>

<action name="kolorBoxJsReady_socialShare">
	set(ptplugin[socialShare].jsready, true);

</action>



<action name="showSocialShare_socialShare">
	ifnot(ptplugin[socialShare].isOpen,
		set(ptplugin[socialShare].isOpen, true);
		pauseautorotation(forceplugin);

			js(invokePluginFunction(socialShare, loadSingleArrayItem, social));
		events.dispatch(onremovedisplayedobject);
	);
</action>

<action name="toggleSocialShare_socialShare">
	js(invokePluginFunction(socialShare, toggleKolorBox, %1));
</action>


<action name="closeKolorBox_socialShare">
	js(invokePluginFunction(socialShare, closeKolorBox));
</action>

<action name="closeKolorBoxCallback_socialShare">
	resumeautorotation(forceplugin);

	
	set(ptplugin[socialShare].isOpen, false);
</action>

<action name="changeLanguage_socialShare">
	if(ptplugin[socialShare].jsready,
		js(invokePluginFunction(socialShare, changeLanguage));
	);
</action>

<events name="kolorBoxEvents_socialShare" 
	keep="true"
	onsharetour="showSocialShare_socialShare();" 
	
	
	changetourlanguage="changeLanguage_socialShare();"
	/>

<!-- ********** -->
<!-- Description -->
<!-- id : description -->
<!-- ********** -->

<ptplugin name="description" canStart="false" newPano="false" openatstart="false" mode="spot" startMethod="" engine="kolorArea">
	<settings>
		<option name="position" value="center" type="string" />
		<option name="start_position" value="left" type="string" />
		<option name="margin_x" value="0" type="int" />
		<option name="margin_y" value="0" type="int" />
		<option name="background_color" value="ffffff" type="string" />
		<option name="background_alpha" value="0.80000000000000004" type="float" />
		<option name="topleft_radius" value="10" type="int" />
		<option name="topright_radius" value="10" type="int" />
		<option name="bottomleft_radius" value="10" type="int" />
		<option name="bottomright_radius" value="10" type="int" />
		<option name="area_border_width" value="0" type="int" />
		<option name="area_border_color" value="f2f2f2" type="string" />
		<option name="area_border_alpha" value="1" type="float" />
		<option name="padding" value="10" type="int" />
		<option name="display_title" value="false" type="bool" />
		<option name="close_displayed" value="true" type="bool" />
		<option name="close_text" value="descriptiondisplay_close_text" type="string" />

		<option name="overlay_displayed" value="true" type="bool" />
		<option name="overlay_color" value="000000" type="string" />
		<option name="overlay_alpha" value="0.50000762951094835" type="float" />

		<option name="area_width" value="50" type="int" />
		<option name="area_height" value="50" type="int" />
		<option name="area_width_unit" value="percent" type="string" />
		<option name="area_height_unit" value="percent" type="string" />
		<option name="animation" value="true" type="bool" />
		<option name="animation_duration" value="500" type="int" />
		<option name="refresh_content" value="true" type="bool" />
		<option name="close_callback" value="invokeKrFunction('closeKolorAreaCallback_description')" type="string" />
		<option name="close_on_click" value="false" type="bool" />
		<option name="zorder" value="9" type="int" />
		<option name="use_i18n" value="true" type="bool" />
	</settings>
</ptplugin>

<action name="kolorAreaJsReady_description">
	set(ptplugin[description].jsready, true);

</action>


<action name="openKolorArea_description">
	ifnot(ptplugin[description].isOpen,
		set(ptplugin[description].isOpen, true);
		
		js(showKolorArea(description, get(ptplugin[description].descID)));
		events.dispatch(onremovedisplayedobject);
	);
</action>

<action name="closeKolorArea_description">
	if(ptplugin[description].isOpen,
		js(invokePluginFunction(description, closeKolorArea));
	);
</action>

<action name="toggleKolorArea_description">
	if(ptplugin[description].isOpen,
		closeKolorArea_description();
	,
		openKolorArea_description();
	);
</action>

<action name="closeKolorAreaCallback_description">
	set(ptplugin[description].isOpen, false);
	if(tour_displayinfo,hideTourInfo();

	);
</action>



<action name="showKolorArea_description">
	ifnot(ptplugin[description].startMethod == "",
		delayedcall(0,get(ptplugin[description].startMethod));
	,
		set(ptplugin[description].isOpen, true);
		
		js(invokePluginFunction(description, showKolorArea, %1));
		events.dispatch(onremovedisplayedobject);
	);
</action>
	
<action name="hideKolorArea_description">
	
	set(ptplugin[description].isOpen, false);
	js(invokePluginFunction(description, hideKolorArea, %1));
</action>

<action name="openDescription_description">
	openKolorArea_description();
</action>

<action name="openSpotDescription_description">
	set(ptplugin[description].descID, %1);
	openKolorArea_description();
</action>

<action name="closeDescription_description">
	set(ptplugin[description].currentGroup, false);
	if(%1,
		set(restore_description, true);
	,
		set(restore_description, false);
	);
	closeKolorArea_description();
</action> 

<action name="showDescription_description">
	if(ptplugin[description].canStart,
		if(ptplugin[description].descID != "",
			openDescription_description();
		,
			hideKolorArea_description(false);
		);
		set(ptplugin[description].startMethod, "");
	);
</action>



<action name="changeLanguage_description">
	if(ptplugin[description].jsready,
		stopdelayedcall(delay_description);
		js(invokePluginFunction(description, changeLanguage, true));
	,
		delayedcall(delay_description, 0.1, changeLanguage_description(););
	);
</action>

<events name="kolorAreaEvents_description" 
	keep="true"
	onTourStart="set(ptplugin[description].canStart, true);if(ptplugin[description].openatstart,showTourInfo();
);"
	onhidetourinfo="if(ptplugin[description].isOpen,closeDescription_description(false););"
	changetourlanguage="changeLanguage_description();"
/>

<!-- ********** -->
<!-- Lecteur de vidéo Web -->
<!-- id : webVideoViewer -->
<!-- ********** -->

<ptplugin name="webVideoViewer" engine="kolorBox">
	<settings>
		<option name="position" value="center" type="string" />
		<option name="margin_x" value="0" type="int" />
		<option name="margin_y" value="0" type="int" />
		<option name="external_padding" value="15" type="int" />
		<option name="draggable_box" value="false" type="bool" />
		<option name="container_auto_size" value="true" type="bool" />
		<option name="container_width" value="100" type="int" />
		<option name="container_width_unit" value="percent" type="string" />
		<option name="container_height" value="100" type="int" />
		<option name="container_height_unit" value="percent" type="string" />
		<option name="container_color" value="ffffff" type="string" />
		<option name="container_alpha" value="0.80000000000000004" type="float" />
		<option name="container_topleft_border_radius" value="15" type="int" />
		<option name="container_topright_border_radius" value="15" type="int" />
		<option name="container_bottomleft_border_radius" value="15" type="int" />
		<option name="container_bottomright_border_radius" value="15" type="int" />
		<option name="container_border_width" value="0" type="int" />
		<option name="container_border_color" value="ffffff" type="string" />
		<option name="container_border_alpha" value="1" type="float" />
		<option name="overlay_displayed" value="true" type="bool" />
		<option name="overlay_color" value="000000" type="string" />
		<option name="overlay_alpha" value="0.50000762951094835" type="float" />

		<option name="title_displayed" value="false" type="bool" />
		<option name="title_position" value="top" type="string" />
		<option name="title_font" value="Verdana" type="string" />
		<option name="title_size" value="14" type="int" />
		<option name="title_weight" value="normal" type="string" />
		<option name="title_style" value="normal" type="string" />
		<option name="title_decoration" value="none" type="string" />
		<option name="title_color" value="000000" type="string" />
		<option name="caption_displayed" value="false" type="bool" />
		<option name="video_autoplay" value="false" type="bool" />
		<option name="fullscreen_displayed" value="true" type="bool" />
		<option name="fullscreen_position" value="topleft" type="string" />
		<option name="fullscreen_text" value="webVideoViewerfullscreen_text" type="string" />




		<option name="close_displayed" value="true" type="bool" />
		<option name="close_position" value="topright" type="string" />
		<option name="close_text" value="webVideoViewerclose_text" type="string" />

		<option name="close_callback" value="invokeKrFunction('closeKolorBoxCallback_webVideoViewer')" type="string" />
		<option name="zorder" value="10" type="int" />
		<option name="use_i18n" value="true" type="bool" />
	</settings>
	<internaldata>
		
	</internaldata>
</ptplugin>

<action name="kolorBoxJsReady_webVideoViewer">
	set(ptplugin[webVideoViewer].jsready, true);
</action>

<action name="openWebVideo_webVideoViewer">
	ifnot(ptplugin[webVideoViewer].isOpen,
		if(ptplugin[webVideoViewer].doNotDeleteMe,
			set(ptplugin[webVideoViewer].currentCall, false);
		set(ptplugin[webVideoViewer].isOpen, true);
		set(ptplugin[webVideoViewer].doNotDeleteMe, false);
		pauseautorotation(forceplugin);

		stopTourSounds();

		getmessage(webVideoViewer_boxurl, %1);
		js(invokePluginFunction(webVideoViewer, loadSingleArrayItem, get(webVideoViewer_boxurl), %2));
		,
			set(ptplugin[webVideoViewer].currentCall, true);
			set(ptplugin[webVideoViewer].doNotDeleteMe, true);
			events.dispatch(onremovedisplayedobject);
			delayedcall(0.3,openWebVideo_webVideoViewer(%1,%2););
		);
	,
		if('%1' != webVideoViewer_boxurl,
			closeKolorBox_webVideoViewer();
			delayedcall(0.3,openWebVideo_webVideoViewer(%1,%2););
		);
	);
</action>

<action name="toggleWebVideo_webVideoViewer">
	js(invokePluginFunction(webVideoViewer, toggleKolorBox, %1));
</action>


<action name="closeKolorBox_webVideoViewer">
	if(ptplugin[webVideoViewer].doNotDeleteMe,
		set(ptplugin[webVideoViewer].doNotDeleteMe, false);
	,
	js(invokePluginFunction(webVideoViewer, closeKolorBox));
	);
</action>

<action name="closeKolorBoxCallback_webVideoViewer">
	resumeautorotation(forceplugin);

	playTourSounds();

	set(ptplugin[webVideoViewer].doNotDeleteMe, false);
	set(ptplugin[webVideoViewer].isOpen, false);
</action>

<action name="changeLanguage_webVideoViewer">
	if(ptplugin[webVideoViewer].jsready,
		stopdelayedcall(delay_webVideoViewer);
		js(invokePluginFunction(webVideoViewer, changeLanguage));
	,
		delayedcall(delay_webVideoViewer, 0.1, changeLanguage_webVideoViewer(););
	);
</action>

<events name="kolorBoxEvents_webVideoViewer" 
	keep="true" 
	onremovepano="if(ptplugin[webVideoViewer].isOpen,closeKolorBox_webVideoViewer(););"
	onremovedisplayedobject="ifnot(ptplugin[webVideoViewer].currentCall,if(ptplugin[webVideoViewer].isOpen,closeKolorBox_webVideoViewer();););"
	changetourlanguage="changeLanguage_webVideoViewer();"
	/>

<!-- ********** -->
<!-- Galerie de la bretêche -->
<!-- id : gallery -->
<!-- ********** -->

<ptplugin name="gallery" engine="kolorBox">
	<settings>
		<option name="position" value="center" type="string" />
		<option name="margin_x" value="0" type="int" />
		<option name="margin_y" value="0" type="int" />
		<option name="external_padding" value="15" type="int" />
		<option name="draggable_box" value="false" type="bool" />
		<option name="slideshow_autoplay" value="false" type="bool" />
		<option name="slideshow" value="5000" type="int" />
		<option name="container_auto_size" value="true" type="bool" />
		<option name="container_width" value="100" type="int" />
		<option name="container_width_unit" value="percent" type="string" />
		<option name="container_height" value="100" type="int" />
		<option name="container_height_unit" value="percent" type="string" />
		<option name="container_color" value="ffffff" type="string" />
		<option name="container_alpha" value="0.80000000000000004" type="float" />
		<option name="container_topleft_border_radius" value="15" type="int" />
		<option name="container_topright_border_radius" value="15" type="int" />
		<option name="container_bottomleft_border_radius" value="15" type="int" />
		<option name="container_bottomright_border_radius" value="15" type="int" />
		<option name="container_border_width" value="0" type="int" />
		<option name="container_border_color" value="ffffff" type="string" />
		<option name="container_border_alpha" value="1" type="float" />
		<option name="overlay_displayed" value="true" type="bool" />
		<option name="overlay_color" value="000000" type="string" />
		<option name="overlay_alpha" value="0.50000762951094835" type="float" />

		<option name="item_border_width" value="0" type="int" />
		<option name="item_border_color" value="ffffff" type="string" />
		<option name="item_border_alpha" value="1" type="float" />
		
		<option name="title_displayed" value="false" type="bool" />
		
		<option name="caption_displayed" value="false" type="bool" />
		
		<option name="play_displayed" value="true" type="bool" />
		<option name="play_position" value="bottomleft" type="string" />
		<option name="play_text" value="galleryplay_text" type="string" />




		<option name="navigation_displayed" value="true" type="bool" />
		<option name="navigation_position" value="bottom" type="string" />
		<option name="counter_color" value="666666" type="string" />
		<option name="navprev_text" value="gallerynavprev_text" type="string" />
		<option name="navnext_text" value="gallerynavnext_text" type="string" />




		<option name="navigation_arrows" value="true" type="bool" />




		<option name="fullscreen_displayed" value="true" type="bool" />
		<option name="fullscreen_position" value="topleft" type="string" />
		<option name="fullscreen_text" value="galleryfullscreen_text" type="string" />




		<option name="close_displayed" value="true" type="bool" />
		<option name="close_position" value="topright" type="string" />
		<option name="close_text" value="galleryclose_text" type="string" />

		<option name="close_callback" value="invokeKrFunction('closeKolorBoxCallback_gallery')" type="string" />
		<option name="zorder" value="11" type="int" />
		<option name="use_i18n" value="true" type="bool" />
	</settings>
	<internaldata>
		<item name="item_1" title="gallerypicture_title0" caption="gallerypicture_caption0" value="indexdata/graphics/gallery/d50_7694.jpg"/>
		<item name="item_2" title="gallerypicture_title1" caption="gallerypicture_caption1" value="indexdata/graphics/gallery/d50_8550.jpg"/>
		<item name="item_3" title="gallerypicture_title2" caption="gallerypicture_caption2" value="indexdata/graphics/gallery/dji_0210.jpg"/>
		<item name="item_4" title="gallerypicture_title3" caption="gallerypicture_caption3" value="indexdata/graphics/gallery/img_1811.jpg"/>
		<item name="item_5" title="gallerypicture_title4" caption="gallerypicture_caption4" value="indexdata/graphics/gallery/img_1812.jpg"/>
		<item name="item_6" title="gallerypicture_title5" caption="gallerypicture_caption5" value="indexdata/graphics/gallery/img_1814.jpg"/>
	</internaldata>
</ptplugin>

<action name="kolorBoxJsReady_gallery">
	set(ptplugin[gallery].jsready, true);
</action>

<action name="showGallery_gallery">
	ifnot(ptplugin[gallery].isOpen,
		set(ptplugin[gallery].isOpen, true);
		set(ptplugin[gallery].doNotDeleteMe, false);
		set(gallery_boxurl, %1);
		pauseautorotation(forceplugin);

		js(invokePluginFunction(gallery, openKolorBox, %1));
		events.dispatch(onremovedisplayedobject);
	,
		if(%1 !== null AND %1 != gallery_boxurl,
			closeKolorBox_gallery();
			delayedcall(0.3,showGallery_gallery(%1););
		);
	);
</action>

<action name="toggleGallery_gallery">
	js(invokePluginFunction(gallery, toggleKolorBox, %1));
</action>


<action name="closeKolorBox_gallery">
	js(invokePluginFunction(gallery, closeKolorBox));
</action>

<action name="closeKolorBoxCallback_gallery">
	resumeautorotation(forceplugin);

	set(ptplugin[gallery].isOpen, false);
</action>

<action name="changeLanguage_gallery">
	if(ptplugin[gallery].jsready,
		js(invokePluginFunction(gallery, changeLanguage));
	,
		delayedcall(delay_gallery, 0.1, changeLanguage_gallery(););
	);
</action>

<events name="kolorBoxEvents_gallery" 
	keep="true"
	changetourlanguage="changeLanguage_gallery();"
	/>

<!-- ********** -->
<!-- Galerie1 -->
<!-- id : gallery1 -->
<!-- ********** -->

<ptplugin name="gallery1" engine="kolorBox">
	<settings>
		<option name="position" value="center" type="string" />
		<option name="margin_x" value="0" type="int" />
		<option name="margin_y" value="0" type="int" />
		<option name="external_padding" value="15" type="int" />
		<option name="draggable_box" value="false" type="bool" />
		<option name="slideshow_autoplay" value="false" type="bool" />
		<option name="slideshow" value="5000" type="int" />
		<option name="container_auto_size" value="true" type="bool" />
		<option name="container_width" value="100" type="int" />
		<option name="container_width_unit" value="percent" type="string" />
		<option name="container_height" value="100" type="int" />
		<option name="container_height_unit" value="percent" type="string" />
		<option name="container_color" value="ffffff" type="string" />
		<option name="container_alpha" value="0.80000000000000004" type="float" />
		<option name="container_topleft_border_radius" value="15" type="int" />
		<option name="container_topright_border_radius" value="15" type="int" />
		<option name="container_bottomleft_border_radius" value="15" type="int" />
		<option name="container_bottomright_border_radius" value="15" type="int" />
		<option name="container_border_width" value="0" type="int" />
		<option name="container_border_color" value="ffffff" type="string" />
		<option name="container_border_alpha" value="1" type="float" />
		<option name="overlay_displayed" value="true" type="bool" />
		<option name="overlay_color" value="000000" type="string" />
		<option name="overlay_alpha" value="0.50000762951094835" type="float" />

		<option name="item_border_width" value="0" type="int" />
		<option name="item_border_color" value="ffffff" type="string" />
		<option name="item_border_alpha" value="1" type="float" />
		
		<option name="title_displayed" value="false" type="bool" />
		
		<option name="caption_displayed" value="false" type="bool" />
		
		<option name="play_displayed" value="true" type="bool" />
		<option name="play_position" value="bottomleft" type="string" />
		<option name="play_text" value="gallery1play_text" type="string" />




		<option name="navigation_displayed" value="true" type="bool" />
		<option name="navigation_position" value="bottom" type="string" />
		<option name="counter_color" value="666666" type="string" />
		<option name="navprev_text" value="gallery1navprev_text" type="string" />
		<option name="navnext_text" value="gallery1navnext_text" type="string" />




		<option name="navigation_arrows" value="true" type="bool" />




		<option name="fullscreen_displayed" value="true" type="bool" />
		<option name="fullscreen_position" value="topleft" type="string" />
		<option name="fullscreen_text" value="gallery1fullscreen_text" type="string" />




		<option name="close_displayed" value="true" type="bool" />
		<option name="close_position" value="topright" type="string" />
		<option name="close_text" value="gallery1close_text" type="string" />

		<option name="close_callback" value="invokeKrFunction('closeKolorBoxCallback_gallery1')" type="string" />
		<option name="zorder" value="12" type="int" />
		<option name="use_i18n" value="true" type="bool" />
	</settings>
	<internaldata>
		<item name="item_1" title="gallery1picture_title0" caption="gallery1picture_caption0" value="indexdata/graphics/gallery1/"/>
	</internaldata>
</ptplugin>

<action name="kolorBoxJsReady_gallery1">
	set(ptplugin[gallery1].jsready, true);
</action>

<action name="showGallery_gallery1">
	ifnot(ptplugin[gallery1].isOpen,
		set(ptplugin[gallery1].isOpen, true);
		set(ptplugin[gallery1].doNotDeleteMe, false);
		set(gallery1_boxurl, %1);
		pauseautorotation(forceplugin);

		js(invokePluginFunction(gallery1, openKolorBox, %1));
		events.dispatch(onremovedisplayedobject);
	,
		if(%1 !== null AND %1 != gallery1_boxurl,
			closeKolorBox_gallery1();
			delayedcall(0.3,showGallery_gallery1(%1););
		);
	);
</action>

<action name="toggleGallery_gallery1">
	js(invokePluginFunction(gallery1, toggleKolorBox, %1));
</action>


<action name="closeKolorBox_gallery1">
	js(invokePluginFunction(gallery1, closeKolorBox));
</action>

<action name="closeKolorBoxCallback_gallery1">
	resumeautorotation(forceplugin);

	set(ptplugin[gallery1].isOpen, false);
</action>

<action name="changeLanguage_gallery1">
	if(ptplugin[gallery1].jsready,
		js(invokePluginFunction(gallery1, changeLanguage));
	,
		delayedcall(delay_gallery1, 0.1, changeLanguage_gallery1(););
	);
</action>

<events name="kolorBoxEvents_gallery1" 
	keep="true"
	changetourlanguage="changeLanguage_gallery1();"
	/>

<!-- ********** -->
<!-- Barre de contrôle Vidéo -->
<!-- id : videoControlBar -->
<!-- ********** -->






	<events name="videoControlBar_events"
		onenterfullscreen.fullscreensupport="videoControlBar_fs_button_update(true);"
		onexitfullscreen.fullscreensupport="videoControlBar_fs_button_update(false);"

		onTourStart="set(layer[videoControlBar_footer].canstart, true);if(layer[videoControlBar_footer].isready,videoControlBar_show(););"
		videointerfaceready="videoControlBar_init_menu();set(layer[videoControlBar_footer].isready, true);if(layer[videoControlBar_footer].canstart,videoControlBar_show(););"
		onremovepano="videoControlBar_hide();"
		onpausevideointerface="videoControlBar_update_pausestate();"
		onplayvideointerface="videoControlBar_update_pausestate();"
		changetourlanguage="videoControlBar_update_language();"
		keep="true"
		/>


	<action name="videoControlBar_init_menu">
		ifnot(device.fullscreensupport,
			
			ifnot(videoControlBar_fullscreenoff,set(layer[videoControlBar_pj_button].x, 0););
			ifnot(videoControlBar_fullscreenoff,set(layer[videoControlBar_quality].x, calc(layer[videoControlBar_quality].x - 30)););
			set(videoControlBar_fullscreenoff, true);
		);
		if(!device.panovideosupport OR scene[get(xml.scene)].planar == true,
			set(layer[videoControlBar_pj_button].visible, false);
		,
			set(layer[videoControlBar_pj_button].visible, true);
		);
		if(videoControlBar_fullscreenoff,
			set(layer[videoControlBar_pj_button].x, 0);
		,
			set(layer[videoControlBar_pj_button].x, calc(layer[videoControlBar_fs_button].x + 30));
			set(layer[videoControlBar_quality].x, calc(layer[videoControlBar_pj_button].x + 30));
		);
		set(videoControlBar_menuposx, 2);
		set(videoControlBar_menuposy, 40);
		videoControlBar_createmenu(qualitymenu, bottomright, 150, get(videoControlBar_menuposx), get(videoControlBar_menuposy));
		videoControlBar_setup_video_quality();
		set(plugin[get(videointerface_video)].current_videoscene_name, get(scene[get(xml.scene)].name));

		if(device.panovideosupport AND scene[get(xml.scene)].planar == false,
			videoControlBar_createmenu(viewmenu, bottomright, 150, get(videoControlBar_menuposx), get(videoControlBar_menuposy));
			getmessage(projection_caption, videoControlBarsourcelabel);
			videoControlBar_addmenuitem(viewmenu, sour, get(projection_caption), videoControlBar_source_view() );
			getmessage(projection_caption, videoControlBarnormallabel);
			videoControlBar_addmenuitem(viewmenu, rect, get(projection_caption), videoControlBar_rectilinear_view() );

			videoControlBar_selectmenuitem(viewmenu, rect);
		);
	</action>

	<action name="videoControlBar_update_language">

		if(scene[get(xml.scene)].name,
			getmessage(layer[videoControlBar_title].html, get(scene[get(xml.scene)].titleid));
			escape(layer[videoControlBar_title].html);
		);

if(videoControlBar_quality_counter GT 1,
	getmessage(quality_caption_high, videoControlBarquality_high_tip);
	getmessage(quality_caption_low, videoControlBarquality_low_tip);
	videoControlBar_updatemenuitem(qualitymenu, q1, get(quality_caption_high));
	videoControlBar_updatemenuitem(qualitymenu, q1, get(quality_caption_low));
	if(videoControlBar_current_videoscene_quality == 'low',
		videoControlBar_changequality_txt(get(quality_caption_low));
	,
		videoControlBar_changequality_txt(get(quality_caption_high));
	);
);
	getmessage(projection_caption, videoControlBarsourcelabel);
	videoControlBar_updatemenuitem(viewmenu, sour, get(projection_caption));
	getmessage(projection_caption, videoControlBarnormallabel);
	videoControlBar_updatemenuitem(viewmenu, rect, get(projection_caption));
	</action>


	<action name="videoControlBar_show">
		if(scene[get(xml.scene)].video,
			set(videointerface_controlbar_update, 'videoControlBar_apply_timer');
			videoControlBar_show_header();
			videoControlBar_show_seekbar();
			videoControlBar_show_footer();
		);
	</action>
	<action name="videoControlBar_hide">
		videoControlBar_hide_header();
		videoControlBar_hide_seekbar();
		videoControlBar_hide_footer();
		videoControlBar_hidemenu(viewmenu);
		videoControlBar_hidemenu(qualitymenu);
	</action>


	<layer name="videoControlBar_header"
		type="container"
		bgcolor="0x000000"
		bgalpha="0.7000076295109483"
		align="lefttop"
		x="0"
		y="0"
		zorder="13"
		enabled="true"
		capture="true"
		visible="false"
		height="30"
		width="100%"
		keep="true"
		>
		<layer name="videoControlBar_title"
			type="image"
			style="videoControlBar_titletxt_base"
			x="5"
			y="1"
			zorder="1"
			visible="false"
			/>
	</layer>
	<action name="videoControlBar_hide_header">
		set(layer[videoControlBar_header].visible, false);
	</action>
	<action name="videoControlBar_show_header">
		if(scene[get(xml.scene)].name,
			getmessage(layer[videoControlBar_title].html, get(scene[get(xml.scene)].titleid));
			escape(layer[videoControlBar_title].html);
			set(layer[videoControlBar_title].visible, true);
		);
		set(layer[videoControlBar_header].visible, true);
	</action>


	<layer name="videoControlBar_footer"
		type="container"
		bgcolor="0x000000"
		bgalpha="0.7000076295109483"
		align="bottomleft"
		x="0"
		y="0"
		zorder="13"
		enabled="true"
		capture="false"
		visible="false"
		height="30"
		width="100%"
		keep="true"
		>


		<layer name="videoControlBar_pp_button"
			style="videoControlBar_baseimage|videoControlBar_over" crop="0|0|30|30"
			align="bottomleft" x="0" y="0" zorder="1" width="30" height="30"
			onclick="videoControlBar_togglepause();"
			tooltip="videoControlBarplay_tip"
			/>

		<layer name="videoControlBar_snd_button"
			style="videoControlBar_baseimage|videoControlBar_over" crop="210|0|30|30"
			align="bottomleft" x="30" y="0" zorder="1" width="30" height="30"
			onclick="videoControlBar_togglesound();"
			tooltip="videoControlBarsound_mute_tip"
			/>


		<layer name="videoControlBar_timer"
			style="videoControlBar_timertxt_base" 
			x="65" y="0" zorder="1"
			html=""
			onautosized="videoControlBar_changetotaltime_pos();"
			/>

		<layer name="videoControlBar_timer_total"
			style="videoControlBar_timertxt_base" 
			x="65" y="0" zorder="1"
			baseposx="65"
			html=""
			/>


		<layer name="videoControlBar_fs_button" devices="fullscreensupport"
			style="videoControlBar_baseimage|videoControlBar_over" crop="60|0|30|30"
			align="bottomright" x="0" y="0" zorder="1" width="30" height="30"
			fs_state="false"
			onclick="videoControlBar_hidemenu(viewmenu);videoControlBar_hidemenu(qualitymenu);if(fs_state == false,enterFullscreen();
,exitFullscreen();
);"
			tooltip="videoControlBarfullscreen_open_tip"
			/>


		<layer name="videoControlBar_pj_button" devices="panovideosupport"
			style="videoControlBar_baseimage|videoControlBar_over" crop="240|0|30|30"
			align="bottomright" x="30" y="0" zorder="1" width="30" height="30"
			onclick="videoControlBar_toggle_viewmenu();"
			tooltip="videoControlBarprojection_tip"
			/>


		<layer name="videoControlBar_quality" devices="panovideosupport"
			type="container" width="10" height="30"
			align="bottomright" x="65" y="0" zorder="1"
			>
				<layer name="videoControlBar_quality_button_txt"
					style="videoControlBar_menutxt_base|videoControlBar_menutxt_normal" 
					align="bottomright" x="0" y="0" zorder="2"
					html=""
					onclick="videoControlBar_toggle_qualitymenu();"
					onautosized="videoControlBar_changequality_pos();"
					/>

				<layer name="videoControlBar_quality_button"
					style="videoControlBar_qualityimage" width="10" height="prop"
					align="right" x="0" y="0" zorder="2"
					onclick="videoControlBar_toggle_qualitymenu();"
					tooltip="videoControlBarquality_tip"
					onhover="videoControlBar_btntooltip_show();"
					onout="videoControlBar_btntooltip_hide();"
					/>
		</layer>

	</layer>
	<action name="videoControlBar_hide_footer">
		set(layer[videoControlBar_footer].visible, false);
	</action>
	<action name="videoControlBar_show_footer">
		set(layer[videoControlBar_footer].visible, true);
	</action>


	<layer name="videoControlBar_btntooltip"
		style="videoControlBar_tooltiptxt_base" 
		zorder="3"
		html=""
		edge="center"
		visible="false"
		keep="true"
		xoffset="0"
		yoffset="0"
		/>
	<action name="videoControlBar_btntooltip_show">
		if(tooltip,
			showTooltip('plugin', videoControlBar_btntooltip, bottom);
		);
	</action>
	<action name="videoControlBar_btntooltip_hide">
		hideTooltip();
	</action>


	<layer name="videoControlBar_seekbar"
		type="container"
		bgcolor="0x000000"
		bgalpha="0.7000076295109483"
		align="bottomleft"
		x="0"
		y="30"
		zorder="14"
		enabled="true"
		capture="true"
		bgcapture="true"
		visible="true"
		height="10"
		width="100%"
		ondown="if(plugin[get(videointerface_video)].isvideoready, asyncloop(pressed, videoControlBar_seekbar_seeking() ); );"
		onup="if(plugin[get(videointerface_video)].isvideoready, plugin[get(videointerface_video)].seek(get(seekpos_percent_text)); );"

		onhover="videoControlBar_timetooltip_show();"
		onout="videoControlBar_timetooltip_hide();"

		keep="true"
		>


		<layer name="videoControlBar_timetooltip"
			style="videoControlBar_tooltiptxt_base" 
			x="0" y="18" zorder="2"
			html=""
			tooltip=""
			edge="center"
			visible="false"
			/>

		<layer name="videoControlBar_loader"
			type="container"
			bgcolor="0xff6600"
			bgalpha="0.50000762951094835"
			align="bottomleft"
			x="0"
			y="0"
			zorder="1"
			enabled="false"
			capture="false"
			visible="true"
			height="10"
			width="0%"
			/>
		<layer name="videoControlBar_time"
			type="container"
			bgcolor="0xff6600"
			bgalpha="1"
			align="bottomleft"
			x="0"
			y="0"
			zorder="2"
			enabled="false"
			capture="false"
			visible="true"
			height="10"
			width="0%"
			/>
	</layer>
	<action name="videoControlBar_hide_seekbar">
		<!-- set(layer[videoControlBar_seekbar].y, 0); -->
		set(layer[videoControlBar_seekbar].visible, false);
	</action>
	<action name="videoControlBar_show_seekbar">
		<!-- set(layer[videoControlBar_seekbar].y, 30); -->
		set(layer[videoControlBar_seekbar].visible, true);
	</action>


	<action name="videoControlBar_seekbar_seeking">
		screentolayer(videoControlBar_seekbar, mouse.stagex, mouse.stagey, lx, ly);
		div(seekpos, lx, layer[videoControlBar_seekbar].pixelwidth);
		mul(seekpos_percent, seekpos, 100);
		clamp(seekpos_percent, 0, 100);
		txtadd(seekpos_percent_text, get(seekpos_percent), '%');
	</action>

	<action name="videoControlBar_timetooltip_show">
		screentolayer(videoControlBar_seekbar, mouse.stagex, mouse.stagey, lx, ly);
		div(tooltippos, lx, layer[videoControlBar_seekbar].pixelwidth);
		mul(tooltippos_percent, tooltippos, 100);
		clamp(tooltippos_percent, 0, 100);

		copy(vpc, plugin[get(videointerface_video)]);
		if(vpc AND vpc.loaded AND vpc.isvideoready AND vpc.isseeking == false,
			copy(tt, vpc.totaltime);

			mul(ttime, tooltippos_percent, tt);
			div(ttime, 100);

			videoControlBar_format_sec_to_hhmmss(ttime, layer[videoControlBar_timetooltip].html, false);
			
			set(layer[videoControlBar_timetooltip].x, get(lx));
			set(layer[videoControlBar_timetooltip].visible, true);
		);
		delete(vpc);
	</action>
	<action name="videoControlBar_timetooltip_hide">
		set(layer[videoControlBar_timetooltip].visible, false);
	</action>



	<action name="videoControlBar_fs_button_update" devices="fullscreensupport">
		if (%1,
			set(layer[videoControlBar_fs_button].fs_state, true);
			set(layer[videoControlBar_fs_button].crop, 90|0|30|30);
			set(layer[videoControlBar_fs_button].tooltip,'videoControlBarfullscreen_close_tip');
		,
			set(layer[videoControlBar_fs_button].fs_state, false);
			set(layer[videoControlBar_fs_button].crop, 60|0|30|30);
			set(layer[videoControlBar_fs_button].tooltip,'videoControlBarfullscreen_open_tip');
		);
	</action>


	<action name="videoControlBar_createmenu">
		set(name_w, 'videoControlBar_%1_window');
		set(name_m, 'videoControlBar_%1_menu');
		addlayer(get(name_w));
		addlayer(get(name_m));
		copy(layer_w, layer[get(name_w)]);
		copy(layer_m, layer[get(name_m)]);

		set(layer_w.parent, 'videoControlBar_footer');
		set(layer_w.type, container);
		set(layer_w.maskchildren, true);
		set(layer_w.align, %2);
		set(layer_w.width, %3);
		set(layer_w.height, 0);
		set(layer_w.x, %4);
		set(layer_w.y, %5);
		set(layer_w.bgcolor, 0x000000);
		set(layer_w.bgalpha, 0.7000076295109483);
		set(layer_w.visible, false);

		set(layer_m.state, 'closed');
		set(layer_m.parent, get(name_w));
		set(layer_m.type, container);
		set(layer_m.maskchildren, true);
		set(layer_m.align, lefttop);
		sub(layer_m.width, %3, 12);
		set(layer_m.height, 6);
		set(layer_m.x, 6);
		set(layer_m.y, 6);
	</action>


	<action name="videoControlBar_addmenuitem">
		set(name_w, 'videoControlBar_%1_window');
		set(name_m, 'videoControlBar_%1_menu');
		set(name_i, 'videoControlBar_%1_menuitem_%2');
		addlayer(get(name_i));
		copy(layer_w, layer[get(name_w)]);
		copy(layer_m, layer[get(name_m)]);
		copy(layer_i, layer[get(name_i)]);

		set(layer_i.parent, get(name_m));
		sub(layer_i.y, layer_m.height, 6);

		set(caption, %3);
		set(method, %4);

		if(caption,
			set(layer_i.html, %3);
			layer_i.loadstyle(videoControlBar_menuitem_base|videoControlBar_menuitem_normal);
			add(layer_m.height, 26);
			add(layer_w.height, layer_m.height, 6);
		,
			add(layer_i.y, 6);
			set(layer_i.width, 100%);
			set(layer_i.height, 1);
			set(layer_i.type, container);
			set(layer_i.bgalpha, 1.0);
			set(layer_i.bgcolor, 0xFFFFFF);
			add(layer_m.height, 13);
			add(layer_w.height, layer_m.height, 6);
		);
		if(method,
			set(layer_i.onclick, %4);
		);
		delete(caption, method, name_w, name_m, name_i, layer_i);
	</action>


	<action name="videoControlBar_updatemenuitem">
		set(name_i, 'videoControlBar_%1_menuitem_%2');
		addlayer(get(name_i));
		copy(layer_i, layer[get(name_i)]);

		set(caption, %3);

		if(caption,
			set(layer_i.html, %3);
			<!--
			layer_i.loadstyle(videoControlBar_menuitem_base|videoControlBar_menuitem_normal);
			-->
		);
		delete(caption, name_i, layer_i);
	</action>


	<action name="videoControlBar_selectmenuitem">
		set(name_i, 'videoControlBar_%1_menuitem_%2');
		copy(layer_i, layer[get(name_i)]);
		if(layer_i,
			if(%3 !== false,
				layer_i.loadstyle(videoControlBar_menuitem_selected);
			,
				layer_i.loadstyle(videoControlBar_menuitem_normal);
			);
		);
		delete(name_i);
	</action>


	<action name="videoControlBar_deselectmenuitem">
		videoControlBar_selectmenuitem(%1, %2, false);
	</action>


	<action name="videoControlBar_toggle_viewmenu">
		if(layer[videoControlBar_viewmenu_menu].state == 'closed',
			if(layer[videoControlBar_qualitymenu_menu].state == 'opened', videoControlBar_hidemenu(qualitymenu) );
			videoControlBar_showmenu(viewmenu);
		,
			videoControlBar_hidemenu(viewmenu);
		);
	</action>


	<action name="videoControlBar_update_viewmenu">
		resolvecondition(issour, %1 == sour);
		resolvecondition(isrect, %1 == rect);
		videoControlBar_selectmenuitem(viewmenu, sour, get(issour));
		videoControlBar_selectmenuitem(viewmenu, rect, get(isrect));
		delete(issour, isrect);
		videoControlBar_hidemenu(viewmenu);
	</action>


	<action name="videoControlBar_source_view">
		videoControlBar_update_viewmenu(sour);
		
		setViewSource();
	</action>


<action name="setViewSource">
	if(normalViewActivated,stopSetViewTweens(););
	setViewSourceComplete();
</action>

<action name="setViewSourceComplete">
	if(current_view_isflat !== true,
		set(current_view_isflat, true);
		stoptween(view.fov);
		mod(view.hlookat, 360);
		set(view.limitview, off);
		set(view.maxpixelzoom, 0);
		copy(video_controlbar_backup_fovmin, view.fovmin);
		copy(video_controlbar_backup_fov, view.fov);
		set(view.fovmin, 0.01);
		set(control.usercontrol, off);

		copy(current_fov, view.fov);
		remapfovtype(current_fov, get(view.fovtype), HFOV);
		set(view.fovtype, HFOV);
		copy(view.fov, current_fov);
		copy(startfov, current_fov);

		copy(image_hfov, image.hfov);
		tween(image_hfov, 1.0, 3.0, linear,
			set(control.usercontrol,all);
			set(view.fovmin, 0.25);
			set(view.hlookatmin, -2);
			set(view.hlookatmax, +2);
			set(view.vlookatmin, -1);
			set(view.vlookatmax, +1);
			set(view.limitview, range);
		,
			if(image_hfov LT 90,
				mul(view.fov, image_hfov, 1.1);
			,
				sub(hr, image_hfov, 90);
				div(hr, 270);
				sub(hr2, 1, hr);
				mul(a, startfov, hr);
				mul(b, 99, hr2);
				add(view.fov, a,b);
			);
			copy(image.hfov, image_hfov);
			set(image.vfov, 0);
			set(view.pannini, 0.0);
			updateobject(true, true);
		);

		adjusthlookat(0);
		tween(view.hlookat, 0, 1.5);
		tween(view.vlookat, 0, 1.5);
	);
</action>


<action name="setViewNonFlat">
	if(current_view_isflat === true,
		set(current_view_isflat, false);
		set(view.limitview, off);
		set(control.usercontrol, all);

		copy(current_fov, view.fov);
		remapfovtype(current_fov, get(view.fovtype), %1);
		set(view.fovtype, %1);
		copy(view.fov, current_fov);
		copy(image_hfov, image.hfov);

		if(view.fovtype == VFOV,
			if(scene[get(xml.scene)].planar,
				set(view.limitview, fullrange);
			,
				set(view.limitview, range);
				set(view.hlookatmin, get(panoview.hmin));
				set(view.hlookatmax, get(panoview.hmax));
				set(view.vlookatmin, get(panoview.vmin));
				set(view.vlookatmax, get(panoview.vmax));
			);
		);
	
		tween(image_hfov, 360.0, 3.0, linear,
			copy(view.fovmin, video_controlbar_backup_fovmin);
			if(view.fovtype != VFOV,
				if(scene[get(xml.scene)].planar,
					set(view.limitview, fullrange);
				,
					set(view.limitview, range);
					set(view.hlookatmin, get(panoview.hmin));
					set(view.hlookatmax, get(panoview.hmax));
					set(view.vlookatmin, get(panoview.vmin));
					set(view.vlookatmax, get(panoview.vmax));
				);
			);
		,
			copy(image.hfov, image_hfov);
			set(image.vfov, 0);
			updateobject(true, true);
		);
	,
		copy(current_fov, view.fov);
		remapfovtype(current_fov, get(view.fovtype), %1);
		set(view.fovtype, %1);
		copy(view.fov, current_fov);
	);

	if(view.vlookat LT -60 OR view.vlookat GT +60,
		tween(view.vlookat, 0.0, 0.30, easeInOutSine);
	);
</action>



	<action name="videoControlBar_rectilinear_view">
		videoControlBar_update_viewmenu(rect);setViewNormal();

	</action>









	<action name="videoControlBar_toggle_qualitymenu">
		if(layer[videoControlBar_qualitymenu_menu].state == 'closed',
			if(layer[videoControlBar_viewmenu_menu].state == 'opened', videoControlBar_hidemenu(viewmenu) );
			videoControlBar_showmenu(qualitymenu);
		,
			videoControlBar_hidemenu(qualitymenu);
		);
	</action>


	<action name="videoControlBar_showmenu">
		set(layer[videoControlBar_%1_menu].state, 'opened');
		set(layer[videoControlBar_%1_window].visible, true);
		delayedcall(videoControlBar_view_stop, 4.0, videoControlBar_hidemenu(viewmenu););
		delayedcall(videoControlBar_quality_stop, 4.0, videoControlBar_hidemenu(qualitymenu););
	</action>


	<action name="videoControlBar_hidemenu">
		stopdelayedcall(videoControlBar_view_stop);
		stopdelayedcall(videoControlBar_quality_stop);
		set(layer[videoControlBar_%1_menu].state, 'closed');
		set(layer[videoControlBar_%1_window].visible, false);
	</action>


	<style name="videoControlBar_baseimage" url="%FIRSTXML%/graphics/videocontrolbar/videointerface_skin_kolor.png" />
	<style name="videoControlBar_qualityimage" url="%FIRSTXML%/graphics/videocontrolbar/quality_skin_kolor.png" />


	<style name="videoControlBar_timertxt_base" type="text" align="bottomleft" vcenter="true" 
		height="30" padding="0" bg="false" capture="false" enabled="false" bgborder="0" 
		css="text-align:left;color:#ffffff;font-family:Arial;font-size:16px;" />

	<style name="videoControlBar_tooltiptxt_base" type="text" align="bottomleft" vcenter="true" 
		height="14" padding="0 2" roundedge="2" 
		 bg="true" bgcolor="0xeeeeee" bgalpha="1"
		 bgborder="0"
		
		capture="false" enabled="false" 
		css="text-align:left;color:#000000;font-family:Arial;font-weight:bold;font-size:11px;" />



	<style name="videoControlBar_titletxt_base" type="text" align="topleft" vcenter="true" wordwrap="false"  
		height="30" padding="0" bg="false" capture="false" enabled="true" bgborder="0" 
		css="text-align:left;color:#ffffff;font-family:Arial;font-size:14px;" 
		/>


	<style name="videoControlBar_menutxt_base" type="text" align="bottomright" x="0" vcenter="true" 
		height="30" padding="0 0 0 5" bg="false" border="false" 
		onover="loadstyle(videoControlBar_menutxt_over);" onout="loadstyle(videoControlBar_menutxt_normal);" 
		ondown.touch="onover();" onup.touch="onout();" />
	<style name="videoControlBar_menutxt_normal" enabled="true" alpha="1.0" 
		css="text-align:right; color:#ffffff;font-family:Arial;font-size:16px;" />
	<style name="videoControlBar_menutxt_over" enabled="true" alpha="1.0" 
		css="text-align:right; color:#ff6600;font-family:Arial;font-size:16px;" />
	<style name="videoControlBar_menuitem_base" type="text" align="lefttop" x="0" vcenter="true" 
		width="138" height="26" padding="0 3" bg="false" bgcolor="0xff6600" bgalpha="1.0" bgborder="0" 
		onover="set(bg,true);" onout="set(bg,false);" ondown.touch="onover();" onup.touch="onout();" />
	<style name="videoControlBar_menuitem_normal" txtshadow="" enabled="true" alpha="1.0" 
		css="text-align:left; color:#ffffff;font-family:Arial;font-size:16px;" />
	<style name="videoControlBar_menuitem_selected" txtshadow="0.01 0.01 4.0 0x000000 1.0" enabled="true" alpha="1.0" 
		css="text-align:left; color:#ff6600;font-family:Arial;font-size:16px;" />


	<action name="videoControlBar_changequality_pos">
		set(layer[videoControlBar_quality_button].x, get(layer[videoControlBar_quality_button_txt].width));
		set(layer[videoControlBar_quality].width, get(layer[videoControlBar_quality_button_txt].width));
		add(layer[videoControlBar_quality].width, 15);
	</action>
	<action name="videoControlBar_changequality_txt">
		set(layer[videoControlBar_quality_button_txt].html, %1);
	</action>

	<action name="videoControlBar_changetotaltime_pos">
		set(layer[videoControlBar_timer_total].x, get(layer[videoControlBar_timer].width));
		add(layer[videoControlBar_timer_total].x, get(layer[videoControlBar_timer_total].baseposx));
	</action>



	<style name="videoControlBar_over"
		ondown="videoControlBar_buttonover(get(name));"
		onhover="videoControlBar_btntooltip_show();"
		onover="videoControlBar_buttonover(get(name));"
		onout="videoControlBar_buttonover(null);videoControlBar_btntooltip_hide();"
		/>
	<action name="videoControlBar_buttonover">
		set(skin_newover_bt, %1);
		set(skin_newover_part2, '');

		indexoftxt(skin_overpos1, get(crop), '|');
		subtxt(skin_over_part1, get(crop), 0, get(skin_overpos1));
		inc(skin_overpos1);
		subtxt(skin_over1, get(crop), get(skin_overpos1), 8);
		indexoftxt(skin_overpos2, get(skin_over1), '|');
		subtxt(skin_newover_part2, get(skin_over1), 0, 2);
		txtreplace(skin_newover_part2, '|', '');
		inc(skin_overpos2);
		subtxt(skin_over2, get(skin_over1), get(skin_overpos2), 8);

		if(%1 != null,
			txtadd(skin_newover, get(skin_over_part1), '|30|', get(skin_over2));
		,
			txtadd(skin_newover, get(skin_over_part1), '|0|', get(skin_over2));
		);
		set(crop, get(skin_newover));
		delete(skin_newover, skin_over_part1, skin_over2, skin_over1, skin_overpos2, skin_overpos1);
	</action>


	<action name="videoControlBar_format_sec_to_hhmmss">
		copy(t,%1);
		div(hh,get(t),3600);
		Math.floor(hh);
		roundval(hh);
		div(mm,t,60);
		mod(mm,60);
		Math.floor(mm);
		roundval(mm);
		copy(ss,t);
		mod(ss,60);
		Math.floor(ss);
		roundval(ss);
		if(hh GT 0, if(mm LT 10, txtadd(mm, '0', get(mm)); ); );
		if(ss LT 10, txtadd(ss, '0', get(ss)); );
		txtadd(ft, get(mm),':',get(ss));
		if(hh GT 0, txtadd(ft,get(hh),':',get(ft)); );
		if(%3 == true, txtadd(ft,'&#x00A0;/&#x00A0;',get(ft)); );
		copy(%2,ft);
	</action>


<action name="videoControlBar_apply_timer">
	videoControlBar_format_sec_to_hhmmss(%1, layer[videoControlBar_timer].html, false);
	videoControlBar_format_sec_to_hhmmss(%2, layer[videoControlBar_timer_total].html, true);

	copy(layer[videoControlBar_loader].width, %3);
	copy(layer[videoControlBar_time].width, %4);
</action>


	<action name="videoControlBar_setup_video_quality">
		set(videoControlBar_quality_counter, 0);
		getmessage(quality_caption_high, videoControlBarquality_high_tip);
		videoControlBar_addmenuitem(qualitymenu, q1, get(quality_caption_high), videoControlBar_change_video_file(q1, get(quality_caption_high), get(scene[get(xml.scene)].scenevideourl), get(scene[get(xml.scene)].scenevideoposterurl), 'high'); );
		inc(videoControlBar_quality_counter);
		if(scene[get(xml.scene)].scenevideolowresurl != '',
			getmessage(quality_caption_low, videoControlBarquality_low_tip);
			videoControlBar_addmenuitem(qualitymenu, q2,  get(quality_caption_low), videoControlBar_change_video_file(q2, get(quality_caption_low), get(scene[get(xml.scene)].scenevideolowresurl), get(scene[get(xml.scene)].scenevideolowresposterurl), 'low'); ); 
			inc(videoControlBar_quality_counter);
		);
		
		if(videoControlBar_quality_counter GT 1,

			if(scene[get(xml.scene)].scenevideolowresurl != '' AND (device.html5 AND (device.mobile OR device.tablet OR device.safari)) AND scene[get(xml.scene)].name != plugin[get(videointerface_video)].current_videoscene_name,
				set(videoControlBar_current_videoscene_quality, 'low');
			);
			if(videoControlBar_current_videoscene_quality == 'low',
				videoControlBar_selectmenuitem(qualitymenu, q2);
				videoControlBar_changequality_txt(get(quality_caption_low));
			,
				videoControlBar_selectmenuitem(qualitymenu, q1);
				videoControlBar_changequality_txt(get(quality_caption_high));
			);
		,
			set(layer[videoControlBar_quality].visible, false);
		);
	</action>


	<action name="videoControlBar_change_video_file">
		plugin[get(videointerface_video)].playvideo(%3, %4, get(plugin[get(videointerface_video)].ispaused), get(plugin[get(videointerface_video)].time));
		videoControlBar_deselectmenuitem(qualitymenu, q1);
		videoControlBar_deselectmenuitem(qualitymenu, q2);
		videoControlBar_selectmenuitem(qualitymenu, %1);
		set(videoControlBar_current_videoscene_quality, %5);
		videoControlBar_hidemenu(qualitymenu);
		videoControlBar_changequality_txt(%2);
	</action>


	<action name="videoControlBar_togglepause">
		videoControlBar_hidemenu(viewmenu);
		videoControlBar_hidemenu(qualitymenu);videointerface_togglepause();
	</action>


	<action name="videoControlBar_update_pausestate">
		if(plugin[get(videointerface_video)].ispaused,
			set(layer[videoControlBar_pp_button].tooltip, 'videoControlBarplay_tip');
			if(skin_newover_bt == 'videoControlBar_pp_button',
				txtadd(newcrop, '0|',get(skin_newover_part2),'|30|30');
				set(layer[videoControlBar_pp_button].crop, get(newcrop));
			,
				set(layer[videoControlBar_pp_button].crop, 0|0|30|30);
			);
		,
			set(layer[videoControlBar_pp_button].tooltip, 'videoControlBarpause_tip');
			if(skin_newover_bt == 'videoControlBar_pp_button',
				txtadd(newcrop, '30|',get(skin_newover_part2),'|30|30');
				set(layer[videoControlBar_pp_button].crop, get(newcrop));
			,
				set(layer[videoControlBar_pp_button].crop, 30|0|30|30);
			);
			if(layer[videoControlBar_splashscreen_image].visible,
				tween(layer[videoControlBar_splashscreen_image].alpha, 0.0, 0.25, default, 
					set(layer[videoControlBar_splashscreen_image].visible,false);
				);
			);
		);
		layer[videoControlBar_pp_button].onout();
		layer[videoControlBar_pp_button].onover();
	</action>


	<action name="videoControlBar_togglesound">
		videoControlBar_hidemenu(viewmenu);
		videoControlBar_hidemenu(qualitymenu);
		videoControlBar_update_soundstate();
	</action>


	<action name="videoControlBar_update_soundstate">
		set(newcrop, '');
		set(snd_iconpos, 210);

		if(plugin[get(videointerface_video)].volume GT 0,
			if(plugin[get(videointerface_video)].volume LT 0.4,
				set(snd_iconpos, 180);
				add(plugin[get(videointerface_video)].volume, 0.33);
				set(layer[videoControlBar_snd_button].tooltip, 'videoControlBarsound_high_tip');
			,
				if(plugin[get(videointerface_video)].volume LT 0.7,
					add(plugin[get(videointerface_video)].volume, 0.33);
					set(layer[videoControlBar_snd_button].tooltip, 'videoControlBarsound_mute_tip');
				,
					set(snd_iconpos, 120);
					set(plugin[get(videointerface_video)].volume, 0);
					set(layer[videoControlBar_snd_button].tooltip, 'videoControlBarsound_low_tip');
				);
			);

			if(skin_newover_bt == 'videoControlBar_snd_button',
				txtadd(newcrop, get(snd_iconpos),'|',get(skin_newover_part2),'|30|30');
				set(layer[videoControlBar_snd_button].crop, get(newcrop));
			,
				txtadd(newcrop, get(snd_iconpos),'|0|30|30');
				set(layer[videoControlBar_snd_button].crop, get(newcrop));
			);

		,
			if(skin_newover_bt == 'videoControlBar_snd_button',
				txtadd(newcrop, '150|',get(skin_newover_part2),'|30|30');
				set(layer[videoControlBar_snd_button].crop, get(newcrop));
			,
				set(layer[videoControlBar_snd_button].crop, 150|0|30|30);
			);
			set(plugin[get(videointerface_video)].volume, 0.33);
			set(layer[videoControlBar_snd_button].tooltip, 'videoControlBarsound_medium_tip');
		);
		layer[videoControlBar_snd_button].onout();
		layer[videoControlBar_snd_button].onover();
		delete(newcrop, snd_iconpos);
	</action>

<!-- ********** -->
<!-- Barre de progression vidéo -->
<!-- id : videoProgressBar -->
<!-- ********** -->



<area mode="border" left="0" top="0" right="0" bottom="0" />


<events name="videoProgressBar_events" 
    onTourStart="set(layer[videoProgressBar_seekbar].canstart, true);if(layer[videoProgressBar_seekbar].isready,videoProgressBar_show(););" 
    videointerfaceready="set(layer[videoProgressBar_seekbar].isready, true);if(layer[videoProgressBar_seekbar].canstart,videoProgressBar_show(););" 
    onremovepano="videoProgressBar_hide();" 
    hidetourcontrols="videoProgressBar_hide();" 
    showtourcontrols="videoProgressBar_show();" 
    keep="true" />


<action name="videoProgressBar_show">
	if (tour_displaycontrols,

	if(scene[get(xml.scene)].video,
		set(videointerface_seekbar_update, 'videoProgressBar_apply_timer');
		set(area.bottom, 18);
		videoProgressBar_show_seekbar();
	);
	);
</action>
<action name="videoProgressBar_hide">

	set(area.bottom, 0);
	videoProgressBar_hide_seekbar();
</action>

<!-- interface seek bar -->

<layer name="videoProgressBar_seekbar"
	type="container"
	parent="STAGE"
	bgcolor="0xffffff"
	bgalpha="1.0"
	align="bottomleft"
	x="0"
	y="0"
	zorder="15"
	enabled="true"
	capture="true"
	bgcapture="true"
	visible="false"
	height="18"
	width="100%"
	ondown="if(plugin[get(videointerface_video)].isvideoready, asyncloop(pressed, videoProgressBar_seeking() ); );"
	onup="if(plugin[get(videointerface_video)].isvideoready, plugin[get(videointerface_video)].seek(get(seekpos_percent_text)); );"
	onhover="videoProgressBar_timetooltip_show();"
	onout="videoProgressBar_timetooltip_hide();"
	keep="true"
	>
	<!-- the timer text -->
	<layer name="videoProgressBar_timer"
		type="text" align="bottomleft" vcenter="true"
		height="18" padding="0" bg="false" capture="false" enabled="false" bgborder="0"
		css="text-align:left;color:#000000;font-family:Arial;font-size:14px;"
		x="5" y="0" zorder="3"
		html=""
		onautosized="videoProgressBar_changetotaltime_pos();"
		keep="true"
		/>

	<!-- the total timer text -->
	<layer name="videoProgressBar_timer_total"
		type="text"
		align="bottomleft" vcenter="true"
		height="18" padding="0" bg="false" capture="false" enabled="false" bgborder="0"
		css="text-align:left;color:#000000;font-family:Arial;font-size:14px;"
		x="5" y="0" zorder="3"
		baseposx="5"
		html=""
		keep="true"
		/>

	<!-- buffer/loader bar -->
	<layer name="videoProgressBar_loader"
		type="container"
		bgcolor="0xff6600"
		bgalpha="0.50000762951094835"
		align="bottomleft"
		x="0"
		y="0"
		zorder="1"
		enabled="false"
		capture="false"
		visible="true"
		height="18"
		width="0%"
		keep="true"
		/>

	<!-- time bar -->
	<layer name="videoProgressBar_time"
		type="container"
		bgcolor="0xff6600"
		bgalpha="1"
		align="bottomleft"
		x="0"
		y="0"
		zorder="2"
		enabled="false"
		capture="false"
		visible="true"
		height="18"
		width="0%"
		keep="true"
		/>
</layer>
<action name="videoProgressBar_hide_seekbar">
	set(layer[videoProgressBar_seekbar].visible, false);
</action>
<action name="videoProgressBar_show_seekbar">
	set(layer[videoProgressBar_seekbar].visible, true);
</action>

<action name="videoProgressBar_changetotaltime_pos">
	set(layer[videoProgressBar_timer_total].x, get(layer[videoProgressBar_timer].width));
	add(layer[videoProgressBar_timer_total].x, get(layer[videoProgressBar_timer_total].baseposx));
</action>

<action name="videoProgressBar_seeking">
	screentolayer(videoProgressBar_seekbar, mouse.stagex, mouse.stagey, lx, ly);
	div(seekpos, lx, layer[videoProgressBar_seekbar].pixelwidth);
	mul(seekpos_percent, seekpos, 100);
	clamp(seekpos_percent, 0, 100);
	txtadd(seekpos_percent_text, get(seekpos_percent), '%');
</action>

<!-- tooltip for seek bar -->
<layer name="videoProgressBar_timetooltip"
	keep="true"
	enabled="false"
	capture="false"
	type="text"
	align="bottomleft"
	bg="true"
	bgcolor="0xeeeeee"
	bgalpha="1"
	bgroundedge="2"
	bgborder="0"
	css="color:#000000;font-family:Arial;font-size:11px;text-align:center;"
	height="14"
	edge="bottom"
	interactivecontent="false"
	zorder="99"
	padding="0 2"
	x="0"
	y="3"
	visible="false"
	html=""
	/>

<action name="videoProgressBar_timetooltip_show">
	screentolayer(videoProgressBar_seekbar, mouse.stagex, mouse.stagey, lx, ly);
	div(tooltippos, lx, layer[videoProgressBar_seekbar].pixelwidth);
	mul(tooltippos_percent, tooltippos, 100);
	clamp(tooltippos_percent, 0, 100);

	copy(vps, plugin[get(videointerface_video)]);
	if(vps AND vps.loaded AND vps.isvideoready AND vps.isseeking == false,
		copy(tt, vps.totaltime);

		mul(ttime, tooltippos_percent, tt);
		div(ttime, 100);

		videoProgressBar_format_sec_to_hhmmss(ttime, layer[videoProgressBar_timetooltip].html, false);
		set(layer[videoProgressBar_timetooltip].x, get(lx));
		set(layer[videoProgressBar_timetooltip].visible, true);
	);
	delete(vps);
</action>
<action name="videoProgressBar_timetooltip_hide">
	set(layer[videoProgressBar_timetooltip].visible, false);
</action>


<action name="videoProgressBar_format_sec_to_hhmmss">
	copy(t,%1);
	div(hh,get(t),3600);
	Math.floor(hh);
	roundval(hh);
	div(mm,t,60);
	mod(mm,60);
	Math.floor(mm);
	roundval(mm);
	copy(ss,t);
	mod(ss,60);
	Math.floor(ss);
	roundval(ss);
	if(hh GT 0, if(mm LT 10, txtadd(mm, '0', get(mm)); ); );
	if(ss LT 10, txtadd(ss, '0', get(ss)); );
	txtadd(ft, get(mm),':',get(ss));
	if(hh GT 0, txtadd(ft,get(hh),':',get(ft)); );
	if(%3 == true, txtadd(ft,'&#x00A0;/&#x00A0;',get(ft)); );
	copy(%2,ft);
</action>


<action name="videoProgressBar_apply_timer">
	videoProgressBar_format_sec_to_hhmmss(%1, layer[videoProgressBar_timer].html, false);
	videoProgressBar_format_sec_to_hhmmss(%2, layer[videoProgressBar_timer_total].html, true);

	copy(layer[videoProgressBar_loader].width, %3);
	copy(layer[videoProgressBar_time].width, %4);
</action>

<!-- ********** -->
<!-- Salle 01 -->
<!-- id : callActionsOnTourEvents -->
<!-- ********** -->
    <events name="callActionsOnTourEventsevents" keep="true"
            onnewpano="callActionsOnTourEventsonnewpano()"

     />



    <action name="callActionsOnTourEventsonnewpano">
        callActionsOnTourEventsCheckIfActionShouldBeDone();
        if (callActionsOnTourEventsDoTheAction,
playsound3Dwhenpossible(soundcallActionsOnTourEvents, %$videos_sounds_path%/sounds/intro_salle_01_01.mp3, false, true, 1, callActionsOnTourEvents);


        );
    </action>






    <action name="callActionsOnTourEventsCheckIfActionShouldBeDone">
        set(callActionsOnTourEventsDoTheAction, false);

        if (xml.scene == pano105,
            set(callActionsOnTourEventsDoTheAction, true);
        );


    </action>
<!-- ********** -->
<!-- SAlle 02 -->
<!-- id : callActionsOnTourEvents1 -->
<!-- ********** -->
    <events name="callActionsOnTourEvents1events" keep="true"
            onnewpano="callActionsOnTourEvents1onnewpano()"

     />



    <action name="callActionsOnTourEvents1onnewpano">
        callActionsOnTourEvents1CheckIfActionShouldBeDone();
        if (callActionsOnTourEvents1DoTheAction,
playsound3Dwhenpossible(soundcallActionsOnTourEvents1, %$videos_sounds_path%/sounds/intro_salle_02_01.mp3, false, false, 1, callActionsOnTourEvents1);


        );
    </action>






    <action name="callActionsOnTourEvents1CheckIfActionShouldBeDone">
        set(callActionsOnTourEvents1DoTheAction, false);

        if (xml.scene == pano109,
            set(callActionsOnTourEvents1DoTheAction, true);
        );


    </action>
<!-- ********** -->
<!-- Salle 03 -->
<!-- id : callActionsOnTourEvents2 -->
<!-- ********** -->
    <events name="callActionsOnTourEvents2events" keep="true"
            onnewpano="callActionsOnTourEvents2onnewpano()"

     />



    <action name="callActionsOnTourEvents2onnewpano">
        callActionsOnTourEvents2CheckIfActionShouldBeDone();
        if (callActionsOnTourEvents2DoTheAction,
playsound3Dwhenpossible(soundcallActionsOnTourEvents2, %$videos_sounds_path%/sounds/salle-3-intro_01.mp3, false, false, 1, callActionsOnTourEvents2);


        );
    </action>






    <action name="callActionsOnTourEvents2CheckIfActionShouldBeDone">
        set(callActionsOnTourEvents2DoTheAction, false);

        if (xml.scene == pano111,
            set(callActionsOnTourEvents2DoTheAction, true);
        );


    </action>
<!-- ********** -->
<!-- Salle 04 -->
<!-- id : callActionsOnTourEvents3 -->
<!-- ********** -->
    <events name="callActionsOnTourEvents3events" keep="true"
            onnewpano="callActionsOnTourEvents3onnewpano()"

     />



    <action name="callActionsOnTourEvents3onnewpano">
        callActionsOnTourEvents3CheckIfActionShouldBeDone();
        if (callActionsOnTourEvents3DoTheAction,
playsound3Dwhenpossible(soundcallActionsOnTourEvents3, %$videos_sounds_path%/sounds/salle_4_intro.mp3, false, false, 1, callActionsOnTourEvents3);


        );
    </action>






    <action name="callActionsOnTourEvents3CheckIfActionShouldBeDone">
        set(callActionsOnTourEvents3DoTheAction, false);

        if (xml.scene == pano113,
            set(callActionsOnTourEvents3DoTheAction, true);
        );


    </action>
<!-- ********** -->
<!-- Salle 05 -->
<!-- id : callActionsOnTourEvents4 -->
<!-- ********** -->
    <events name="callActionsOnTourEvents4events" keep="true"
            onnewpano="callActionsOnTourEvents4onnewpano()"

     />



    <action name="callActionsOnTourEvents4onnewpano">
        callActionsOnTourEvents4CheckIfActionShouldBeDone();
        if (callActionsOnTourEvents4DoTheAction,
playsound3Dwhenpossible(soundcallActionsOnTourEvents4, %$videos_sounds_path%/sounds/salle_5_intro.mp3, false, false, 1, callActionsOnTourEvents4);


        );
    </action>






    <action name="callActionsOnTourEvents4CheckIfActionShouldBeDone">
        set(callActionsOnTourEvents4DoTheAction, false);

        if (xml.scene == pano115,
            set(callActionsOnTourEvents4DoTheAction, true);
        );


    </action>
<!-- ********** -->
<!-- Boussole -->
<!-- id : compass -->
<!-- ********** -->

  <layer name="compassbackground"
         type="container"
         keep="true"
         handcursor="false"
         capture="false"
         align="topright"
         x="0"
         y="15"
         zorder="21"
         visible="false"
         active="true"
         started="false"

         height="100"
         width="100"

         >

    <layer name="compassrotatebackground"
           url="%FIRSTXML%/graphics/compass/compassbg53a0d7.png"
           keep="true"
           handcursor="false"
           capture="false"
           align="center"
           zorder="0"
           height="100%"
           width="100%"
           />



    <layer name="compasspointer"
           url="%FIRSTXML%/graphics/compass/compasspointerb17135.png"
           keep="true"
           align="center"
           handcursor="false"
           capture="false"
           zorder="1"
           height="100%"
           width="100%"
          />
  </layer>

  <events name="compassevts"
          keep="true"
          onnewpano="compassUpdateOrientation();"
          onviewchanged="compassUpdateOrientation();"
    onTourStart="set(layer[compassbackground].started, true);showcompass();"
          hidetourcontrols="hidecompass();"
          showtourcontrols="set(layer[compassbackground].started, true);showcompass();"
         />

  <action name="compassUpdateOrientation">
    if(scene[get(xml.scene)].planar,
      set(layer[compassbackground].active, false);
      hidecompass();
    ,

      set(layer[compassbackground].active, true);
      mod(compasshlookat, view.hlookat, 360);
      mul(compassheading, -1, get(scene[get(xml.scene)].heading));
      if (compassheading == null, set(compassheading, 0));
      sub(layer[compassrotatebackground].rotate, compassheading, compasshlookat);

      showcompass();
    );
  </action>

 
  <action name="hidecompass">
    set(layer[compassbackground].visible, false);
  </action>
  <action name="showcompass">
    if(tour_displaycontrols,
    if(layer[compassbackground].active AND layer[compassbackground].started,set(layer[compassbackground].visible, true););
    ,hidecompass(););
  </action>

<!-- ********** -->
<!-- Logo sur Pano 1 -->
<!-- id : callActionsOnTourEvents6 -->
<!-- ********** -->
    <events name="callActionsOnTourEvents6events" keep="true"
            ontourstart="callActionsOnTourEvents6ontourstart()"

     />



    <action name="callActionsOnTourEvents6ontourstart">
        callActionsOnTourEvents6CheckIfActionShouldBeDone();
        if (callActionsOnTourEvents6DoTheAction,

displayImage(%FIRSTXML%/graphics/actionstourevents6/fichier_4.png
             ,topleft,0,0
             ,'',''
             ,false
             ,false
             ,false
             ,false
             ,000000
             ,0.80000000000000004);


        );
    </action>






    <action name="callActionsOnTourEvents6CheckIfActionShouldBeDone">
        set(callActionsOnTourEvents6DoTheAction, false);

        if (xml.scene == pano72,
            set(callActionsOnTourEvents6DoTheAction, true);
        );


    </action>
<!-- ********** -->
<!-- OURS -->
<!-- id : callActionsOnTourEvents8 -->
<!-- ********** -->
    <events name="callActionsOnTourEvents8events" keep="true"
            onnewpano="callActionsOnTourEvents8onnewpano()"

     />



    <action name="callActionsOnTourEvents8onnewpano">
        callActionsOnTourEvents8CheckIfActionShouldBeDone();
        if (callActionsOnTourEvents8DoTheAction,
openPDF_PdfViewer1("indexdata/graphics/KolorBox/pdfjs/web/viewer.html?file=../../../../graphics/actionstourevents8/ours.pdf", callActionsOnTourEvents8onnewpanoaction114332PdfViewer1|PdfViewer|displaypdfpdf_title);



        );
    </action>






    <action name="callActionsOnTourEvents8CheckIfActionShouldBeDone">
        set(callActionsOnTourEvents8DoTheAction, false);

        if (xml.scene == pano724,
            set(callActionsOnTourEvents8DoTheAction, true);
        );


    </action>
<!-- ********** -->
<!-- Description1 -->
<!-- id : description1 -->
<!-- ********** -->

<ptplugin name="description1" canStart="false" newPano="false" openatstart="false" mode="panorama" startMethod="showDescription_description1" engine="kolorArea">
	<settings>
		<option name="position" value="bottomleft" type="string" />
		<option name="start_position" value="left" type="string" />
		<option name="margin_x" value="0" type="int" />
		<option name="margin_y" value="0" type="int" />
		<option name="background_color" value="f2f2f2" type="string" />
		<option name="background_alpha" value="0.80000000000000004" type="float" />
		<option name="topleft_radius" value="0" type="int" />
		<option name="topright_radius" value="0" type="int" />
		<option name="bottomleft_radius" value="0" type="int" />
		<option name="bottomright_radius" value="0" type="int" />
		<option name="area_border_width" value="0" type="int" />
		<option name="area_border_color" value="f2f2f2" type="string" />
		<option name="area_border_alpha" value="1" type="float" />
		<option name="padding" value="5" type="int" />
		<option name="display_title" value="false" type="bool" />
		<option name="close_displayed" value="true" type="bool" />
		<option name="close_text" value="description1display_close_text" type="string" />

		<option name="overlay_displayed" value="false" type="bool" />
		<option name="overlay_color" value="000000" type="string" />
		<option name="overlay_alpha" value="0.50000762951094835" type="float" />

		<option name="area_width" value="40" type="int" />
		<option name="area_height" value="100" type="int" />
		<option name="area_width_unit" value="percent" type="string" />
		<option name="area_height_unit" value="percent" type="string" />
		<option name="animation" value="true" type="bool" />
		<option name="animation_duration" value="500" type="int" />
		<option name="refresh_content" value="true" type="bool" />
		<option name="close_callback" value="invokeKrFunction('closeKolorAreaCallback_description1')" type="string" />
		<option name="close_on_click" value="false" type="bool" />
		<option name="zorder" value="24" type="int" />
		<option name="use_i18n" value="true" type="bool" />
	</settings>
</ptplugin>

<action name="kolorAreaJsReady_description1">
	set(ptplugin[description1].jsready, true);

</action>


<action name="openKolorArea_description1">
	ifnot(ptplugin[description1].isOpen,
		set(ptplugin[description1].isOpen, true);
		
		js(showKolorArea(description1, get(ptplugin[description1].descID)));
		events.dispatch(onremovedisplayedobject);
	);
</action>

<action name="closeKolorArea_description1">
	if(ptplugin[description1].isOpen,
		js(invokePluginFunction(description1, closeKolorArea));
	);
</action>

<action name="toggleKolorArea_description1">
	if(ptplugin[description1].isOpen,
		closeKolorArea_description1();
	,
		openKolorArea_description1();
	);
</action>

<action name="closeKolorAreaCallback_description1">
	set(ptplugin[description1].isOpen, false);
	if(tour_displayinfo,hideTourInfo();

	);
</action>



<action name="showKolorArea_description1">
	ifnot(ptplugin[description1].startMethod == "",
		delayedcall(0,get(ptplugin[description1].startMethod));
	,
		set(ptplugin[description1].isOpen, true);
		
		js(invokePluginFunction(description1, showKolorArea, %1));
		events.dispatch(onremovedisplayedobject);
	);
</action>
	
<action name="hideKolorArea_description1">
	
	set(ptplugin[description1].isOpen, false);
	js(invokePluginFunction(description1, hideKolorArea, %1));
</action>

<action name="openDescription_description1">
	openKolorArea_description1();
</action>

<action name="openSpotDescription_description1">
	set(ptplugin[description1].descID, %1);
	openKolorArea_description1();
</action>

<action name="closeDescription_description1">
	set(ptplugin[description1].currentGroup, false);
	if(%1,
		set(restore_description1, true);
	,
		set(restore_description1, false);
	);
	closeKolorArea_description1();
</action> 

<action name="showDescription_description1">
	if(ptplugin[description1].canStart,
		set(ptplugin[description1].descID, get(scene[get(xml.scene)].descriptionid));
		if(ptplugin[description1].descID == null,
			set(ptplugin[description1].descID, "");
		);
		if(ptplugin[description1].descID != "",
			openDescription_description1();
		,
			hideKolorArea_description1(false);
		);
		set(ptplugin[description1].startMethod, "");
	);
</action>


<action name="refreshPanoDescription_description1">
	set(ptplugin[description1].descID, get(scene[get(xml.scene)].descriptionid));
	if(ptplugin[description1].descID == null,
		set(ptplugin[description1].descID, "");
	);
	if(ptplugin[description1].descID != "",
		if(ptplugin[description1].isOpen,
			js(invokePluginFunction(description1, updateKolorArea, get(ptplugin[description1].descID)));
		,
			if(restore_description1,
				showDescription_description1();
			);
		);
	,
		if(tour_displayinfo,
			delayedcall(0.1,showTourInfo();
);
		);
		closeDescription_description1(get(ptplugin[description1].isOpen));
	);
</action>

<action name="onNewPano_description1">
	if(ptplugin[description1].newPano,
		if(ptplugin[description1].startMethod == "",
			if(ptplugin[description1].isOpen,
				refreshPanoDescription_description1();
			,
				if(tour_displayinfo,
				showDescription_description1();
				,
				refreshPanoDescription_description1();
				);
			);
		);
	);
	set(ptplugin[description1].newPano, true);
</action>

<action name="changeLanguage_description1">
	if(ptplugin[description1].jsready,
		stopdelayedcall(delay_description1);
		js(invokePluginFunction(description1, changeLanguage, true));
	,
		delayedcall(delay_description1, 0.1, changeLanguage_description1(););
	);
</action>

<events name="kolorAreaEvents_description1" 
	keep="true"
	onTourStart="set(ptplugin[description1].canStart, true);if(ptplugin[description1].openatstart,showTourInfo();
);"
	onshowtourinfo="if(tour_displayinfo,showDescription_description1(););"
	onhidetourinfo="if(ptplugin[description1].isOpen,closeDescription_description1(false););"
	onnewpano="onNewPano_description1();"
	changetourlanguage="changeLanguage_description1();"
/>

<!-- ********** -->
<!-- Lecteur PDF -->
<!-- id : PdfViewer -->
<!-- ********** -->

<ptplugin name="PdfViewer" engine="kolorBox">
	<settings>
		<option name="position" value="center" type="string" />
		<option name="margin_x" value="0" type="int" />
		<option name="margin_y" value="0" type="int" />
		<option name="external_padding" value="15" type="int" />
		<option name="draggable_box" value="false" type="bool" />
		<option name="container_auto_size" value="true" type="bool" />
		<option name="container_width" value="100" type="int" />
		<option name="container_width_unit" value="percent" type="string" />
		<option name="container_height" value="100" type="int" />
		<option name="container_height_unit" value="percent" type="string" />
		<option name="container_color" value="ffffff" type="string" />
		<option name="container_alpha" value="0" type="float" />
		<option name="container_topleft_border_radius" value="15" type="int" />
		<option name="container_topright_border_radius" value="15" type="int" />
		<option name="container_bottomleft_border_radius" value="15" type="int" />
		<option name="container_bottomright_border_radius" value="15" type="int" />
		<option name="container_border_width" value="0" type="int" />
		<option name="container_border_color" value="ffffff" type="string" />
		<option name="container_border_alpha" value="1" type="float" />
		<option name="overlay_displayed" value="true" type="bool" />
		<option name="overlay_color" value="000000" type="string" />
		<option name="overlay_alpha" value="0.50000762951094835" type="float" />

		<option name="title_displayed" value="false" type="bool" />
		<option name="title_position" value="top" type="string" />
		<option name="title_font" value="Verdana" type="string" />
		<option name="title_size" value="14" type="int" />
		<option name="title_weight" value="normal" type="string" />
		<option name="title_style" value="normal" type="string" />
		<option name="title_decoration" value="none" type="string" />
		<option name="title_color" value="000000" type="string" />
		<option name="caption_displayed" value="false" type="bool" />
		<option name="fullscreen_displayed" value="true" type="bool" />
		<option name="fullscreen_position" value="topleft" type="string" />
		<option name="fullscreen_text" value="PdfViewerfullscreen_text" type="string" />




		<option name="close_displayed" value="true" type="bool" />
		<option name="close_position" value="topright" type="string" />
		<option name="close_text" value="PdfViewerclose_text" type="string" />

		<option name="iframe_default_width" value="600" type="int" />
		<option name="iframe_default_height" value="840" type="int" />
		<option name="iframe_devices_width" value="1024" type="int" />
		<option name="iframe_devices_height" value="5000" type="int" />
		<option name="force_ios_scrolling" value="true" type="bool" />
		<option name="close_callback" value="invokeKrFunction('closeKolorBoxCallback_PdfViewer')" type="string" />
		<option name="zorder" value="25" type="int" />
		<option name="use_i18n" value="true" type="bool" />
	</settings>
	<internaldata>
		
	</internaldata>
</ptplugin>

<action name="kolorBoxJsReady_PdfViewer">
	set(ptplugin[PdfViewer].jsready, true);
</action>

<action name="openPDF_PdfViewer">
	ifnot(ptplugin[PdfViewer].isOpen,
		set(ptplugin[PdfViewer].isOpen, true);
		set(ptplugin[PdfViewer].doNotDeleteMe, false);
		set(PdfViewer_boxurl, %1);
		pauseautorotation(forceplugin);

		js(invokePluginFunction(PdfViewer, loadSingleArrayItem, %1?iframe=true, %2));
		events.dispatch(onremovedisplayedobject);
	,
		if('%1' != PdfViewer_boxurl,
			closeKolorBox_PdfViewer();
			delayedcall(0.3,openPDF_PdfViewer(%1,%2););
		);
	);
</action>

<action name="togglePDF_PdfViewer">
	js(invokePluginFunction(PdfViewer, toggleKolorBox, %1));
</action>


<action name="closeKolorBox_PdfViewer">
	js(invokePluginFunction(PdfViewer, closeKolorBox));
</action>

<action name="closeKolorBoxCallback_PdfViewer">
	resumeautorotation(forceplugin);

	set(ptplugin[PdfViewer].isOpen, false);
</action>

<action name="changeLanguage_PdfViewer">
	if(ptplugin[PdfViewer].jsready,
		stopdelayedcall(delay_PdfViewer);
		js(invokePluginFunction(PdfViewer, changeLanguage));
	,
		delayedcall(delay_PdfViewer, 0.1, changeLanguage_PdfViewer(););
	);
</action>

<events name="kolorBoxEvents_PdfViewer" 
	keep="true"
	changetourlanguage="changeLanguage_PdfViewer();"
	/>

<!-- ********** -->
<!-- Lecteur PDF OURS -->
<!-- id : PdfViewer1 -->
<!-- ********** -->

<ptplugin name="PdfViewer1" engine="kolorBox">
	<settings>
		<option name="position" value="topleft" type="string" />
		<option name="margin_x" value="0" type="int" />
		<option name="margin_y" value="0" type="int" />
		<option name="external_padding" value="10" type="int" />
		<option name="draggable_box" value="false" type="bool" />
		<option name="container_auto_size" value="true" type="bool" />
		<option name="container_width" value="100" type="int" />
		<option name="container_width_unit" value="percent" type="string" />
		<option name="container_height" value="100" type="int" />
		<option name="container_height_unit" value="percent" type="string" />
		<option name="container_color" value="ffffff" type="string" />
		<option name="container_alpha" value="1" type="float" />
		<option name="container_topleft_border_radius" value="0" type="int" />
		<option name="container_topright_border_radius" value="0" type="int" />
		<option name="container_bottomleft_border_radius" value="0" type="int" />
		<option name="container_bottomright_border_radius" value="0" type="int" />
		<option name="container_border_width" value="0" type="int" />
		<option name="container_border_color" value="ffffff" type="string" />
		<option name="container_border_alpha" value="1" type="float" />
		<option name="overlay_displayed" value="false" type="bool" />
		<option name="overlay_color" value="000000" type="string" />
		<option name="overlay_alpha" value="0.50000762951094835" type="float" />

		<option name="title_displayed" value="false" type="bool" />
		<option name="title_position" value="top" type="string" />
		<option name="title_font" value="Verdana" type="string" />
		<option name="title_size" value="14" type="int" />
		<option name="title_weight" value="normal" type="string" />
		<option name="title_style" value="normal" type="string" />
		<option name="title_decoration" value="none" type="string" />
		<option name="title_color" value="000000" type="string" />
		<option name="caption_displayed" value="false" type="bool" />
		<option name="fullscreen_displayed" value="false" type="bool" />
		<option name="fullscreen_position" value="topleft" type="string" />
		<option name="fullscreen_text" value="PdfViewer1fullscreen_text" type="string" />




		<option name="close_displayed" value="true" type="bool" />
		<option name="close_position" value="topright" type="string" />
		<option name="close_text" value="PdfViewer1close_text" type="string" />

		<option name="iframe_default_width" value="600" type="int" />
		<option name="iframe_default_height" value="840" type="int" />
		<option name="iframe_devices_width" value="1024" type="int" />
		<option name="iframe_devices_height" value="5000" type="int" />
		<option name="force_ios_scrolling" value="true" type="bool" />
		<option name="close_callback" value="invokeKrFunction('closeKolorBoxCallback_PdfViewer1')" type="string" />
		<option name="zorder" value="26" type="int" />
		<option name="use_i18n" value="true" type="bool" />
	</settings>
	<internaldata>
		
	</internaldata>
</ptplugin>

<action name="kolorBoxJsReady_PdfViewer1">
	set(ptplugin[PdfViewer1].jsready, true);
</action>

<action name="openPDF_PdfViewer1">
	ifnot(ptplugin[PdfViewer1].isOpen,
		if(ptplugin[PdfViewer1].doNotDeleteMe,
			set(ptplugin[PdfViewer1].currentCall, false);
		set(ptplugin[PdfViewer1].isOpen, true);
		set(ptplugin[PdfViewer1].doNotDeleteMe, false);
		set(PdfViewer1_boxurl, %1);
		pauseautorotation(forceplugin);

		js(invokePluginFunction(PdfViewer1, loadSingleArrayItem, %1?iframe=true, %2));
		,
			set(ptplugin[PdfViewer1].currentCall, true);
			set(ptplugin[PdfViewer1].doNotDeleteMe, true);
			events.dispatch(onremovedisplayedobject);
			delayedcall(0.3,openPDF_PdfViewer1(%1,%2););
		);
	,
		if('%1' != PdfViewer1_boxurl,
			closeKolorBox_PdfViewer1();
			delayedcall(0.3,openPDF_PdfViewer1(%1,%2););
		);
	);
</action>

<action name="togglePDF_PdfViewer1">
	js(invokePluginFunction(PdfViewer1, toggleKolorBox, %1));
</action>


<action name="closeKolorBox_PdfViewer1">
	if(ptplugin[PdfViewer1].doNotDeleteMe,
		set(ptplugin[PdfViewer1].doNotDeleteMe, false);
	,
	js(invokePluginFunction(PdfViewer1, closeKolorBox));
	);
</action>

<action name="closeKolorBoxCallback_PdfViewer1">
	resumeautorotation(forceplugin);

	set(ptplugin[PdfViewer1].doNotDeleteMe, false);
	set(ptplugin[PdfViewer1].isOpen, false);
</action>

<action name="changeLanguage_PdfViewer1">
	if(ptplugin[PdfViewer1].jsready,
		stopdelayedcall(delay_PdfViewer1);
		js(invokePluginFunction(PdfViewer1, changeLanguage));
	,
		delayedcall(delay_PdfViewer1, 0.1, changeLanguage_PdfViewer1(););
	);
</action>

<events name="kolorBoxEvents_PdfViewer1" 
	keep="true"
	onremovedisplayedobject="ifnot(ptplugin[PdfViewer1].currentCall,if(ptplugin[PdfViewer1].isOpen,closeKolorBox_PdfViewer1();););"
	changetourlanguage="changeLanguage_PdfViewer1();"
	/>

<action name="setViewNormal">
	stopSetViewTweens();
	if(current_view_isflat === true,
		setViewNonFlat(VFOV);
	);
	setViewNormalComplete();
</action>

<action name="setViewNormalComplete">
	set(view.fisheyefovlink, 0.5);
	set(view.fovmax, get(panoview.fovmax));
	tween(view.architectural, 0.0, distance(1.0, 0.45));
	tween(view.pannini, 0.0, distance(1.0, 0.45), easeOutQuad, if(panniniViewActivated,restoreViewFromPannini();););
	tween(view.vlookat, get(panoview.v), distance(90, 0.45));
	tween(view.fov, get(panoview.fov), distance(50, 0.45));
	tween(view.fisheye, 0.0, distance(1.0, 0.45),
		set(view.stereographic,false);
	);
</action>

<krpano normalViewActivated="true" />
<action name="stopSetViewTweens">
	stoptween(view.fov);
	stoptween(view.vlookat);
	stoptween(view.fisheye);
	stoptween(view.architectural);
	stoptween(view.pannini);
</action>

  <action name="displayImage">
    if (layer[displayedStandardImage],
      if(layer[displayedStandardImage].doNotDeleteMe,
        set(layer[displayedStandardImage].currentCall, false);
        set(layer[displayedStandardImage].doNotDeleteMe, false);
        
        if (%1 == layer[displayedStandardImage].url,
          applyDisplayedImageObjectAnimation(%8);
        ,
          setDisplayedImageObjectParameters(%1, %2, %3, %4, %5, %6, %7, %8, %9, %10);
        );
      ,
        set(layer[displayedStandardImage].currentCall, false);
        set(layer[displayedStandardImage].doNotDeleteMe, true);
        events.dispatch(onremovedisplayedobject);
        delayedcall(0.2,displayImage(%1, %2, %3, %4, %5, %6, %7, %8, %9, %10, %11, %12););
      );
    ,
      if(%10,
        addlayer(displayedStandardImageOverlay);
        set(layer[displayedStandardImageOverlay].keep, false);
        set(layer[displayedStandardImageOverlay].width, 100%);
        set(layer[displayedStandardImageOverlay].height, 100%);
        set(layer[displayedStandardImageOverlay].type, container);
        set(layer[displayedStandardImageOverlay].zorder, 98);
        set(layer[displayedStandardImageOverlay].visible, false);
        set(layer[displayedStandardImageOverlay].onclick, applyDisplayedImageObjectAnimation(%8););
        set(layer[displayedStandardImageOverlay].bgcolor, "0x%11");
        set(layer[displayedStandardImageOverlay].bgalpha, %12);
        set(layer[displayedStandardImageOverlay].bgcapture, true);
      );
      addlayer(displayedStandardImage);
      set(layer[displayedStandardImage].keep, false);
      set(layer[displayedStandardImage].onclick, applyDisplayedImageObjectAnimation(%8););
      set(layer[displayedStandardImage].zorder , 99);
      set(layer[displayedStandardImage].currentCall, true);
      set(layer[displayedStandardImage].doNotDeleteMe, true);
      set(layer[displayedStandardImage].onloaded, resizeDisplayedImageObject());
      events.dispatch(onremovedisplayedobject);
      delayedcall(0.2,displayImage(%1, %2, %3, %4, %5, %6, %7, %8, %9, %10, %11, %12););
      set(layer[displayedStandardImage].visible, false);
    );
  </action>
  <action name="applyDisplayedImageObjectAnimation">resumeautorotation(forcehotspot);

    if (%1,
      stoptween(layer[displayedStandardImage].width, layer[displayedStandardImage].height);
      tween(layer[displayedStandardImage].width|layer[displayedStandardImage].height, 1|1, 1, easeOutQuad, WAIT);
      if(layer[displayedStandardImage].overlay,removelayer(displayedStandardImageOverlay););removelayer(displayedStandardImage);
    ,
      if(layer[displayedStandardImage].overlay,removelayer(displayedStandardImageOverlay););removelayer(displayedStandardImage);
    );
  </action>
  <action name="setDisplayedImageObjectParameters">
    set(layer[displayedStandardImage].url       , %1);
    set(layer[displayedStandardImage].align     , %2);
    set(layer[displayedStandardImage].x         , %3);
    set(layer[displayedStandardImage].y         , %4);
    set(layer[displayedStandardImage].imgwidth  , %5);
    set(layer[displayedStandardImage].imgheight , %6);
    set(layer[displayedStandardImage].animated  , %8);
    set(layer[displayedStandardImage].applyratio, %9);
    set(layer[displayedStandardImage].overlay   , %10);
    if (%7,pauseautorotation(forcehotspot);
);
  </action>
  <action name="resizeDisplayedImageObject">
    if(layer[displayedStandardImage].url,
    set(layer[displayedStandardImage].fullwidth, get(layer[displayedStandardImage].width));
    set(layer[displayedStandardImage].fullheight, get(layer[displayedStandardImage].height));
    if(layer[displayedStandardImage].animated,
      set(layer[displayedStandardImage].width , 1);
      set(layer[displayedStandardImage].height, 1);
    );
    if(layer[displayedStandardImage].imgwidth != "" AND layer[displayedStandardImage].imgheight != "",
      if(layer[displayedStandardImage].imgwidth == "prop",
        set(tempDisplayedImageObjectHeight, get(layer[displayedStandardImage].imgheight));
        indexoftxt(tempDisplayedImageObjectHeightPercent, get(tempDisplayedImageObjectHeight), "%");
        if(tempDisplayedImageObjectHeightPercent GT 0,
          txtreplace(tempDisplayedImageObjectHeight, '%', '');
          mul(tempDisplayedImageObjectHeight, get(stageheight));
          div(tempDisplayedImageObjectHeight, 100);
          Math.round(tempDisplayedImageObjectHeight);
        );
        mul(flyingImgWidth,get(layer[displayedStandardImage].fullwidth),get(tempDisplayedImageObjectHeight));
        div(flyingImgWidth,get(layer[displayedStandardImage].fullheight));
        Math.round(flyingImgWidth);
        set(layer[displayedStandardImage].imgwidth , get(flyingImgWidth));
        set(layer[displayedStandardImage].imgheight, get(tempDisplayedImageObjectHeight));
      ,
        if(layer[displayedStandardImage].imgheight == "prop",
          set(tempDisplayedImageObjectWidth, get(layer[displayedStandardImage].imgwidth));
          indexoftxt(tempDisplayedImageObjectWidthPercent, get(tempDisplayedImageObjectWidth), "%");
          if(tempDisplayedImageObjectWidthPercent GT 0,
            txtreplace(tempDisplayedImageObjectWidth, '%', '');
            mul(tempDisplayedImageObjectWidth, get(stagewidth));
            div(tempDisplayedImageObjectWidth, 100);
            Math.round(tempDisplayedImageObjectWidth);
          );
          mul(flyingImgHeight,get(layer[displayedStandardImage].fullheight),get(tempDisplayedImageObjectWidth));
          div(flyingImgHeight,get(layer[displayedStandardImage].fullwidth));
          Math.round(flyingImgHeight);
          set(layer[displayedStandardImage].imgwidth , get(tempDisplayedImageObjectWidth));
          set(layer[displayedStandardImage].imgheight , get(flyingImgHeight));
        ,
          set(tempDisplayedImageObjectWidth, get(layer[displayedStandardImage].imgwidth));
          set(tempDisplayedImageObjectHeight, get(layer[displayedStandardImage].imgheight));
          indexoftxt(tempDisplayedImageObjectWidthPercent, get(tempDisplayedImageObjectWidth), "%");
          indexoftxt(tempDisplayedImageObjectHeightPercent, get(tempDisplayedImageObjectHeight), "%");
          if(tempDisplayedImageObjectWidthPercent GT 0,
            txtreplace(tempDisplayedImageObjectWidth, '%', '');
            mul(tempDisplayedImageObjectWidth, get(stagewidth));
            div(tempDisplayedImageObjectWidth, 100);
            Math.round(tempDisplayedImageObjectWidth);
          );
          if(tempDisplayedImageObjectHeightPercent GT 0,
            txtreplace(tempDisplayedImageObjectHeight, '%', '');
            mul(tempDisplayedImageObjectHeight, get(stageheight));
            div(tempDisplayedImageObjectHeight, 100);
            Math.round(tempDisplayedImageObjectHeight);
          );
          set(layer[displayedStandardImage].imgwidth , get(tempDisplayedImageObjectWidth));
          set(layer[displayedStandardImage].imgheight, get(tempDisplayedImageObjectHeight));
        );
      );
    ,
      set(layer[displayedStandardImage].imgwidth , get(layer[displayedStandardImage].fullwidth));
      set(layer[displayedStandardImage].imgheight, get(layer[displayedStandardImage].fullheight));
    );
    
    set(resizedwidth, get(layer[displayedStandardImage].imgwidth));
    set(resizedheight, get(layer[displayedStandardImage].imgheight));
    if(layer[displayedStandardImage].applyratio,
      sub(resizedstagewidth, get(stagewidth), get(layer[displayedStandardImage].x));
      sub(resizedstageheight, get(stageheight), get(layer[displayedStandardImage].y));
      Math.abs(resizedstagewidth);
      Math.abs(resizedstageheight);
      if(resizedwidth GT resizedstagewidth,
        mul(tempresizedheight, get(resizedheight), get(resizedstagewidth));
        div(tempresizedheight, get(resizedwidth));
        Math.round(tempresizedheight);
        set(resizedwidth, get(resizedstagewidth));
        set(resizedheight, get(tempresizedheight));
      );
      if(resizedheight GT resizedstageheight,
        mul(tempresizedwidth, get(resizedwidth), get(resizedstageheight));
        div(tempresizedwidth, get(resizedheight));
        Math.round(tempresizedwidth);
        set(resizedheight, get(resizedstageheight));
        set(resizedwidth, get(tempresizedwidth));
      );
    );
    
    if(layer[displayedStandardImage].animated,
      set(layer[displayedStandardImage].animated, false);
      tween(layer[displayedStandardImage].width , get(resizedwidth), 1, easeOutQuad);
      tween(layer[displayedStandardImage].height, get(resizedheight), 1, easeOutQuad);
    ,
      set(layer[displayedStandardImage].width , get(resizedwidth));
      set(layer[displayedStandardImage].height, get(resizedheight));
    );
    if(layer[displayedStandardImage].overlay,set(layer[displayedStandardImageOverlay].visible, true););
    set(layer[displayedStandardImage].visible, true);
    ,
      delayedcall(0.2,resizeDisplayedImageObject(););
    );
  </action>
  <events name="displayedImageObjectEvents" keep="true" onremovedisplayedobject="displayedImageObjectOnRemoveDisplayedObject" onresize="if(layer[displayedStandardImage],resizeDisplayedImageObject());" />
  <action name="displayedImageObjectOnRemoveDisplayedObject">
    ifnot(layer[displayedStandardImage].currentCall,if(layer[displayedStandardImage].visible,resumeautorotation(forcehotspot);

      if(layer[displayedStandardImage].overlay,removelayer(displayedStandardImageOverlay););
      removelayer(displayedStandardImage);
    ););
  </action>


  <action name="enableGyroscope">
    changeGyroscopeState(true);
  </action>
  <action name="disableGyroscope">
    changeGyroscopeState(false);
  </action>


  <action name="displayVideo">
    set(displayedVideoObjectToCreate, true);
    set(displayedVideoObjectForDesktop, true);
    if(%10,
      set(displayedVideoObjectForDesktop, false);
    ,
      if (device.tablet, set(displayedVideoObjectForDesktop, false););
      if (device.mobile, set(displayedVideoObjectForDesktop, false););
    );
    
    if (layer[displayedStandardVideo],
      if(layer[displayedStandardVideo].donotdeleteme,
        set(layer[displayedStandardVideo].fromdesktop, get(displayedVideoObjectForDesktop));
        set(layer[displayedStandardVideo].currentCall, false);
        set(layer[displayedStandardVideo].visible, true);
        if(layer[displayedStandardVideo].overlay,set(layer[displayedStandardVideoOverlayBkg].visible, true););
        set(layer[displayedStandardVideo].donotdeleteme, false);
        set(layer[displayedStandardVideo].pausebgsound, %11);
        ifnot(layer[displayedStandardVideo].pausedonstart,
          if(layer[displayedStandardVideo].pausebgsound,
            pauseTourSoundsActions(true,true,false,true,true);
          );
        );
        if (%1 == layer[displayedStandardVideo].videourl,
          layer[displayedStandardVideo].stop();
          ifnot(layer[displayedStandardVideo].fromdesktop,
            removelayer(displayedStandardVideoOverlayButton);
            removelayer(displayedStandardVideoOverlay);
          );resumeautorotation(forcehotspot);

          delete(tour_current_played_video);
          set(tour_current_played_video_state, 0);
          if(layer[displayedStandardVideo].pausebgsound,
            resumeTourSoundsActions(true,true,true,true,true);
          );
          if(layer[displayedStandardVideo].overlay,removelayer(displayedStandardVideoOverlayBkg););
          removelayer(displayedStandardVideo);
        ,
          
          set(tour_current_played_video, %1);
          if(tour_current_played_sound,
            set(tour_current_played_video_state, 2);
          ,
            set(tour_current_played_video_state, 1);
          );
          set(layer[displayedStandardVideo].onloaded, displayVideoWhenLoaded(%1,%10););
          set(layer[displayedStandardVideo].autoresume, true);
          if(device.html5,
            set(layer[displayedStandardVideo].url, %FIRSTXML%/graphics/videoplayer.js);
          ,
          );
        );
      ,
        events.dispatch(onremovedisplayedobject);
        if (%1 != layer[displayedStandardVideo].videourl,
          delayedcall(0.2,displayVideo(%1, %2, %3, %4, %5, %6, %7, %8, %9, %10, %11, %12, %13, %14););
        );
      );
    ,
      if(%12,
        addlayer(displayedStandardVideoOverlayBkg);
        set(layer[displayedStandardVideoOverlayBkg].keep, false);
        set(layer[displayedStandardVideoOverlayBkg].visible , false);
        set(layer[displayedStandardVideoOverlayBkg].onclick, displayedVideoObjectStartStopAction(););
        set(layer[displayedStandardVideoOverlayBkg].zorder , 97);
        set(layer[displayedStandardVideoOverlayBkg].type, container);
        set(layer[displayedStandardVideoOverlayBkg].width   , 100%);
        set(layer[displayedStandardVideoOverlayBkg].height  , 100%);
        set(layer[displayedStandardVideoOverlayBkg].bgcolor, "0x%13");
        set(layer[displayedStandardVideoOverlayBkg].bgalpha, %14);
        set(layer[displayedStandardVideoOverlayBkg].bgcapture, true);
      );
      addlayer(displayedStandardVideo);
      set(layer[displayedStandardVideo].keep, false);
      set(layer[displayedStandardVideo].visible , false);
      set(layer[displayedStandardVideo].onclick, displayedVideoObjectStartStopAction(););
      set(layer[displayedStandardVideo].zorder , 98);
      set(layer[displayedStandardVideo].align   , %2);
      set(layer[displayedStandardVideo].x       , %3);
      set(layer[displayedStandardVideo].y       , %4);
      set(layer[displayedStandardVideo].width   , %5);
      set(layer[displayedStandardVideo].height  , %6);
      set(layer[displayedStandardVideo].overlay , %12);
      set(layer[displayedStandardVideo].iphoneworkarounds, false);
      
      if (%7,
        set(layer[displayedStandardVideo].loop, true);
       ,
        set(layer[displayedStandardVideo].onvideocomplete, displayedVideoObjectStartStopAction(););
      );
      if (displayedVideoObjectForDesktop,
        set(layer[displayedStandardVideo].pausedonstart, false);
        set(layer[displayedStandardVideo].onvideoready, set(layer[displayedStandardVideo].visible, true);if(layer[displayedStandardVideo].overlay,set(layer[displayedStandardVideoOverlayBkg].visible, true);););
      ,
        
        set(layer[displayedStandardVideo].pausedonstart, true);
        set(layer[displayedStandardVideo].onvideoready, set(layer[displayedStandardVideo].started, false);set(layer[displayedStandardVideo].visible, true);if(layer[displayedStandardVideo].overlay,set(layer[displayedStandardVideoOverlayBkg].visible, true););delayedcall(0.1,applyDisplayedStandardVideoOverlay(%1, %2, %3, %4, %5, %6, %7, %8, %9, %10, %11)););
      );
      
      set(layer[displayedStandardVideo].currentCall, true);
      set(layer[displayedStandardVideo].donotdeleteme, true);
      events.dispatch(onremovedisplayedobject);
      delayedcall(0.2,displayVideo(%1, %2, %3, %4, %5, %6, %7, %8, %9, %10, %11, %12, %13, %14););
      if (%8,pauseautorotation(forcehotspot);
);
    );
  </action>
  <action name="applyDisplayedStandardVideoOverlay">
      addlayer(displayedStandardVideoOverlay);
      
      set(layer[displayedStandardVideoOverlay].type, container);
      set(layer[displayedStandardVideoOverlay].visible, true);
      set(layer[displayedStandardVideoOverlay].zorder, 99);
      set(layer[displayedStandardVideoOverlay].keep, false);
      set(layer[displayedStandardVideoOverlay].align, %2);
      set(layer[displayedStandardVideoOverlay].x, %3);
      set(layer[displayedStandardVideoOverlay].y, %4);
      set(layer[displayedStandardVideoOverlay].width, get(layer[displayedStandardVideo].pixelwidth));
      set(layer[displayedStandardVideoOverlay].height, get(layer[displayedStandardVideo].pixelheight));
      
      addlayer(displayedStandardVideoOverlayButton);
      set(layer[displayedStandardVideoOverlayButton].visible, true);
      set(layer[displayedStandardVideoOverlayButton].keep, false);
      set(layer[displayedStandardVideoOverlayButton].parent, displayedStandardVideoOverlay);
      set(layer[displayedStandardVideoOverlayButton].align, center);
      set(layer[displayedStandardVideoOverlayButton].url, %FIRSTXML%/graphics/videoplayer_play_button.png);
      set(layer[displayedStandardVideoOverlayButton].width, 50);
      set(layer[displayedStandardVideoOverlayButton].height, 50);
      set(layer[displayedStandardVideoOverlayButton].alpha, 0.5);
      set(layer[displayedStandardVideoOverlayButton].enabled, false);
      set(layer[displayedStandardVideoOverlayButton].capture, false);
      set(layer[displayedStandardVideoOverlayButton].onclick, displayedVideoObjectStartStopAction(););
  </action>
  <action name="displayVideoWhenLoaded">
    layer[displayedStandardVideo].playVideo(%1,,%2);
    ifnot(tour_soundson,
      pauseVideoActionsSounds();
    );
  </action>
  <action name="displayedVideoObjectStartStopAction">
    if(layer[displayedStandardVideo].fromdesktop,
      layer[displayedStandardVideo].stop();
      set(layer[displayedStandardVideo].visible, false);
      if(layer[displayedStandardVideo].overlay,set(layer[displayedStandardVideoOverlayBkg].visible, false););resumeautorotation(forcehotspot);

      delete(tour_current_played_video);
      set(tour_current_played_video, null);
      set(tour_current_played_video_state, 0);
      if(layer[displayedStandardVideo].pausebgsound,
        resumeTourSoundsActions(true,true,true,true,true);
      );
      if(layer[displayedStandardVideo].overlay,removelayer(displayedStandardVideoOverlayBkg););
      removelayer(displayedStandardVideo);
    ,
      if (layer[displayedStandardVideo].started == false,
        set(layer[displayedStandardVideo].visible , true);
        if(layer[displayedStandardVideo].overlay,set(layer[displayedStandardVideoOverlayBkg].visible, true););
        set(layer[displayedStandardVideoOverlay].visible , false);
        removelayer(displayedStandardVideoOverlayButton);
        removelayer(displayedStandardVideoOverlay);
        set(layer[displayedStandardVideo].started, true);
        if(layer[displayedStandardVideo].pausedonstart,
          if(layer[displayedStandardVideo].pausebgsound,
            pauseTourSoundsActions(true,true,false,true,true);
          );
        );
        layer[displayedStandardVideo].play();
        ifnot(tour_soundson,
          pauseVideoActionsSounds();
        );
      ,
        layer[displayedStandardVideo].stop();
        set(layer[displayedStandardVideo].visible , false);
        if(layer[displayedStandardVideo].overlay,set(layer[displayedStandardVideoOverlayBkg].visible, false););resumeautorotation(forcehotspot);

        delete(tour_current_played_video);
        set(tour_current_played_video, null);
        set(tour_current_played_video_state, 0);
        if(layer[displayedStandardVideo].pausebgsound,
          resumeTourSoundsActions(true,true,true,true,true);
        );
        if(layer[displayedStandardVideo].overlay,removelayer(displayedStandardVideoOverlayBkg););
        removelayer(displayedStandardVideo);
      );
    );
  </action>
  <events name="displayedVideoObjectEvents" keep="true" onremovedisplayedobject="displayedVideoObjectOnRemoveDisplayedObject"/>
  <action name="displayedVideoObjectOnRemoveDisplayedObject">
    ifnot(layer[displayedStandardVideo].currentCall,
      if(layer[displayedStandardVideo].visible,
        layer[displayedStandardVideo].stop();
        ifnot(layer[displayedStandardVideo].fromdesktop,
          removelayer(displayedStandardVideoOverlayButton);
          removelayer(displayedStandardVideoOverlay);
        );
        set(layer[displayedStandardVideo].visible , false);
        if(layer[displayedStandardVideo].overlay,set(layer[displayedStandardVideoOverlayBkg].visible, false););resumeautorotation(forcehotspot);

        delete(tour_current_played_video);
        set(tour_current_played_video, null);
        set(tour_current_played_video_state, 0);
        if(layer[displayedStandardVideo].pausebgsound,
          resumeTourSoundsActions(true,true,true,true,true);
        );
        if(layer[displayedStandardVideo].overlay,removelayer(displayedStandardVideoOverlayBkg););
        removelayer(displayedStandardVideo);
      );
    );
  </action>

  <!-- Share Tour -->
  <action name="shareTour">events.dispatch(onsharetour);</action>

<action name="viewControlMoveUp">
	if(%1,
		if(%2,
			set(isfullvertical, false);
			ifnot(scene[get(xml.scene)].planar,
				sub(viewvfov, panoview.vmax, panoview.vmin);
				if (viewvfov == 180,
					set(isfullvertical, true);
				);
			);
			if(isfullvertical == false AND calc(view.vlookat-%2) LT view.vlookatmin,
				moveto(get(view.hlookat), get(view.vlookatmin));
			,
				moveto(get(view.hlookat), calc(view.vlookat-%2));
			);
		,
			set(vlookat_moveforce, -1);
			delayedcall(0.1, viewControlMoveVertStop());
		);
	,
		set(vlookat_moveforce, -1);
	);
</action>
<action name="viewControlMoveDown">
	if(%1,
		if(%2,
			set(isfullvertical, false);
			ifnot(scene[get(xml.scene)].planar,
				sub(viewvfov, panoview.vmax, panoview.vmin);
				if (viewvfov == 180,
					set(isfullvertical, true);
				);
			);
			if(sceneisfull360 == false AND calc(view.vlookat+%2) GT view.vlookatmax,
				moveto(get(view.hlookat), get(view.vlookatmax));
			,
				moveto(get(view.hlookat), calc(view.vlookat+%2));
			);
		,
			set(vlookat_moveforce, +1);
			delayedcall(0.1, viewControlMoveVertStop());
		);
	,
		set(vlookat_moveforce, +1);
	);
</action>
<action name="viewControlMoveLeft">
	if(%1,
		if(%2,
			set(isfullhorizontal, false);
			ifnot(scene[get(xml.scene)].planar,
				sub(viewhfov, panoview.hmax, panoview.hmin);
				if (viewhfov == 360,
					set(isfullhorizontal, true);
				);
			);
			if(isfullhorizontal == false AND calc(view.hlookat-%2) LT view.hlookatmin,
				moveto(get(view.hlookatmin), get(view.vlookat));
			,
				moveto(calc(view.hlookat-%2), get(view.vlookat));
			);
		,
			set(hlookat_moveforce, -1);
			delayedcall(0.1, viewControlMoveHoriStop());
		);
	,
		set(hlookat_moveforce, -1);
	);
</action>
<action name="viewControlMoveRight">
	if(%1,
		if(%2,
			set(isfullhorizontal, false);
			ifnot(scene[get(xml.scene)].planar,
				sub(viewhfov, panoview.hmax, panoview.hmin);
				if (viewhfov == 360,
					set(isfullhorizontal, true);
				);
			);
			if(isfullhorizontal == false AND calc(view.hlookat+%2) GT view.hlookatmax,
				moveto(get(view.hlookatmax), get(view.vlookat));
			,
				moveto(calc(view.hlookat+%2), get(view.vlookat));
			);
		,
			set(hlookat_moveforce, +1);
			delayedcall(0.1, viewControlMoveHoriStop());
			
		);
	,
		set(hlookat_moveforce, +1);
	);
</action>
<action name="viewControlMoveHoriStop">
	set(hlookat_moveforce, 0);
</action>
<action name="viewControlMoveVertStop">
	set(vlookat_moveforce, 0);
</action>

  <!-- Hide / Show Controls -->
  <action name="hideTourControls">set(tour_displaycontrols, false);events.dispatch(hidetourcontrols);</action>
  <action name="showTourControls">set(tour_displaycontrols, true); events.dispatch(showtourcontrols);</action>


  <!-- Tour Information -->
  <action name="hideTourInfo">set(tour_displayinfo, false);events.dispatch(onhidetourinfo);</action>
  <action name="showTourInfo">set(tour_displayinfo, true); events.dispatch(onshowtourinfo);</action>


  <!-- Fullscreen Management -->
  <action name="exitFullScreen" devices="fullscreensupport">set(tour_fullscreen,false);js(setFullscreen(false));</action>
  <action name="enterFullScreen" devices="fullscreensupport">set(tour_fullscreen,true);js(setFullscreen(true));</action>
  <action name="switchFullScreen">if(tour_fullscreen,exitFullScreen();,enterFullScreen(););</action>

  
  <events name="krpanoExitFullscreenEvent"
    onexitfullscreen="if(tour_fullscreen,exitFullScreenChangeEvent(););"
    keep="true" />

  <action name="exitFullScreenChangeEvent" devices="fullscreensupport">set(tour_fullscreen,false);events.dispatch(onexitfullscreen);</action>
  <action name="enterFullScreenChangeEvent" devices="fullscreensupport">set(tour_fullscreen,true);events.dispatch(onenterfullscreen);</action>
  <action name="exitFullScreenFallback">set(fullscreen,false);</action>
  <action name="enterFullScreenFallback">set(fullscreen,true);</action>
  
  <action name="resizeFullScreenEvent">delayedcall(0,updatescreen(););</action>

  <!-- Sounds Management -->
  <plugin name="soundinterface"
          preload="true"
          url="%FIRSTXML%/graphics/soundinterface.js"
          rootpath="%$videos_sounds_path%/sounds"
          backgroundsound=""
          backgroundsoundloops="0"
          bgsound="false"
          bgsoundpaused="false"
          bgsoundloopended="false"
          volumeinitialized="false"
          started="true"
          keep="true"/>
  <events name="soundmanagementevents"
          onnewpano="if(plugin[soundinterface].started,playbackgroundsound(););"
          onxmlcomplete="soundinterfaceonxmlcomplete();"
          keep="true"/>
  <action name="soundinterfaceonxmlcomplete">
    ifnot(plugin[soundinterface].volumeinitialized,
      div(plugin[soundinterface].volume, tour_soundsvolume, 100);
      set(plugin[soundinterface].volumeinitialized,true);
    );
  </action>
  <action name="playsound3Dwhenpossible">
    set(really_play_sound, true);
    if (tour_current_played_sound,
      if (%1 == tour_current_played_sound,
        delete(tour_current_played_sound);
        set(tour_current_played_sound_state, 0);
        delete(tour_current_played_sound_paused);
        stopsound(%1);
        set(really_play_sound, false);
        if(%4,
          delete(tour_current_played_sound_pausesound);
          resumeTourSoundsActions(true,true,true,true,true);
        );
      );
    );
    if (really_play_sound,
      if (tour_current_played_sound,
        stopsound(get(tour_current_played_sound));

        ifnot(%4,
          if(tour_current_played_sound_pausesound,
            delete(tour_current_played_sound_pausesound);
            resumeTourSoundsActions(true,true,true,true,true);
          );
        );
      );
      if(%4,
        set(tour_current_played_sound_pausesound, true);
        pauseTourSoundsActions(true,false,true,true,true);
      );
      set(tour_current_played_sound, %1);
      if(tour_current_played_video,
        set(tour_current_played_sound_state, 2);
      ,
        set(tour_current_played_sound_state, 1);
      );
      set(tour_current_played_sound_paused, false);
      if (%3,
        if (device.flash,
          div(volume, tour_soundsvolume, 100);
          if(%9 != null,
            playsound3D(%1,%2,%5,%6,%7,get(volume),%8,stopsound3Dwhenpossible(%1,%4));
          ,
            playsound3D(%1,%2,%5,%6,%7,get(volume),%8);
          );
        ,
          if(%9 != null,
            playsound(%1,%2,%8,stopsound3Dwhenpossible(%1,%4));
          ,
            playsound(%1,%2,%8);
          );
        );
      ,
        if(%6 != null,
          playsound(%1,%2,%5,stopsound3Dwhenpossible(%1,%4));
        ,
          playsound(%1,%2,%5);
        );
      );

      ifnot(tour_soundson,
        set(tour_current_played_sound_paused, true);
        pausesound(%1);
      );
    );
  </action>
  <action name="stopsound3Dwhenpossible">
    if (%1 == tour_current_played_sound,
      delete(tour_current_played_sound);
      set(tour_current_played_sound_state, 0);
      delete(tour_current_played_sound_paused);

      ifnot(device.safari,
        stopsound(%1);
      );
      if(%2,
        delete(tour_current_played_sound_pausesound);
        resumeTourSoundsActions(true,true,true,true,true);
      );
    );
  </action>
  <action name="playbackgroundsound">
  if(playsound,
    if (xml.scene,
      if (scene[get(xml.scene)].backgroundsound,
        if (plugin[soundinterface].backgroundsound != scene[get(xml.scene)].backgroundsound,
          copy(plugin[soundinterface].backgroundsound, scene[get(xml.scene)].backgroundsound);
          copy(plugin[soundinterface].backgroundsoundloops, scene[get(xml.scene)].backgroundsoundloops);
          if (tour_soundson,
            set(plugin[soundinterface].bgsound, true);
            set(plugin[soundinterface].bgsoundpaused, false);
            set(plugin[soundinterface].bgsoundloopended, false);
            if((scene[get(xml.scene)].video == true AND scene[get(xml.scene)].scenevideomute == true) OR scene[get(xml.scene)].video == false,
              if(plugin[soundinterface].backgroundsoundloops GT 0,
                playsound(bgsoundname, get(plugin[soundinterface].backgroundsound), get(plugin[soundinterface].backgroundsoundloops), stopbackgroundsoundoncomplete());
              ,
                playsound(bgsoundname, get(plugin[soundinterface].backgroundsound), get(plugin[soundinterface].backgroundsoundloops));
              );
            );
           ,
            set(plugin[soundinterface].bgsound, false);
          );
        ,
          if (tour_soundson,
            if((plugin[soundinterface].bgsoundpaused == true AND scene[get(xml.scene)].video == false) OR (scene[get(xml.scene)].video == true AND scene[get(xml.scene)].scenevideomute == true),
              resumesound(bgsoundname);
              set(plugin[soundinterface].bgsoundpaused, false);
            );
          ,
            set(plugin[soundinterface].bgsound, false);
          );
        );
      );
    );
  ,
    delayedcall(0.2, playbackgroundsound());
  );
  </action>
  <action name="stopbackgroundsoundoncomplete">
    if (plugin[soundinterface].backgroundsound,
    if (plugin[soundinterface].backgroundsoundloops GT 0,

      set(plugin[soundinterface].backgroundsoundloops, 0);
      set(plugin[soundinterface].bgsound, false);
      set(plugin[soundinterface].bgsoundpaused, false);
      set(plugin[soundinterface].bgsoundloopended, true);
    );
    );
  </action>
  <action name="resetbackgroundsoundifneeded">
    if (xml.scene,
      if (scene[get(xml.scene)].backgroundsound != scene[%1].backgroundsound,
        if(plugin[soundinterface].backgroundsound,
          stopsound(bgsoundname);
        );
        set(plugin[soundinterface].backgroundsound, "");
        set(plugin[soundinterface].backgroundsoundloops, 0);
        set(plugin[soundinterface].bgsound, false);
        set(plugin[soundinterface].bgsoundpaused, false);
        set(plugin[soundinterface].bgsoundloopended, false);
      );
    );
  </action>
  <action name="pausebackgroundsound">
    if(plugin[soundinterface].backgroundsound,
      if (plugin[soundinterface].bgsound,
        if(plugin[soundinterface].bgsoundpaused == false AND plugin[soundinterface].bgsoundloopended == false,
          pausesound(bgsoundname);
          set(plugin[soundinterface].bgsoundpaused, true);
        );
      );
    );
    
  </action>
  <action name="resumebackgroundsound">
    set(bgSoundOnResume, true);
    set(forceBgSoundOnResume, true);
    if(layer[displayedStandardVideo],
    if(layer[displayedStandardVideo].pausebgsound AND tour_current_played_video,
      set(bgSoundOnResume, false);
      set(forceBgSoundOnResume, false);
    ););
    if(layer[webvideodisplay_player],
    if(layer[webvideodisplay_player].pausebgsound AND tour_current_played_web_video,
      set(bgSoundOnResume, false);
      set(forceBgSoundOnResume, false);
    ););
    if(tour_current_played_sound_pausesound AND tour_current_played_sound,
      set(bgSoundOnResume, false);
    );
    ifnot(plugin[soundinterface].backgroundsound AND scene[get(xml.scene)].backgroundsound,
      set(bgSoundOnResume, false);
    );
    if(videospots_playing GT 0,
      set(bgSoundOnResume, false);
      set(forceBgSoundOnResume, false);
    );
    if(bgSoundOnResume,
      if (plugin[soundinterface].backgroundsound,
        if (tour_soundson,
          if (plugin[soundinterface].bgsound AND plugin[soundinterface].bgsoundloopended == false,
            if((plugin[soundinterface].bgsoundpaused == true AND scene[get(xml.scene)].video == false) OR (scene[get(xml.scene)].video == true AND scene[get(xml.scene)].scenevideomute == true),
              resumesound(bgsoundname);
              set(plugin[soundinterface].bgsoundpaused, false);
            ,

              if(device.mobile OR device.tablet OR device.safari,
                resumesound(bgsoundname);
                set(plugin[soundinterface].bgsoundpaused, false);
              );
            );
          ,
            set(plugin[soundinterface].bgsound, true);
            set(plugin[soundinterface].bgsoundpaused, false);
            set(plugin[soundinterface].bgsoundloopended, false);
            if(plugin[soundinterface].backgroundsoundloops GT 0,
              playsound(bgsoundname, get(plugin[soundinterface].backgroundsound), get(plugin[soundinterface].backgroundsoundloops), stopbackgroundsoundoncomplete());
            ,
              playsound(bgsoundname, get(plugin[soundinterface].backgroundsound), get(plugin[soundinterface].backgroundsoundloops));
            );
          );
        );
      );
      
    ,
      if(forceBgSoundOnResume,
        playbackgroundsound();
        
      );
    );
  </action>
  <action name="preloadSounds">
    preloadsound("sommet_de_la-tour.mp3");
    preloadsound("poudriere_01.mp3");
    preloadsound("tour_a_canon_01.mp3");
    preloadsound("l_escalier.mp3");
    preloadsound("tunnel_01.mp3");
    preloadsound("salle_01_maquette_centrale.mp3");
    preloadsound("salle_01_posidonie_01.mp3");
    preloadsound("cycle_de_l_eau_01_01.mp3");
    preloadsound("salle_02_crane.mp3");
    preloadsound("vergers_01.mp3");
    preloadsound("_20180413-154030_01.mp3");
    preloadsound("salle_03_les_amphores_01.mp3");
    preloadsound("salle_4_plan_fortifications.mp3");
    preloadsound("salle_5_logo_des_pn.mp3");
    preloadsound("intro_salle_01_01.mp3");
    preloadsound("intro_salle_02_01.mp3");
    preloadsound("salle-3-intro_01.mp3");
    preloadsound("salle_4_intro.mp3");
    preloadsound("salle_5_intro.mp3");
  </action>

  <action name="play3DLocalSounds">
    if (xml.scene, if (scene[get(xml.scene)].haslocalsounds, playpanolocalsounds();););
  </action>
  <action name="stop3DLocalSounds">
    if (xml.scene, if (scene[get(xml.scene)].haslocalsounds, stoppanolocalsounds();););
  </action>
  <action name="resume3DLocalSounds">
    if (xml.scene, if (scene[get(xml.scene)].haslocalsounds, 
      set(kill3dSoundOnResume, true);
      if(layer[displayedStandardVideo],
      if(layer[displayedStandardVideo].pausebgsound,
      if(tour_current_played_video,
        set(kill3dSoundOnResume, false);
      );););
      if(layer[webvideodisplay_player],
      if(layer[webvideodisplay_player].pausebgsound,
      if(tour_current_played_web_video,
        set(kill3dSoundOnResume, false);
      );););
      if(tour_current_played_sound_pausesound,
      if(tour_current_played_sound,
        set(kill3dSoundOnResume, false);
      ););
      if(kill3dSoundOnResume,
        resumepanolocalsounds();
      );
    ););
  </action>
  <action name="pause3DLocalSounds">
    if (xml.scene, if (scene[get(xml.scene)].haslocalsounds, pausepanolocalsounds();););
  </action>
  <action name="set3DLocalSoundsVolume">
    if (xml.scene, if (scene[get(xml.scene)].haslocalsounds, setpanolocalsoundsvolume();););
  </action>
  <action name="playTourSounds">
    set(tour_soundson, true);events.dispatch(playtoursoundsevent);
    resumeTourSoundsActions(true,true,true,true,true);
  </action>
  <action name="stopTourSounds">
    set(tour_soundson, false);events.dispatch(stoptoursoundsevent);
    pauseTourSoundsActions(true,true,true,true,true);
  </action>
  <action name="setTourSoundsVolume">
    set(tour_soundsvolume, %1);events.dispatch(changetoursoundsevent);
    div(volume, tour_soundsvolume, 100);
    set(plugin[soundinterface].volume, get(volume));
    set3DLocalSoundsVolume();
  </action>
  <action name="playTourSoundsActions">
    if(%1,
      if(plugin[soundinterface],
        if(plugin[soundinterface].started,
        play3DLocalSounds();
        );
      );
    );
    if(%2,
      if(plugin[soundinterface],
        if(plugin[soundinterface].started,
          resumebackgroundsound();
        );
      );
    );
  </action>
  <action name="stopTourSoundsActions">
    if(%1,
      stop3DLocalSounds();
    );
    if(%2,
      stopSoundActionsSounds();
    );
    if(%3,
      stopVideoActionsSounds();
    );
    if(%4,
      pausebackgroundsound();
    );
  </action>
  <action name="resumeTourSoundsActions">
    if(%1,
      if(plugin[soundinterface],
        if(plugin[soundinterface].started,
        resume3DLocalSounds();
        );
      );
    );
    if(%2,
      resumeSoundActionsSounds();
    );
    if(%3,
      resumeVideoActionsSounds();
    );
    if(%4,
      if(%5,
        if(plugin[soundinterface],
          if(plugin[soundinterface].started,
            resumebackgroundsound();
          );
        );
      ,
        pausebackgroundsound();
      );
    );
  </action>
  <action name="pauseTourSoundsActions">
    if(%1,
      pause3DLocalSounds();
    );
    if(%2,
      pauseSoundActionsSounds();
    );
    if(%3,
      pauseVideoActionsSounds();
    );
    if(%4,
      if(%5,
        pausebackgroundsound();
      ,
        if(plugin[soundinterface],
          if(plugin[soundinterface].started,
            resumebackgroundsound();
          );
        );
      );
    );
  </action>
  <action name="stopSoundActionsSounds">
    if (tour_current_played_sound,
      delete(tour_current_played_sound_paused);
      stopsound(get(tour_current_played_sound));
      delete(tour_current_played_sound);
      set(tour_current_played_sound_state, 0);
    );
  </action>
  <action name="stopVideoActionsSounds">
    if(tour_current_played_video,
      if(layer[displayedStandardVideo],
        layer[displayedStandardVideo].stop();
        removelayer(displayedStandardVideo);
        if(layer[displayedStandardVideoOverlayButton], removelayer(displayedStandardVideoOverlayButton); );
        if(layer[displayedStandardVideoOverlay], removelayer(displayedStandardVideoOverlay); );
        delete(tour_current_played_video);
        set(tour_current_played_video_state, 0);
      );
    );
    if(tour_current_played_web_video,
      displayWebVideoObjectClose();
    );
  </action>
  <action name="resumeSoundActionsSounds">
    if (tour_current_played_sound,
      set(resumeSoundActionsVerification, true);
      if(tour_current_played_video,
        if(tour_current_played_sound_state LT tour_current_played_video_state,
          set(resumeSoundActionsVerification, false);
        );
      );
      if(resumeSoundActionsVerification,
        if (tour_soundson,
          if(tour_current_played_sound_paused,
            set(tour_current_played_sound_paused, false);
            resumesound(get(tour_current_played_sound));
          ,

            if(device.mobile OR device.tablet OR device.safari,
              set(tour_current_played_sound_paused, false);
              resumesound(get(tour_current_played_sound));
            );
          );
        );
      );
    );
  </action>
  <action name="resumeVideoActionsSounds">
    if(tour_current_played_video,
      set(resumeVideoActionsVerification, true);
      if(tour_current_played_sound,
        if(tour_current_played_video_state LT tour_current_played_sound_state,
          set(resumeVideoActionsVerification, false);
        );
      );
      if(resumeVideoActionsVerification,
        if (tour_soundson,
          if(device.flash OR (device.webgl AND !device.ios),
            div(volume, tour_soundsvolume, 100);
            set(layer[displayedStandardVideo].volume, get(volume));
          ,
            ifnot(device.ios,
              js(kpanotour.Sounds.startVideosSounds(get(volume)));
            ,
              if(tour_soundsvolume GT 0,
                set(layer[displayedStandardVideo].muted, false);
              ,
                set(layer[displayedStandardVideo].muted, true);
              );
            );
          );
        ,
          if(device.flash OR (device.webgl AND !device.ios),
            set(layer[displayedStandardVideo].volume, 0);
          ,
            ifnot(device.ios,
              js(kpanotour.Sounds.stopVideosSounds());
            ,
              set(layer[displayedStandardVideo].muted, true);
            );
          );
        );
      );
    );
  </action>
  <action name="pauseSoundActionsSounds">
    if (tour_current_played_sound,
      ifnot(tour_current_played_sound_paused,
        set(tour_current_played_sound_paused, true);
        pausesound(get(tour_current_played_sound));
      );
    );
  </action>
  <action name="pauseVideoActionsSounds">
    if(tour_current_played_video,
      if(device.flash OR (device.webgl AND !device.ios),
        set(layer[displayedStandardVideo].volume, 0);
      ,
        ifnot(device.ios,
          js(kpanotour.Sounds.stopVideosSounds());
        ,
          set(layer[displayedStandardVideo].muted, true);
        );
      );
    );
  </action>

<action name="viewControlZoomIn">
	if(%1,
		if(%2,
			if(%2 LT view.fovmin,
				zoomto(get(view.fovmin));
			,
				if(%2 LT view.fov,
					zoomto(%2);
				);
			);
		,
			set(fov_moveforce, -1);
			delayedcall(0.1, viewControlZoomStop());
		);
	,
		set(fov_moveforce, -1);
	);
</action>
<action name="viewControlZoomOut">
	if(%1,
		if(%2,
			if(%2 GT view.fovmax,
				zoomto(get(view.fovmax));
			,
				if(%2 GT view.fov,
					zoomto(%2);
				);
			);
		,
			set(fov_moveforce, +1);
			delayedcall(0.1, viewControlZoomStop());
		);
	,
		set(fov_moveforce, +1);
	);
</action>
<action name="viewControlZoomStop">
	set(fov_moveforce, 0);
</action>

</krpano>

Anon7 - 2022
AnonSec Team