//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
/**
 * @package Starweb Webshop System
 * @version See version-file
 * @copyright Copyright (c) 2000 - 2010, Ehandelslogik AB
 * 
 * @author Ehandelslogik AB, org.no 556696-9019  (Starweb)
 *  Country: Sweden
 *  Homepage: www.starweb.se
 *  E-mail: support@starweb.se
 * 
 * License:
 * This program is not "free" software and restrictions apply!
 * This file as well as all other files containing the code to our software may ONLY be used and/or redistributed with written permission from us.
 * You'll find information regarding our conditions and pricing on our homepage. Contact us immediately if any of these conditions are not clear.
 */
//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
// 27f567f5261ae43c5a8a22abd85adf2a
/**
 * @name Function: Set Highslide Settings
 * @access public
 *
 * @param object hs
 * @param string sGraphicsDir
 * @param string sLangBtnCancel
 * @param string sLangBtnExpand
 * @param string sLangBtnPrevImgLeftKey
 * @param string sLangBtnNextImgRightKey
 * @param string sLangBtnClickDragToMove
 * @param string sLangBtnClose
 * @param string sLangBtnResize
 * @param string sLangBtnPlay
 * @param string sLangBtnPlayTitle
 * @param string sLangBtnPause
 * @param string sLangBtnPauseTitle
 * @param string sLangImgNr
 * @param boolean bIsAdmin
 */
function SetHighslideSett(hs, sGraphicsDir,
   sLangBtnCancel, sLangBtnExpand, sLangBtnPrevImg, sLangBtnNextImg, sLangBtnPrevImgLeftKey, sLangBtnNextImgRightKey, sLangBtnClickDragToMove,
   sLangBtnClose, sLangBtnResize, sLangBtnPlay, sLangBtnPlayTitle, sLangBtnPause, sLangBtnPauseTitle, sLangImgNr, bIsAdmin)
{
   hs.graphicsDir             = sGraphicsDir;
   hs.showCredits             = false;
   hs.outlineType             = 'custom';
   hs.dimmingOpacity          = 0.35;
   hs.align                   = 'center';
   hs.captionEval             = 'this.thumb.alt'; // Tell Highslide to use the thumbnail's title for captions // this.thumb.title
   hs.captionOverlay.position = 'bottom left';
   hs.marginBottom            = 80;
   hs.expandDuration          = 0;
   hs.restoreDuration         = 0;
   hs.transitions             = ['expand', 'crossfade'];
   hs.registerOverlay({
      html: '<div class="closebutton" onclick="return hs.close(this)" title="' + sLangBtnClose + '"></div>',
      position: 'top right',
      useOnHtml: true,
      fade: 2 // fading the semi-transparent overlay looks bad in IE
   });
   
   
   
   // Add the controlbar
   if(bIsAdmin == true)
   {
      hs.addSlideshow({
         interval       : 3000,
         repeat         : false,
         useControls    : true,
         fixedControls  : 'fit',
         overlayOptions : {
            className      : 'text-controls',
            opacity        : '0.6',
            position       : 'bottom center',
            offsetX        : '0',
            offsetY        : '-20',
            hideOnMouseOut : true
         }
      });
   }
   else
   {
      hs.addSlideshow({
         interval       : 3000,
         repeat         : false,
         useControls    : true,
         fixedControls  : 'fit',
         overlayOptions : {
            className      : 'text-controls',
            opacity        : '0.6',
            position       : 'bottom center',
            offsetX        : '0',
            offsetY        : '-15',
            hideOnMouseOut : true
         },
         thumbstrip : {
            position    : 'bottom center',
            mode        : 'horizontal',
            relativeTo  : 'viewport'
         }
      });
   }
   
   
   
   // Language strings
   hs.lang = {
      cssDirection    : 'ltr',
      loadingText     : '...',
      loadingTitle    : sLangBtnCancel,
      focusTitle      : '',
      fullExpandTitle : sLangBtnExpand,
      fullExpandText  : sLangBtnExpand,
      creditsText     : '',
      creditsTitle    : '',
      previousText    : sLangBtnPrevImg,
      nextText        : sLangBtnNextImg,
      previousTitle   : sLangBtnPrevImgLeftKey,
      nextTitle       : sLangBtnNextImgRightKey,
      closeText       : sLangBtnClose,
      closeTitle      : sLangBtnClose + ' (esc)',
      resizeTitle     : sLangBtnResize,
      playText        : sLangBtnPlay,
      playTitle       : sLangBtnPlayTitle,
      pauseText       : sLangBtnPause,
      pauseTitle      : sLangBtnPauseTitle,
      moveText        : sLangBtnClickDragToMove,
      moveTitle       : sLangBtnClickDragToMove,
      number          : sLangImgNr,
      restoreTitle    : ''
   };
}