File "all.min.js"

Full path: E:/sites/Single15/tinmung2007/webroot/GIADINHTANHIEN/CAC MIEN/THhoaky-2022/TH-Hoa-Ky-2022/res/all.min.js
File size: 116.96 KiB (119765 bytes)
MIME-type:
Charset: utf-8

Download   Open   Back

/* all.min.js - Turtle skin scripts */
var VER='5.4.8',DEBUG=false;
Texts={closeWindow:'Close window',okButton:'OK',warning:'Warning',error:'Error',today:'today',yesterday:'yesterday',daysAgo:'{0} days ago',monthsAgo:'{0} months ago',yearsAgo:'{0} years ago',play:'Play',pause:'Pause',stop:'Stop',mute:'Mute',unmute:'Unmute',fullScreen:'Full screen',restoreScreen:'Restore screen',repeat:'Repeat',repeatOff:'Repeat off',localFlashWarning:'Local Flash playback is possibly blocked by Flash security rules. Test videos in the uploaded album!',unsupportedMediaFormat:'<span>Unsupported media format</span>You might need to either update your browser or the <a href=&#34;http://get.adobe.com/flashplayer/&#34; target=&#34;_blank&#34;>Flash plugin</a> or use another browser to play this media.',addCart:'Add to Cart',buyNow:'Buy Now',viewCart:'View Cart',items:'items',success:'Success',couponCode:'Coupon code',redeem:'Redeem',noSuch:'No such coupon exists!',expired:'The coupon code <b>{0}</b> has expired!',accepted:'The coupon code is accepted. You will get <b>{0}</b> discount the next time you add this item to the cart.',lowerThanCurrent:'This coupon offers lower discount than the current <b>{0}</b>.',higherThanPrice:'You can use this coupon only for items priced higher than <b>{0}</b>.',reclaimed:'This coupon has already been used!',shareOn:'Share on',checkOutThis:'Check this out',localWarning:'Can&#39;t share local albums. Please upload your album first!',searchBoxTip:'Search...',searchResultsFor:'Search results for',newImages:'New images',notFound:'Not found',foundNImages:'Found {0} item(s)',close:'Close',newItem:'NEW',help_title:'Using Gallery Controls',help_pressF1:'Press <b>F1</b> any time to get help!',help_topNavigation:'Top <b>navigation</b> bar with <b>Home</b> button',help_upOneLevel:'<b>Up</b> one level',help_authorInfo:'Author or company <b>information</b>',help_shareAndLike:'<b>Share</b> and <b>Like</b> buttons for social networking',help_searchNew:'Search <b>new images</b>',help_search:'<b>Search</b> button',help_downloadZip:'<b>Download</b> album or current folder as ZIP file',help_startSlideshow:'Start <b>slideshow</b> <em>Numpad *</em>',help_previousPicture:'<b>Previous</b> picture <em>Left arrow</em><em>Swipe right</em>',help_backToIndex:'Back to <b>thumbnail page</b> / up one level <em>Esc</em>',help_toggleFit:'Toggle <b>fit to screen</b> or <b>1:1</b> size <em>Numpad +</em>',help_toggleInfo:'Show/hide <b>captions</b> and other panels, like Metadata, Map, Shopping, etc. <em>Numpad -</em>',help_toggleThumbnails:'Show/hide <b>thumbnail</b> scroller <em>Numpad -</em>',help_toggleAutoPlay:'Start/stop <b>slideshow</b> <em>Numpad *</em>',help_nextPicture:'<b>Next</b> picture <em>Right arrow</em><em>Swipe left</em>',help_toggleMeta:'Toggle <b>photo data</b>',help_toggleMap:'Toggle <b>map</b>',help_toggleShop:'Toggle <b>shopping options</b> panel',help_downloadImage:'Download <b>high resolution</b> file',help_shareAndLike:'<b>Share</b> and <b>Like</b> buttons for social networking',help_toggleComments:'Toggle <b>Facebook comments</b>',help_toggleFaces:'Toggle visibility of <b>tagged people</b>',startSlideshow:'Start slideshow',atFirstPage:'At first page',atLastPage:'At last page',atLastPageQuestion:'Where to go next?',startOver:'Start over',backToHome:'Back to home',stop:'Stop',upOneLevel:'Up one level',backToIndex:'Back to index page',previousPicture:'Previous picture',nextPicture:'Next picture',previousFolder:'Previous folder',nextFolder:'Next folder',changeSpeed:'Change speed',oneToOneSize:'1:1 size',fitToScreen:'Fit to screen',showInfo:'Show caption / info',hideInfo:'Hide caption / info',showThumbs:'Show thumbnails',hideThumbs:'Hide thumbnails',startAutoplay:'Start autoplay',stopAutoplay:'Stop autoplay',clickToOpen:'Click to open this document with the associated viewer',commentsBtn:'Comments',commentsLabel:'Add a comment, view other&#39;s comments',metaBtn:'Photo data',metaLabel:'Display photographic (Exif/Iptc) data',mapBtn:'Map',mapLabel:'Show the photo location on map',shopBtn:'Buy',shopLabel:'Show options to buy this item',shareBtn:'Share',shareLabel:'Share this photo over social sites',download:'Download',original:'Original',hiRes:'Hi res.',saveTip:'Use <b>Right click + Save link as...</b> to download',print:'print',printLabel:'Print out this photo on your printer',fotomotoBtn:'Buy / Share',fotomotoLabel:'Buy prints or digital files, share, send free eCards',mostphotosBtn:'Purchase',mostphotosLabel:'Download this image from <b>mostphotos.com</b>!',people:'People',sendFeedback:'Send feedback',message:'Message',subject:'Subject',comment:'Comment',yourEmail:'Your email address',send:'Send',messageSent:'Message sent',errorSending:'Error sending email!',tooLong:'Text is too long or too many items!',emailMissing:'Email is misssing or wrong format!',noItemsSelected:'No items selected',selectItemsHint:'Select the desired items first!',nonShoppableItems:'The selected items have no or have proprietary shopping options, or different discount rates.',buyNItems:'Buy {0} items',locationWarning:'Works only when uploaded',cookiePolicyText:'This album uses cookies to remember user preferences. By using it, you agree to our use of cookies.',cookiePolicyAgree:'Got it',cookiePolicyLearnMore:'Learn more'};
!function(t){var e=["DOMMouseScroll","mousewheel"];if(t.event.fixHooks)for(var n=e.length;n;)t.event.fixHooks[e[--n]]=t.event.mouseHooks;t.event.special.mousewheel={setup:function(){if(this.addEventListener)for(var t=e.length;t;)this.addEventListener(e[--t],r,!1);else this.onmousewheel=r},teardown:function(){if(this.removeEventListener)for(var t=e.length;t;)this.removeEventListener(e[--t],r,!1);else this.onmousewheel=null}},t.fn.extend({mousewheel:function(t){return t?this.bind("mousewheel",t):this.trigger("mousewheel")},unmousewheel:function(t){return this.unbind("mousewheel",t)}});var r=function(e){var n=e||window.event,r=[].slice.call(arguments,1),i=0,o=0,s=0;return e=t.event.fix(n),e.type="mousewheel",n.wheelDelta?i=n.wheelDelta/120:n.detail&&(i=-n.detail/3),s=i,void 0!==n.axis&&n.axis===n.HORIZONTAL_AXIS&&(s=0,o=-1*i),void 0!==n.wheelDeltaY&&(s=n.wheelDeltaY/120),void 0!==n.wheelDeltaX&&(o=-1*n.wheelDeltaX/120),r.unshift(e,i,o,s),(t.event.dispatch||t.event.handle).apply(this,r)}}(jQuery);
!function(n){!function(){function e(e){function t(n){return n===!0?function(n){return n}:"string"==typeof n&&(n=c(n.split("")))||"function"==typeof n?function(e){return n(encodeURIComponent(e))}:encodeURIComponent}function c(e){var t=new RegExp(n.map(e,encodeURIComponent).join("|"),"ig");return function(n){return n.replace(t,decodeURIComponent)}}e=n.extend({unescape:!1},e||{}),o.encoder=t(e.unescape)}var t=!(navigator.userAgent.indexOf("Firefox")>=0&&parseInt(navigator.userAgent.match(/Firefox\/(\d*(\.\d*)*)/)[1])<41),o={put:function(n,e){(e||window).location.hash=this.encoder(n)},get:function(n){var e=(n||window).location.hash.replace(/^#/,"");try{return t?decodeURIComponent(e):e}catch(o){return e}},encoder:encodeURIComponent},c={};c.base={callback:void 0,type:void 0,check:function(){},load:function(){},init:function(n,t){e(t),a.callback=n,a._options=t,a._init()},_init:function(){},_options:{}},c.timer={_appState:void 0,_init:function(){var n=o.get();a._appState=n,a.callback(n),setInterval(a.check,100)},check:function(){var n=o.get();n!==a._appState&&(a._appState=n,a.callback(n))},load:function(n){n!==a._appState&&(o.put(n),a._appState=n,a.callback(n))}},c.hashchangeEvent={_init:function(){a.callback(o.get()),n(window).on("hashchange",a.check)},check:function(){a.callback(o.get())},load:function(n){o.put(n)}};var a=n.extend({},c.base);a.type="onhashchange"in window?"hashchangeEvent":"timer",n.extend(a,c[a.type]),n.history=a}()}(jQuery);
var UNDEF="undefined",NOLINK="javascript:void(0)",LOCAL=0===location.protocol.indexOf("file:"),VEND=function(t){return t.indexOf("Trident")>0?"ms":t.indexOf("AppleWebKit")>0?"webkit":t.indexOf("Gecko")>0?"moz":t.indexOf("Presto")>0?"o":t.indexOf("Blink")>0?"webkit":""}(navigator.userAgent);String.wsp=[],String.wsp[9]=!0,String.wsp[10]=!0,String.wsp[11]=!0,String.wsp[12]=!0,String.wsp[13]=!0,String.wsp[32]=!0,String.wsp[133]=!0,String.wsp[160]=!0,String.wsp[5760]=!0,String.wsp[6158]=!0,String.wsp[8192]=!0,String.wsp[8193]=!0,String.wsp[8194]=!0,String.wsp[8195]=!0,String.wsp[8196]=!0,String.wsp[8197]=!0,String.wsp[8198]=!0,String.wsp[8199]=!0,String.wsp[8200]=!0,String.wsp[8201]=!0,String.wsp[8202]=!0,String.wsp[8203]=!0,String.wsp[8232]=!0,String.wsp[8233]=!0,String.wsp[8239]=!0,String.wsp[8287]=!0,String.wsp[12288]=!0,String.prototype.trim=function(){var t=this+"",n=t.length;if(n){var e=String.wsp,r=0;for(--n;n>=0&&e[t.charCodeAt(n)];)--n;for(++n;n>r&&e[t.charCodeAt(r)];)++r;t=t.substring(r,n)}return t},String.prototype.trunc=function(t){var n=this+"";if(n.length<=t)return n.toString();var e=n.substring(0,t-1),r=e.lastIndexOf(" ");return(r>6&&e.length-r<20?e.substring(0,r):e)+"..."},String.prototype.startsWith=function(t){return 0===(this+"").indexOf(t)},String.prototype.endsWith=function(t){return(this+"").substring(this.length-t.length)===t},String.prototype.capitalize=function(){return this.charAt(0).toUpperCase()+this.slice(1)},String.prototype.unCamelCase=function(){return this.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase()},String.prototype.getExt=function(){var t=this+"",n=t.lastIndexOf(".");return 0>=n||n>=t.length-1?"":t.substring(n+1).toLowerCase()},String.prototype.hasExt=function(t){var n=this+"",e=n.lastIndexOf(".");return e>=0?(n=n.substring(e+1).toLowerCase(),(t+",").indexOf(n+",")>=0):!1},String.prototype.replaceExt=function(t){var n=this+"",e=n.lastIndexOf(".");return 0>=e?n:n.substring(0,e+1)+t},String.prototype.fixExtension=function(){return(this+"").replace(/.gif$/gi,".png").replace(/.tif+$/gi,".jpg")},String.prototype.getDir=function(){var t=(this+"").split("#")[0];return t.substring(0,t.lastIndexOf("/")+1)},String.prototype.getFile=function(){var t=(this+"").split("#")[0];return t.substring(t.lastIndexOf("/")+1)},String.prototype.getRelpath=function(t){var n=this+"",e=n.lastIndexOf("#");for(-1===e?e=n.length-1:e--;e>=0&&("/"!==n[e]||0!==t--);e--);return n.substring(e+1)},String.prototype.fixUrl=function(){for(var t,n,e=this+"";(t=e.indexOf("../"))>0;){if(1===t||-1===(n=e.lastIndexOf("/",t-2)))return e.substring(t+3);e=e.substring(0,n)+e.substring(t+2)}return e},String.prototype.fullUrl=function(){var t=this+"";return t.match(/^(http|ftp|file)/)||(t=window.location.href.getDir()+t),t.fixUrl()},String.prototype.cleanupHTML=function(){for(var t=[[/<br>/gi,"\n"],[/\&amp;/gi,"&"],[/\&lt;/gi,"<"],[/\&gt;/gi,">"],[/\&(m|n)dash;/gi,"-"],[/\&apos;/gi,"'"],[/\&quot;/gi,'"']],n=this+"",e=t.length-1;e>=0;e--)n=n.replace(t[e][0],t[e][1]);return n},String.prototype.stripHTML=function(t){var n=this+"";return t&&(n=n.cleanupHTML()),n.replace(/<\/?[^>]+>/gi,"")},String.prototype.stripQuote=function(){return(this+"").replace(/\"/gi,"&quot;")},String.prototype.appendSep=function(t,n){return(this.length?this+(n||" &middot; "):"")+t},String.prototype.rgb2hex=function(){var t=this+"";if("#"===t.charAt(0)||"transparent"===t)return t;var n,e=t.match(/\d+/g),r="";if(e){for(var o=0;o<e.length&&3>o;o++)n=parseInt(e[o],10).toString(16),r+=(n.length<2?"0":"")+n;return"#"+r}return"transparent"},String.prototype.template=function(t){if(typeof t===UNDEF||!this)return this;$.isNumeric(t)&&(t+="");var n=this+"";if($.isArray(t))for(var e=0;e<t.length;e++)n=n.replace(new RegExp("\\{"+e+"\\}","gi"),t[e]);else n=n.replace(/\{0\}/gi,t);return n},Math.minMax=function(t,n,e){return n=isNaN(n)?parseFloat(n):n,t>n?t:n>e?e:n},String.prototype.objectify=function(){if(!this||!this.length)return this;var t=this+"";"?"===t.charAt(0)&&(t=t.substring(1));for(var n,e={},r=t.split("&"),o=0,i=r.length;i>o;o++)n=r[o].split("="),n.length>1&&(e[n[0]]=n[1]);return e},String.prototype.testIn=function(t){return"string"!=typeof t&&(t+=""),new RegExp(this,"i").test(t)};var getCoords=function(t){return t.touches&&t.touches.length>0?{x:Math.round(t.touches[0].clientX),y:Math.round(t.touches[0].clientY)}:null!==t.clientX?{x:Math.round(t.clientX),y:Math.round(t.clientY)}:null},noAction=function(t){return t.stopPropagation(),t.preventDefault(),!1},TOUCH_START="touchstart",TOUCH_MOVE="touchmove",TOUCH_END="touchend",scrollbarWidth=function(){var t=document.createElement("div");t.style.cssText="width:100px;height:100px;overflow:scroll !important;position:absolute;top:-9999px",document.body.appendChild(t);var n=t.offsetWidth-t.clientWidth;return document.body.removeChild(t),n};!function(t,n){var e=function(){window.navigator.pointerEnabled?(TOUCH_START="pointerdown",TOUCH_MOVE="pointermove",TOUCH_END="pointerup"):(TOUCH_START="MSPointerDown",TOUCH_MOVE="MSPointerMove",TOUCH_END="MSPointerUp")};/Trident/.test(navigator.userAgent)?(n.touchMode="undefined"!=typeof navigator.maxTouchPoints&&navigator.maxTouchPoints,e()):/Edge/.test(navigator.userAgent)?(n.touchMode=0==scrollbarWidth(),e()):(TOUCH_START="touchstart",TOUCH_MOVE="touchmove",TOUCH_END="touchend",n.touchMode=/(Chrome|CriOS)/.test(navigator.userAgent)?/Mobile/.test(navigator.userAgent)||Object.prototype.hasOwnProperty.call(window,"ontouchstart"):"ontouchstart"in window);var r="moz"===VEND?"transform":"-"+VEND+"-transform";t.fn.translate=function(n,e,o){return this.each(function(){o&&t(this).addClass(o).data("tr_cls",o),this.style[r]="translate("+(n||0)+"px,"+(e||0)+"px)",t(this).data({tr_x:n,tr_y:e})})},t.fn.translateToPos=function(){return this.each(function(){var n=t(this),e=n.data("tr_x")||0,o=n.data("tr_y")||0;if(e||o){var i=n.position(),a=n.data("tr_cls");a&&n.removeClass(a),this.style[r]="translate(0,0)",n.removeData("tr_x tr_y").css({left:i.left,top:i.top})}})}}(jQuery,document),function(){function t(){n&&(o(t),jQuery.fx.tick())}for(var n,e=0,r=["webkit","moz"],o=window.requestAnimationFrame,i=window.cancelAnimationFrame;e<r.length&&!o;e++)o=window[r[e]+"RequestAnimationFrame"],i=i||window[r[e]+"CancelAnimationFrame"]||window[r[e]+"CancelRequestAnimationFrame"];o?(window.requestAnimationFrame=o,window.cancelAnimationFrame=i,jQuery.fx.timer=function(e){e()&&jQuery.timers.push(e)&&!n&&(n=!0,t())},jQuery.fx.stop=function(){n=!1}):(window.requestAnimationFrame=function(t){var n=(new Date).getTime(),r=Math.max(0,16-(n-e)),o=window.setTimeout(function(){t(n+r)},r);return e=n+r,o},window.cancelAnimationFrame=function(t){clearTimeout(t)})}(jQuery);var translate=function(t,n){if(t=t.trim(),typeof Texts!==UNDEF&&Texts.hasOwnProperty(t))return Texts[t];if(typeof n!==UNDEF)return DEBUG&&console&&console.log("Using default translation: "+t+"="+n),n;DEBUG&&console&&console.log("Missing translation: "+t);var e=t.replace(/([A-Z])/g," $1").toLowerCase();return e[0]=e.charAt(0).toUpperCase(),e},getKeys=function(t,n){var e,r={},o=t.split(","),i=o.length;for(e=0;i>e;e++)r[o[e]]=translate(o[e],n[o]);return r},getTranslations=function(t){var n,e={};for(n in t)e[n]="object"==typeof t[n]?getTranslations(t[n]):translate(n,t[n]);return e},printImage=function(t,n,e){if(t){var r=window.open("about:blank","print","location=no,status=no,titlebar=no");r.document.open(),r.document.write('<!DOCTYPE html>\n<html>\n<head>\n<meta charset="utf-8">\n<title>'+(n||"Print")+'</title>\n<script>printOut=function(){window.print();window.close();}</script>\n<style>body{margin:0;padding:0;text-align:center;overflow:hidden;}\nimg{display:block;width:100%;height:auto;}</style>\n</head>\n<body onLoad="setTimeout(printOut,100)"><img src="'+t+'">'+(e||"")+"</body>\n</html>"),r.document.close()}},xDecrypt=function(t){var n,e,r,o=[147,163,87,254,153,4,198,23],i=t.length,a=5*Math.ceil(i/8),s=new Array(a),u="",p=0;for(n=0;a>n;n++)s[n]=0;for(n=0;i>n;n++)(r=t.charCodeAt(n)-48)>9&&(r-=7),r<<=11-p%8,e=Math.floor(p/8),a>e&&(s[e]|=r>>8,++e<a&&(s[e]|=255&r)),p+=5;for(n=0;a>n;n++)s[n]^=o[n%8];for(a=s[0]|s[1]<<8,r=0,n=4;a>n;n++)u+=String.fromCharCode(s[n]),r+=s[n];return r!=(255&s[2]|s[3]<<8)&&(u=""),u},log=function(){};!function(t){var n,e,r=!1,o=1;log=function(i){DEBUG&&!r&&(n||(n=t('<div id="log" style="position:fixed;left:0;top:0;width:200px;bottom:0;overflow:auto;padding:10px;background-color:rgba(0,0,0,0.5);color:#fff;font-size:15px;z-index:99999"></div>').hover(function(){r=!0},function(){r=!1}).appendTo("body")),i===e?n.children(":first").empty().html(e+" ("+ ++o+")"):(t('<div style="height:2em;overflow:hidden;">'+i+"</div>").prependTo(n),e=i,o=1))},t.fn.logEvents=function(n){if(DEBUG){var e=n||"mousedown mouseup mouseover mouseout mousewheel dragstart click blur focus load unload reset submit change abort cut copy paste selection drag drop orientationchange touchstart touchmove touchend touchcancel MSPointerDown MSPointerMove MSPointerUp gesturestart gesturechange gestureend";return this.each(function(){t(this).on(e,function(t){return typeof t===UNDEF?log("Undefined event"):t.target?"log"!==t.target.id&&log(t.type+' <span style="padding:0 4px;font-size:0.8em;background-color:#000;border-radius:4px;"><b>'+(t.target.nodeName?t.target.nodeName.toLowerCase():"???")+"</b>"+(t.target.id?":"+t.target.id:"")+"</span>"+(t.relatedTarget?' <span style="padding:0 4px;font-size:0.8em;background-color:#800;border-radius:4px;"><b>'+t.relatedTarget.nodeName.toLowerCase()+"</b>"+(t.relatedTarget.id?":"+t.relatedTarget.id:"")+"</span>":"")):log("No event target!"),!0})})}},t.fn.logCss=function(n,e,r){if(DEBUG){r=r||20,e=e||2e3;var o=new Date;return this.each(function(){var i=t(this),a=function(t){var n=new Date-o;log(n+"&nbsp;::&nbsp;"+t+" = "+i.css(t)),n>e&&clearInterval(s)},s=setInterval(function(){if(t.isArray(n))for(var e=0;e<n.length;e++)a(n[e]);else a(n)},r)})}}}(jQuery);var getRelativeDate=function(t){if(!t)return translate("today");if(1===t)return translate("yesterday");var n,e;return t>=730?(n=translate("yearsAgo"),e=Math.floor(t/365)):t>=60?(n=translate("monthsAgo"),e=Math.floor(t/30.5)):(n=translate("daysAgo"),e=t),n.replace("{0}",e)};
!function(e){var t=function(){return document.fullscreenElement||document.webkitFullscreenElement||document.mozFullScreenElement||document.msFullscreenElement},n=function(e){t()||(e.requestFullscreen?e.requestFullscreen():e.webkitRequestFullscreen?e.webkitRequestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.msRequestFullscreen&&document.body.msRequestFullscreen())},o=function(){t()&&(document.exitFullscreen?document.exitFullscreen():document.webkitExitFullscreen?document.webkitExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.msExitFullscreen&&document.msExitFullscreen())};e.fn.fullScreen=function(e){return document.fullscreenEnabled||document.webkitFullscreenEnabled||document.mozFullScreenEnabled||document.msFullscreenEnabled?"undefined"==typeof e?t():(e?n(this[0]):o(),void 0):!1}}(jQuery);
!function(e){e.event.special.dbltap={setup:function(){e(this).on("touchend.dbltap",e.event.special.dbltap.handler)},teardown:function(){e(this).off("touchend.dbltap")},handler:function(t){var n=[].slice.call(arguments,1),o=e(t.target),a=(new Date).getTime(),i=a-(o.data("lastTouch")||0);return i>5&&300>i?(t.preventDefault(),o.data("lastTouch",0),t=e.e.fix(t||window.event),t.type="dbltap",n.unshift(t),(e.e.dispatch||e.e.handle).apply(this,n)):(o.data("lastTouch",a),!0)}}}(jQuery);
!function(e){LOCALSTORAGE=function(){try{return localStorage.setItem("_t",VER),localStorage.removeItem("_t"),!0}catch(e){return!1}}(),e.cookie=function(t,n,o){var a,i,s="; ",r=function(e){return/^(true|yes)$/.test(e)?!0:/^(false|no)$/.test(e)?!1:/^([\d.]+)$/.test(e)?parseFloat(e):e};if(arguments.length>1)return i=new Date,null===n?LOCALSTORAGE?localStorage.removeItem(t):document.cookie=encodeURIComponent(t)+"="+"; expires="+i.toGMTString()+"; path=/":/^(string|number|boolean)$/.test(typeof n)&&(i.setTime(i.getTime()+1e3*("number"!=typeof o?3600:o)),LOCALSTORAGE?localStorage.setItem(t,String(n)+s+String(i.getTime())):document.cookie=encodeURIComponent(t)+"="+String(n)+"; expires="+i.toGMTString()+"; path=/"),n;if(t)if(LOCALSTORAGE){if(a=localStorage.getItem(t)){if(a=a.split(s),!(e.isArray(a)&&a.length>1))return r(a);if(i=new Date,i.getTime()<parseInt(a[1],10))return r(a[0]);localStorage.removeItem(t)}}else{var l;a=document.cookie.split(";"),t+="=";for(var d=0;d<a.length;d++)l=a[d].trim(),0===l.indexOf(t)&&(l=l.substring(t.length),r(l))}return null}}(jQuery);
!function(t){var e=0,a=0,o=1,n=1,i=2,s=2,r=["left","center","right"],l=["top","middle","bottom"],p="align-left align-center align-right valign-top valign-middle valign-bottom";t.fn.alignTo=function(d,u){if(u=t.extend({},t.fn.alignTo.defaults,u),"string"==typeof d&&(d=t(d)),d instanceof t&&d.length){var f,c,h,g=t(window).width(),v=t(window).height();if("AREA"===d[0].nodeName&&"RECT"===d[0].shape.toUpperCase()){var m=d[0].coords.split(",");c=parseInt(m[2],10)-parseInt(m[0],10),h=parseInt(m[3],10)-parseInt(m[1],10),f=d.parent().offset(),f.left+=parseInt(m[0],10),f.top+=parseInt(m[1],10)}else f=d.offset(),c=d.outerWidth(),h=d.outerHeight();return t(this).each(function(){var d=t(this),m=u.pos[2],y=u.pos[3];d.css("maxHeight","none");var j=d.outerWidth(),b=d.outerHeight(),w=Math.round(f.left+u.pos[2]*c/2+(u.pos[2]-1)*u.gap),T=Math.round(f.top+u.pos[3]*h/2+(u.pos[3]-1)*u.gap),x=Math.round(w-u.pos[0]*j/2),I=Math.round(T-u.pos[1]*b/2);(0>I||I+b>v)&&(u.pos[2]!==o?I=2*I+b>v?v-b:0:u.pos[3]===a?v>2*f.top+h&&(I=f.top+h+u.gap,y=s):u.pos[3]===s&&v<2*f.top+h&&(I=Math.max(0,f.top-b-u.gap),y=a),0>I&&(I=0),I+b>v&&d.css({overflow:"auto",maxHeight:v-I-(parseInt(d.css("paddingTop"),10)+parseInt(d.css("paddingBottom"),10))})),(0>x||x+j>g)&&(u.pos[3]!==n?x=2*x+j>g?g-j:0:u.pos[2]===e?g>2*f.left+c&&(x=f.left+c+u.gap,m=i):u.pos[2]===i&&g<2*f.left+c&&(x=Math.max(0,f.left-j-u.gap),m=e),0>x&&(x=0),x+j>g&&d.css({overflow:"auto",maxWidth:g-x-(parseInt(d.css("paddingLeft"),10)+parseInt(d.css("paddingRight"),10))})),d.css({position:"absolute",left:x,top:I}).removeClass(p).addClass("align-"+r[m]).addClass("valign-"+l[y])})}},t.fn.alignTo.defaults={gap:0,pos:[o,s,o,a]}}(jQuery);
!function(e){e.fn.addTooltip=function(t,o){t&&"string"!=typeof t&&!t.jquery&&(o=t,t=null);var i={tooltip:"tooltip"},n=".tt";o=e.extend({},e.fn.addTooltip.defaults,o),e.fn.hideAllTooltips=function(){e("."+o.className).hide()};var a=function(t,n){var a;if(n)if("string"==typeof n)a=e("<div>",{html:n}).appendTo("body");else{if(!n.jquery)return null;a=e.contains(document.body,n[0])?n:n.appendTo("body")}else{if((n=t.data(i.tooltip))?("."===n.charAt(0)?n=t.find(n):"#"===n.charAt(0)&&(n=e(n)),n.jquery&&n.removeClass("hidden")):(n=t.attr("title"),t.removeAttr("title")),!n||!n.length)return null;a=e("<div>",{html:n}).appendTo("body")}return a.addClass(o.className).hide(),a.append(e("<span>",{"class":o.nub})),a};return this.each(function(){var i,l,s,r,p=e(this),d=!1,c=!1,u=function(){s=clearTimeout(s),d=!0,i.finish().show()},h=function(){c||(clearTimeout(s),d=!1,s=setTimeout(b,100))},m=function(){l=clearTimeout(l),clearTimeout(s),d=!1,s=setTimeout(b,100)},f=function(){return m(),!0},b=function(){!d&&i&&i.stop(!0,!1).fadeOut(200,function(){i.hide()})},g=function(){clearTimeout(s),s=setTimeout(b,o.stay)},w=function(){return(i=a(p,t))?(document.touchMode||i.on("mouseover"+n,u).on("mouseout"+n,h),i.find("input, textarea").on("focus"+n,function(){c=!0,u()}).on("blur"+n,function(){c=!1}),!0):!1},v=function(){var e=p.offset();e.top===r.top&&e.left===r.left&&i.fadeIn(300).alignTo(p,{gap:10,pos:o.pos})},y=function(){if(i)i.stop(!0,!1),s=clearTimeout(s);else if(!w())return;r=p.offset(),clearTimeout(l),l=setTimeout(v,o.delay),document.touchMode?g():d=!0},k=function(e){if(e.preventDefault(),!i||i.is(":hidden"))y();else if(d=!1,m(),"A"===p[0].nodeName){var t=p.attr("href");t&&!t.startsWith("javascript:")?window.location.href=t:p.trigger("click")}return!1},T=function(e){e.preventDefault(),e.stopPropagation()};p.on("removeTooltip",m),document.touchMode?p.on("touchstart"+n+" pointerdown"+n+" MSPointerDown"+n,k).on("touchend"+n+" touchcancel"+n+" pointerup"+n+" MSPointerUp"+n,T).on("click"+n,T):p.on("focus"+n+" mouseenter"+n,y).on("blur"+n+" mouseleave"+n,m).on("click"+n,f)})},e.fn.addTooltip.defaults={delay:50,className:"hint",nub:"nub",stay:2e3,pos:[1,2,1,0]}}(jQuery);
!function(e){e.fn.addModal=function(t,n,a){var o=e(this);if("string"==typeof t&&(t=e(t)),t instanceof e&&t.length){e.isArray(n)||(a=n,n=null),a=e.extend({},e.fn.addModal.defaults,a),a.savePosition=a.savePosition&&"uid"in a;var i=getTranslations(e.fn.addModal.text);a.defaultButton&&(a.defaultButton=translate(a.defaultButton,"OK"));var s,r,l,d,c,u,p,h,f,m={w:"_m_window",p:"_m_panel",h:"_m_head",c:"_m_cont",ci:"_m_cont_i",x:"close",r:"resize"},g=0;a.uid&&e("#"+a.uid).parents("."+m.w).remove(),s=e("<div>",{"class":m.w,role:"dialog","aria-hidden":!0,"aria-labelledby":m.h}).css({opacity:0}).appendTo(o),o.css({position:"relative"});var v=function(){p=o.width(),h=o.height()};v(),e(window).on("resize",v),a.darkenBackground&&s.addClass("darken"),r=e("<div>",{id:a.uid||"_mod_"+Math.floor(1e4*Math.random()),"class":m.p+" "+a.type}).css({width:a.width}).appendTo(s),l=e("<header>",{"class":m.h}).appendTo(r),l.append(e("<h5>",{id:m.h,text:a.title||("error"===a.type||"warning"===a.type?i[a.type]:"")})),("error"===a.type||"warning"===a.type)&&l.append(e("<span>",{"class":a.type,text:"!"}));var b=function(){return d.trigger("removeTooltip"),f=clearTimeout(f),s.animate({opacity:0},a.speed,function(){s.remove()}),!1};s.on("destroy",b),a.blocking&&a.closeOnClickOut&&s.on("click",function(t){return e(t.target).hasClass(m.w)?b(t):void 0}),d=e("<a>",{"class":m.x,html:"&times;"}).appendTo(l),document.touchMode?d[0].addEventListener(TOUCH_END,b):(d.on("click",b),d.addTooltip(i.closeWindow));var w=function(t){t.preventDefault();var n=r.position().left,o=r.position().top,i=getCoords(t),s=p-r.width()-a.pad,d=h-r.height()-a.pad,c=l.css("cursor");l.css({cursor:"move"});var u=function(e){e.preventDefault();var t=getCoords(e);return r.css({left:Math.minMax(a.pad,n+t.x-i.x,s),top:Math.minMax(a.pad,o+t.y-i.y,d)}),!1},f=function(t){return t.preventDefault(),e(document).off({mousemove:u,mouseup:f}),l.css("cursor",c),a.savePosition&&E(),!1};return document.touchMode?(this.addEventListener(TOUCH_END,f),this.addEventListener(TOUCH_MOVE,u)):e(document).on({mousemove:u,mouseup:f}),!1};if(a.movable&&(document.touchMode?l[0].addEventListener(TOUCH_START,w):l.on("mousedown",w)),c=e("<div>",{"class":m.c}).appendTo(r),u=e("<div>",{"class":m.ci}).append(t).appendTo(c),!n&&a.defaultButton&&(n=[{t:a.defaultButton,h:b}]),n){var y,T,k,x=e("<div>",{"class":"buttons"}).appendTo(u),S=function(t){k.each(function(n){e(this).toggleClass("active",n===t)})},I=function(){e(document).off("keydown",M),b()},M=function(t){if(document.activeElement&&"input"===document.activeElement.nodeName||e.isFunction(a.enableKeyboard)&&!a.enableKeyboard())return!0;var n=t?t.keyCode:window.event.keyCode;if(27===n)return I(),!1;if(x){var o=x.find("a.active"),i=k.index(o);switch(n){case 13:case 10:e.isFunction(o[0].handler)&&o[0].handler.call(s)!==!1&&I();break;case 39:S((i+1)%k.length);break;case 37:S(i?i-1:k.length-1);break;default:return!0}return!1}return!0},C=function(t){t.preventDefault();var n=t.target;return e.isFunction(n.handler)&&n.handler.call(s,r)!==!1&&I(),!1};for(y=0;y<n.length;y++)y&&x.append(" "),T=e("<a>",{html:n[y].t}).on("click",C).appendTo(x),e.isFunction(n[y].h)&&(T[0].handler=n[y].h);k=x.children("a"),k.last().addClass("active"),(e.isFunction(a.enableKeyboard)||a.enableKeyboard)&&e(document).on("keydown",M)}if(a.resizable){var O=function(e){e.preventDefault();var t=[r.position().left,r.position().top,r.width(),r.height()],n=[a.pad,a.pad,p-2*a.pad,h-2*a.pad],o=function(e){r.css({left:Math.minMax(a.gap,e[0],p-e[2]-a.gap),top:Math.minMax(a.gap,e[1],h-e[3]-a.gap),width:e[2],height:e[3]}),u.css({height:e[3]-g})};return t[0]===n[0]&&t[1]===n[1]&&t[2]===n[2]&&t[3]===n[3]?o(r.data("wpos")):(o(n),r.data("wpos",t)),a.savePosition&&E(),!1};l.on(document.touchMode?"dbltap":"dblclick",O);var F=e("<a>",{"class":m.r}).appendTo(r),P=function(t){t.preventDefault();var n=r.width(),o=r.height(),i=getCoords(t),l=s.width(),d=h-a.pad-r.position().top-g,l=p-a.pad-r.position().left,c=function(e){e.preventDefault();var t=getCoords(e),a=Math.min(Math.max(o+t.y-i.y-g,20),d);return r.css({width:Math.min(Math.max(n+t.x-i.x,60),l),height:a+g}),u.css({height:a}),!1},f=function(t){return t.preventDefault(),e(document).off({mousemove:c,mouseup:f}),a.savePosition&&E(),!1};return document.touchMode?(this.addEventListener(TOUCH_MOVE,c),this.addEventListener(TOUCH_END,f)):e(document).on({mousemove:c,mouseup:f}),!1};document.touchMode?F[0].addEventListener(TOUCH_START,P):F.on("mousedown",P)}var D=function(){var e=r.width(),t=r.height();g=t-u.height(),e&&t&&p&&h&&(e+2*a.pad>p&&r.css({width:e=p-2*a.pad}),t+2*a.pad>h&&(r.css({height:t=h-2*a.pad}),u.css({height:h-2*a.pad-g})),r.css({left:Math.max(Math.round((p-e)*a.pos[0]/2),a.pad),top:Math.max(Math.round((h-t)*a.pos[1]/2),a.pad)}))},L=function(e){var t,n=Math.minMax(a.pad,parseInt(e[0],10),p-a.pad-60),o=Math.minMax(a.pad,parseInt(e[1],10),h-a.pad-60),i=Math.minMax(120,parseInt(e[2],10),p-n-a.pad);(isNaN(n)||isNaN(o)||isNaN(i))&&D(),g=l.outerHeight()+parseInt(c.css("padding-top"),10)+parseInt(c.css("padding-bottom"),10)+parseInt(u.css("padding-top"),10)+parseInt(u.css("padding-bottom"),10)+parseInt(c.css("border-top-width"),10),r.css({position:"absolute",left:n,top:o,width:i}),r.height()>(t=h-o-a.pad)&&(r.css({height:t}),u.css({height:t-g}))},E=function(){e.cookie("modalPosition"+a.uid,r.position().left+","+r.position().top+","+r.width()+","+r.height())},N=function(t){s.css({opacity:0}).show(),setTimeout(function(){t&&(t=t.split(","))&&e.isArray(t)&&t.length>3?L(t):D(),a.blocking||s.css({width:0,height:0,right:"auto",bottom:"auto",overflow:"visible"}),s.animate({opacity:1},a.speed),a.savePosition&&E(),a.autoFade&&(f=setTimeout(b,a.autoFade)),a.scrollIntoView&&setTimeout(function(){var e=u.children(":not(.buttons)").find(".active:first");e&&e.length&&u.scrollTop(Math.max(Math.floor(e.position().top)-50,0))},200),s.attr({tabindex:0,"aria-hidden":!1}),s.focus()},40)};return N(a.savePosition?e.cookie("modalPosition"+a.uid):null),this}},e.fn.addModal.defaults={speed:300,autoFade:0,width:400,resizable:!1,movable:!0,blocking:!0,enableKeyboard:!0,closeOnClickOut:!0,darkenBackground:!0,savePosition:!1,scrollIntoView:!1,defaultButton:"okButton",pad:6,pos:[1,1],type:"normal"},e.fn.addModal.text={closeWindow:"Close window",error:"error",warning:"warning"}}(jQuery);
!function(e){e.fn.loadImages=function(t){return t=e.extend({},e.fn.loadImages.defaults,t),this.each(function(){var n=e(this),o=n.find(t.selector).eq(0)||n.children().eq(0);if(o.length&&n.is(":visible")&&o.is(":visible")){var i=o.find("img."+t.loadClass);if(i.length){var a,r,s,l,d,c,u="absolute"===o.css("position"),p=-("left"in t?t.left:o.position().left-(u?0:n.scrollLeft()))-t.d,h=-("top"in t?t.top:o.position().top-(u?0:n.scrollTop()))-t.d,f=o.offset().left,g=o.offset().top,m=(u?n.width():e(window).width())+2*t.d,v=(u?n.height():e(window).height())+2*t.d,w=0;i.each(function(){r=e(this),a=r.parent(),(d=r.data("src"))&&(l=a.offset().left-f,s=a.offset().top-g,h+v>s&&p+m>l&&s+a.outerHeight()>h&&l+a.outerWidth()>p&&(c=e("<span>",{"class":t.wait}).appendTo(a),r.hide().on("load",function(){e(this).fadeIn().siblings("."+t.wait).remove()}).attr({src:d}).removeClass(t.loadClass),w++))})}}})},e.fn.loadImages.defaults={selector:".load",loadClass:"toload",wait:"wait",d:80}}(jQuery);
!function(e){e.fn.addScroll=function(t){return t=e.extend({},e.fn.addScroll.defaults,t),this.each(function(){var n,o,a,i,r,s,c,u,d,l,h,p,f,m,v,g,M=e(this),T=M.parent(),b=0;M.css({position:"absolute",width:T.width-20}),T.css({overflow:"hidden"}),"absolute"!==T.css("position")&&T.css({position:"relative"}),o=e("<div>",{"class":t.upbtn}).appendTo(T),a=e("<div>",{"class":t.dnbtn}).appendTo(T),i=e("<div>",{"class":t.scbar}).appendTo(T),r=e("<div>").appendTo(i),s=o.add(a).add(i),s.hide();var y=function(){c=M.height(),u=T.height()},w=function(){return M.position().top},O=function(e){return Math.round((i.height()-6)*-(null==e?w():e)/c)+3},D=function(){return Math.max(Math.round((i.height()-6)*u/c),t.dragMinSize)},I=function(e){null==e&&(e=w()),o.css({opacity:e?1:t.disabledOpacity}),a.css({opacity:e===u-c?t.disabledOpacity:1})},E=function(){return!1},C=function(){var e=c,t=u;y(),T.scrollTop()&&(M.css({top:-T.scrollTop()}),T.scrollTop(0)),(e!==c||t!==u)&&(u>=c?(M.css({top:0}).off("selectstart",E),s.hide()):(M.position().top<u-c&&M.css({top:u-c}),r.css({top:O(),height:D()}),M.on("selectstart",E),s.show(),I()),T.loadImages())},H=function(){M.css({top:Math.minMax(u-c,-Math.round((r.position().top-3)*c/(i.height()-6)),0)}),I(),T.loadImages()},U=function(e){clearInterval(d),u>=c||(e=Math.minMax(u-c,Math.round(e),0),r.stop(!0,!1).animate({top:O(e)},t.speed,t.effect),M.stop(!0,!1).animate({top:e},t.speed,t.effect,function(){I(e)}),T.loadImages({top:e}))};o.on("click",function(){return U(w()+u),!1}),a.on("click",function(){return U(w()-u),!1}),i.on("click",function(e){return e.pageY<r.offset().top?U(w()+u):e.pageY>r.offset().top+r.height()&&U(w()-u),!1}),t.enableMouseWheel&&M.on("mousewheel",function(e,n){return n&&(clearTimeout(d),r.stop(!0,!0),M.stop(!0,!0),U(w()+t.wheelIncr*(0>n?-1:1))),!1});var k=function(e){return e.preventDefault(),r.css({top:Math.minMax(2,Math.round(e.pageY-r.data("my")),i.height()-r.height()-2)}),H(),!1},x=function(t){return t.preventDefault(),e(document).off("mousemove",k).off("mouseup",x),!1};r.on("mousedown",function(t){return t.preventDefault(),e(this).data("my",Math.round(t.pageY)-e(this).position().top),e(document).on({mousemove:k,mouseup:x}),!1});var N=function(e){return b=e.touches&&e.touches.length>0?e.touches[0].clientY:e.clientY?e.clientY:b},S=function(){v+=Math.round(m/20);var e=f+v;return e>0||g>e?(clearInterval(d),void T.loadImages()):(M.css({top:e}),r.css({top:O(),height:D()}),m*=.8,void(Math.abs(m)<10&&(m=0,clearInterval(d),T.loadImages())))},Y=function(e){if(e.preventDefault(),h){var t=N(e)-h;t&&(M.data("dragOn",!0),M.css({top:Math.minMax(g,l+t,0)}),r.css({top:O(),height:D()}))}else h=N(e);return!1},L=function(t){t.preventDefault(),f=w();var n=N(t)-h,o=(new Date).getTime()-p;return m=1e3*n/o,d=setInterval(S,50),document.touchMode?(this.removeEventListener(TOUCH_MOVE,Y),this.removeEventListener(TOUCH_END,L)):e(document).off({mousemove:Y,mouseup:L}),setTimeout(function(){M.data("dragOn",!1)},20),T.loadImages(),Math.abs(n)<4&&300>o},A=function(n){var o=n.target.nodeName;return"INPUT"===o||"TEXTAREA"===o||"BUTTON"===o||"SELECT"===o?!0:(n.preventDefault(),M.data("dragOn")?(L(n),!0):n.target.scrollHeight-1>n.target.clientHeight?!0:t.dontDrag&&(e(n.target).is(t.dontDrag).length||e(n.target).parents(t.dontDrag).length)?!0:u>=c||("touchstart"===n.type||"touchmove"===n.type)&&(!n.touches||n.touches.length>1||M.is(":animated"))?!0:(r.stop(!0,!0),M.stop(!0,!0),clearInterval(d),l=w(),h=N(n),p=(new Date).getTime(),v=0,g=u-c,document.touchMode?(e(n.target).closest("a").focus(),this.addEventListener(TOUCH_MOVE,Y),this.addEventListener(TOUCH_END,L),!0):(e(document).on({mousemove:Y,mouseup:L}),!1)))};document.touchMode?M[0].addEventListener(TOUCH_START,A):M.on("mousedown",A),e(window).on("resize",function(){clearTimeout(n),n=setTimeout(C,50)}),n=setTimeout(C,10),t.refresh&&setInterval(function(){e("[role=gallery]").is(":visible")||C()},t.refresh),M.attr("role","scroll").data("dragOn",!1).on("adjust",C),s.on("selectstart",E);var K=function(){if(!M.data("dragOn")){var t=e(this).parent()===M?e(this):e(this).parent(),n=t.position().top,o=t.outerHeight(!0),a=M.position().top,i=T.height();if(!(i>M.height())){if(n+o>i-a)a=Math.max(i-o-n,i-M.height());else{if(!(-a>n))return;a=-n}U(a)}}};t.focusActive&&M.find("a").on("setactive",K);var _=function(e){return M.data("dragOn")?(e.preventDefault(),!1):!0};M.find("a").on("click",_),(e.isFunction(t.enableKeyboard)||t.enableKeyboard)&&e(document).on("keydown",function(n){if(document.activeElement&&"INPUT"===document.activeElement.nodeName||e.isFunction(t.enableKeyboard)&&!t.enableKeyboard())return!0;var o=n?n.keyCode:window.event.keyCode;switch(o){case 33:return n.preventDefault(),U(w()+u),!1;case 34:return n.preventDefault(),U(w()-u),!1}return!0})})},e.fn.addScroll.defaults={upbtn:"scrup",dnbtn:"scrdn",scbar:"scrbar",dragMinSize:10,speed:300,effect:"swing",disabledOpacity:.3,wheelIncr:50,enableKeyboard:!0,enableMouseWheel:!0,focusActive:!0,refresh:0}}(jQuery);
!function(e){e.extend(jQuery.easing,{easeOutBack:function(e,t,n,a,o,i){return null==i&&(i=1.70158),a*((t=t/o-1)*t*((i+1)*t+i)+1)+n}}),e.fn.scrollThumbs=function(t){return t=e.extend({},e.fn.scrollThumbs.defaults,t),this.each(function(){var n,a,o,i,s,r,l,d,c,u=e(this),p=u.parent(),h=0,f=e("<div>",{"class":t.scleft}).insertAfter(p),m=e("<div>",{"class":t.scright}).insertAfter(p),g=function(e){e=null==e?u.position().left:e,f.css({opacity:0>e?1:t.disabledOpacity}),m.css({opacity:p.width()<e+u.width()?1:t.disabledOpacity})},v=function(n){var a=p.width(),o=u.width();a&&o&&!(a>=o)&&e.isNumeric(n)&&(n>0?n=0:a-o>n&&(n=a-o),g(n),u.stop(!0,!1),clearInterval(d),u.animate({left:n},t.speed,t.effect),p.loadImages({left:n}))},b=function(e){return e.preventDefault(),y(),v(u.position().left+p.width()),!1},w=function(e){return e.preventDefault(),y(),v(u.position().left-p.width()),!1};f.on("click",b),m.on("click",w);var y=function(e){"number"==typeof c&&clearTimeout(c),c="undefined"!=typeof e?e:setTimeout(function(){c=!1},t.seekStay)},T=function(){if(!u.data("dragOn")&&!c){var e=u.find(t.active).closest("li");if(e.length){var n=e.position().left,a=e.outerWidth(!0),o=Math.round(a*t.headRoom),i=u.position().left,s=p.width();if(s>u.width())return;if(n>s-a-o-i)i=Math.max(s-a-o-n,s-u.width());else{if(!(-i+o>n))return;i=-n+o}v(i)}}};u.on("setactive",T);var k=function(e,t){return e.preventDefault(),t&&(u.stop(!0,!1),clearInterval(d),y(),v(u.position().left+p.width()*(0>t?-1:1))),!1};t.enableMouseWheel&&u.on("mousewheel",k),g();var x=function(e){return h=e.touches&&e.touches.length>0?e.touches[0].clientX:e.clientX?e.clientX:h},S=function(){r+=Math.round(s/20);var e=i+r;return e>0||l>e?(clearInterval(d),void 0):(u.css({left:e}),s*=.8,Math.abs(s)<10&&(s=0,clearInterval(d)),void 0)},I=function(e){if(e.preventDefault(),a){var t=x(e)-a;t&&(u.data("dragOn",!0),u.css({left:Math.minMax(l,n+t,0)}))}else a=x(e);return!1},M=function(t){t.preventDefault(),i=u.position().left;var n=x(t)-a,r=(new Date).getTime()-o;return s=1e3*n/r,d=setInterval(S,50),y(),document.touchMode?(u[0].removeEventListener(TOUCH_MOVE,I),u[0].removeEventListener(TOUCH_END,M),Math.abs(n)<10&&e(t.target).parents("a").trigger("click")):e(document).off({mousemove:I,mouseup:M}),setTimeout(function(){u.data("dragOn",!1)},20),p.loadImages(),Math.abs(n)<4&&300>r},C=function(t){return t.preventDefault(),"touchstart"!==t.type&&"touchmove"!==t.type||!(!t.touches||t.touches.length>1||u.is(":animated"))?(u.stop(!0,!1),clearInterval(d),y(!0),n=u.position().left,a=x(t),o=(new Date).getTime(),r=0,l=p.width()-u.width(),l>=0?!0:(document.touchMode?(e(t.target).closest("a").focus(),u[0].addEventListener(TOUCH_MOVE,I),u[0].addEventListener(TOUCH_END,M)):e(document).on({mousemove:I,mouseup:M}),!1)):!0};document.touchMode?u[0].addEventListener(TOUCH_START,C):u.on("mousedown",C),u.attr("role","scroll").data("dragOn",!1),u.add(f).add(m).on("selectstart",noAction),p.loadImages()})},e.fn.scrollThumbs.defaults={active:".active",scleft:"scleft",scright:"scright",seekStay:3e3,speed:1500,incr:100,effect:"easeOutBack",headRoom:.67,disabledOpacity:.3,enableMouseWheel:!0}}(jQuery);
!function(e){e.extend(jQuery.easing,{easeOutCubic:function(e,t,n,i,o){return i*((t=t/o-1)*t*t+1)+n}}),e.fn.addSwipe=function(t,n,i){return i=e.extend({},e.fn.addSwipe.defaults,i),this.each(function(){var o,r,u,a,d,s,c,l,f=e(this),h=f.parent(),v=this,g=0,m=0,p=h.outerWidth(),w=h.outerHeight(),T=f.outerWidth(),O=f.outerHeight(),E=function(){p=h.outerWidth(),w=h.outerHeight()};e(window).on("resize.addswipe",function(){clearTimeout(r),r=setTimeout(E,50)});var H=function(e){return v.dragOn?!1:void e.target.trigger("click",e)},C=function(e){l?(s=(e.touches&&e.touches.length>0?e.touches[0].clientX:e.clientX)-a,f.translate(g+s,0)):(e.touches&&e.touches.length>0?(s=e.touches[0].clientX-a,c=e.touches[0].clientY-d):null!==e.clientX&&(s=e.clientX-a,c=e.clientY-d),f.translate(g+s,m+c))},_=function(){return Y(),v.removeEventListener(TOUCH_MOVE,L),v.removeEventListener(TOUCH_END,_),!1},D=function(t){return t.preventDefault(),Y(),e(document).off("mousemove.addswipe mouseup.addswipe"),!1},L=function(e){return e.preventDefault(),C(e),!1},U=function(e){return e.preventDefault(),C(e.originalEvent),!1},X=function(e){if(e.touches){if(e.touches.length>1)return!0;a=e.touches[0].clientX,d=e.touches[0].clientY}else a=e.clientX,d=e.clientY;return W(),v.addEventListener(TOUCH_MOVE,L),v.addEventListener(TOUCH_END,_),!0},M=function(e){a=e.originalEvent.clientX,d=e.originalEvent.clientY},S=function(t){return t.preventDefault(),M(t),W(),f.on("click.addswipe",H),e(document).on({"mousemove.addswipe":U,"mouseup.addswipe":D}),!1},W=function(){f.removeClass("smooth"),v.dragOn=!0,u=(new Date).getTime(),p=p||h.outerWidth(),T=f.outerWidth(),O=f.outerHeight(),l=w>=O,g=f.data("tr_x")||0,m=l?0:f.data("tr_y")||0,s=c=0,o=T>p?Math.round((T-p*(1-i.oversizeTreshold))/2):0},Y=function(){if(l&&!o&&Math.abs(s)<i.treshold)v.dragOn=null,f.translate(0,0),f.trigger("click");else{var r=(new Date).getTime()-u,a=g+s+300*s/r,d=l?0:m+c+300*c/r;f.translate(a,d,"smooth"),-o>a?e.isFunction(t)&&t.call(v):a>o&&e.isFunction(n)&&n.call(v)}return setTimeout(function(){v.dragOn=null},100),!1};f.attr("draggable","true"),document.touchMode?v.addEventListener(TOUCH_START,X):f.on({"dragstart.addswipe":S,"mousedown.addswipe":M});var b=function(){return setTimeout(function(){v.dragOn=null},20),f.translate(0,0,"smooth"),!1};f.on("dragcancel.addswipe",b);var A=function(){setTimeout(function(){v.dragOn=null},20),f.removeAttr("draggable"),document.touchMode?(v.removeEventListener(TOUCH_MOVE,L),v.removeEventListener(TOUCH_END,_),v.removeEventListener(TOUCH_START,X)):(f.off(".addswipe"),e(document).off(".addswipe"))};f.on("unswipe.addswipe",A),f.on("selectstart.addswipe",noAction)})},e.fn.addSwipe.defaults={treshold:40,oversizeTreshold:.25,margin:15}}(jQuery);
!function(e){e.fn.addPlayer=function(a){if("undefined"!=typeof e.fn.jPlayer){a=e.extend({},e.fn.addPlayer.defaults,a);var t=getTranslations(e.fn.addPlayer.text),i=navigator.userAgent.indexOf("Firefox")>=0&&navigator.platform.indexOf("Mac")>=0,n={cont:"jp-cont",mini:"jp-mini",audio:"jp-audio",video:"jp-video",playerType:"jp-type-single",player:"jp-jplayer",title:"jp-title",progress:"jp-progress",controls:"jp-controls-holder",startStop:"jp-startstop",volume:"jp-volume",times:"jp-times",toggles:"jp-toggles",warning:"jp-warning",videoPlay:"jp-video-play",play:"jp-play",pause:"jp-pause",stop:"jp-stop",seekBar:"jp-seek-bar",playBar:"jp-play-bar",mute:"jp-mute",unmute:"jp-unmute",volumeBar:"jp-volume-bar",volumeBarValue:"jp-volume-bar-value",volumeMax:"jp-volume-max",currentTime:"jp-current-time",duration:"jp-duration",fullScreen:"jp-full-screen",restoreScreen:"jp-restore-screen",repeat:"jp-repeat",repeatOff:"jp-repeat-off",gui:"jp-gui",noSolution:"jp-no-solution",playing:"playing"},o=function(e){var a,i=function(e){return'<a class="'+n[e]+'" title="'+t[e]+'">'+t[e]+"</a>"};return a='<div class="'+n.progress+'"><div class="'+n.seekBar+'"><div class="'+n.playBar+'"></div></div></div>',a+='<div class="'+n.controls+'">',a+='<div class="'+n.startStop+'">'+i("play")+i("pause")+i("stop")+"</div>",a+='<div class="'+n.volume+'">'+i("mute")+i("unmute")+'<div class="'+n.volumeBar+'"><div class="'+n.volumeBarValue+'"></div></div></div>',a+='<div class="'+n.times+'"><div class="'+n.currentTime+'"></div><div class="'+n.duration+'"></div></div>',a+='<div class="'+n.toggles+'">'+(e?"":i("fullScreen")+i("restoreScreen"))+i("repeat")+i("repeatOff")+"</div>",a+="</div>"},r=function(e){var a=e.css("paddingTop"),t=e.css("paddingLeft"),i=e.css("paddingRight"),o=e.css("paddingBottom");e.find("."+n.gui).css({bottom:o,left:t,right:i}),e.find("."+n.title).css({top:a,left:t,right:i})},s=function(a,i,s){"absolute"!==a.css("position")&&"fixed"!==a.css("position")&&a.css({position:"relative"}),a.css({overflow:"hidden"});var l,d=e('<div class="'+(s?n.audio:n.video)+'"></div>').appendTo(a);return d=e('<div class="'+n.playerType+'"></div>').appendTo(d),l=e('<div class="'+n.player+'"></div>').appendTo(d),d.append('<div class="'+n.videoPlay+'"><a>'+t.play+"</a></div>"),i&&d.append('<div class="'+n.title+'"><ul><li>'+i+"</li></ul></div>"),d.append('<div class="'+n.gui+'">'+o(s)+"</div>"),!document.touchMode&&a.hasClass(n.fullScreen)&&d.find("."+n.gui).hide(),a.append('<div class="'+n.noSolution+'">'+t.unsupportedMediaFormat+"</div>"),r(a),l},l=function(){var a;return(a=e(this).data("media"))&&a.jPlayer("pause"),!1},d=function(){var a;return(a=e(this).data("media"))&&a.jPlayer("destroy"),e(window).off("keydown",f),!1},p=function(){var a;return(a=e(this).data("media"))&&a.jPlayer("stop"),!1},u=function(){var a;return(a=e(this).data("media"))&&a.jPlayer("play"),!1},c=e(this).eq(0),f=function(e){if(document.activeElement&&("INPUT"===document.activeElement.nodeName||"TEXTAREA"===document.activeElement.nodeName))return!0;var a=e?e.keyCode:window.event.keyCode;return 32===a?(c.find("."+n.player).jPlayer(c.data(n.playing)?"pause":"play"),!1):!0},v=function(e){return a.hasOwnProperty("audio")?a.audio:".mp3.m4a.f4a.rtmpa".indexOf(e.getExt())>0},m=function(){return e("."+n.cont).each(function(){return e(this).data(n.playing)?!0:void 0}),!1},y=function(e){var a,t=v(e)?"a":"v";switch(e.getExt()){case"mp3":a="mp3";break;case"mp4":a="m4"+t;break;case"ogg":a="og"+t;break;case"webm":a="webm"+t;break;case"flv":case"f4a":case"f4v":a="fl"+t;break;case"rtmp":a="rtmp"+t;break;default:a=null}return a};return this.each(function(){var o,r,c,h,g,j,w,P,b,k,S=e(this),T=a.folder||"",x=0;if(a.elem){b=e(this).find(a.elem),w=b.attr("title");var F=b.find("img:first");F.length?(j=F.data("link"),P=F.data("poster")||F.attr("src"),w||(w=F.attr("alt"))):(j=b.attr("href"),P=w="")}else j=a.src,w=a.title||"",P=a.poster||"",b=e('<a href="'+j+'"'+(w?' title="'+w+'"':"")+">"+(P?'<img src="'+P+'">':"")+"</a>").appendTo(e(this));if(LOCAL){var O=e('<div class="'+n.warning+'">'+t.localFlashWarning+"</a></div>").appendTo(b);b.css("position","relative"),O.hide(),setTimeout(function(){O.fadeIn()},2e3)}if(j){c=a.auto&&!a.lowPriority&&!m(),j.indexOf("::")>0?(j=j.split("::"),o=v(j[0]),r=y(j[0])):(o=v(j),r=y(j)),this.id||(this.id=a.id+e.fn.addPlayer.id++),g="#"+this.id,e(S).addClass(n.cont),a.mini&&e(S).addClass(n.mini),k=s(S,a.showTitle?w:"",o);var I=function(){var t,i,n={},o=a.relativeUrl?"":location.href.substring(0,location.href.lastIndexOf("/")+1);return e.isArray(j)?(x>=j.length&&(x=0),t=j[x]):(t=j,P&&(n.poster=(o+T+P).fixUrl())),i=y(t),n[i]=(o+T+t).fixUrl(),n},M=function(){if(e.cookie){var a=S.find("."+n.currentTime).text().split(":");a=a.length>2?60*(60*parseInt(a[0],10)+parseInt(a[1],10))+parseInt(a[2],10):60*parseInt(a[0],10)+parseInt(a[1],10),e.cookie("jp_"+S[0].id,(S.data(n.playing)?"1":"0")+"::"+a+"::"+k.jPlayer("option","volume").toString().substring(0,5)+(x?"::"+x:""))}},B=function(a){if(e.cookie){var t=e.cookie("jp_"+a[0].id);if(t)return t=t.split("::"),{playing:"1"===t[0],time:parseInt(t[1]||0,10),volume:parseFloat(t[2]||.8),curr:parseInt(t[3]||0,10)}}return null};h=!o&&!i,S.on("setEndedFn",function(t,i){a.ended=i&&e.isFunction(i)?i:null}),k.jPlayer({cssSelectorAncestor:g,backgroundColor:a.backgroundColor,supplied:r,swfPath:a.resPath+"/"+a.swf,solution:a.solution,size:{width:"100%",height:"100%"},fullWindow:!o&&a.fullScreen,preload:"auto",loop:a.loop,volume:a.volume,autohide:{restored:h,full:h},ready:function(){var t=e(this),i=a.saveStatus?B(S):null;S.data("media",t),a.saveStatus&&(e(window).on("unload",M),i&&(x=i.curr));var n=I();b&&b.hide(),t.jPlayer("setMedia",n),S.on({play:u,pause:l,stop:p,destroy:d}),a.saveStatus&&i?(t.jPlayer("volume",i.volume),t.jPlayer(i.playing?"play":"pause",i.time)):a.auto&&!document.touchMode&&t.jPlayer("play"),a.lowPriority||e(window).on("keydown",f)},play:function(){e(this).jPlayer("pauseOthers"),S.data(n.playing,!0),document.touchMode&&settimeout(function(){S.find("."+n.title).fadeOut(1e3)},600),e.isFunction(a.play)&&a.play.call()},pause:function(){S.data(n.playing,!1),e.isFunction(a.pause)&&a.pause.call()},stop:function(){S.data(n.playing,!1),document.touchMode&&S.find("."+n.title).fadeIn(300),e.isFunction(a.stop)&&a.stop.call()},ended:function(){e.isArray(j)&&(x+1<j.length||a.loop)?(x=(x+1)%j.length,e(this).jPlayer("setMedia",I()),a.auto&&e(this).jPlayer("play")):S.data(n.playing,!1),e.isFunction(a.ended)&&a.ended.call()}})}})}},e.fn.addPlayer.id=0,e.fn.addPlayer.defaults={id:"jp_container_",backgroundColor:"#000000",resPath:"",swf:"Jplayer.swf",relativeUrl:!1,solution:"html,flash",volume:.8,auto:!1,loop:!1,keyboard:!0,lowPriority:!1,saveStatus:!1,mini:!1,fullScreen:!1,showTitle:!1,size:{width:"100%",height:"100%"}},e.fn.addPlayer.text={play:"play",pause:"pause",stop:"stop",mute:"mute",unmute:"unmute",fullScreen:"full screen",restoreScreen:"restore screen",repeat:"repeat",repeatOff:"repeat off",localFlashWarning:"Local Flash playback is possibly blocked by Flash security rules. Test videos in the uploaded album!",unsupportedMediaFormat:'<span>Unsupported media format</span>You might need to either update your browser or the <a href="http://get.adobe.com/flashplayer/" target="_blank">Flash plugin</a> or use another browser to play this media.'}}(jQuery);
!function(e){e.getLatLng=function(e){return"undefined"==typeof google||null==e?null:"string"==typeof e?(e=e.split(","),new google.maps.LatLng(parseFloat(e[0])||0,parseFloat(e[e.length-1])||0)):new google.maps.LatLng(e[0],e[1])},e.fn.addMap=function(t){if("undefined"==typeof google||!google.maps)return this;t=e.extend({},e.fn.addMap.defaults,t);var n=t.resPath+"/marker-curr.png",o=t.resPath+"/marker.png",i=new google.maps.MarkerImage(n,new google.maps.Size(17,24),new google.maps.Point(0,0),new google.maps.Point(8,24)),a=new google.maps.MarkerImage(o,new google.maps.Size(17,24),new google.maps.Point(0,0),new google.maps.Point(8,24)),r=new google.maps.MarkerImage(t.resPath+"/marker-shadow.png",new google.maps.Size(24,24),new google.maps.Point(0,0),new google.maps.Point(8,24));return this.each(function(){var s,l,d,c,u,p,h,f=e(this),g=[];f.readData(t,"type,zoom,map,label,resPath,markers");var m=function(){f&&f.data("fresh")&&(d&&f.is(":visible")&&!f.parents(":hidden").length&&f.width()&&f.height()?(clearTimeout(u),f.width(f.parent().width()),google.maps.event.trigger(d,"resize"),d.setCenter(s),f.data("fresh",!1)):u=setTimeout(m,200))};if(c&&c.length&&c.remove(),c=e("<div>").css({position:"absolute",top:"-9000px",width:f.width(),height:f.height()}).appendTo("body"),f.data("fresh",!0).on({adjust:m,destroy:function(){d.getParentNode().removeChild(d),e(window).off("resize",m)}}),t.markers&&t.markers.length&&null!=t.curr)s=t.markers[t.curr].map;else{if(!t.map)return;s=e.getLatLng(t.map),l=t.label}null!==(p=e.cookie("mapType"))&&(t.type=p),null!==(p=e.cookie("mapZoom"))&&(t.zoom=parseInt(p,10)||t.zoom),setTimeout(function(){var u,p=new google.maps.Map(c[0],{zoom:t.zoom,center:s,scrollwheel:!1,mapTypeId:t.type.toLowerCase()});if(google.maps.event.addListener(p,"maptypeid_changed",function(){e.cookie("mapType",e.fn.addMap.defaults.type=p.getMapTypeId(),3600)}),google.maps.event.addListener(p,"zoom_changed",function(){e.cookie("mapZoom",e.fn.addMap.defaults.zoom=p.getZoom(),3600)}),t.markers&&t.markers.length>1){var m,v,w,b=Math.max(t.curr-t.range,0),y=Math.min(t.curr+t.range,t.markers.length),T=function(){t.click.call(this)};for(m=b;y>m;m++)w=t.markers[m],v={position:w.map,map:p,title:w.label,icon:m===t.curr?i:a,shadow:r,zIndex:m===t.curr?999:m},u=new google.maps.Marker(v),e.isFunction(t.click)&&w.link&&(u.link=w.link,google.maps.event.addListener(u,"click",T)),g.push(u)}else u=new google.maps.Marker(e.extend({position:s,map:p,title:l},n));c.css({top:0}).appendTo(f),d=p,h=t.curr,f.on("setactive",function(t,i){e.isArray(g)&&g.length&&(h>=b&&(g[h].setIcon(o),g[h].setZIndex(h)),"undefined"!=typeof i&&i>=b&&i<b+g.length?(g[i-b].setIcon(n),g[i-b].setZIndex(9999),d.setCenter(g[i-b].position),h=i):h=-1)})},20),e(window).on("resize",function(){clearTimeout(u),f.data("fresh",!0),u=setTimeout(m,100)})})},e.fn.addMap.defaults={type:"roadmap",zoom:16,range:30,resPath:""}}(jQuery);
!function(e){e.fn.addShop=function(t,n){if(n=e.extend({},e.fn.addShop.defaults,n),!t||!t.length||!n.id)return this;var o,i,a,r,d,p,s="undefined",c=e.fn.addShop.id,l=e.fn.addShop.text,u=n.id.replace("|","@"),h=DEBUG?e.fn.addShop.st.sandboxurl:e.fn.addShop.st.url,m=e.fn.addShop.st.curr_symbol[n.currency]||n.currency,f=(e.fn.addShop.st.btn_lng[n.locale]||"en_US",e(this).eq(0)),g=t.length,y=g>1?e.fn.addShop.st.targetCart:e.fn.addShop.st.target,b=function(e){var t,n,o,i,a=e.split("::"),r=[];for(t=0;t<a.length;t++)if(n=a[t].split("="),n.length>1){if(i={},i.label=n[0],o=n[1].split("+"),null==(i.price=parseFloat(o[0])))continue;i.shipping=o.length>1?parseFloat(o[1]):0,i.shipping2=o.length>2?parseFloat(o[2]):i.shipping,i.text=n[0]+" = "+m+" "+i.price.toFixed(2)+(o.length>1?"+"+i.shipping.toFixed(2):""),r.push(i)}return r},v=function(t,n){var o,i=e("<select>").appendTo(t);for(o=0;o<n.length;o++)i.append(e("<option>",{val:n[o].price,html:n[o].text}));return i},_=function(t,n,o,i,a){if(!t||!n)return{};var r=e("<input>",{type:i||"text"}).appendTo(t);return r.prop("name",n),o&&r.val("string"==typeof o?o.stripQuote():o),a&&r.prop(a,!0),r},w=function(e){return typeof e===s?x(g>1?c.discountRateCart:c.discountRate):void(g>1?x(c.discountRateCart,e):(x(c.discountRate,e),x(c.discountRate+"2",e)))},C=function(e){return typeof e===s?x(g>1?c.discountAmountCart:c.discountAmount):void x(g>1?c.discountAmountCart:c.discountAmount,e)},S=function(e,t){var n=i.children("[name="+c.option+"]");if(n&&n.length){var o=n.val().replace(/(\s\(CC\:.+\))$/,"");n.val(o+" (CC:"+e+(typeof t!==s?"="+t:"")+")")}},x=function(e,t){var n=i.children("[name="+e+"]");return typeof t===s?n&&n.length?parseFloat(n.val()):null:void(null==t?n.remove():n&&n.length?n.val(t):_(i,e,t,"hidden"))},T=function(){var e=o.children("select").eq(0);return e&&e.length?e.prop("selectedIndex"):0},R=function(){var t=T(),n=o.children(".discount").eq(0),i=o.children(".total").eq(0),a=o.children("[name=copies]").val()||1,r=p[t].price,d=p[t].shipping+(a-1)*p[t].shipping2,s=C(),c=w();n.length||(n=e("<span>",{"class":"discount"}).insertAfter(o.children("select"))),s&&s>0?(n.show().html("- "+m+" "+s.toFixed(2)),i.html(m+" <b>"+(g*(a*r+d)-s).toFixed(2)+"</b>")):c&&c>0?(n.show().text("-"+c+"%"),i.html(m+" <b>"+(g*(a*r*(100-c)/100+d)).toFixed(2)+"</b>")):(n.hide(),i.html(m+" <b>"+(g*(a*r+d)).toFixed(2)+"</b>"))},F=function(){var e=T(),t=o.children("[name=copies]").val()||1,i=p[e].price,a=p[e].shipping,r=p[e].shipping2;if(n.quantityCap&&t>n.quantityCap&&o.children("[name=copies]").val(t=n.quantityCap),g>1)for(var d=1;g>=d;d++)x(c.price+"_"+d,i),x(c.copies+"_"+d,t),x(c.shipping+"_"+d,a?a:null),x(c.shipping2+"_"+d,r?r:null);else x(c.price,i),x(c.copies,t),x(c.shipping,a?a:null),x(c.shipping2,r?r:null);x(c.option,p[e].text),R()},U=function(t){var i,a,d=new Date,s=t===!0;if(n.coupons&&(i=o.children("[name=coupon]"))&&(a=i.val().trim()).length){var c,u,h,f=xDecrypt(n.coupons).split("::");for(c=0;c<f.length;c++)if(u=f[c].split(/=|\s*<\s*/),u[0]===a&&u.length>1){if(h=parseFloat(u[1]),.01>h)continue;if(u.length>2){var y,b=u[2].split(/-|:|\//);if(b.length<2&&(b[1]=1),b.length<3&&(b[2]=1),y=new Date(parseInt(b[0]),parseInt(b[1]),parseInt(b[2])),d>y)return e("body").addModal(e("<div>",{html:l.expired.replace("{0}",a)}),{type:"error"}),!1}if("%"===u[1].charAt(u[1].length-1)){if(h>99||1>h)continue;var v=w();v>h?s&&e("body").addModal(e("<div>",{html:l.lowerThanCurrent.replace("{0}",v+"%")}),{type:"warning"}):(s&&e("body").addModal(e("<div>",{html:l.accepted.replace("{0}",h+"%")}),{title:l.success}),w(h),S(a,h+"%"),e.cookie("discountRate",a,86400))}else if(e.cookie("discount_"+a))s&&e("body").addModal(e("<div>",{html:l.reclaimed}),{type:"warning"}),C(null),r&&(w(r),S(a,r+"%"));else{var v=w(),_=p[T()].price,x=C()||(v>0?g*_*v/100:0);h>_*g?s&&e("body").addModal(e("<div>",{html:l.higherThanPrice.replace("{0}",m+"&nbsp;"+h)}),{type:"warning"}):x>h?s&&e("body").addModal(e("<div>",{html:l.lowerThanCurrent.replace("{0}",m+"&nbsp;"+x.toFixed(2))}),{type:"warning"}):(s?e("body").addModal(e("<div>",{html:l.accepted.replace("{0}",m+"&nbsp;"+h)}),{title:l.success}):(e.cookie("discount_"+a,h,86400),r=w(),w(null)),C(h),S(a,n.currency+" "+h))}return R(),!0}return e("body").addModal(e("<div>",{html:l.noSuch}),{type:"error"}),!1}return!0};if(p=b(n.options),p.length){if(o=e("<form>",{name:"shopping",method:"post"}).appendTo(f),g>1&&o.append(e("<span>",{"class":"count",html:"<b>"+g+"</b> &times;"})),d=v(o,p),d.on("change",F),n.hasOwnProperty("discount")||(n.discount=e.fn.addShop.defaults.discount||0),"-"===n.discount&&(n.discount=0),1!==n.quantityCap&&(o.append("&times;"),d=_(o,"copies",1),d.addClass("copies").on("change",F)),o.append("="),o.append(e("<span>",{"class":"total"})),n.coupons){o.append(e("<input>",{type:"text",name:"coupon","class":"coupon",placeholder:l.couponCode}));var q=e("<a>",{html:"&nbsp;","class":"redeem"}).on("click",function(e){return e.preventDefault(),U(!0),!1});document.touchMode||q.addTooltip(l.redeem),o.append(q)}if(i=e("<form>",{name:c.form,target:y,action:h+"cgi-bin/webscr/",method:"post"}).appendTo(f),x("cmd","_cart"),x("charset","utf-8"),x("lc",n.locale),x(c.seller,u),x(c.currency,n.currency),x(c.shopUrl,n.continueUrl||decodeURIComponent(window.location.href)),null!=n.handling&&e.isNumeric(n.handling)&&x(c.handlingCart,n.handling),x(c.option,p[0].label),n.discount&&n.discount<100&&w(n.discount),g>1){x("upload",1),x(c.name,g+" "+l.items);var A;t.each(function(t){d=e(this).find("img:first"),A=d.data("src")||d.attr("src")||"",x(c.name+"_"+(t+1),decodeURIComponent(A.getFile()+" ["+n.path+A.getDir().replace("thumbs/","")+"]"))})}else x("add",1),d=t.eq(0).find("img:first"),x(c.name,decodeURIComponent((d.data("src")||d.attr("src")||"").getFile()+" ["+n.path+"]"));if(F(),i.append(e("<button>",{id:"shopAdd",name:"submit","class":"paypalbtn",html:g>1?l.buyNow:l.addCart})),i.on("submit",function(t){var o=!0,i=e(t.target);return n.coupons&&(o=U()),o?(i.parents("[role=modal]").trigger("destroy"),n.continueUrl||window.open("",y,"width=1024,height=600,scrollbars=yes,resizable=yes,menubar=no,toolbar=no,directories=no,status=no,copyhistory=no"),!0):o}),n.coupons){var D=e.cookie("discountRate");D&&(e("input[name=coupon]").val(D),U(!1))}return 1===g&&(a=e("<form>",{"class":"view",name:"paypalview",target:y,action:h+"cgi-bin/webscr/",method:"post"}).appendTo(f),_(a,"cmd","_cart","hidden"),_(a,"lc",n.locale,"hidden"),_(a,c.seller,u,"hidden"),_(a,"display",1,"hidden"),a.append(e("<button>",{id:"shopView","class":"paypalbtn",name:"submit",html:l.viewCart})),n.continueUrl||a.on("submit",function(){return window.open("",y,"width=1024,height=600,scrollbars=yes,resizable=yes,menubar=no,toolbar=no,directories=no,status=no,copyhistory=no"),!0})),R(),this}},e.fn.addShop.defaults={currency:"EUR",locale:"US",quantityCap:0,shippingFlat:!1},e.fn.addShop.text=getTranslations({addCart:"Add to Cart",viewCart:"View Cart",buyNow:"Buy Now",items:"items",success:"Success",couponCode:"Coupon code",redeem:"Redeem",noSuch:"No such coupon exists!",expired:"The coupon code <b>{0}</b> has expired!",accepted:"The coupon code is accepted. You will get <b>{0}</b> discount the next time you add this item to the cart.",lowerThanCurrent:"This coupon offers lower discount than the current <b>{0}</b>.",higherThanPrice:"You can use this coupon only for items priced higher than <b>{0}</b>.",reclaimed:"This coupon has already been used!"}),e.fn.addShop.st={target:"ShoppingCart",targetCart:"BuyNow",url:"https://www.paypal.com/",sandboxurl:"https://www.sandbox.paypal.com/",btn_lng:{DE:"de_DE",FR:"fr_FR",IT:"it_IT",ES:"es_ES",PT:"pt_PT",PT:"pt_BR",DA:"da_DK",NL:"nl_NL",NO:"no_NO",SV:"sv_SE",TR:"tr_TR",RU:"ru_RU",PL:"pl_PL",IL:"he_IL",TH:"th_TH"},curr_symbol:{USD:"US$",EUR:"&euro;",GBP:"GB&pound;",JPY:"&yen;",HUF:"Ft"}},e.fn.addShop.id={form:"paypal",seller:"business",currency:"currency_code",name:"item_name",option:"item_number",custom:"custom",price:"amount",priceCart:"amount_1",copies:"quantity",discountRate:"discount_rate",discountRateCart:"discount_rate_cart",discountAmount:"discount_amount",discountAmountCart:"discount_amount_cart",shipping:"shipping",shipping2:"shipping2",handlingCart:"handling_cart",shopUrl:"shopping_url"}}(jQuery);
!function(e){var t="",a="",i="";e.fn.addSocial=function(o){o=e.extend({},e.fn.addSocial.defaults,o);var n=0===location.protocol.indexOf("file:"),l=getTranslations(e.fn.addSocial.text),s=window.location.href.split("#")[0]+(o.useHash?"#"+encodeURIComponent(o.hash||""):""),p=encodeURIComponent(window.location.href.split("#")[0])+(o.useHash?"#"+encodeURIComponent(o.hash||""):""),r=encodeURIComponent(o.title||e("meta[name=title]").attr("content")||e("title").text()),d=encodeURIComponent(l.checkOutThis),c=o.inline?90:o.width,u=22,h=o.image?window.location.href.getDir()+o.image:e("link[rel=image_src]").attr("href");return this.each(function(){var m=e(this),b=e("<div>",{"class":o.className});if(n&&!DEBUG)b.html(l.localWarning);else{if(!n){if(!o.useHash){if(o.facebookLike&&b.append('<div class="likebtn"><iframe src="https://www.facebook.com/plugins/like.php?href='+s+"&amp;layout=button_count&amp;show_faces=false&amp;width="+c+"&amp;action=like&amp;font=arial&amp;colorscheme="+o.likeBtnTheme+"&amp;height="+u+'" scrolling="no" frameborder="0" style="border:none;overflow:hidden;width:'+c+"px;height:"+u+'px;" allowTransparency="true"></iframe></div>'),o.twitterTweet&&b.append('<div class="likebtn"><iframe allowtransparency="true" frameborder="0" scrolling="no" src="//platform.twitter.com/widgets/tweet_button.html?url='+s+"&text="+r+'" style="width:'+c+"px; height:"+u+'px;"></iframe></div>'),o.googlePlus){var f=o.inline?90:120,g=e('<div class="likebtn" style="max-width:'+f+"px;min-width:"+f+'px;"><div class="g-plusone" data-href="'+s+'"></div></div>').appendTo(b),w=20,k=function(){"undefined"==typeof gapi?w--?setTimeout(k,200):"console"in window&&console.log("Google Plus API failed to load!"):setTimeout(function(){gapi.plusone.render(g[0],{size:"medium",annotation:"bubble"})},200)};k()}o.pinItBtn&&b.append('<div class="likebtn" style="height:'+u+'px;"><a data-pin-config="beside" href="//pinterest.com/pin/create/button/?url='+p+"&media="+encodeURIComponent(h)+"&description="+r+'" data-pin-do="buttonPin" ><img src="http://assets.pinterest.com/images/pidgets/pin_it_button.png" /></a></div>')}o.tumblrBtn&&(b.append('<div class="likebtn" id="tumblr"><a href="//www.tumblr.com/share/'+(o.image?"photo?source=":"link?url=")+encodeURIComponent(s)+"&name="+r+'" title="Share on Tumblr" style="display:inline-block;text-indent:-9999px;overflow:hidden;width:'+c+"px;height:"+u+'px;background:url(http://platform.tumblr.com/v1/share_1.png) top left no-repeat transparent;">Tumblr</a></div>'),t=h,a=r,i=s)}(o.facebook||o.twitter||o.gplus||o.pinterest||o.digg||o.delicious||o.myspace||o.stumbleupon||o.reddit||o.email)&&(o.buttonLabels||b.append("<span>"+l.shareOn+"</span>"),o.facebook&&!o.useHash&&b.append('<a href="http://www.facebook.com/sharer.php?s=100&p%5Burl%5D='+p+"&p%5Bimages%5D%5B0%5D="+h+"&p%5Btitle%5D="+r+'" class="facebook"'+(o.buttonLabels?">Facebook":' title="Facebook">')+"</a>"),o.twitter&&b.append('<a href="http://twitter.com/home?status='+d+": "+p+'" class="twitter"'+(o.buttonLabels?">Twitter":' title="Twitter">')+"</a>"),o.gplus&&!o.useHash&&b.append(e("<a>",{"class":"gplus",href:"https://plus.google.com/share?url="+p,title:"Google+",text:o.buttonLabels?"Google+":""}).on("click",function(){return window.open(this.href,this.title,"menubar=no,toolbar=no,resizable=yes,scrollbars=yes,height=760,width=980"),!1})),o.pinterest&&b.append('<a href="http://pinterest.com/pin/create/button/?url='+p+"&media="+encodeURIComponent(h)+"&description="+r+'" class="pinterest"'+(o.buttonLabels?">Pinterest":' title="Pinterest">')+"</a>"),o.digg&&b.append('<a href="http://digg.com/submit?url='+s+'" class="digg"'+(o.buttonLabels?">Digg":' title="Digg">')+"</a>"),o.delicious&&b.append('<a href="http://delicious.com/save?url='+s+"&title="+r+'&v=5" class="delicious"'+(o.buttonLabels?">Delicious":' title="Delicious"')+"</a>"),o.myspace&&b.append('<a href="http://www.myspace.com/index.cfm?fuseaction=postto&t='+r+"&u="+s+'&l=3" class="myspace"'+(o.buttonLabels?">MySpace":' title="MySpace"')+"</a>"),o.stumbleupon&&b.append('<a href="http://www.stumbleupon.com/submit?url='+s+"&title="+r+'" class="stumbleupon"'+(o.buttonLabels?">StumbleUpon":' title="StumbleUpon">')+"</a>"),o.reddit&&b.append('<a href="http://www.reddit.com/submit?url='+s+'" class="reddit"'+(o.buttonLabels?">Reddit":' title="Reddit"')+"</a>"),b.children("a").attr("target","_blank"),o.email&&b.append('<a href="mailto:?subject='+d+"&body="+r+"%0D%0A"+s.replace(/%/g,"%25")+'" class="email"'+(o.buttonLabels?">Email":' title="Email">')+"</a>"),o.buttonLabels||document.touchMode||b.children("a").addTooltip())}m.on("destroy",function(){b.remove()}),b.not(":empty")&&(o.inline?b.appendTo(m):m.addTooltip(b,{width:o.width,stay:5e3,pos:o.pos}))})},e.fn.addSocial.defaults={className:"shares",width:120,useHash:!0,likeBtnTheme:"light",inline:!1,buttonLabels:!0,pos:[1,2,1,0]},e.fn.addSocial.text={shareOn:"Share on",checkOutThis:"Found this page",localWarning:"Can't share local albums. Please upload your album first!"}}(jQuery);
var fixFbComments=function(e){var t=window.location.href;-1===t.indexOf("?fb_")?(t=t.split("#")[0],e&&"/"===t[t.length-1]&&(t+=e)):t=t.split("?")[0],document.getElementById("fb-comments").setAttribute("data-href",t)},initMobile=function(){if(!(!/Mobile/.test(navigator.userAgent)||screen.width>980||screen.height>980||window.innerWidth!==document.documentElement.clientWidth&&window.innerWidth-1!==document.documentElement.clientWidth)){var e=function(){return Object.prototype.hasOwnProperty.call(window,"pageYOffset")&&window.scrollTo(0,window.pageYOffset+1),!0};setTimeout(function(){e()},1e3),$(window).on("orientationchange",e)}};!function(e){e.fn.readData=function(t,n){if(null==t||null==n)return this;n=n.split(",");var a,i,o=n.length;return this.each(function(){for(a=0;o>a;a++)null!=(i=e(this).data(n[a]))&&(t[n[a]]=i)})},e.fn.showin=function(){return this.each(function(){e(this).css("display","inline-block")})},e.fn.togglein=function(t){return typeof t===UNDEF?this.each(function(){e(this).css("display","none"===e(this).css("display")?"inline-block":"none")}):(e(this).css("display",t?"inline-block":"none"),this)},e.fn.getDim=function(){var t=e(this).eq(0),n={width:t.width(),height:t.height()};if((0===n.width||0===n.height)&&"none"===t.css("display")){var a=t.css("position"),i=t.css("left");t.css({position:"absolute",left:"-10000px",display:"block"}),n.width=t.width(),n.height=t.height(),t.css({display:"none",position:a,left:i})}return n},typeof Search!==UNDEF&&(Search.text=getTranslations({searchBoxTip:"Search...",searchResultsFor:"Search results for",newImages:"New images",notFound:"Not found",foundNImages:"Found {0} item(s)",close:"Close"}),Search.start=function(t){if(null!=t){var n,a,i,o,s,r,l,d,c,h,u,p,f,m,g,b,v,w,k,y="string"==typeof t||e.isNumeric(t)?String(t):"FORM"===t.nodeName?e(t).find("input[type=search]").val().trim():e(t).text().trim(),T=0,x=!1;if(Search.data&&e.isArray(Search.data)&&Search.data.length&&y&&!(y.length<2)){n=e("<div>",{"class":"searchresults"});var S=function(e){if(e&&e.length){var t=e.val().trim();t.length>=2&&Search.start(t)}};y.startsWith("@new")?(x=!0,o=Search.created||Math.floor((new Date).getTime()/864e5),i=parseInt(y.split(":")[1],10)||30):(k=new RegExp("("+y.replace(/\s/g,"|")+")","i"),n.append('<form><input type="text" value="'+y+'"><a class="button">&nbsp;</a></form>'),n.find(".button").on("click",function(){return S(e(this).siblings("input")),!1}),n.find("input").on("keydown",function(t){return 13===t.which?(t.preventDefault(),S(e(t.currentTarget)),!1):void 0})),f=Search.rootPath&&"."!==Search.rootPath?Search.rootPath+"/":"",r=window.location.href.getRelpath(Math.floor(f.length/3));var I=function(t){var n=e(t.target).closest("a");return n.length&&n.hasClass("active")&&window.location.href.endsWith(n.attr("href"))?(t.cancelBubble=!0,!1):(Search.makeSlides||(n.addClass("active"),n.siblings(".active").removeClass("active")),e.cookie("lastSearch",y,8),!0)};for(l=0;l<Search.data.length;l++)for(p=f,Search.data[l][0].length&&(p+=(Search.urlEncode?Search.data[l][0]:encodeURIComponent(Search.data[l][0]).replace(/%2F/g,"/"))+"/"),h=Search.data[l][1].length,d=0;h>d;d++)if(m=Search.data[l][1][d].split(Search.sep),x&&m.length>5&&(s=o-parseInt(m[5],10))<i||!x&&k.test(Search.data[l][1][d])){switch(g=m[0].split(":"),w=g[0].getExt(),v=g.length>1?g[1]:g[0].substring(g[0].lastIndexOf(".")+1),b=encodeURIComponent(g[0]),0>s&&(s=0),w.toLowerCase()){case Search.ext:g=p+Search.folderThumb;break;case"tif":case"bmp":Search.makeSlides||(b=b.replaceExt(v));case"jpg":case"jpeg":case"png":case"mp4":g=p+Search.thumbs+"/"+b.replaceExt(v);break;case"mp3":g="png"===v?f+"res/audio.png":p+Search.thumbs+"/"+b.replaceExt(v);break;case"gif":b=b.replaceExt(v),g=p+Search.thumbs+"/"+b;break;case"pdf":case"zip":case"txt":case"doc":case"xls":g=f+"res/"+w+".png";break;default:g=f+"res/unknown.png"}for(w===Search.ext?(b=p+b,g=p+Search.folderThumb):b=p+(Search.makeSlides?Search.slides+"/"+b.replaceExt(Search.ext):Search.indexName+"#"+(Search.urlEncode?b.replace(/\'/g,"%27").replace(/%/g,"%25").replace(/\(/g,"%2528").replace(/\)/g,"%2529"):b)),u=e("<a>",{href:b.fixUrl()}).append(e("<aside>").append(e("<img>",{src:g}))).on("click",I).appendTo(n),b.endsWith(r)&&u.addClass("active"),m[1]&&u.append(e("<h5>").append(x?m[1]:m[1].replace(k,"<em>$1</em>"))),m[2]&&m[2]!==m[1]&&u.append(e("<p>").append(x?m[2].trunc(192):m[2].trunc(192).replace(k,"<em>$1</em>"))),c=3;c<m.length-1;c++)m[c]&&m[c].trim().length&&u.append(e("<p>").append(x?m[c].trunc(192):m[c].trunc(192).replace(k,"<em>$1</em>")));x&&u.append(e("<p>").append("<em>"+getRelativeDate(s)+"</em>")),window.location.hash===m[0]&&(a=T),T++}return t.jquery&&e(t).parents(".hint:first").fadeOut(100,function(){e(this).remove()}),T?(n.children("a:first").before(e("<p>",{text:Search.text.foundNImages.template(T)})),setTimeout(function(){e(".searchresults > a").eq(a||0).focus()},250)):n.append(e("<p>",{text:Search.text.notFound})),e("body").addModal(n,{uid:"searchres",title:y.startsWith("@new")?Search.text.newImages:Search.text.searchBoxTip,darkenBackground:!1,movable:!0,blocking:!1,closeOnClickOut:!1,defaultButton:"close",resizable:!0,width:240,pos:[2,0],scrollIntoView:!0,savePosition:!0}),!1}}},Search.rootPath="",Search.init=function(t){Search.rootPath=t;var n=e.cookie("lastSearch");n&&n.length&&"null"!==n&&(e.cookie("lastSearch",null),Search.start(n))}),e.fn.addRegions=function(t,n,a){if(t&&t.length&&n){a=e.extend({},e.fn.addRegions.defaults,a);var i=[],o=function(){var e,t,a,o,s,r,l=n.split("::");for(e=0;e<l.length;e++)t=l[e].split(";"),t.length>4&&t[0].length&&null!==(a=parseFloat(t[1]))&&null!==(o=parseFloat(t[2]))&&null!==(s=parseFloat(t[3]))&&null!==(r=parseFloat(t[4]))&&i.push([t[0],100*a+"%",100*o+"%",100*s+"%",100*r+"%"])};return o(),i.length?this.each(function(){for(var n,o,s=e(this),r=parseInt(s.css("padding-top"),10),l=e("<div>",{"class":a.id}).hide(),d=e("<div>",{"class":a.id+"-cont"}).css({left:r,top:r,right:r,bottom:r}),c=function(e){return e.preventDefault(),Search.start(e.target),!1},h=function(t){d.children("a").eq(e(t.target).index()).addClass(a.active)},u=function(t){d.children("a").eq(e(t.target).index()).removeClass(a.active)},p=0;p<i.length;p++)n=e("<a>",{text:i[p][0]}).appendTo(l),o=e("<a>").css({left:i[p][1],top:i[p][2],width:i[p][3],height:i[p][4]}).append(e("<span>",{text:i[p][0]})).appendTo(d),n.on({mouseover:h,mouseout:u}),typeof Search!==UNDEF&&o.on("click",c);s.addTooltip(l,{stay:5e3}),s.on("destroy",function(){l.remove()}),s.hasClass(a.active)&&d.addClass(a.active),s.on("click",function(){e(this).add(d).toggleClass(a.active)}),t.append(d)}):this}},e.fn.addRegions.defaults={id:"regions",active:"active",pos:[1,2,1,0]},e.fn.centerThis=function(t){return t=e.extend({},e.fn.centerThis.defaults,t),this.each(function(){var n=e(this),a=n.find(t.selector);if(a.length){var i,o,s,r,l,d,c,h,u,p,f=t.marginLeft+t.padding,m=t.marginRight+t.padding,g=t.marginTop+t.padding,b=t.marginBottom+t.padding;if(c=a.data("ow"),h=a.data("oh"),c&&h||(a.data("ow",c=a.width()),a.data("oh",h=a.height())),(u=a.data("bw"))||a.data("bw",u=parseInt(a.css("border-top-width"),10)||0),(p=a.data("pw"))||a.data("pw",p=parseInt(a.css("padding-top"),10)||0),i=(n.innerWidth()||e("body").width())-2*(u+p)-f-m,o=(n.innerHeight()||e("body").height())-2*(u+p)-g-b,t.fit&&(c>i||h>o||t.enlarge)){var v=Math.min(i/c,o/h);s=Math.round(c*v),r=Math.round(h*v)}else s=c,r=h;if(l=Math.round((i-s)/2)+f,d=Math.round((o-r)/2)+g,s!==c&&a.translateToPos(),t.animate){if(a.stop(!0,!1),t.preScale&&1!==t.preScale){var w=s*t.preScale,k=r*t.preScale;a.css({left:Math.round((i-w)/2)+f,top:Math.round((o-k)/2)+g,width:Math.round(w),height:Math.round(k)})}else t.init&&a.css({left:l,top:d});a.animate({left:l,top:d,width:s,height:r},{duration:t.speed,easing:t.effect,complete:t.complete})}else a.css({left:l,top:d,width:s,height:r}),e.isFunction(t.complete)&&t.complete.call(this)}})},e.fn.centerThis.defaults={selector:".main",speed:500,fit:!0,enlarge:!0,marginTop:0,marginBottom:0,marginLeft:0,marginRight:0,padding:0,init:!1,animate:!1,effect:"swing",complete:null},e.fn.collectMarkers=function(t){t=e.extend({},e.fn.collectMarkers.defaults,t);var n,a,i,o=[];return this.each(function(s){n=e(this).find(t.selector),n.length&&(a=n.data(t.mapid))&&(a=e.getLatLng(a))&&(i=n.data(t.captionid)||n.attr("alt"),o.push({map:a,label:s+1+(i?": "+i.stripHTML():""),link:t.dynamic?e(this):e(this).attr("href")}))}),o},e.fn.collectMarkers.defaults={selector:"img:first",mapid:"map",captionid:"caption"},e.fn.markFoldersNew=function(t){if(t=e.extend({},e.fn.markFoldersNew.defaults,t),text=getTranslations(e.fn.markFoldersNew.text),t.days){var n=t.ref||Math.round((new Date).getTime()/864e5);return this.each(function(){n-parseInt(e(this).data("modified")||0,10)<=t.days&&e(this).after('<span class="'+t.cls+'">'+text.newItem+"</span>")})}},e.fn.markFoldersNew.defaults={days:7,cls:"newlabel"},e.fn.markFoldersNew.text={newItem:"NEW"},e.fn.turtleHelp=function(t){t=e.extend({},e.fn.turtleHelp.defaults,t);var n=getTranslations(e.fn.turtleHelp.text),a=e("<div>",{"class":"help"}),i=function(t){if(n.hasOwnProperty(t)){var i,o=1,s=e("<ul>",{"class":t}).appendTo(a);for(i in n[t])s.append(e("<li><span>"+o++ +"</span>"+n[t][i]+"</li>"))}};t.index&&i("index"),t.slide&&i("slide"),t.pressF1&&a.append(e("<p>",{html:n.help_pressF1}));var o=function(){e("body").addModal(a,{uid:"help",title:n.help_title,width:720,savePosition:!0,resizable:!0})};return t.useF1&&!document.touchMode&&e(document).on("keydown",function(n){if(document.activeElement&&"INPUT"===document.activeElement.nodeName||e.isFunction(t.enableKeyboard)&&!t.enableKeyboard()||e("#help").is(":visible"))return!0;var a=n?n.keyCode:window.event.keyCode;return 112===a?(n.preventDefault(),o(),!1):!0}),this.each(function(){e(this).on("click",function(e){return e.preventDefault(),o(),!1})})},e.fn.turtleHelp.defaults={useF1:!0,index:!0,slide:!1},e.fn.turtleHelp.text={help_title:"Using Turtle gallery",help_pressF1:"Press <b>F1</b> any time to get help!",index:{help_topNavigation:"Top <b>navigation</b> bar with <b>Home</b> button",help_upOneLevel:"<b>Up</b> one level",help_authorInfo:"Author or company <b>information</b>",help_shareAndLike:"<b>Share</b> and <b>Like</b> buttons for social networking",help_searchNew:"Search <b>new images</b>",help_search:"<b>Search</b> button",help_downloadZip:"<b>Download</b> album or current folder as ZIP file",help_startSlideshow:"Start <b>slideshow</b> <em>Numpad *</em>"},slide:{help_previousPicture:"<b>Previous</b> picture <em>Left arrow</em><em>Swipe right</em>",help_backToIndex:"Back to <b>thumbnail page</b> / up one level <em>Esc</em>",help_toggleFit:"Toggle <b>fit to screen</b> or <b>1:1</b> size <em>Numpad +</em>",help_toggleInfo:"Show/hide <b>captions</b> and other panels, like Metadata, Map, Shopping, etc. <em>Numpad -</em>",help_toggleThumbnails:"Show/hide <b>thumbnail</b> scroller <em>Numpad -</em>",help_toggleAutoPlay:"Start/stop <b>slideshow</b> <em>Numpad *</em>",help_nextPicture:"<b>Next</b> picture <em>Right arrow</em><em>Swipe left</em>",help_toggleMeta:"Toggle <b>photo data</b>",help_toggleMap:"Toggle <b>map</b>",help_toggleShop:"Toggle <b>shopping options</b> panel",help_downloadImage:"Download <b>high resolution</b> file",help_shareAndLike:"<b>Share</b> and <b>Like</b> buttons for social networking",help_toggleComments:"Toggle <b>Facebook comments</b>",help_toggleFaces:"Toggle visibility of <b>tagged people</b>"}},e.fn.turtle=function(t,n){t=e.extend({},e.fn.turtle.defaults,t),n=e.fn.turtle.ids;var a=getTranslations(e.fn.turtle.text),i=function(n,a,i){e.cookie(n,a,i),t[n]=a};!function(n){for(var a,i=0;i<n.length;i++)null!==(a=e.cookie(n[i]))&&(t[n[i]]=a)}(["thumbsOn","infoOn","commentsOn","metaOn","mapOn","regionsOn","shopOn","shareOn","printOn","fitImage","slideshowDelay","slideshowOn"]),document.touchMode&&(t.preScale=!1),e.fn.addScroll.defaults.dontDrag="#"+n.map,e.fn.addMap.defaults.zoom=t.mapZoom,e.fn.addMap.defaults.type=t.mapType,e.fn.addMap.defaults.resPath=t.resPath,e.fn.addShop.defaults.id=t.shopId,e.fn.addShop.defaults.path=(t.albumName?t.albumName+"/":"")+t.relPath,e.fn.addShop.defaults.currency=t.shopCurrency||"EUR",e.fn.addShop.defaults.handling=t.shopHandling||null,e.fn.addShop.defaults.locale=t.shopLocale||"US",e.fn.addShop.defaults.quantityCap=t.shopQuantityCap||0,e.fn.addShop.defaults.discount=t.shopDiscount||0,e.fn.addShop.defaults.options=t.shopOptions||"",e.fn.addShop.defaults.coupons=t.shopCoupons||"",t.shopContinueUrl&&(e.fn.addShop.defaults.continueUrl=t.shopContinueUrl.match(/^https?:/i)?t.shopContinueUrl:window.location.origin+t.shopContinueUrl),e.fn.addPlayer.defaults.backgroundColor=e("body").css("background-color").rgb2hex(),t.linkSlides||(e.fn.addPlayer.defaults.fullScreen=t.videoMaximize,e.fn.addPlayer.defaults.auto=t.videoAuto,e.fn.addPlayer.defaults.solution=t.prioritizeFlash?"flash,html":"html,flash"),e.fn.centerThis.defaults.fit=t.fitImage,e.fn.centerThis.defaults.animate=t.transitions,e.fn.centerThis.defaults.padding=t.fitPadding,e.fn.centerThis.defaults.enlarge=!t.fitShrinkonly,e.fn.centerThis.defaults.selector="."+n.main,function(t){for(var n in t)t.hasOwnProperty(n)&&(e.fn.addSocial.defaults[n]=t[n])}(t.shares),t.shareSlides=t.shares&&(t.linkSlides&&(t.shares.facebookLike||t.shares.facebook||t.shares.gplus)||t.shares.twitter||t.shares.pinterest||t.shares.digg||t.shares.delicious||t.shares.myspace||t.shares.stumbleupon||t.shares.reddit||t.shares.email);var o,s,r,l,d,c,h,u,p,f=Math.round((new Date).getTime()/864e5),m="ms"===VEND&&Modernizr&&Modernizr.opacity===!1,g={},b=null,v=null,w=0,k=null,y=null,T="index"===e("body").attr("id"),x="page"===e("body").attr("id"),S=T&&!t.linkSlides,I=[],O=!1,F=!1,M=null,P=null,C=e(window).width(),L=e(window).height(),D=function(){clearTimeout(P),P=setTimeout(function(){if(!e(".jp-video-full").length){var t=e(window).width(),n=e(window).height();(t!==C||n!==L)&&(yt(),C=t,L=n)}},100)},N=-1,B=-1,A=function(s){if(s){var r=e("<div>",{"class":n.startShow}).appendTo(s),l=e("<div>",{"class":n.startTxt,width:"auto",text:a.startSlideshow}).appendTo("body"),d=r.width(),c=l.outerWidth();r.append(l),c>d&&l.on({mouseenter:function(){r.stop(!0,!1).animate({width:c},500)},mouseleave:function(){r.stop(!0,!1).animate({width:d},500)}}),r.on({click:function(a){return S?(a.preventDefault(),t.slideshowFullScreen&&e("html").fullScreen(!0),w===o.length-1?Lt(0):Lt(),o.length&&setTimeout(st,1e3),!1):(i("slideshowOn",!0,8),void(window.location.href=o.filter("."+n.active).attr("href")))}})}},z=function(e){e&&e.length&&(T&&o.length>1&&t.showStart&&A(e),t.uplink=e.find("."+n.parent+">a").attr("href")||"")},E=function(){if(!(t.licensee||typeof _jaShowAds!==UNDEF&&!_jaShowAds||LOCAL||e.cookie("ls"))){var n=t.resPath+"/logo.png",a=e(new Image);a.load(function(){var t=e("<div>").css({background:"url("+n+") 10px top no-repeat",textAlign:"left",minHeight:"60px",paddingLeft:"90px"}).html("<h4>Turtle skin <small>"+VER+"</small></h4><p>Unlicensed</p>");e("body").addModal(t,{width:240,defaultButton:!1,autoFade:600}),e.cookie("ls",!0)}).attr("src",n)}},H=function(){if(!e.cookie("cookiePolicy")){var n=e("<div>",{id:"cookiepolicy"}).appendTo("body"),i=e("<p>",{html:a.cookiePolicyText}).appendTo(n);t.cookiePolicyUrl&&i.append(e("<a>",{text:a.cookiePolicyLearnMore,href:t.cookiePolicyUrl})),i.append(e("<a>",{"class":"btn",text:a.cookiePolicyAgree}).on("click",function(){e("#cookiepolicy").fadeOut(500,function(){e(this).remove()}),e.cookie("cookiePolicy",!0,36e6)})),n.fadeIn(500),setTimeout(function(){e("#cookiepolicy").fadeOut(500,function(){e(this).remove()})},1e3*t.cookiePolicyStay)}},U=function(n){if(r&&r.is(":visible")||document.activeElement&&("INPUT"===document.activeElement.nodeName||"TEXTAREA"===document.activeElement.nodeName)||e.isFunction(t.enableKeyboard)&&!t.enableKeyboard())return!0;var a=n?n.keyCode:window.event.keyCode;switch(a){case 13:case 10:S?Lt():window.location.href=o.eq(w).attr("href");break;case 37:w=(w?w:o.length)-1,V();break;case 38:w&&t.cols&&(w=Math.max(0,w-t.cols)),V();break;case 39:w=(w+1)%o.length,V();break;case 40:w<o.length-1&&t.cols&&(w=Math.min(o.length-1,w+t.cols)),V();break;case 97:case 35:w=o.length-1,V();break;case 103:case 36:w=0,V();break;case 106:case 179:S&&t.slideshowFullScreen&&(F=!1,e("html").fullScreen(!0)),S&&Lt(),st();break;default:return!0}return!1},R=function(n){if(r.is(":hidden")||document.activeElement&&("INPUT"===document.activeElement.nodeName||"TEXTAREA"===document.activeElement.nodeName)||e.isFunction(t.enableKeyboard)&&!t.enableKeyboard())return!0;var a=n?n.keyCode:window.event.keyCode;switch(a){case 27:j();break;case 37:Z();break;case 38:G();break;case 39:$();break;case 40:J();break;case 97:case 35:S?Lt(o.length-1):window.location.href=t.firstPage;break;case 103:case 36:S?Lt(0):window.location.href=t.firstPage;break;case 106:case 179:k?rt():(S&&t.slideshowFullScreen&&(F=!1,e("html").fullScreen(!0)),st());break;case 107:xt();break;case 109:vt();break;default:return!0}return!1},_=function(){var e=t.level>0?window:parent;e.location.href=t.uplink||t.indexPage||"../"},j=function(){if(S||(t.curr&&e.cookie("curr:"+t.albumName+"/"+t.relPath,t.curr,t.keepPrefs),window.location.href=t.indexPage),!t.skipIndex||t.level||t.uplink){var a,i=e("[role=main]");e.fn.hideAllTooltips(),r.is(":visible")?(rt(),S&&t.slideshowFullScreen&&e("html").fullScreen(!1),t.skipIndex?_():(i.length&&i.is(":hidden")&&(i.children().addBack().css({visibility:"visible",display:"block"}),s.children("."+n.cont).trigger("adjust"),setTimeout(function(){s.loadImages()},100)),t.transitions?r.fadeOut(t.speed):r.hide(),b&&(a=b.find("."+n.video+",."+n.audio)).length&&a.trigger("pause"),e("#"+n.map+">."+n.cont).trigger("adjust"),"no"!==t.hash&&e.history.load(""))):i.length&&i.is(":hidden")&&(i.children().addBack().css({visibility:"visible",display:"block"}),setTimeout(function(){s.loadImages()},100)),i.find("[role=scroll]").data("dragOn",!1)}},W=function(e){var t;return null==e?t=w:"number"==typeof e?t=Math.minMax(0,e,o.length):(t=o.index(e))<0&&p&&(t=p.index(e)),t},q=function(e){var t,a,i;for(t=0;t<o.length;t++)if(a=o.eq(t).children("img:first"),i=a.length&&(a.data(n.link)||a.data(n.src)).getFile(),i&&i===e)return t;return-1},K=function(){var e=o.eq(w).children("img:first");return e.length?(e.data(n.link)||e.data(n.src)).getFile():null},Y=function(e){o.children("."+n.checkbox).toggleClass(n.active,e),r&&r.find("."+n.checkbox).toggleClass(n.active,e)},Q=function(){var t=function(t){t.preventDefault();var a=e(this).hasClass(n.active);return e(this).toggleClass(n.active,!a),e(this).parent().hasClass(n.active)&&r.find("."+n.checkbox).toggleClass(n.active,!a),!1},a=function(t){return t.preventDefault(),Y(!e(this).hasClass(n.active)),!1};o.children("."+n.checkbox).on("click",t).on(document.touchMode?"dbltap":"dblclick",a)},V=function(a){var i=o.eq(w);o.filter("."+n.active).removeClass(n.active),i.addClass(n.active),t.skipIndex||typeof a!==UNDEF&&a!==!1||i.trigger("setactive"),p&&(p.filter("."+n.active).removeClass(n.active),p.eq(w).addClass(n.active).trigger("setactive")),t.mapOnIndex&&e("#"+n.map+" ."+n.cont).trigger("setactive",i.find("img:first").data(n.mapid)),w&&e.cookie("curr:"+t.albumName+"/"+t.relPath,w,t.keepPrefs)},X=function(){e.cookie("curr:"+t.albumName+"/"+t.relPath,null)},$=function(){var a=e("."+n.main),i=e("."+n.img);if(a.length)if(a.position().left+a.outerWidth()<=i.width()-t.fitPadding)nt();else{var o=Math.round(.8*i.width());a.animate({left:Math.max(a.position().left-o,i.width()-t.fitPadding-a.outerWidth())},t.scrollDuration)}},Z=function(){var a=e("."+n.main),i=e("."+n.img);if(a.length)if(a.position().left>=t.fitPadding)tt();else{var o=Math.round(.8*i.width());a.animate({left:Math.min(a.position().left+o,t.fitPadding)},t.scrollDuration)}},G=function(){var a=e("."+n.main),i=e("."+n.img);if(a.length&&!(a.position().top>t.fitPadding)){var o=Math.round(.8*i.width());a.animate({top:Math.min(a.position().top+o,t.fitPadding)},t.scrollDuration)}},J=function(){var a=e("."+n.main),i=e("."+n.img);if(a.length&&!(a.position().top+a.outerHeight()<=i.height()-t.fitPadding)){var o=Math.round(.8*i.width());a.animate({top:Math.max(a.position().top-o,i.height()-t.fitPadding-a.outerHeight())},t.scrollDuration)}},et=function(){b.find("."+n.main).trigger("dragcancel")},tt=function(){if(rt(),S)w?Lt(w-1):"startover"===t.afterLast?Lt(o.length-1):"nextfolder"===t.afterLast&&t.previousFoldersLast?window.location.href=t.previousFoldersLast:et();else{var a=e("."+n.controls+" ."+n.prev);a.length&&(a=a.attr("href"))!==NOLINK?window.location.href=a:et()}},nt=function(s){var r=[];if(S){if(w<o.length-1)return s?ot():rt(),void Lt(w+1);if("startover"===t.afterLast||k&&t.slideshowLoop)return s?ot():rt(),void Lt(0);switch(X(),et(),t.afterLast){case"onelevelup":t.uplink&&_();break;case"backtoindex":t.skipIndex||j();break;case"nextfolder":t.nextFoldersFirst?(null!==k&&e.cookie("slideshowDelay",t.slideshowDelay,8),window.location.href=t.nextFoldersFirst):rt();break;case"ask":rt(),o.length>1&&r.push({t:a.startOver,h:function(){Lt(0)}}),t.uplink&&r.push({t:t.level>0?a.upOneLevel:t.homepageLinkText||a.backToHome,h:function(){_()}}),t.skipIndex||r.push({t:a.backToIndex,h:function(){j()}}),t.nextFoldersFirst&&r.push({t:a.nextFolder,h:function(){window.location.href=t.nextFoldersFirst}}),e("body").addModal(e("<p>",{text:a.atLastPageQuestion}),r,{type:"question",uid:"dialog",title:a.atLastPage,width:500})}et()}else{var l=e("."+n.controls+" ."+n.next);l.length&&(l=l.attr("href"))&&l.length&&l!==NOLINK?(i("slideshowDelay",t.slideshowDelay),k&&i("slideshowOn",s,8),window.location.href=l):"ask"===t.afterLast&&(rt(),et(),X(),t.firstPage&&r.push({t:a.startOver,h:function(){k&&i("slideshowOn",null!=k,8),window.location.href=t.firstPage}}),t.uplink&&r.push({t:t.level>0?a.upOneLevel:t.homepageLinkText||a.backToHome,h:function(){_()}}),t.indexPage&&r.push({t:a.backToIndex,h:function(){window.location.href=t.indexPage}}),t.nextFoldersFirst&&r.push({t:a.nextFolder,h:function(){window.location.href=t.nextFoldersFirst}}),e("body").addModal(e("<p>",{text:a.atLastPageQuestion}),r,{uid:"dialog",type:"question",title:a.atLastPage,width:500}))}},at=function(){y&&(y=clearTimeout(k),k=setTimeout(function(){nt(!0)},300))},it=function(){k&&(y=k,k=clearTimeout(k))},ot=function(){k&&(clearTimeout(k),k=setTimeout(function(){nt(!0)},t.slideshowDelay))},st=function(){k=clearTimeout(k);var a;g.play.hide(),g.pause.showin(),e.cookie("slideshowDelay",t.slideshowDelay,8),(a=b.find("."+n.video+",."+n.audio)).length&&(a.data("playing")||t.videoAuto)?(y=!0,a.trigger("setEndedFn",at)):k=setTimeout(function(){nt(!0)},t.slideshowDelay),t.bgAudioId&&e(t.bgAudioId).trigger("play"),ct()},rt=function(){if(y=!1,g.pause.hide(),g.play.showin(),e.cookie("slideshowDelay",null),k){var a;k=clearTimeout(k),ct(),S?t.bgAudioId&&e(t.bgAudioId).trigger("pause"):i("slideshowOn",!1),(a=b.find("."+n.video+",."+n.audio)).length&&(a.data("playing")||t.videoAuto)&&a.trigger("setEndedFn",null)}},lt=!1,dt=function(){F||lt||(lt=!0,c.stop(!0,!1).fadeTo(200,.8,function(){m&&c.css("filter",null)}),M=setTimeout(function(){ct()},1500))},ct=function(){F?M=setTimeout(function(){ct()},750):(lt=!1,M=clearTimeout(M),c.fadeTo(500,t.controlOutOpacity))},ht=function(a){return a.target&&("A"===a.target.nodeName||e(a.target).parents("."+n.bottom).length)?!0:(lt?(lt=!1,M=clearTimeout(M),c.fadeTo(500,t.controlOutOpacity)):dt(),!0)},ut=function(){t.infoOn?(g.showInfo.hide(),g.hideInfo.showin(),h.show().css({bottom:0})):(g.hideInfo.hide(),g.showInfo.showin(),h.css({bottom:-h.outerHeight()}).hide())},pt=function(){t.infoOn&&(g.hideInfo.hide(),g.showInfo.showin(),t.transitions?h.animate({bottom:-h.outerHeight()},500,function(){h.hide()}):h.css({bottom:-h.outerHeight()}).hide(),b&&t.fitFreespace&&b.centerThis({fit:t.fitImage,marginTop:wt(),marginBottom:0}),ct(),i("infoOn",!1))},ft=function(){if(!t.infoOn){g.showInfo.hide(),g.hideInfo.showin(),h.is(":hidden")&&h.show().css({bottom:-h.outerHeight()});var e=function(){h.children("."+n.map).trigger("adjust")};t.transitions?h.animate({bottom:0},500,e):(h.show().css({bottom:0}),e()),b&&t.fitFreespace&&b.centerThis({fit:t.fitImage,marginTop:wt(),marginBottom:h.outerHeight()}),ct(),i("infoOn",!0)}},mt=function(){t.thumbsOn?(g.showThumbs.hide(),g.hideThumbs.showin(),d.css({top:0}).removeClass("hide")):(g.hideThumbs.hide(),g.showThumbs.showin(),d.css({top:-u.outerHeight()-10}).removeClass("hide"))},gt=function(){t.thumbsOn&&(g.hideThumbs.hide(),g.showThumbs.showin(),t.transitions?d.animate({top:-u.outerHeight()-10},500):d.css({top:-u.outerHeight()-10}),b&&t.fitFreespace&&b.centerThis({fit:t.fitImage,marginTop:0,marginBottom:kt()}),ct(),i("thumbsOn",!1))},bt=function(){t.thumbsOn||(g.showThumbs.hide(),g.hideThumbs.showin(),t.transitions?d.animate({top:0},500):d.css({top:0}),b&&t.fitFreespace&&b.centerThis({fit:t.fitImage,marginTop:u.outerHeight(),marginBottom:kt()}),ct(),i("thumbsOn",!0))},vt=function(){var e=t.fitFreespace;t.fitFreespace=!1,t.infoOn||t.thumbsOn?(gt(),pt(),b&&e&&b.centerThis({fit:t.fitImage,marginTop:0,marginBottom:0})):(bt(),ft(),b&&e&&b.centerThis({fit:t.fitImage,marginTop:u.outerHeight()||0,marginBottom:h.outerHeight()||0})),t.fitFreespace=e},wt=function(){return t.fitFreespace&&d.position().top>=0?u.outerHeight()||0:0},kt=function(){return t.fitFreespace&&h.is(":visible")?h.outerHeight()||0:0},yt=function(){b&&b.centerThis({fit:t.fitImage,marginTop:wt(),marginBottom:kt()})},Tt=function(){t.hideFitBtn||(t.fitImage?(g.resize.hide(),g.noresize.showin()):(g.noresize.hide(),g.resize.showin()))},xt=function(){t.fitImage?St():It()},St=function(){t.hideFitBtn||(g.noresize.hide(),g.resize.showin()),e.fn.centerThis.defaults.enlarge=!t.fitShrinkonly,b.centerThis({fit:!1,marginTop:wt(),marginBottom:kt()}),ct(),i("fitImage",!1)},It=function(){t.hideFitBtn||(g.resize.hide(),g.noresize.showin()),e.fn.centerThis.defaults.enlarge=!0,b.centerThis({fit:!0,marginTop:wt(),marginBottom:kt()}),ct(),i("fitImage",!0)},Ot=function(e){e.trigger("destroy"),e.find("."+n.video+",."+n.audio).trigger("destroy"),e.find("."+n.share+"-"+n.icon).trigger("destroy"),e.find("."+n.map).trigger("destroy")},Ft=function(t){return t.preventDefault(),e(this).parents("[role=scroll]").data("dragOn")===!0?!1:(Lt(e(this)),!1)},Mt=function(e){e&&e.length&&(e.stop(),Ot(e),e.remove())},Pt=function(n){var a;n&&n.length&&(a="number"===t.hash?(parseInt(n,10)||1)-1:q(n))>=0&&a<o.length?(Lt(a,!1),t.slideshowAuto=!1):(j(),"ms"==VEND&&setTimeout(function(){e("[role=main]").show(),e("[role=scroll]").trigger("adjust")},10))},Ct=function(n){if("number"===t.hash)e.history.load(n+1);else{var a=K();a&&e.history.load(a)}},Lt=function(i,s){if(typeof s===UNDEF&&(s=!0),"number"!=typeof i&&(i=i?W(i):w),r.is(":hidden")&&(b&&b.data("curr")!==i&&Mt(b),t.transitions?r.fadeIn(t.speed):r.show(),e.fn.hideAllTooltips(),u.children(":first").loadImages()),b&&b.data("curr")===i)return void(s!==!1&&Ct(i));var d,c,h,p=o.eq(i),f=p.attr("href"),m=p.children("img").eq(0);if(m.length){b&&(Mt(v),v=b,v.css({zIndex:0}),setTimeout(function(e){e.trigger("unswipe")},50,v.find("."+n.main)),document.touchMode||v.unmousewheel()),(d=r.children("."+n.img).not(b)).length&&d.stop().remove(),b=e("<div>",{id:"img"+i,"class":n.img}).css({zIndex:1,display:"none"}).data({curr:i}).appendTo(r),t.clickBesideForIndex&&(!t.skipIndex||t.level||t.uplink)&&b.on("click",function(t){return e(t.target).hasClass("img")?(t.preventDefault(),j(),!1):void 0}),l.css({opacity:0,display:"block"}).animate({opacity:1}),w=i,V(),S&&s&&Ct(w);var g=e("<div>",{"class":n.main});if(m.data(n.isother)||!f){c=Math.max(m.data(n.width)||r.width()-160,280),h=Math.max(m.data(n.height)||r.height()-120,200),g.addClass(n.other);var T=m.data(n.content);if(T&&(T=T.trim()).length)g.css({width:c,height:h}).append(T.match(/^https?:\/\//i)?e("<iframe>",{width:"100%",height:"100%",src:T,frameborder:0,allowfullscreen:"allowfullscreen"}):T);else{{var p=e("<a>",{href:m.data(n.link),target:"_blank"});e("<img>",{src:m.data(n.src)||m.attr("src")}).appendTo(p)}g.append(p).append(e("<p>",{text:a.clickToOpen}))}Ut(g)}else if(m.data(n.isvideo)||m.data(n.isaudio)){if(c=m.data(n.width)||r.width()-160,h=m.data(n.height)||r.height()-120,y=k,y&&(k=clearTimeout(k)),m.data(n.isvideo)){var x=r.width()-40,I=r.height()-40;if(c>x||h>I){var O=Math.min(x/c,I/h);c=Math.round(c*O),h=Math.round(h*O)}g.addClass(n.video)}else c=Math.max(240,m.data(n.width)||0),h=Math.max(180,m.data(n.height)||0),g.addClass(n.audio);g.css({width:c,height:h}).data({ow:c,oh:h}),setTimeout(function(){d=g.addPlayer({src:m.data(n.link),title:t.showVideoTitle?m.attr("alt"):"",poster:m.data(n.poster),play:it,ended:at,resPath:t.resPath})},t.speed/3),Ut(g)}else{c=m.data(n.width),h=m.data(n.height);var F=e(new Image);g.addClass(n.image).append(F).css({width:c,height:h}).data({ow:c,oh:h}),F.attr({src:f,width:c||"auto",height:h||"auto"}),F[0].complete?(m.data("cached",!0),Ut(g)):F.on("load",function(){m.data("cached",!0),Ut(g)}).prop({src:f})}(d=p.find(".checkbox")).length&&(g.append(d=d.clone()),d.on("click",function(t){t.preventDefault();var a=e(this).hasClass(n.active);return e(this).toggleClass(n.active,!a),o.filter("."+n.active).find("."+n.checkbox).toggleClass(n.active,!a),!1})),Rt(m,i)}},Dt=function(e){var t=b.find("nav a."+n.regions+"-icon").eq(0);if(t.length){var a=o.eq(e).find("img:first");t.addRegions(b.find("."+n.main).eq(0),a.data(n.regions))}},Nt=function(e){e&&e.length&&(e.data(n.kill,!0),setTimeout(function(){e&&e.removeData(n.kill)},500))},Bt=function(t){var a=e(t.target).parents("."+n.main);return a.data(n.kill)||a[0].dragOn||(Nt(a),t.pageX<a.offset().left+a.outerWidth()/2?tt():nt()),!1},At=function(t,a){t.preventDefault();var i=e(t.target).parents("."+n.img);return i.data(n.kill)||(Nt(i),a>0?tt():nt()),!1},zt=function(e){t.rightClickProtect&&e.on("contextmenu",noAction),setTimeout(function(){!document.touchMode&&t.enableMouseWheel&&b.on("mousewheel",At),document.touchMode?(k||dt(),b[0].addEventListener(TOUCH_START,ht),e.on({click:noAction,dbltap:xt})):(o.length>1||!S)&&e.hasClass(n.image)&&(t.clickForNext?e.on("click",Bt):e.on({click:noAction,dblclick:xt})),e.hasClass(n.image)&&e.addSwipe(nt,tt)},t.speed/2)},Et=function(t){var a=t.attr("href"),i=t.children("img").eq(0);!a||!i||i.data("cached")||i.data(n.isvideo)||i.data(n.isother)||e("<img>").on("load",function(){i.data("cached",!0)}).attr({src:a})},Ht=function(){w<o.length-1&&Et(o.eq(w+1)),w>0&&Et(o.eq(w-1))},Ut=function(a){if(l&&l.length&&(t.transitions?l.stop(!0,!1).animate({opacity:0},{duration:100,complete:function(){e(this).hide()}}):l.hide()),S)t.transitions?v&&v.stop(!0,!1).animate({opacity:0},t.speed/2,"linear",function(){Mt(v)}):Mt(v),b.children().not("."+n.bottom).remove(),b.append(a);else if(a=b.find("."+n.main),!a.length)return;var i=a.hasClass(n.image);zt(a),setTimeout(function(){t.transitions?b.css({opacity:0,display:"block"}).animate({opacity:1},{duration:t.speed,complete:m?function(){b.css({filter:""})}:null}).centerThis({init:!0,speed:Math.round(.75*t.speed),marginTop:wt(),marginBottom:kt(),preScale:i&&t.preScale,animate:i&&t.preScale&&1!==t.preScale,fit:t.fitImage}):b.show().centerThis({init:!0,marginTop:wt(),marginBottom:kt(),fit:t.fitImage}),Dt(w)},50),S?Ht():t.slideshowOn&&st()},Rt=function(s,r){var l,d,c,u,f,m=Math.round(.8*b.width())-30,g=!(s.data(n.isvideo)||s.data(n.isaudio)||s.data(n.isother));S?(h=e("<div>",{"class":n.bottom}).appendTo(b),l=e("<div>",{"class":n.cont}).appendTo(h),typeof r!==UNDEF&&t.showImageNumbers&&l.append('<h4 class="nr"><strong>'+(r+1)+"</strong> / "+o.length+"</h4>"),(c=s.data(n.caption))&&l.append(c),f=s.data(n.src).replace(t.thumbs+"/",t.slides+"/")):(l=h.children("."+n.cont),f=s.attr("src")),d=e("<nav>",{"class":"buttons"}).prependTo(l),l.width()>m&&l.width(m);var v=function(a){a.preventDefault();var o=e(a.target),s=o.data("rel"),r=l.children("."+s),d=r.is(":visible"),c=kt(),h=r.outerHeight(!0);if(o.toggleClass(n.active,!d),s===n.map){var u=function(){d||r.children("."+n.mapcont).trigger("adjust")
};t.transitions?r.slideToggle("fast",u):(r.toggle(),setTimeout(u,50))}else t.transitions?r.slideToggle("fast"):r.toggle();return b&&t.fitFreespace&&b.centerThis({fit:t.fitImage,marginTop:wt(),marginBottom:c+(d?-h:h)}),i(s+"On",!d),!1},k=function(t,a){var i=e("<div>",{"class":n.panel+" "+t}).data("rel",t);if(a){var o=l.find("."+n.panel).eq(0);i=o.length?i.insertBefore(o):i.appendTo(l)}else i=i.appendTo(l);return i.append(e("<div>",{"class":n.icon})),i},y=function(i){var o=e("<a>",{"class":i+"-"+n.icon}).data("rel",i).appendTo(d);return t.buttonLabels&&o.text(a[i+"Btn"]||i),document.touchMode||o.addTooltip(a[i+"Label"]||(t.buttonLabels?"":a[i+"Btn"]||i)),o.on("click",v),o};if(t.shareSlides){var T;t.shareInline?(T=k(n.share,!0),y(n.share),T=e("<div>",{"class":n.shares}).css("min-height","25px").appendTo(T)):(T=e("<a>",{"class":n.share+"-"+n.icon}).appendTo(d),t.buttonLabels&&T.text(a.shareBtn)),S?(u="number"===t.hash?w+1:K(),setTimeout(function(){T.addSocial({hash:u,inline:t.shareInline,buttonLabels:t.shareLabels,title:(s.data(n.caption)||"").stripHTML(!0),image:f})},t.speed/2)):T.addSocial({useHash:!1,inline:t.shareInline,buttonLabels:t.shareLabels,title:(s.data(n.caption)||"").stripHTML(!0),image:f})}var x;!S&&(x=l.children("."+n.comments)).length&&(x.data("rel",n.comments),y(n.comments));for(var O,F=[n.meta,n.map,n.shop,n.print],M=0;M<F.length;M++)O=F[M],null==s.data(O)||O==n.map&&!t.mapOnSlide||(k(O),y(O));if(g){if(t.printOn){var P=e("<a>",{"class":n.print+"-"+n.icon,text:t.buttonLabels?a.printBtn:""});P.addTooltip(a.printLabel),setTimeout(function(){P.on("click",function(e){return e.preventDefault(),printImage(s.data(n.link)||f,s.attr("alt")||"",s.data(n.caption)||""),!1})},t.speed),d.append(P)}if(t.fotomotoOn){var C=e("<a>",{"class":n.fotomoto+"-"+n.icon,text:t.buttonLabels?a.fotomotoBtn:""});C.addTooltip(LOCAL?a.locationWarning:"<h5>Fotomoto</h5>"+a.fotomotoLabel),setTimeout(function(){C.on("click",function(e){return e.preventDefault(),typeof FOTOMOTO===UNDEF||LOCAL||FOTOMOTO.API.showWindow(10,s.data(n.link)||f),!1})},t.speed),d.append(C)}if(c=s.data(n.mostphotos)){c.startsWith("http")||(c="http://www.mostphotos.com/"+c);var L=e("<a>",{href:c,"class":n.mostphotos+"-"+n.icon,text:t.buttonLabels?a.mostphotosBtn:"",target:"_blank"}).appendTo(d);L.addTooltip("<h5>"+a.mostphotosBtn+"</h5>"+a.mostphotosLabel)}if(s.data(n.regions)){var D=e("<a>",{"class":n.regions+"-"+n.icon});t.buttonLabels&&D.text(a.people),t[n.regions+"On"]&&D.addClass(n.active),D.on("click",function(){i(n.regions+"On",!e(this).hasClass(n.active))}),d.append(D)}}c=s.data(n.link);var N=g&&t.hasOwnProperty("extraSizes")&&f.hasExt("jpg,png,jpeg");if(N||c&&(!g&&t.downloadNonImages||g&&!t.rightClickProtect)){var B=f.getFile(),A=e("<div>"),z=e("<a>",{href:c,"class":n.link+"-"+n.icon,download:"",target:"_blank"});t.buttonLabels&&z.text(t.hasOwnProperty("extraSizes")?a.download:s.data(n.isoriginal)?a.original:a.hiRes),A.append(e("<h5>",{text:a.download}));var E=e("<div>",{"class":"sizes"}).appendTo(A);if(N)for(var H=t.extraSizes.split(","),M=0;M<H.length;M++)E.append(e("<a>",{href:(S?"":"../")+"dl/"+H[M]+"/"+B,text:H[M],download:""}));c&&(E.append(e("<a>",{href:c,text:s.data(n.isoriginal)?a.original:a.hiRes,download:""})),A.append(e("<input>",{"class":"fullw",type:"text",value:c.fullUrl(),readonly:""})),"download"in z[0]||A.append(e("<small>",{html:a.saveTip}))),z.addTooltip(A,{stay:5e3}),d.append(z)}if(t.imgHook){var U=e("<a>",{"class":n.custom+"-"+n.icon});t.buttonLabels&&t.imgHookBtn&&U.text(t.imgHookBtn),U.on("click",function(a){a.preventDefault();var i=s.data(n.link)||(S?s.data(n.src):s.attr("src")).replace(t.thumbs+"/","");return e("body").addModal(e(t.imgHook.replace(/\%fileName\%/g,i)),{uid:n.custom,width:t.imgHookWidth||600,title:t.imgHookBtn,defaultButton:"okButton",resizable:!0,savePosition:!0}),!1}),d.append(U)}t.imgHookFn&&e.isFunction(t.imgHookFn)&&t.imgHookFn.call(s),l.children("."+n.panel).each(function(){var a=e(this),i=a.data("rel");if(i&&null!==(c=s.data(i))){if(i===n.map){var o=e("<div>",{"class":n.mapcont}).appendTo(a);if(o.width(l.width()-30),t.mapAll){var r=function(){S?Lt(this.link):window.location.href=this.link};o.addMap({click:r,markers:I,curr:parseInt(S?s.data(n.mapid):p.filter("."+n.active).find("img:first").data(n.mapid),10)})}else{var h=(s.data(n.caption)||"").stripHTML()||s.attr("alt")||w+1+"";o.addMap({map:c,label:h})}setTimeout(function(){o.trigger("adjust")},t.speed)}else if(i===n.shop){var u={};"+"!==c&&(u.options=c),null!==(c=s.data(n.discount))&&(u.discount=c),a.addShop(s.closest("a"),u)}else a.append(c);t[i+"On"]?d.children("a."+i+"-icon").addClass(n.active):a.hide()}}),d.html().length||d.remove(),t.infoOn||h.hide()},_t=function(){var i=e("<div>",{"class":n.feedback}),s=window.location.href.getDir(),r=e("<form>",{id:n.feedback}).appendTo(i);t.directKey&&(r.append('<input type="hidden" name="from" value="'+t.feedbackEmail.replace("|","@")+'">'),r.append('<input type="hidden" name="to" value="'+xDecrypt(t.directKey)+'">'),r.append(e('<p class="email"><label for="email">'+a.yourEmail+'</label><input id="email" name="email" type="email"></p>'))),r.append(e('<p class="subject"><label for="subject">'+a.subject+'</label><input id="subject" name="subject" value="'+t.albumName+(t.relPath.length?"/"+t.relPath:"")+'"></p>')),r.append(e('<p class="message"><label for="message">'+a.message+'</label><textarea id="message" name="message"></textarea></p>')),o.filter(function(){return e(this).children("."+n.active).length}).each(function(t){var i=e(this).find("img").eq(0),o=i.data("src"),l=(i.data(n.isimage)||i.data(n.isother)?o:i.data("link")||"").getFile();r.append(e('<div><aside><img src="'+o+'"></aside><div><a class="remove">&times;</a><label for="img'+t+'">'+l+'</label><input type="hidden" name="file['+(t+1)+']" value="'+s+"#"+encodeURIComponent(l)+'"><textarea id="img'+t+'" name="comment['+(t+1)+']" placeholder="'+a.comment+'"></textarea></div></div>'))}),r.find("a.remove").on("click",function(t){return t.preventDefault(),e(this).parents("div").eq(1).remove(),!1});var l=function(n){if(!n||!n.length)return console&&console.log("Submitform Error: Missing form"),!1;var i,o=!1,s=n.find("form").eq(0),r=window.location.href.split("#")[0];if(t.directKey){if(i=s.find("input#email").val(),!i.length||!i.match(/^\S+@\S+[\.][0-9a-z]+$/))return e("body").addModal(e("<div>",{html:a.emailMissing}),{type:"error"}),!1;var l=function(t){"Ok"===t.Result?e("body").addModal(e("<div>",{html:a.messageSent}),{autoFade:1500}):(o=!0,DEBUG&&console&&console.log("Error sending mail: Result="+t.Result+" Cause="+t.Cause),e("body").addModal(e("<div>",{html:"<h3>"+a.errorSending+'</h3><p class="err">'+t.Result+", "+t.Cause+"</p>"}),{type:"error"}))};if(e.ajax({url:"http://jalbum.net/integration/api/sendmail.json",dataType:"jsonp",data:s.serialize(),success:function(e){l(e)}}),o)return!1}else if(t.php)e.ajax({url:resPath+"feddback.php",type:"POST",data:{message:s.serialize(),subject:"Subject of your e-mail"},success:function(e){alert("You data has been successfully e-mailed"),alert("Your server-side script said: "+e)}});else{var d="mailto:"+encodeURIComponent(t.feedbackEmail.replace("|","@"));if(d+="?subject="+encodeURIComponent(s.find("input#subject").val()),d+="&body=",(i=s.find("textarea#message").val())&&(d+=encodeURIComponent(i+"\n\n")),s.children("div").each(function(t){d+=encodeURIComponent(t+1+". "+r+"#"+encodeURIComponent(e(this).find("label").eq(0).text())+"\n"),(i=e(this).find("textarea").val())&&(d+=encodeURIComponent(i+"\n")),d+=encodeURIComponent("\n")}),d.length>2048)return e("body").addModal(e("<div>",{html:"<p>"+a.tooLong+"</p>"}),{type:"error"}),!1;window.location.href=d}return!0};return r.on("submit",function(){return l(e("#feedback"))}),e("body").addModal(i,[{t:a.send,h:l}],{uid:"feedback",enableKeyboard:!1,title:a.sendFeedback,width:480,resizable:!0,savePosition:!0}),!1},jt=function(){var t=!1,i=o.filter(function(){var a,i=e(this);return i.children("."+n.checkbox).hasClass(n.active)?(i=i.children("img:first"),a=i.data(n.shop),t=!0,!(a&&"+"!==a||i.data(n.discount))):!1});if(0===i.length)return void e("body").addModal(e("<h3>"+a.noItemsSelected+"</h3><p>"+(t?a.nonShoppableItems:a.selectItemsHint)+"</p>"),{type:"warning"});var s=e("<div>",{"class":n.shopAll}),r=(window.location.href.getDir(),e("<ul>",{"class":n.thumbs}).appendTo(s));i.each(function(){r.append(e("<li>").append(e("<img>",{src:e(this).children("img:first").data("src")})))});var l=e("<div>",{"class":n.shop}).appendTo(s);l.addShop(i),e("body").addModal(s,{uid:n.shopAll+"w",title:a.buyNItems.replace("{0}",i.length),width:640,resizable:!0,savePosition:!0,enableKeyboard:!1,blocking:!0,defaultButton:"close"})},Wt=function(){c=e("<nav>",{"class":n.controls+" clearfix"}).appendTo(d),g.prev=e("<a>",{"class":n.prev,title:a.previousPicture}).appendTo(c),(!t.skipIndex||t.level||t.uplink)&&(g.up=e("<a>",{"class":n.up,title:t.skipIndex?a.upOneLevel:a.backToIndex}).appendTo(c)),g.noresize=e("<a>",{"class":n.noresize,title:a.oneToOneSize}).appendTo(c),g.resize=e("<a>",{"class":n.resize,title:a.fitToScreen}).appendTo(c),t.hideFitBtn?g.resize.add(g.noresize).hide():(g.resize.togglein(!t.fitImage),g.noresize.togglein(t.fitImage)),g.hideThumbs=e("<a>",{"class":n.hideThumbs,title:a.hideThumbs}).appendTo(c),g.showThumbs=e("<a>",{"class":n.showThumbs,title:a.showThumbs}).appendTo(c),g.showThumbs.togglein(!t.thumbsOn),g.hideThumbs.togglein(t.thumbsOn),g.hideInfo=e("<a>",{"class":n.hideInfo,title:a.hideInfo}).appendTo(c),g.showInfo=e("<a>",{"class":n.showInfo,title:a.showInfo}).appendTo(c),g.showInfo.togglein(!t.infoOn),g.hideInfo.togglein(t.infoOn),g.play=e("<a>",{"class":n.play,title:a.startAutoplay}).appendTo(c),g.pause=e("<a>",{"class":n.pause,title:a.stopAutoplay}).appendTo(c),o.length>1||"nextfolder"===t.afterLast?(g.play.togglein(!t.slideshowAuto),g.pause.togglein(t.slideshowAuto)):g.play.add(g.pause).hide(),g.next=e("<a>",{"class":n.next,title:a.nextPicture}).appendTo(c)},qt=function(){var n=0;c.children().each(function(){"none"!==e(this).css("display")&&(n+=e(this).outerWidth())}),c.css({marginLeft:-Math.floor(n/2)}),document.touchMode||c.children("a").not(g.play).addTooltip({delay:500});var a=e("<div>",{"class":"slideshowdelay",text:g.play.prop("title")}),o=e("<form>").appendTo(a);o.on("submit",function(e){return e.preventDefault(),st(),!1}).append(e("<input>",{type:"text",value:t.slideshowDelay/1e3}).focus().on("change",function(){return i("slideshowDelay",Math.round(parseFloat(1e3*e(this).val())||e.fn.turtle.defaults.slideshowDelay)),!0})).append(e("<a>",{"class":"button",text:" "}).on("click",en)),o.find("input"),g.play.prop("title","").addTooltip(a,{stay:5e3}),document.touchMode||(S?c.hide():M=setTimeout(function(){ct()},1500)),c.on({mouseenter:function(){F=!0,e(this).stop(!0,!1).fadeTo(200,1)},mouseleave:function(){F=!1,e(this).stop(!0,!1).fadeTo(200,.8)}}),document.touchMode||r.on("mousemove",function(e){!O&&(N-e.clientY||B-e.clientX)&&(B>=0&&dt(),B=e.clientX,N=e.clientY)})},Kt=function(e){return e.preventDefault(),rt(),tt(),!1},Yt=function(e){return e.preventDefault(),rt(),j(),!1},Qt=function(){return t.curr&&e.cookie("curr:"+t.albumName+"/"+t.relPath,t.curr,600),!0},Vt=function(e){return e.preventDefault(),St(),!1},Xt=function(e){return e.preventDefault(),It(),!1},$t=function(e){return e.preventDefault(),pt(),!1},Zt=function(e){return e.preventDefault(),ft(),!1},Gt=function(e){return e.preventDefault(),gt(),!1},Jt=function(e){return e.preventDefault(),bt(),!1},en=function(n){return n.preventDefault(),S&&t.slideshowFullScreen&&(F=!1,e("html").fullScreen(!0)),st(),!1},tn=function(e){return e.preventDefault(),rt(),!1},nn=function(e){return e.preventDefault(),ot(),nt(),!1},an=function(){Wt(),g.prev.on("click",Kt),g.up&&g.up.on("click",Yt),g.noresize.on("click",Vt),g.resize.on("click",Xt),g.hideInfo.on("click",$t),g.showInfo.on("click",Zt),g.hideThumbs.on("click",Gt),g.showThumbs.on("click",Jt),g.play.on("click",en),g.pause.on("click",tn),g.next.on("click",nn),qt()},on=function(){g.prev=c.children("."+n.prev),g.up=c.children("."+n.up),g.noresize=c.children("."+n.noresize),g.resize=c.children("."+n.resize),g.hideInfo=c.children("."+n.hideInfo),g.showInfo=c.children("."+n.showInfo),g.hideThumbs=c.children("."+n.hideThumbs),g.showThumbs=c.children("."+n.showThumbs),g.play=c.children("."+n.play),g.pause=c.children("."+n.pause),g.next=c.children("."+n.next),u.find("."+n.cont+" a").length>1?(g.play.togglein(!t.slideshowAuto),g.pause.togglein(t.slideshowAuto)):g.play.add(g.pause).hide(),t.hideFitBtn&&g.resize.add(g.noresize).hide(),g.up&&g.up.on("click",Qt),g.noresize.on("click",Vt),g.resize.on("click",Xt),g.hideInfo.on("click",$t),g.showInfo.on("click",Zt),g.hideThumbs.on("click",Gt),g.showThumbs.on("click",Jt),g.play.on("click",en),g.pause.on("click",tn),g.next.on("click",nn),qt()},sn=function(){var i,r,l=function(){var n=o.index(e(this));n&&e.cookie("curr:"+t.albumName+"/"+t.relPath,n,t.keepPrefs)};o.each(function(){i=e(this),r=i.find("img").eq(0),r.length&&(t.rightClickProtect&&i.on("contextmenu",noAction),r.attr("src").endsWith("/"+t.loadImg)&&r.addClass(n.toload),t.markNewDays&&f-parseInt(r.data(n.modified)||0,10)<=t.markNewDays&&i.append(e("<span>",{"class":n.newItem,text:a.newItem})),document.touchMode||i.addTooltip({delay:500}),S||o.on("click",l))}),setTimeout(function(){s.loadImages(),setTimeout(function(){s.loadImages()},1200)},100);var d=function(){return s.loadImages(),!0};document.touchMode&&(s[0].addEventListener("scroll",d),s[0].addEventListener(TOUCH_END,d)),Q(),e("#"+n.selectAll).on("click",function(e){return e.preventDefault(),Y(!0),!1}),e("#"+n.selectNone).on("click",function(e){return e.preventDefault(),Y(!1),!1}),e("#"+n.shopAll).on("click",jt)},rn=function(){s.find("."+n.folders).on("click",function(){return e.cookie("curr:"+t.albumName+"/"+t.relPath,null),!0})},ln=function(){var a,i,s,r,l,c,h,f,m,g,b=0;u=e("<div>",{"class":n.scrollbox}).appendTo(d),l=e("<div>",{"class":"wrap"}).appendTo(u),l=e("<ul>",{"class":n.cont+" "+n.load}).appendTo(l),o.each(function(){a=e(this),r=a.find("img").eq(0),r.length&&(i=e("<a>",{href:NOLINK}).appendTo(e("<li>").appendTo(l)),c||(isNaN(c=parseInt(i.css("width"),10))&&(c=133),isNaN(h=parseInt(i.css("height"),10))&&(h=100)),f=r.attr("width"),m=r.attr("height"),(f>c||m>h)&&(f/c>m/h?(m=Math.round(m*c/f),f=c):(f=Math.round(f*h/m),m=h)),s=e("<img>",{src:r.attr("src"),"class":r.attr("class")}).data({src:r.data("src")}).appendTo(i),f&&m&&s.attr({width:f,height:m}),g=a.children("."+n.newItem),g.length&&i.append(g.clone()),document.touchMode||i.addTooltip(a.data("hint")||a.siblings("."+n.caption).html(),{delay:500}))}),i=l.children("li").first(),i.length&&(isNaN(b=parseInt(i.css("width"),10))?b=135:b+=(parseInt(i.css("marginLeft"),10)||0)+(parseInt(i.css("marginRight"),10)||0),l.width(b*l.children().length+2)),l.scrollThumbs({enableMouseWheel:t.enableMouseWheel}),p=u.find("li > a"),p.on("click",function(){return e(this).parents("[role=scroll]").data("dragOn")===!0?!1:(e(this).hasClass(n.active)||(rt(),Lt(p.index(e(this)))),V(),!1)})},dn=function(){var a=u.find("."+n.cont),i=0;document.touchMode||p.addTooltip({delay:500}).each(function(){i+=e(this).outerWidth()}),i+=2*p.length,a.width(i),a.scrollThumbs({enableMouseWheel:t.enableMouseWheel}),p.on("click",function(){return!e(this).parents("[role=scroll]").data("dragOn")}),a.trigger("setactive"),t.thumbsOn||d.css("top",-u.outerHeight()-10)},cn=function(){z(e(t.header)),s=e("."+n.items),o.length&&sn(),rn(),e("#"+n.feedback).on("click",_t),o.length&&((t.mapOnIndex||t.mapAll&&t.mapOnSlide)&&(I=o.collectMarkers({dynamic:S})),t.mapOnIndex&&I.length&&e("#"+n.map+" ."+n.cont).addMap({click:function(){S?Lt(this.link):window.location.href=this.link},markers:I,range:999,curr:0}),null===(w=e.cookie("curr:"+t.albumName+"/"+t.relPath))||w>=o.length?(w=0,V(!0)):setTimeout(function(){V()},300),(e.isFunction(t.enableKeyboard)||t.enableKeyboard)&&e(window).on("keydown",U))},hn=function(){o.on("click",Ft),r=e("<div>",{"class":n.gallery}).attr("role","gallery").appendTo("body"),l=e("<div>",{"class":n.wait}).appendTo(r),d=e("<div>",{"class":n.navigation}).appendTo(r),ln(),an(),t.thumbsOn||d.css("top",-u.outerHeight()-10),u.on({mouseenter:function(){ct(),O=!0},mouseleave:function(){O=!1}}),"page"!==e("body").attr("id")&&t.hash&&"no"!==t.hash&&e.history.init(Pt);var a=e.cookie("slideshowDelay");t.slideshowAuto||a&&e.isNumeric(a)?(S&&t.slideshowFullScreen&&e("html").fullScreen(!0),a&&e.isNumeric(a)&&(t.slideshowDelay=a),Lt(w),st()):(rt(),t.skipIndex&&Lt(w)),(e.isFunction(t.enableKeyboard)||t.enableKeyboard)&&e(window).on("keydown",R)},un=function(){r=e("."+n.gallery),d=e("."+n.navigation),c=e("."+n.controls),b=e("."+n.img),h=e("."+n.bottom),o=b.children("."+n.main),w=0,u=e("."+n.scrollbox),p=u.find("li > a");var a=o.find("img:first");t.mapAll&&(I=p.collectMarkers()),dn(),on(),mt(),ut(),Tt(),a.length&&(o.hasClass(n.image)&&!a[0].complete?(a.on("load",function(){a.data("cached",!0),Ut()}).attr({src:a.attr("src")}),l=e("<div>",{"class":n.wait}).appendTo(r),l.fadeIn()):(a.data("cached",!0),Ut()),Rt(a)),(e.isFunction(t.enableKeyboard)||t.enableKeyboard)&&e(window).on("keydown",R)};return T?(setTimeout(E,1e3),o=e(this).find("td > a"),cn(),o.length&&S&&hn(),t.showCookiePolicy&&setTimeout(H,2e3)):(o=e(this),un()),(o.length&&S||!x)&&(e(window).on("resize",D),document.touchMode&&e(window).on("orientationchange",D)),this},e.fn.turtle.defaults={header:"#main header",slides:"slides",thumbs:"thumbs",linkSlides:!1,loadImg:"blank.png",hash:"fileName",resPath:"res/",relPath:"",level:0,skipIndex:!1,showStart:!0,keepPrefs:600,speed:600,controlbarOpacity:0,controlOutOpacity:0,transitions:!0,preScale:.95,slideshowDelay:4e3,slideshowLoop:!1,slideshowAuto:!1,slideshowFullScreen:!1,markNewDays:0,afterLast:"ask",thumbsOn:!1,fitImage:!1,fitShrinkonly:!1,fitFreespace:!0,hideFitBtn:!1,fitPadding:15,borderWidth:10,clickForNext:!0,clickBesideForIndex:!1,rightClickProtect:!1,cookiePolicyStay:8,showImageNumbers:!0,buttonLabels:!1,infoOn:!0,metaOn:!1,mapOn:!1,mapOnIndex:!1,mapOnSlide:!1,mapType:"roadmap",mapZoom:18,mapAll:!1,shopOn:!0,shopGateway:"paypal",shopCurrency:"USD",shareOn:!1,commentOn:!1,printOn:!1,regionsOn:!1,downloadNonImages:!1,enableKeyboard:!0,enableMouseWheel:!0,videoAuto:!1,videoMaximize:!1,videoTitleOn:!1,prioritizeFlash:!1,scrollDuration:1e3},e.fn.turtle.ids={gallery:"gallery",items:"items",folders:"folders",thumbs:"thumbs",navigation:"navigation",scrollbox:"scrollbox",active:"active",parent:"parent",bottom:"bottom",img:"img",main:"main",image:"image",video:"video",audio:"audio",other:"other",wait:"wait",cont:"cont",panel:"panel",icon:"icon",caption:"caption",meta:"meta",map:"map",mapcont:"mapcont",mapid:"mapid",shop:"shop",shopAll:"shopall",discount:"discount",fotomoto:"fotomoto",mostphotos:"mostphotos",share:"share",shares:"shares",print:"print",comments:"comments",link:"link",custom:"custom",poster:"poster",isoriginal:"isoriginal",content:"content",width:"width",height:"height",src:"src",ext:"ext",thumbExt:"thumbext",regions:"regions",isimage:"isimage",isvideo:"isvideo",isaudio:"isaudio",isother:"isother",modified:"modified",startShow:"startshow",startBtn:"startbtn",startTxt:"starttxt",controls:"controls",prev:"prev",next:"next",up:"up",noresize:"noresize",resize:"resize",hideInfo:"hideinfo",showInfo:"showinfo",hideThumbs:"hidethumbs",showThumbs:"showthumbs",play:"play",pause:"pause",newItem:"newlabel",showHint:"showhint",kill:"kill",load:"load",toload:"toload",feedback:"feedback",checkbox:"checkbox",selectAll:"selectall",selectNone:"selectnone"},e.fn.turtle.text={startSlideshow:"Start slideshow",close:"Close",atLastPage:"At last page",atLastPageQuestion:"Where to go next?",startOver:"Start over",backToHome:"Back to home",stop:"Stop",upOneLevel:"Up one level",backToIndex:"Back to index page",previousPicture:"Previous picture",nextPicture:"Next picture",previousFolder:"Previous folder",nextFolder:"Next folder",changeSpeed:"Change speed",oneToOneSize:"1:1 size",fitToScreen:"Fit to screen",showInfo:"Show caption / info",hideInfo:"Hide caption / info",showThumbs:"Show thumbnails",hideThumbs:"Hide thumbnails",startAutoplay:"Start autoplay",stopAutoplay:"Stop autoplay",newItem:"NEW",clickToOpen:"Click to open this document with the associated viewer",commentsBtn:"Comments",commentsLabel:"Add a comment, view other's comments",metaBtn:"Photo data",metaLabel:"Display photograpic (Exif/Iptc) data",mapBtn:"Map",mapLabel:"Show the photo location on map",printBtn:"Print",printLabel:"Print out this photo on your printer",shopBtn:"Buy",shopLabel:"Show options to buy this item",shareBtn:"Share",shareLabel:"Share this photo over social sites",download:"Download",original:"Original",hiRes:"Hi res.",saveTip:"Use Right click -> Save link as... to download",fotomotoBtn:"Buy / Share",fotomotoLabel:"Buy prints or digital files, send free eCard through Fotomoto",mostphotosBtn:"Purchase",mostphotosLabel:"Download this image from <b>mostphotos.com</b>!",people:"People",sendFeedback:"Send feedback",message:"Message",subject:"Subject",comment:"Comment",yourEmail:"Your email address",send:"Send",messageSent:"Message sent",errorSending:"Error sending email!",tooLong:"Text is too long or too many items!",emailMissing:"Email is misssing or wrong!",noItemsSelected:"No items selected!",selectItemsHint:"Select the desired items first!",nonShoppableItems:"The selected items have no or have proprietary shopping options, or different discount rates.",buyNItems:"Buy {0} items",locationWarning:"Works only when uploaded",cookiePolicyText:"This album uses cookies to remember user preferences. By using it, you agree to our use of cookies.",cookiePolicyAgree:"Got it",cookiePolicyLearnMore:"Learn more"}}(jQuery);

PHP File Manager