Version Description
= 8.1.08 =
- This version addresses various bug fixes, feature requests and security fixes.
Download this release
Release Info
Developer | opajaap |
Plugin | WP Photo Album Plus |
Version | 8.2.01.002 |
Comparing to | |
See all releases |
Code changes from version 8.1.10.005 to 8.2.01.002
- changelog.txt +7 -0
- js/wppa-all.js +4 -2
- js/wppa-flatpan.js +553 -0
- js/wppa-flatpan.min.js +1 -0
- js/wppa-slideshow.js +16 -18
- js/wppa-slideshow.min.js +1 -1
- js/wppa-zoom.js +48 -74
- js/wppa-zoom.min.js +1 -1
- wppa-admins-choice-widget.php +2 -2
- wppa-album-navigator-widget.php +5 -9
- wppa-album-widget.php +9 -10
- wppa-bestof-widget.php +15 -18
- wppa-cache.php +2 -2
- wppa-comment-widget.php +14 -14
- wppa-common-functions.php +20 -18
- wppa-featen-widget.php +11 -11
- wppa-functions.php +2 -2
- wppa-gp-widget.php +5 -7
- wppa-input.php +3 -2
- wppa-lasten-widget.php +16 -21
- wppa-multitag-widget.php +18 -22
- wppa-non-admin.php +13 -9
- wppa-picture.php +106 -563
- wppa-potd-widget.php +3 -5
- wppa-qr-widget.php +9 -9
- wppa-scripts.php +4 -2
- wppa-search-widget.php +2 -10
- wppa-setting-functions.php +16 -11
- wppa-settings-autosave.php +4 -20
- wppa-slideshow-widget.php +27 -68
- wppa-stats-widget.php +1 -19
- wppa-stereo-widget.php +1 -3
- wppa-super-view-widget.php +1 -6
- wppa-tagcloud-widget.php +2 -6
- wppa-thumbnail-widget.php +10 -15
- wppa-topten-widget.php +17 -22
- wppa-upldr-widget.php +2 -7
- wppa-upload-widget.php +1 -4
- wppa-upload.php +17 -9
- wppa-utils.php +13 -26
- wppa-widget-functions.php +85 -68
- wppa-wpdb-update.php +5 -5
- wppa-wrappers.php +2 -1
- wppa.php +2 -2
changelog.txt
CHANGED
@@ -1,5 +1,12 @@
|
|
1 |
WP Photo Album Plus Changelog
|
2 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
3 |
= 8.1.10 =
|
4 |
|
5 |
* Widgets do no longer give errors in the widget block editor.
|
1 |
WP Photo Album Plus Changelog
|
2 |
|
3 |
+
= 8.2.01 =
|
4 |
+
|
5 |
+
* The start/stop icon in the center of the slideshow sometimes displayed the wrong icon. Fixed.
|
6 |
+
* Optimized code for zoomable images and flat panoramas.
|
7 |
+
* Fixed layout and text issues on the settings page.
|
8 |
+
* Description field in album and photo admin lost linebreaks. Fixed.
|
9 |
+
|
10 |
= 8.1.10 =
|
11 |
|
12 |
* Widgets do no longer give errors in the widget block editor.
|
js/wppa-all.js
CHANGED
@@ -3,7 +3,7 @@ function wppaAnimate(e,t,a,p,i){wppaIsMobile&&wppaNoAnimateOnMobile?(jQuery(e).c
|
|
3 |
// wppa
|
4 |
function wppaTabbyClick(){jQuery(window).trigger("resize"),jQuery(document).trigger("tabbychange"),jQuery(window).trigger("orientationchange"),wppaAdjustAllFilmstrips(wppaEasingSlide)}function wppaQRUpdate(e){wppaAjaxSetQrCodeSrc(e,"#wppa-qr-img")}function wppaDoInit(){_wppaTextDelay=wppaAnimationSpeed,wppaFadeInAfterFadeOut&&(_wppaTextDelay*=2),wppaIsMobile&&wppaNoAnimateOnMobile&&(_wppaTextDelay=10),jQuery(".wppa-ajax-spin").hide(),jQuery(".wppa-ovl-spin").hide(),setTimeout(function(){jQuery(".wppa-ubb").each(function(){var e=jQuery(this).attr("id").substr(6);wppaUbb(e,"l","hide"),wppaUbb(e,"r","hide")})},3e3),jQuery(window).on("DOMContentLoaded load resize wppascrollend orientationchange",wppaDoAllAutocols),jQuery(window).on("DOMContentLoaded load resize scroll wheel orientationchange",wppaSizeArea),jQuery(window).on("DOMContentLoaded load resize wppascrollend orientationchange",function(){wppaMakeLazyVisibleScrollEnd("doinitwindowon")}),jQuery(".wppa-divnicewrap").on("DOMContentLoaded load resize wppascrollend wheelend orientationchange",function(){wppaMakeLazyVisibleScrollEnd("doinitnicewrapon")}),jQuery(window).on("DOMContentLoaded load resize wppascrollend orientationchange",wppaInitMasonryPlus),jQuery(window).on("resize",function(){wppaAdjustAllFilmstrips(wppaEasingSlide)}),jQuery(window).on("DOMContentLoaded load resize wppascrollend orientationchange",function(){setTimeout(function(){wppaResizeNice()},1e3)}),jQuery(window).trigger("resize"),wppaProtect(),setTimeout(function(){jQuery(".responsive-tabs__heading").on("click",wppaTabbyClick),jQuery(".responsive-tabs__list__item").on("click",wppaTabbyClick)},10),jQuery(document).on("tabbychange",function(){void 0!==jQuery("div").getNiceScroll&&setTimeout(function(){jQuery("div").getNiceScroll().resize(),wppaDoAllAutocols()},500),setTimeout(function(){wppaDoAllAutocols(),jQuery(window).trigger("resize"),jQuery("#wppa-ovl-spin").hide(),wppaMakeLazyVisibleScrollEnd("tabbychange")},1500)}),wppaOvlGlobal&&jQuery("a").each(function(){var e=jQuery(this).attr("href");e&&("jpg"!=(e=(e=e.split("."))[e.length-1])&&"jpeg"!=e&&"png"!=e||jQuery(this).attr("data-rel")||(jQuery(this).attr("data-rel",wppaOvlGlobal),jQuery(this).css("cursor","wait")))}),jQuery("div").on("touchmove",wppaMakeLazyVisibleScrollEnd)}var wppaResizeNiceTimer,wppaResizeEndTimer,wppaScrollEndTimer;function wppaResizeNice(){clearTimeout(wppaResizeNiceTimer),wppaResizeNiceTimer=setTimeout(function(){_wppaResizeNice()},200)}function _wppaResizeNice(){"function"==typeof jQuery("body").getNiceScroll&&jQuery("body").getNiceScroll().resize(),jQuery("div").each(function(){"function"==typeof jQuery(this).getNiceScroll&&jQuery(this).getNiceScroll().resize()})}function wppaSizeAutoDiv(){jQuery(".wppa-autodiv").each(function(e){var p=jQuery(window).height(),a=jQuery(this).attr("data-max-height");jQuery(this).css({maxHeight:p*a})})}wppaWppaVer="8.1.07.001",jQuery(document).ready(function(){wppaConsoleLog("Document.ready","force")}),jQuery(document).ready(function(){wppaDoInit()}),jQuery(document).ready(function(){wppaQRUpdate(document.location.href)}),window.onpopstate=function(e){wppaQRUpdate(document.location.href)},jQuery(document).ready(function(){jQuery(window).on("resize load",function(){clearTimeout(wppaResizeEndTimer),wppaResizeEndTimer=setTimeout(function(){jQuery(window).trigger("wpparesizeend")},wppaResizeEndDelay)})}),jQuery(document).ready(function(){jQuery(window).on("scroll wheel touchmove",function(){clearTimeout(wppaScrollEndTimer),wppaScrollEndTimer=setTimeout(function(){jQuery(window).trigger("wppascrollend")},wppaScrollEndDelay)})}),jQuery(document).ready(function(){jQuery(window).on("DOMContentLoaded load resize scroll wheel orientationchange",wppaSizeAutoDiv)});var wppaLastAllAutocols=0,wppaLastAllAutocolsTimer=0;function wppaDoAllAutocols(e){wppaTimNow()<wppaLastAllAutocols+200?wppaLastAllAutocolsTimer=wppaLastAllAutocolsTimer||setTimeout(wppaDoAllAutocols,200):(clearTimeout(wppaLastAllAutocolsTimer),wppaLastAllAutocols=wppaTimNow(),_wppaDoAllAutocols(0))}function _wppaDoAllAutocols(p){return jQuery(".wppa-container").each(function(){var e=jQuery(this).attr("id").substr(15);wppaAutoColumnWidth[e]&&_wppaDoAutocol(e,p)}),(p<wppaExtendedResizeCount||-1==wppaExtendedResizeCount)&&setTimeout(function(){_wppaDoAllAutocols(p+1)},wppaExtendedResizeDelay),!0}function wppaProtect(){wppaHideRightClick&&(jQuery("img").bind("contextmenu",function(e){return!1}),jQuery("video").bind("contextmenu",function(e){return!1}),jQuery("canvas").bind("contextmenu",function(e){return!1}))}function wppaUpdateLightboxes(){"function"==typeof wppaInitOverlay&&wppaInitOverlay(),"undefined"!=typeof myLightbox&&"function"==typeof myLightbox.updateImageList&&myLightbox.updateImageList(),jQuery().prettyPhoto&&jQuery("a[rel^='prettyPhoto']").prettyPhoto({deeplinking:!1})}function wppaStopVideo(e){var p,a,t=[];for(t[1]="wppa-overlay-img",t[2]="theimg0-"+e,t[3]="theimg1-"+e,a=0;a<3;)1==++a&&0!=e||(p=document.getElementById(t[a]))&&"function"==typeof p.pause&&p.pause()}function wppaStopAudio(e){if("number"==typeof e)jQuery("#audio-"+e).pause&&jQuery("#audio-"+e).pause();else{var p=jQuery("audio");if(0<p.length)for(var a=0;a<p.length;)"wppa"==jQuery(p[a]).attr("data-from")&&p[a].pause(),a++}}function wppaMakeFullsizeUrl(e){var p,a;e=(p=(e=e.replace("/thumbs/","/")).split("//"))[1]?(a=p[1].split("/"),p[0]+"//"):(a=p[0].split("/"),"");for(var t=0;t<a.length;){var o=a[t];"w"!=o.split("_")[0]&&(0!=t&&(e+="/"),e+=o),t++}return e}function wppaGetContainerWidth(e){var p=document.getElementById("wppa-container-"+e);if(p){var a=0;if(!wppaAutoColumnWidth[e])return p.clientWidth;for(;0==a;)p=p.parentNode,a=jQuery(p).width();return parseInt(a)}}function _wppaDoAutocol(e,p){if(!wppaAutoColumnWidth[e])return!0;var a,t,o=wppaGetContainerWidth(e);if(document.getElementById("wppa-container-"+e)){if(wppaCoverImageResponsive[e]||1<(a=jQuery(".wppa-asym-text-frame-"+e)).length&&(jQuery(a[0]).width(),0==wppaResponseSpeed?(jQuery(".wppa-asym-text-frame-"+e).css({width:o-wppaTextFrameDelta}),jQuery(".wppa-cover-box-"+e).css({width:o})):(wppaAnimate(".wppa-asym-text-frame-"+e,{width:o-wppaTextFrameDelta},wppaResponseSpeed,wppaEasingDefault),wppaAnimate(".wppa-cover-box-"+e,{width:o},wppaResponseSpeed,wppaEasingDefault))),1<(a=jQuery(".wppa-cover-box-mcr-"+e)).length){var r=document.getElementById("wppa-albumlist-"+e).clientWidth,n=parseInt((r+wppaCoverSpacing)/(wppaMaxCoverWidth+wppaCoverSpacing))+1,s=n-1,i=parseInt((r+wppaCoverSpacing)/n-wppaCoverSpacing);if(wppaColWidth[e]!=r||wppaMCRWidth[e]!=i){wppaColWidth[e]=r,wppaMCRWidth[e]=i;for(var l=0;l<a.length;){switch(l%n){case 0:jQuery(a[l]).css({marginLeft:"0px",clear:"both",float:"left"});break;case s:jQuery(a[l]).css({marginLeft:"0px",clear:"none",float:"right"});break;default:jQuery(a[l]).css({marginLeft:wppaCoverSpacing,clear:"none",float:"left"})}l++}wppaCoverImageResponsive[e]||wppaAnimate(".wppa-asym-text-frame-mcr-"+e,{width:i-wppaTextFrameDelta},wppaResponseSpeed,wppaEasingDefault),jQuery(a[0]).width(),wppaAnimate(".wppa-cover-box-mcr-"+e,{width:i},wppaResponseSpeed,wppaEasingDefault)}}else 1==a.length&&(wppaCoverImageResponsive[e]||(wppaAnimate(".wppa-asym-text-frame-mcr-"+e,{width:o-wppaTextFrameDelta},wppaResponseSpeed,wppaEasingDefault),jQuery(".wppa-cover-box-mcr-"+e).css({marginLeft:"0px",float:"left"})));0<jQuery(".wppa-album-cover-grid-"+e).length&&(jQuery("#wppa-container-"+e).css("line-height","0"),(t=parseInt(o/wppaMaxCoverWidth+.9999))<1&&(t=1),jQuery(".wppa-album-cover-grid-"+e).css({width:100/t+"%"})),!wppaThumbSpaceAuto||(r=parseInt(jQuery(".thumbnail-frame-"+e).css("width")))&&(i=wppaMinThumbSpace,t=o-wppaThumbnailAreaDelta-7,i=Math.max(1,parseInt(t/(r+i))),i=parseInt((t-i*r)/(i+1)),jQuery(".thumbnail-frame-"+e).css({marginLeft:i})),jQuery(".thumbnail-frame-comalt-"+e).css("width",o-wppaThumbnailAreaDelta),jQuery(".wppa-com-alt-"+e).css("width",o-wppaThumbnailAreaDelta-wppaComAltSize-16);for(var u,c=1,w=jQuery("#wppa-mas-h-"+c+"-"+e).attr("data-height-perc");w;)u=w*(o-wppaThumbnailAreaDelta)/100,jQuery("#wppa-mas-h-"+c+"-"+e).css("height",u),c++,w=jQuery("#wppa-mas-h-"+c+"-"+e).attr("data-height-perc");return wppaSetMasHorFrameWidthsForIeAndChrome(e),document.getElementById("slide_frame-"+e)&&wppaFormatSlide(e),jQuery("#audio-slide-"+e).css("width",o-wppaBoxDelta-6),jQuery(".wppa-comment-textarea-"+e).css("width",.7*o),wppaFilmStripLength[e]=o-wppaFilmStripAreaDelta[e],jQuery("#filmwindow-"+e).css("width",wppaFilmStripLength[e]),_wppaAdjustFilmstrip(e,wppaEasingSlide),wppaIsMini[e]||void 0===_wppaSlides[e]||(wppaColWidth[e]<wppaMiniTreshold?(jQuery("#wppa-avg-rat-"+e).html(wppaAvgRat),jQuery("#wppa-my-rat-"+e).html(wppaMyRat),jQuery("#counter-"+e).html(_wppaCurIdx[e]+1+" / "+_wppaSlides[e].length)):(jQuery("#wppa-avg-rat-"+e).html(wppaAvgRating),jQuery("#wppa-my-rat-"+e).html(wppaMyRating),jQuery("#counter-"+e).html(wppaPhoto+" "+(_wppaCurIdx[e]+1)+" "+wppaOf+" "+_wppaSlides[e].length))),jQuery(".wppa-sphoto-"+e).css("width",o),jQuery(".wppa-simg-"+e).css("width",o-2*wppaSlideBorderWidth),jQuery(".wppa-simg-"+e).css("height",""),jQuery(".wppa-mphoto-"+e).css("width",o+10),jQuery(".wppa-mimg-"+e).css("width",o),jQuery(".wppa-mimg-"+e).css("height",""),jQuery(".smxpdf-"+e).css("height",.8*wppaWindowHeight()),0<wppaSearchBoxSelItems[e]&&(o/wppaSearchBoxSelItems[e]<125?jQuery(".wppa-searchsel-item-"+e).css("width","100%"):jQuery(".wppa-searchsel-item-"+e).css("width",100/wppaSearchBoxSelItems[e]+"%")),jQuery(".wppa-upload-album-"+e).css("maxWidth",.6*o),wppaSetRealCalendarHeights(e),!0}}function wppaSetRealCalendarHeights(p){var a,t,o,e=jQuery("#wppa-real-calendar-"+p).width();0<e&&(a=!0,t=e*wppaThumbAspect/7,jQuery(".wppa-real-calendar-day-"+p).css({height:t}),e=e/50+2,jQuery("#wppa-real-calendar-"+p).css({fontSize:e}),e=e/4,jQuery(".wppa-real-calendar-head-td-"+p).css({marginTop:e,marginBottom:e}),o=t/2,jQuery(".wppa-realcalimg-"+p).each(function(){var e;0==this.height?a=!1:(e=jQuery(this).attr("data-day"),thisb=o-(t-this.height)/2,jQuery(".wppa-real-calendar-day-content-"+e+"-"+p).css({bottom:thisb}))}),a||setTimeout(function(){wppaSetRealCalendarHeights(p)},100))}function wppaSetMasHorFrameWidthsForIeAndChrome(e){for(var p=jQuery(".wppa-mas-h-"+e),a=wppaMinThumbSpace,t=0;t<p.length;t++){var o=wppaGetChildI(p[t]);if(o){if("IMG"==o.nodeName&&!o.complete)return void setTimeout("wppaSetMasHorFrameWidthsForIeAndChrome( "+e+" )",400);o=o.naturalWidth/o.naturalHeight*o.height+a;jQuery(p[t]).css({width:o})}}}function wppaGetChildI(e){for(var p=e.childNodes,a=0;a<p.length;a++){var t=p[a];if(t.id&&"i-"==t.id.substr(0,2))return t;t=wppaGetChildI(t);if(t)return t}return!1}jQuery(document).ready(function(e){if(wppaAllowAjax&&jQuery.ajax&&(wppaCanAjaxRender=!0),void 0!==history.pushState){for(var p=1;p<=wppaMaxOccur;)wppaStartHtml[p]=jQuery("#wppa-container-"+p).html(),p++;wppaCanPushState=!0}});var wppaFotomotoLoaded=!1,wppaFotomotoToolbarIds=[];function fotomoto_loaded(){wppaFotomotoLoaded=!0}function wppaFotomotoToolbar(e,p){if(!(wppaColWidth[e]>=wppaFotomotoMinWidth))return jQuery("#wppa-fotomoto-container-"+e).css("display","none"),void jQuery("#wppa-fotomoto-checkout-"+e).css("display","none");jQuery("#wppa-fotomoto-container-"+e).css("display","inline"),jQuery("#wppa-fotomoto-checkout-"+e).css("display","inline"),wppaFotomoto&&document.getElementById("wppa-fotomoto-container-"+e)&&(wppaFotomotoLoaded?(FOTOMOTO.API.checkinImage(p),wppaFotomotoToolbarIds[e]=FOTOMOTO.API.showToolbar("wppa-fotomoto-container-"+e,p)):setTimeout("wppaFotomotoToolbar( "+e+',"'+p+'" )',200))}function wppaFotomotoHide(e){jQuery("#wppa-fotomoto-container-"+e).css("display","none"),jQuery("#wppa-fotomoto-checkout-"+e).css("display","none")}function wppaStringContainsForbiddenChars(e){for(var p=["?","&","#","/",'"',"'"],a=0;a<p.length;){if(-1!=e.indexOf(p[a]))return!0;a++}return!1}function wppaPushStateSlide(e,p,a){wppaIsMini[e]||wppaCanPushState&&wppaUpdateAddressLine&&""!=a&&jQuery(document).ready(function(){setTimeout(function(){try{history.pushState({page:wppaHis,occur:e,type:"slide",slide:p},"---",a),wppaQRUpdate(a),wppaConsoleLog("Pushed history stack","force")}catch(e){wppaConsoleLog("Slide history stack update failed")}},1e3)})}function wppaRepairScriptTags(e){if(void 0===e)return"";for(;-1!=e.indexOf("[script");)e=e.replace("[script","<script");for(;-1!=e.indexOf("[/script");)e=e.replace("[/script","</script");return e}function wppaRepairBrTags(e){return void 0===e?"":e.replace("[br /]","<br />").replace("[a","<a").replace(/"/g,'"').replace('"]','">').replace("[/a]","</a>").replace("[img","<img").replace("/]","/>")}function wppaTrimAlt(e){return void 0===e?"":13<e.length?e.substr(0,10)+"...":e}var wppaFbInitBusy=!1;function wppaFbInit(){wppaFbInitBusy||("undefined"!=typeof FB?(wppaFbInitBusy=!0,setTimeout("_wppaFbInit()",10)):setTimeout("wppaFbInit()",200))}function _wppaFbInit(){FB.init({status:!0,xfbml:!0}),wppaFbInitBusy=!1}function wppaInsertAtCursor(e,p){var a,t;document.selection?(e.focus(),sel=document.selection.createRange(),sel.text=p):e.selectionStart||"0"==e.selectionStart?(a=e.selectionStart,t=e.selectionEnd,e.value=e.value.substring(0,a)+p+e.value.substring(t,e.value.length),e.selectionStart=a+p.length,e.selectionEnd=a+p.length):e.value+=p}function wppaGeoInit(e,p,a){var t,o;document.getElementById("map-canvas-"+e)&&(p=new google.maps.LatLng(p,a),a={disableDefaultUI:!1,panControl:!1,zoomControl:!0,mapTypeControl:!0,scaleControl:!0,streetViewControl:!0,overviewMapControl:!0,zoom:wppaGeoZoom,center:p},t=new google.maps.Map(document.getElementById("map-canvas-"+e),a),o=new google.maps.Marker({position:p,map:t,title:""}),google.maps.event.addListener(t,"center_changed",function(){window.setTimeout(function(){t.panTo(o.getPosition())},1e3)}))}function wppaEncode(e){if(void 0!==e){for(var p=(t=(t=String(e).replace(/#/g,"||HASH||")).replace(/&/g,"||AMP||")).split("+"),a=0,t="";a<p.length;)t+=p[a],++a<p.length&&(t+="||PLUS||");return t}}function wppaUrlToId(e){var p=e.split("/wppa/");return 1==p.length&&(p=e.split("/upload/")),1==p.length?0:p=(p=(p=(p=(p=(p=(p=p[1]).split("."))[0].replace("/","")).replace("/","")).replace("/","")).replace("/","")).replace("/","")}function wppaSuperSearchSelect(e,p){jQuery("#wppa-ss-albumopt-"+e).css("display","none"),jQuery("#wppa-ss-albumcat-"+e).css("display","none"),jQuery("#wppa-ss-albumname-"+e).css("display","none"),jQuery("#wppa-ss-albumtext-"+e).css("display","none"),jQuery("#wppa-ss-photoopt-"+e).css("display","none"),jQuery("#wppa-ss-photoname-"+e).css("display","none"),jQuery("#wppa-ss-photoowner-"+e).css("display","none"),jQuery("#wppa-ss-phototag-"+e).css("display","none"),jQuery("#wppa-ss-phototext-"+e).css("display","none"),jQuery("#wppa-ss-photoexif-"+e).css("display","none"),jQuery("#wppa-ss-photoiptc-"+e).css("display","none"),jQuery("#wppa-ss-exifopts-"+e).css("display","none"),jQuery("#wppa-ss-iptcopts-"+e).css("display","none"),jQuery("#wppa-ss-spinner-"+e).css("display","none"),jQuery("#wppa-ss-button-"+e).css("display","none");var a=jQuery("#wppa-ss-pa-"+e).val(),t="",o="",r="";switch(a){case"a":switch(jQuery("#wppa-ss-albumopt-"+e).css("display",""),t=jQuery("#wppa-ss-albumopt-"+e).val()){case"c":jQuery("#wppa-ss-albumcat-"+e).css("display","");var n=jQuery(".wppa-ss-albumcat-"+e),r="";for(s=0;s<n.length;s++)jQuery(n[s]).prop("selected")&&(r+="."+jQuery(n[s]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"n":jQuery("#wppa-ss-albumname-"+e).css("display",""),null!=(r=jQuery("#wppa-ss-albumname-"+e).val())&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"t":jQuery("#wppa-ss-albumtext-"+e).css("display","");n=jQuery(".wppa-ss-albumtext-"+e);for(r="",s=0;s<n.length;s++)jQuery(n[s]).prop("selected")&&(r+="."+jQuery(n[s]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+e).css("display","")}break;case"p":switch(jQuery("#wppa-ss-photoopt-"+e).css("display",""),t=jQuery("#wppa-ss-photoopt-"+e).val()){case"n":jQuery("#wppa-ss-photoname-"+e).css("display",""),null!=(r=jQuery("#wppa-ss-photoname-"+e).val())&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"o":jQuery("#wppa-ss-photoowner-"+e).css("display",""),null!=(r=jQuery("#wppa-ss-photoowner-"+e).val())&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"g":jQuery("#wppa-ss-phototag-"+e).css("display","");n=jQuery(".wppa-ss-phototag-"+e);for(r="",s=0;s<n.length;s++)jQuery(n[s]).prop("selected")&&(r+="."+jQuery(n[s]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"t":jQuery("#wppa-ss-phototext-"+e).css("display","");var s,n=jQuery(".wppa-ss-phototext-"+e);for(r="",s=0;s<n.length;s++)jQuery(n[s]).prop("selected")&&(r+="."+jQuery(n[s]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"i":jQuery("#wppa-ss-photoiptc-"+e).css("display",""),(o=jQuery("#wppa-ss-photoiptc-"+e).val())&&(2<o.length&&(o=o.replace("#","H")),""!=o&&(jQuery("#wppa-ss-iptcopts-"+e).css("display",""),wppaLastIptc!=o?(wppaAjaxGetSsIptcList(e,o,"wppa-ss-iptcopts-"+e),wppaLastIptc=o):null!=(r=jQuery("#wppa-ss-iptcopts-"+e).val())&&""!=r&&jQuery("#wppa-ss-button-"+e).css("display","")));break;case"e":jQuery("#wppa-ss-photoexif-"+e).css("display",""),(o=jQuery("#wppa-ss-photoexif-"+e).val())&&(2<o.length&&(o=o.replace("#","H")),""!=o&&(jQuery("#wppa-ss-exifopts-"+e).css("display",""),wppaLastExif!=o?(wppaAjaxGetSsExifList(e,o,"wppa-ss-exifopts-"+e),wppaLastExif=o):null!=(r=jQuery("#wppa-ss-exifopts-"+e).val())&&""!=r&&jQuery("#wppa-ss-button-"+e).css("display","")))}}p&&(-1==(p=jQuery("#wppa-ss-pageurl-"+e).val()).indexOf("?")?p+="?":p+="&",p+="occur=1&wppa-supersearch="+a+","+t+","+o+","+r,document.location.href=p)}function wppaSetIptcExifSize(e,p){e=jQuery(e).length;6<e&&(e=6),e<2&&(e=2),jQuery(p).attr("size",e)}function wppaUpdateSearchRoot(e,p){for(var a=jQuery(".wppa-search-root"),t=0;t<a.length;)jQuery(a[t]).html(e),t++;for(a=jQuery(".wppa-rootbox"),t=0;t<a.length;)p?(jQuery(a[t]).prop("checked",!1),jQuery(a[t]).prop("disabled",!1)):(jQuery(a[t]).prop("checked",!0),jQuery(a[t]).prop("disabled",!0)),t++;for(a=jQuery(".wppa-search-root-id"),t=0;t<a.length;)jQuery(a[t]).val(p),t++}function wppaSubboxChange(e){jQuery(e).prop("checked")&&jQuery(".wppa-rootbox").each(function(e){jQuery(this).prop("checked",!0)})}function wppaClearSubsearch(){for(var e=jQuery(".wppa-display-searchstring"),p=0;p<e.length;)jQuery(e[p]).html(""),p++;for(e=jQuery(".wppa-search-sub-box"),p=0;p<e.length;)jQuery(e[p]).prop("disabled",!0),p++}function wppaEnableSubsearch(){for(var e=jQuery(".wppa-search-sub-box"),p=0;p<e.length;)jQuery(e[p]).removeAttr("disabled"),p++}function wppaDisplaySelectedFiles(e){for(var p=jQuery("#"+e),a=0,t="";a<p[0].files.length;)t+=p[0].files[a].name+" ",a++;jQuery("#"+e+"-display").val(t)}function wppaIsEmpty(e){return null==e||(void 0===e||(""==e||(0==e||(0==e||void 0))))}function wppaGetUploadOptions(yalb,mocc,where,onComplete){var options={beforeSend:function(){jQuery("#progress-"+yalb+"-"+mocc).show(),jQuery("#bar-"+yalb+"-"+mocc).width("0%"),jQuery("#message-"+yalb+"-"+mocc).html(""),jQuery("#percent-"+yalb+"-"+mocc).html("")},uploadProgress:function(e,p,a,t){jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#7F7"),jQuery("#bar-"+yalb+"-"+mocc).width(t+"%"),t<95?jQuery("#percent-"+yalb+"-"+mocc).html(t+"%"):jQuery("#percent-"+yalb+"-"+mocc).html(wppaProcessing)},success:function(){jQuery("#bar-"+yalb+"-"+mocc).width("100%"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaDone),jQuery(".wppa-upload-button").val(wppaUploadButtonText)},complete:function(response){-1!=response.responseText.indexOf(wppaUploadFailed)?(jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#F77"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaUploadFailed),jQuery("#message-"+yalb+"-"+mocc).html('<span style="font-size: 10px;" >'+response.responseText+"</span>")):(jQuery("#message-"+yalb+"-"+mocc).html('<span style="font-size: 10px;" >'+response.responseText+"</span>"),"thumb"!=where&&"cover"!=where||eval(onComplete))},error:function(){jQuery("#message-"+yalb+"-"+mocc).html('<span style="color: red;" >'+wppaServerError+"</span>"),jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#F77"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaUploadFailed)}};return options}function wppaInitMasonryPlus(){jQuery(".grid-masonryplus").each(function(){var e=jQuery(this).attr("id").substr(5),p=wppaGetContainerWidth(e)-wppaThumbnailAreaDelta,p=p/parseInt((p+wppaTfMargin)/(.75*wppaThumbSize+wppaTfMargin));jQuery(".grid-item").css("visibility","visible"),jQuery(".grid-item-"+e).css("width",p+"px"),jQuery("#grid-"+e).masonry({itemSelector:".grid-item-"+e,columnWidth:p,fitWidth:!0})})}function wppaFsChange(){wppaFsShow(),wppaOvlShowSame()}function wppaGlobalFS(){if(wppaIsIpad)return!1;if(wppaIsSafari)return!1;var e=parseInt(wppaGlobalFsIconSize/4),p=e;!wppaIsMobile&&0<jQuery("#wpadminbar").length&&(e+=jQuery("#wpadminbar").height()),jQuery("body").append('<div id="wppa-fulls-btn-1" class="wppa-fulls-btn" style="position:fixed;top:'+e+"px;right:"+p+'px;display:none;" title="Enter fullscreen" onclick="wppaFsOn()" >'+wppaSvgHtml("Full-Screen",wppaGlobalFsIconSize+"px",!0,!1,"0","0","0","0")+"</div>"),jQuery("body").append('<div id="wppa-exit-fulls-btn-1" class="wppa-exit-fulls-btn" style="position:fixed;top:'+e+"px;right:"+p+'px;display:none;" title="Leave fullscreen" onclick="wppaFsOff()" >'+wppaSvgHtml("Exit-Full-Screen",wppaGlobalFsIconSize+"px",!0,!1,"0","0","0","0")+"</div>"),wppaFsShow()}function wppaFsOn(){var e=document.documentElement;e.requestFullscreen?e.requestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.webkitRequestFullScreen&&e.webkitRequestFullScreen()}function wppaFsOff(){document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen&&document.webkitCancelFullScreen()}function wppaIsFs(){return!wppaIsIpad&&(!wppaIsSafari&&null!==document.fullscreenElement)}function wppaFsShow(){wppaIsFs()?(jQuery(".wppa-fulls-btn").hide(),jQuery(".wppa-exit-fulls-btn").show()):(jQuery(".wppa-fulls-btn").show(),jQuery(".wppa-exit-fulls-btn").hide())}jQuery(document).ready(function(){jQuery(".wppa-ss-button").each(function(){mocc=jQuery(this).attr("data-mocc"),wppaSuperSearchSelect(mocc)})}),jQuery(document).ready(function(){"global"==wppaFsPolicy&&wppaGlobalFS(),jQuery(window).on("DOMContentLoaded load",wppaFsShow),jQuery(document).on("fullscreenchange mozfullscreenchange webkitfullscreenchange msfullscreenchange",wppaFsChange)});
|
5 |
// wppa-slideshow
|
6 |
-
var wppaJsSlideshowVersion="8.1.07.001";function wppaStoreSlideInfo(p,a,e,t,i,w,r,n,o,l,s,d,u,_,m,c,h,y,S,g,x,f,I,j,Q,b,v,T,N,C,k,R,F){o=wppaRepairScriptTags(o),_wppaSlides[p]&&"0"!=a||(_wppaSlides[p]=[],_wppaNames[p]=[],_wppaFilmThumbTitles[p]=[],_wppaFullNames[p]=[],_wppaDsc[p]=[],_wppaOgDsc[p]=[],_wppaCurIdx[p]=-1,_wppaNxtIdx[p]=0,"random"==S?_wppaTimeOut[p]="random":0<parseInt(S)?_wppaTimeOut[p]=parseInt(S):_wppaTimeOut[p]=wppaSlideShowTimeOut,_wppaSSRuns[p]=!1,_wppaTP[p]=-2,_wppaFg[p]=0,_wppaIsBusy[p]=!1,_wppaFirst[p]=!0,_wppaId[p]=[],_wppaRealId[p]=[],_wppaAvg[p]=[],_wppaDisc[p]=[],_wppaMyr[p]=[],_wppaVRU[p]=[],_wppaLinkUrl[p]=[],_wppaLinkTitle[p]=[],_wppaLinkTarget[p]=[],_wppaCommentHtml[p]=[],_wppaIptcHtml[p]=[],_wppaExifHtml[p]=[],_wppaUrl[p]=[],_wppaSkipRated[p]=!1,_wppaLbTitle[p]=[],_wppaDidGoto[p]=!1,wppaSlidePause[p]=!1,_wppaShareUrl[p]=[],_wppaShareHtml[p]=[],_wppaFilmNoMove[p]=!1,_wppaHiresUrl[p]=[],_wppaIsVideo[p]=[],_wppaVideoHtml[p]=[],_wppaAudioHtml[p]=[],_wppaVideoNatWidth[p]=[],_wppaVideoNatHeight[p]=[],wppaVideoPlaying[p]=!1,wppaAudioPlaying[p]=!1,_wppaWaitTexts[p]=[],_wppaImageAlt[p]=[],_wppaFilename[p]=[]),S="default",""!=c?S="pointer":""!=wppaLightBox[p]&&(S="url( "+wppaImageDirectory+wppaMagnifierCursor+" ),pointer"),_wppaIsVideo[p][a]=""!=T,_wppaIsVideo[p][a]?(_wppaSlides[p][a]=' alt="'+k+'" class="theimg theimg-'+p+' big" ',wppaSlideVideoStart&&""==wppaLightBox[p]&&(_wppaSlides[p][a]+=" autoplay "),0<R.length&&(_wppaSlides[p][a]+=' poster="'+R+'" ')):_wppaSlides[p][a]=' src="'+e+'" alt="'+k+'" class="theimg theimg-'+p+' big stereo" ',wppaSlideSwipe&&(_wppaSlides[p][a]+=' ontouchstart="wppaTouchStart( event, this.id, '+p+' );" ontouchend="wppaTouchEnd( event );" ontouchmove="wppaTouchMove( event );" ontouchcancel="wppaTouchCancel( event );" '),wppaAutoColumnWidth[p]||(_wppaSlides[p][a]+='width="'+i+'" height="'+w+'" '),_wppaIsVideo[p][a]?(R="wppa"==wppaLightBox[p]?"":"controls",_wppaSlides[p][a]+='style="'+t+"; cursor:"+S+'; display:none;" '+R+">"+T+"</video>"):_wppaSlides[p][a]+='style="'+t+"; cursor:"+S+'; display:none; vertical-align:middle;">',_wppaFullNames[p][a]='<span class="sdf-'+p+'" >'+wppaRepairBrTags(r)+"</span>",_wppaNames[p][a]='<span class="sdn-'+p+'" >'+n+"</span>",_wppaFilmThumbTitles[p][a]=n,_wppaDsc[p][a]=o,_wppaOgDsc[p][a]=b,_wppaId[p][a]=l,_wppaRealId[p][a]=s,_wppaAvg[p][a]=d,_wppaDisc[p][a]=u,_wppaMyr[p][a]=_,_wppaVRU[p][a]=m,_wppaLinkUrl[p][a]=c,_wppaLinkTitle[p][a]=h,""!=y?_wppaLinkTarget[p][a]=y:wppaSlideBlank[p]?_wppaLinkTarget[p][a]="_blank":_wppaLinkTarget[p][a]="_self",_wppaCommentHtml[p][a]=g,_wppaIptcHtml[p][a]=x,_wppaExifHtml[p][a]=f,_wppaUrl[p][a]=e,_wppaLbTitle[p][a]=wppaRepairScriptTags(I),_wppaShareUrl[p][a]=j,_wppaShareHtml[p][a]=wppaRepairScriptTags(Q),_wppaHiresUrl[p][a]=v,_wppaVideoHtml[p][a]=T,_wppaAudioHtml[p][a]=N,_wppaVideoNatWidth[p][a]=i,_wppaVideoNatHeight[p][a]=w,_wppaWaitTexts[p][a]=C,_wppaImageAlt[p][a]=k,_wppaFilename[p][a]=F}function wppaSpeed(p,a){_wppaSSRuns[p]&&_wppaSpeed(p,a)}function wppaStopShow(p){_wppaSSRuns[p]&&_wppaStop(p)}function wppaStartStop(p,a){wppaSlideInitRunning[p]&&("start"==wppaSlideInitRunning[p]?a=-1:"stopprev"==wppaSlideInitRunning[p]?a=_wppaSlides[p].length-1:"stopnext"==wppaSlideInitRunning[p]&&(a=0),wppaSlideInitRunning[p]=""),_wppaIsBusy[p]?_wppaTP[p]=a:(_wppaSSRuns[p]?(_wppaStop(p),jQuery("#wppa-startstop-icon-"+p).html(wppaSvgHtml("Play-Button",wppaIconSize(p,"48px",!0),!1,!0,"0","10","50","50"))):(_wppaStart(p,a),-1==a&&jQuery("#wppa-startstop-icon-"+p).html(wppaSvgHtml("Pause-Button",wppaIconSize(p,"48px",!0),!1,!0,"0","10","50","50"))),wppaIsMobile&&(jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(10,1).fadeTo(3e3,0),jQuery(".ubb-"+p).stop().fadeTo(10,1).fadeTo(3e3,0)))}function wppaBbb(p,a,e){_wppaSSRuns[p]||_wppaBbb(p,a,e)}function wppaUbb(p,a,e){_wppaUbb(p,a,e)}function wppaRateIt(p,a){_wppaRateIt(p,a)}function wppaOvlRateIt(p,a,e,t){_wppaOvlRateIt(p,a,e,t)}function wppaPrev(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaPrev(p)}function wppaPrevN(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaPrevN(p,a)}function wppaFirst(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,0)}function wppaNext(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaNext(p)}function wppaNextN(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaNextN(p,a)}function wppaLast(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,_wppaSlides[p].length-1)}function wppaFollowMe(p,a){_wppaSSRuns[p]||_wppaFollowMe(p,a)}function wppaLeaveMe(p,a){_wppaSSRuns[p]||_wppaLeaveMe(p,a)}function wppaGoto(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,a)}function wppaGotoFilmNoMove(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||(_wppaFilmNoMove[p]=!0,_wppaGoto(p,a))}function wppaGotoKeepState(p,a){_wppaNxtIdx[p]!=a&&(_wppaDidGoto[p]=!0,_wppaGotoKeepState(p,a))}function _wppaGotoKeepState(p,a){(_wppaSSRuns[p]?_wppaGotoRunning:_wppaGoto)(p,a)}function wppaGotoRunning(p,a){_wppaDidGoto[p]=!0,_wppaGotoRunning(p,a)}function wppaValidateComment(p){return _wppaValidateComment(p)}function _wppaNextSlide(p,a){var e=!document.getElementById("slide_frame-"+p);if(_wppaStopping[p])_wppaStopping[p]=0;else{if(!e&&!wppaIsSlidshowVisible(p))return wppaFilmInit[p]=!1,void setTimeout(function(){_wppaNextSlide(p,a)},400);if(_wppaLastIdx[p]=_wppaCurIdx[p],!document.getElementById("slide_frame-"+p)&&document.getElementById("filmwindow-"+p)&&wppaFilmonlyContinuous)return _wppaSSRuns[p]?(_wppaCurIdx[p]++,_wppaCurIdx[p]==_wppaSlides[p].length&&(_wppaCurIdx[p]=0),_wppaAdjustFilmstrip(p,"linear"),_wppaNxtIdx[p]=_wppaCurIdx[p],void setTimeout("_wppaNextSlide( "+p+", '"+a+"' )",wppaAnimationSpeed)):(_wppaCurIdx[p]=_wppaNxtIdx[p],wppaFilmInit[p]=!1,void _wppaAdjustFilmstrip(p,"linear"));if(document.getElementById("slide_frame-"+p)||document.getElementById("filmwindow-"+p)){var t=_wppaFg[p],e=1-t;if((wppaVideoPlaying[p]||wppaAudioPlaying[p])&&_wppaSSRuns[p])setTimeout("_wppaNextSlide( "+p+", '"+a+"' )",500);else{if(wppaStopVideo(p),wppaStopAudio(p),"auto"==a){if(wppaSlidePause[p])return jQuery("#theimg"+t+"-"+p).attr("title",wppaSlidePause[p]),jQuery("#slide_frame-"+p).attr("title",wppaSlidePause[p]),void setTimeout("_wppaNextSlide( "+p+', "auto" )',250)}else jQuery("#slide_frame-"+p).removeAttr("title");if((_wppaSSRuns[p]||"auto"!=a)&&_wppaSlides[p]&&(!(_wppaSlides[p].length<2)||_wppaFirst[p])){if(_wppaSSRuns[p]||"reset"!=a||(_wppaSSRuns[p]=!0,__wppaOverruleRun=!1),_wppaVoteInProgress=!1,_wppaIsBusy[p]=!0,_wppaSSRuns[p]&&_wppaShowMetaData(p,"hide"),_wppaSSRuns[p]&&(_wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length&&(_wppaNxtIdx[p]=0)),jQuery("#geodiv-"+p+"-"+_wppaId[p][_wppaCurIdx[p]]).css({display:"none"}),jQuery("#geodiv-"+p+"-"+_wppaId[p][_wppaNxtIdx[p]]).css({display:""}),"undefined"!=typeof _wppaLat&&_wppaLat[p]?(n=_wppaRealId[p],_wppaLat[p][n[_wppaNxtIdx[p]]]?(jQuery("#map-canvas-"+p).css("display",""),wppaGeoInit(p,_wppaLat[p][n[_wppaNxtIdx[p]]],_wppaLon[p][n[_wppaNxtIdx[p]]])):jQuery("#map-canvas-"+p).css("display","none")):jQuery("#map-canvas-"+p).css("display","none"),jQuery("[id^=wppa-numbar-"+p+"-]").css({backgroundColor:wppaBGcolorNumbar,borderColor:wppaBcolorNumbar,fontFamily:wppaFontFamilyNumbar,fontSize:wppaFontSizeNumbar,color:wppaFontColorNumbar,fontWeight:wppaFontWeightNumbar}),jQuery("#wppa-numbar-"+p+"-"+_wppaNxtIdx[p]).css({backgroundColor:wppaBGcolorNumbarActive,borderColor:wppaBcolorNumbarActive,fontFamily:wppaFontFamilyNumbarActive,fontSize:wppaFontSizeNumbarActive,color:wppaFontColorNumbarActive,fontWeight:wppaFontWeightNumbarActive}),_wppaSlides[p].length>wppaNumbarMax){var i,w,r=_wppaSlides[p].length-1,n=_wppaNxtIdx[p],o=(wppaNumbarMax-1)/2;n<o?(i=0,w=wppaNumbarMax-1-1,jQuery("#wppa-nbar-"+p+"-lodots").css({display:"none"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})):r-o<n?(i=(w=r)-wppaNumbarMax+1+1,jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"none"})):(w=n+o+.5-1,(i=n-o+1)<2?(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"none"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})):r-1<w?(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"none"})):(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})));for(var l=0;l<_wppaSlides[p].length;)0!=l&&l!=r&&(l<i||w<l)?jQuery("#wppa-numbar-"+p+"-"+l).css({display:"none"}):jQuery("#wppa-numbar-"+p+"-"+l).css({display:"block"}),l++}_wppaFirst[p]?(-1!=_wppaCurIdx[p]&&wppaMakeTheSlideHtml(p,"0",_wppaCurIdx[p]),wppaMakeTheSlideHtml(p,"1",_wppaNxtIdx[p]),jQuery("#imagedesc-"+p).html(_wppaDsc[p][_wppaCurIdx[p]]),jQuery("#imagetitle-"+p).html(wppaMakeNameHtml(p)),"void"==_wppaCommentHtml[p][_wppaCurIdx[p]]?(jQuery("#wppa-comments-"+p).hide(),jQuery("#wppa-comments-"+p).html("")):(jQuery("#wppa-comments-"+p).show(),jQuery("#wppa-comments-"+p).html(_wppaCommentHtml[p][_wppaCurIdx[p]])),jQuery("#iptc-"+p).html(_wppaIptcHtml[p][_wppaCurIdx[p]]),jQuery("#exif-"+p).html(_wppaExifHtml[p][_wppaCurIdx[p]]),"icons"==wppaSlideshowNavigationType?(o=wppaIconSize(p,"1.5em",!1),jQuery("#prev-arrow-"+p).html(wppaSvgHtml("Prev-Button",o,!1,!0)),jQuery("#next-arrow-"+p).html(wppaSvgHtml("Next-Button",o,!1,!0))):wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?(jQuery("#prev-arrow-"+p).html("« "+wppaPrevP),jQuery("#next-arrow-"+p).html(wppaNextP+" »")):(jQuery("#prev-arrow-"+p).html("« "+wppaPreviousPhoto),jQuery("#next-arrow-"+p).html(wppaNextPhoto+" »")),wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRat),jQuery("#wppa-my-rat-"+p).html(wppaMyRat)):(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRating),jQuery("#wppa-my-rat-"+p).html(wppaMyRating))):wppaMakeTheSlideHtml(p,e,_wppaNxtIdx[p]),_wppaLoadSpinner(p),_wppaFirst[p]=!1,_wppaCheckRewind(p),setTimeout("_wppaNextSlide_2( "+p+" )",10)}}}}}function _wppaNextSlide_2(p){var a=_wppaFg[p],e=1-a,t=document.getElementById("theimg"+e+"-"+p);!t||1!=t.nodeType||"IMG"!=t.nodeName||t.complete?(wppaUpdateLightboxes(),_wppaUnloadSpinner(p),-1!=_wppaSSRuns[p]&&(_wppaToTheSame||_wppaShowMetaData(p,"hide")),_wppaFg[p]=1-_wppaFg[p],_wppaFg[p],setTimeout("_wppaNextSlide_3( "+p+" )",10)):setTimeout("_wppaNextSlide_2( "+p+" )",200)}function _wppaNextSlide_3(p){var a=_wppaFg[p],e=1-a,t=_wppaCurIdx[p],i=_wppaNxtIdx[p],w="#theslide"+e+"-"+p,r="#theslide"+a+"-"+p,n="#theimg"+e+"-"+p,o="#theimg"+a+"-"+p,l=parseInt(jQuery(w).css("width")),s=t==i+1?"right":t==i-1?"left":t==i?"none":"nil";switch(t==_wppaSlides[p].length-1&&0==i&&wppaSlideWrap[p]&&(s="left"),0==t&&i==_wppaSlides[p].length-1&&wppaSlideWrap[p]&&(s="right"),"nil"==s&&(s=t<i?"left":"right"),jQuery(w).css({marginLeft:0,width:l}),jQuery(r).css({marginLeft:0,width:l}),wppaFormatSlide(p),wppaAnimationType){case"fadeafter":wppaFadeOut(n,wppaAnimationSpeed),setTimeout(wppaFadeIn(o,wppaAnimationSpeed,_wppaNextSlide_4(p)),wppaAnimationSpeed);break;case"swipe":switch(s){case"left":wppaAnimate(w,{marginLeft:-l},wppaAnimationSpeed,wppaEasingSlide),jQuery(r).css({marginLeft:l}),wppaFadeIn(o,10),wppaAnimate(r,{marginLeft:0},wppaAnimationSpeed,wppaEasingSlide,_wppaNextSlide_4(p));break;case"right":wppaAnimate(w,{marginLeft:l},wppaAnimationSpeed,wppaEasingSlide),jQuery(r).css({marginLeft:-l}),wppaFadeIn(o,10),wppaAnimate(r,{marginLeft:0},wppaAnimationSpeed,wppaEasingSlide,_wppaNextSlide_4(p));break;case"none":wppaFadeIn(o,10),setTimeout("_wppaNextSlide_4( "+p+" )",10)}break;default:wppaFadeOut(n,wppaAnimationSpeed),wppaFadeIn(o,wppaAnimationSpeed,_wppaNextSlide_4(p))}}function _wppaNextSlide_4(p){var a=_wppaFg[p],e="#theslide"+a+"-"+p;jQuery("#theslide"+(1-a)+"-"+p).css({zIndex:80}),jQuery(e).css({zIndex:81}),_wppaCurIdx[p]=_wppaNxtIdx[p],wppaFormatSlide(p),wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?jQuery("#counter-"+p).html(_wppaCurIdx[p]+1+" / "+_wppaSlides[p].length):jQuery("#counter-"+p).html(wppaPhoto+" "+(_wppaCurIdx[p]+1)+" "+wppaOf+" "+_wppaSlides[p].length),jQuery("#bc-pname-modal-"+p).html(_wppaNames[p][_wppaCurIdx[p]]),jQuery("#bc-pname-"+p).html(_wppaNames[p][_wppaCurIdx[p]]),_wppaAdjustFilmstrip(p,wppaEasingSlide),_wppaSetRatingDisplay(p),setTimeout("_wppaNextSlide_5( "+p+" )",_wppaTextDelay)}function _wppaNextSlide_5(p){var a,e,t;if(_wppaToTheSame||(a=_wppaDsc[p][_wppaCurIdx[p]],jQuery("#imagedesc-"+p).html(a),wppaHideWhenEmpty&&(""==(a=_wppaDsc[p][_wppaCurIdx[p]])||" "==a?jQuery("#descbox-"+p).css("display","none"):jQuery("#descbox-"+p).css("display","")),jQuery("#imagetitle-"+p).html(wppaMakeNameHtml(p)),"void"==_wppaCommentHtml[p][_wppaCurIdx[p]]?(jQuery("#wppa-comments-"+p).hide(),jQuery("#wppa-comments-"+p).html("")):(jQuery("#wppa-comments-"+p).show(),jQuery("#wppa-comments-"+p).html(_wppaCommentHtml[p][_wppaCurIdx[p]])),jQuery("#iptc-"+p).html(_wppaIptcHtml[p][_wppaCurIdx[p]]),jQuery("#exif-"+p).html(_wppaExifHtml[p][_wppaCurIdx[p]]),jQuery("#wppa-share-"+p).html(_wppaShareHtml[p][_wppaCurIdx[p]])),_wppaToTheSame=!1,wppaThumbPageSize?wppaThumbPage[p]=parseInt(((0|wppaSlideOffset[p])+_wppaCurIdx[p])/wppaThumbPageSize)+1:wppaThumbPage[p]=1,_wppaSSRuns[p]&&!wppaSlideWrap[p]&&_wppaCurIdx[p]+1==_wppaSlides[p].length)return _wppaIsBusy[p]=!1,void _wppaStop(p);if(_wppaShowMetaData(p,"show"),-2!=_wppaTP[p]){var i=_wppaTP[p];return _wppaTP[p]=-2,_wppaDidGoto[p]=!1,_wppaIsBusy[p]=!1,wppaIsMini[p]||_bumpViewCount(_wppaId[p][_wppaCurIdx[p]]),_wppaDoAutocol(p,"next_5"),void wppaStartStop(p,i)}wppaUpdateLightboxes(),wppaIsMini[p]||(i=_wppaShareUrl[p][_wppaCurIdx[p]],"undefined"!=typeof wppaQRUpdate&&wppaQRUpdate(_wppaShareUrl[p][_wppaCurIdx[p]]),1<_wppaSlides[p].length&&wppaPushStateSlide(p,_wppaCurIdx[p],i)),_wppaSSRuns[p]?_wppaCurIdx[p]+1==_wppaSlides[p].length?(t=jQuery("#wppa-next-pagelink-"+p),e=jQuery("#wppa-first-pagelink-"+p),0<t.length&&"hidden"!=jQuery(t).css("visibility")?setTimeout(function(){wppaSlideInitRunning[p]="start",jQuery("#wppa-next-pagelink-"+p).trigger("click")},wppaGetSlideshowTimeout(p)):0<e.length?setTimeout(function(){jQuery(e).trigger("click")},wppaGetSlideshowTimeout(p)):setTimeout("_wppaNextSlide( "+p+', "auto" )',wppaGetSlideshowTimeout(p))):setTimeout("_wppaNextSlide( "+p+', "auto" )',wppaGetSlideshowTimeout(p)):_wppaStopping[p]=!1,jQuery(document).trigger("glossaryTooltipReady"),_wppaDidGoto[p]=!1,_wppaIsBusy[p]=!1,wppaIsMini[p]||_bumpViewCount(_wppaId[p][_wppaCurIdx[p]]),wppaStopAudio(p),!wppaSlideAudioStart||0<(t=jQuery(".wppa-audio-"+_wppaId[p][_wppaCurIdx[p]]+"-"+p)).length&&((t=t[t.length-1])&&(wppaAudioPlaying[p]||t.play())),wppaProtect()}function wppaFormatSlide(p){var a="theimg"+_wppaFg[p]+"-"+p,e=document.getElementById(a);if(e){var t="theslide"+_wppaFg[p]+"-"+p,i="slide_frame-"+p,w=jQuery("#wppa-container-"+p).width();wppaColWidth[p]=w;var r=jQuery(".wppa-audio-"+p),n=e.naturalWidth;void 0===n&&(n=parseInt(e.style.maxWidth));var o=e.naturalHeight;void 0===o&&(o=parseInt(e.style.maxHeight));var l=wppaAspectRatio[p],s=wppaFullSize[p],d=wppaFullFrameDelta[p],u=wppaPortraitOnly[p],_=wppaFullValign[p];void 0===_&&(_="none");var m=wppaFullHalign[p];void 0===m&&(m="none");var c,h,y,S,g,x,f,e=wppaStretch;if(u)j=w-d,y=h=0,x=S=w,f=g=(c=parseInt(j*o/n))+d,jQuery("#"+i).css({width:x,height:f}),jQuery("#"+t).css({width:S,height:g}),jQuery("#"+a).css({width:j,height:c});else{if(s<(x=w)&&(x=s),S=x,g=f=parseInt(x*l),e||x-d<=n||f-d<=o?l<(o+d)/(n+d)?(c=f-d,j=parseInt(c*n/o)):(j=x-d,c=parseInt(j*o/n)):(j=n,c=o),"default"!=_&&"none"!=_){switch(_){case"top":y=0;break;case"center":y=parseInt((f-(c+d))/2);break;case"bottom":y=f-(c+d);break;case"fit":y=0,g=f=c+d}jQuery("#"+a).css({marginTop:y,marginBottom:0})}if(jQuery("#"+i).css({width:x,height:f}),jQuery("#"+t).css({width:S,height:g}),jQuery("#"+a).css({width:j,height:c}),"default"!=_&&"none"!=_&&"none"!=m&&"default"!=m){switch(m){case"left":h=0;break;case"center":h=parseInt((w-x)/2);break;case"right":h=w-x}h<0&&(h=0),jQuery("#"+a).css({marginLeft:"auto",marginRight:"auto"}),jQuery("#"+i).css({marginLeft:h})}var i=jQuery(r).height(),I=(x-j)/2;i&&0<i&&(wppaAudioHeight=i,jQuery(r).css({height:wppaAudioHeight,width:j,left:I}))}var j=parseInt(x/3),I=2*j,r=0<r.length?f-wppaAudioHeight-wppaSlideBorderWidth-y:f;jQuery("#bbb-"+p+"-l").css({height:r,width:j,left:0}),jQuery("#bbb-"+p+"-r").css({height:r,width:j,left:I})}}function wppaMakeNameHtml(p){var a,e,t="";if(_wppaCurIdx[p]<0)return"";if("void"==_wppaFullNames[p][_wppaCurIdx[p]])return jQuery("#namebox-"+p).hide(),"";if(jQuery("#namebox-"+p).show(),wppaIsMini[p]||_wppaIsVideo[p][_wppaCurIdx[p]])t=_wppaFullNames[p][_wppaCurIdx[p]];else switch(wppaArtMonkyLink){case"file":case"zip":t=wppaArtMonkeyButton?_wppaFullNames[p][_wppaCurIdx[p]]?(a=-1!=_wppaFullNames[p][_wppaCurIdx[p]].indexOf("plus.png"),e=_wppaFullNames[p][_wppaCurIdx[p]].replace(/(<([^>]+)>)/gi,""),e=a?e.replace(" )"," +)"):e.replace(" )",")"),'<input type="button" title="Download" style="cursor:pointer;margin-bottom:0px;max-width:'+(wppaGetContainerWidth(p)-24)+'px;" class="wppa-download-button" onclick="'+(wppaIsSafari&&"file"==wppaArtMonkyLink?"wppaWindowReference = window.open();":"")+"wppaAjaxMakeOrigName( "+p+", '"+_wppaId[p][_wppaCurIdx[p]]+'\' );" value="'+wppaDownLoad+": "+e+'" />'):"":wppaArtmonkeyFileNotSource?'<a href="'+_wppaUrl[p][_wppaCurIdx[p]]+'" title="Download" style="cursor:pointer;" download="'+_wppaFilename[p][_wppaCurIdx[p]]+'" >'+wppaDownLoad+": "+_wppaFullNames[p][_wppaCurIdx[p]]+"</a>":'<a title="Download" style="cursor:pointer;" onclick="'+(wppaIsSafari&&"file"==wppaArtMonkyLink?"wppaWindowReference = window.open();":"")+"wppaAjaxMakeOrigName( "+p+", '"+_wppaId[p][_wppaCurIdx[p]]+"' );\" >"+wppaDownLoad+": "+_wppaFullNames[p][_wppaCurIdx[p]]+"</a>";break;case"none":case"new":t=_wppaFullNames[p][_wppaCurIdx[p]];break;default:t=""}return t=wppaRepairBrTags(t)}function wppaMakeTheSlideHtml(p,a,e){var t,i,w=_wppaIsVideo[p][e]?"video":"img",r="title";"wppa"==wppaLightBox[p]&&(r="data-lbtitle");var n,o,l=""==wppaLightBox[p]?' onpause="wppaVideoPlaying['+p+'] = false;" onplay="wppaVideoPlaying['+p+'] = true;"':"";if(""!=_wppaLinkUrl[p][e])t=wppaSlideToFullpopup?'<a onclick="wppaStopAudio();wppaStopShow('+p+");"+_wppaLinkUrl[p][e]+'" target="'+_wppaLinkTarget[p][e]+'" title="'+_wppaLinkTitle[p][e]+'"><'+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e]+"</a>":"<a onclick=\"_bumpClickCount('"+_wppaId[p][e]+"');wppaStopAudio();wppaStopShow("+p+");window.open('"+_wppaLinkUrl[p][e]+"', '"+_wppaLinkTarget[p][e]+'\');" title="'+_wppaLinkTitle[p][e]+'"><'+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e]+"</a>";else if(""==wppaLightBox[p])t="<"+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e];else{for(var s="",d=0,u=wppaLightboxSingle[p]?"":"[slide-"+p+"-"+a+"]";d<e;)i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][d]:wppaMakeFullsizeUrl(_wppaUrl[p][d]),o=".pdf"==(n=_wppaHiresUrl[p][d]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][d]+'" data-videonatheight="'+_wppaVideoNatHeight[p][d]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][d])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][d])+'"':"")+" "+r+'="'+_wppaLbTitle[p][d]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+"></a>",d++;for(i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][e]:wppaMakeFullsizeUrl(_wppaUrl[p][e]),o=".pdf"==(n=_wppaHiresUrl[p][e]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(wppaSlideLinkEqual?' onclick="wppaStopAudio();wppaStopShow('+p+");jQuery('#wppa-film-"+e+"-"+p+"').trigger('click');return false;\"":' onclick="wppaStopAudio();wppaStopShow('+p+');"')+' style="cursor:pointer;" target="'+_wppaLinkTarget[p][e]+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][e]+'" data-videonatheight="'+_wppaVideoNatHeight[p][e]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][e])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][e])+'"':"")+" "+r+'="'+_wppaLbTitle[p][e]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+">"+(o?"<iframe "+l+' src="'+n+'" title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" style="width:100%;height:100%;" ></iframe>':"<"+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e])+"</a>",d=e+1;d<_wppaUrl[p].length;)i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][d]:wppaMakeFullsizeUrl(_wppaUrl[p][d]),o=".pdf"==(n=_wppaHiresUrl[p][d]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][d]+'" data-videonatheight="'+_wppaVideoNatHeight[p][d]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][d])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][d])+'"':"")+" "+r+'="'+_wppaLbTitle[p][d]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+"></a>",d++;t=s}""!=_wppaAudioHtml[p][e]&&(t+='<audio controls id="wppa-audio-'+_wppaId[p][e]+"-"+p+'" class="wppa-audio-'+p+" wppa-audio-"+_wppaId[p][e]+"-"+p+'" data-from="wppa" onplay="wppaAudioPlaying['+p+'] = true;" onpause="wppaAudioPlaying['+p+'] = false" style="position:relative;top:-'+(wppaAudioHeight+wppaSlideBorderWidth)+"px;z-index:10;width:"+_wppaVideoNatWidth[p][e]+'px;padding:0;box-sizing:border-box;" >'+_wppaAudioHtml[p][e]+"</audio>"),t=t.replace(/title=""/g,""),jQuery("#theslide"+a+"-"+p).html(t)}function wppaAdjustAllFilmstrips(p){jQuery(".wppa-filmstrip").each(function(){_wppaAdjustFilmstrip(jQuery(this).attr("id").substr(15),p)})}var wppaLastAnimFilmLoc=[];function _wppaAdjustFilmstrip(p,a){if("linear"!=a&&(a=wppaEasingSlide),document.getElementById("wppa-filmstrip-"+p)&&_wppaSlides[p]){var e,t,i,w,r=!document.getElementById("slide_frame-"+p);if(wppaLastAnimFilmLoc[p]||(wppaLastAnimFilmLoc[p]=0),r){var n=jQuery("#wppa-filmstrip-"+p);if(!wppaIsElementInViewport(n))return}if(r||jQuery(".wppa-film-"+p).removeClass("wppa-filmthumb-active"),_wppaFilmNoMove[p]&&wppaFilmInit[p]?_wppaFilmNoMove[p]=!1:(e=wppaFilmStripLength[p]/2-(_wppaCurIdx[p]+.5+wppaPreambule[p])*wppaThumbnailPitch[p]-wppaFilmStripMargin[p],wppaFilmShowGlue&&(e-=2*wppaFilmStripMargin[p]+2),i=e+wppaThumbnailPitch[p],w=e-wppaThumbnailPitch[p],t=wppaAnimationSpeed,wppaFilmInit[p]||(t=1),0==_wppaCurIdx[p]&&_wppaLastIdx[p]==_wppaSlides[p].length-1?(jQuery("#wppa-filmstrip-"+p).css({marginLeft:i+"px"}),wppaLastAnimFilmLoc[p]!=e&&(wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e)):0==_wppaLastIdx[p]&&_wppaCurIdx[p]==_wppaSlides[p].length-1?(jQuery("#wppa-filmstrip-"+p).css({marginLeft:w}),wppaLastAnimFilmLoc[p]!=e&&(wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e)):(n=parseInt(jQuery("#wppa-filmstrip-"+p).css("margin-left")),i=parseInt(e),w=wppaThumbnailPitch[p],_wppaSSRuns[p]?(n<i?2:i<n-2*w?1:0)&&jQuery("#wppa-filmstrip-"+p).css({marginLeft:i+w}):(i<n-1.5*w||n+1.5*w<i)&&jQuery("#wppa-filmstrip-"+p).css({marginLeft:i}),wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e,wppaFilmInit[p]=!0),_wppaLastIdx[p]=_wppaCurIdx[p]),wppaMakeLazyVisible("filmstripmocc="+p),!r&&-1!=_wppaCurIdx[p]){_wppaCurIdx[p];_wppaCurIdx[p]+10>_wppaSlides[p].length&&_wppaSlides[p].length;for(var o=0;o<_wppaSlides[p].length;)jQuery("#film_wppatnf_"+_wppaId[p][o]+"_"+p).html()&&(""!=jQuery("#wppa-film-"+o+"-"+p).attr("data-title")?(jQuery("#wppa-film-"+o+"-"+p).attr("title",jQuery("#wppa-film-"+o+"-"+p).attr("data-title")),jQuery("#wppa-pre-"+o+"-"+p).attr("title",jQuery("#wppa-film-"+o+"-"+p).attr("data-title"))):""!=wppaFilmThumbTitle&&_wppaCurIdx[p]==o?(jQuery("#wppa-film-"+o+"-"+p).attr("title",wppaFilmThumbTitle),jQuery("#wppa-pre-"+o+"-"+p).attr("title",wppaFilmThumbTitle)):(jQuery("#wppa-film-"+o+"-"+p).attr("title",wppaClickToView+" "+_wppaFilmThumbTitles[p][o]),jQuery("#wppa-pre-"+o+"-"+p).attr("title",wppaClickToView+" "+_wppaFilmThumbTitles[p][o]))),o++}r||jQuery("#wppa-film-"+_wppaCurIdx[p]+"-"+p).addClass("wppa-filmthumb-active")}}function _wppaNext(p){var a,e;!wppaSlideWrap[p]&&_wppaCurIdx[p]==_wppaSlides[p].length-1||(_wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length?(a=jQuery("#wppa-next-pagelink-"+p),e=jQuery("#wppa-first-pagelink-"+p),0<a.length&&"hidden"!=jQuery(a).css("visibility")?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopnext",jQuery("#wppa-next-pagelink-"+p).trigger("click")):0<e.length?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopnext",jQuery(e).trigger("click")):_wppaNextSlide(p,_wppaNxtIdx[p]=0)):_wppaNextSlide(p,0))}function _wppaNextN(p,a){if(wppaSlideWrap[p]||!(_wppaCurIdx[p]>=_wppaSlides[p].length-a)){for(_wppaNxtIdx[p]=_wppaCurIdx[p]+a;_wppaNxtIdx[p]>=_wppaSlides[p].length;)_wppaNxtIdx[p]-=_wppaSlides[p].length;_wppaNextSlide(p,0)}}function _wppaNextOnCallback(p){if(wppaSlideWrap[p]||_wppaCurIdx[p]!=_wppaSlides[p].length-1){if(_wppaSkipRated[p]){var a=_wppaCurIdx[p]+1;a==_wppaSlides[p].length&&(a=0);var e=a;if(0!=_wppaMyr[p][e]){for(++a==_wppaSlides[p].length&&(a=0);a!=e&&0!=_wppaMyr[p][a];)++a==_wppaSlides[p].length&&(a=0);e=a}_wppaNxtIdx[p]=e}else _wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length&&(_wppaNxtIdx[p]=0);_wppaNextSlide(p,0)}}function _wppaPrev(p){!wppaSlideWrap[p]&&0==_wppaCurIdx[p]||(_wppaNxtIdx[p]=_wppaCurIdx[p]-1,_wppaNxtIdx[p]<0?jQuery("#wppa-prev-page-last-item-"+p).length?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopprev",jQuery("#wppa-prev-page-last-item-"+p).trigger("click")):(_wppaNxtIdx[p]+=_wppaSlides[p].length,_wppaNextSlide(p,0)):_wppaNextSlide(p,0))}function _wppaPrevN(p,a){if(wppaSlideWrap[p]||!(_wppaCurIdx[p]<a)){for(_wppaNxtIdx[p]=_wppaCurIdx[p]-a;_wppaNxtIdx[p]<0;)_wppaNxtIdx[p]+=_wppaSlides[p].length;_wppaNextSlide(p,0)}}function _wppaGoto(p,a){_wppaToTheSame=_wppaNxtIdx[p]==a,_wppaNxtIdx[p]=a,_wppaNextSlide(p,0)}function _wppaGotoRunning(p,a){_wppaIsBusy[p]?setTimeout("_wppaGotoRunning( "+p+","+a+" )",10):(_wppaSSRuns[p]=!1,_wppaToTheSame=_wppaNxtIdx[p]==a,_wppaNxtIdx[p]=a,__wppaOverruleRun=!0,_wppaNextSlide(p,"manual"),_wppaGotoContinue(p))}function _wppaGotoContinue(p){_wppaIsBusy[p]?setTimeout("_wppaGotoContinue( "+p+" )",10):setTimeout("_wppaNextSlide( "+p+', "reset" )',wppaGetSlideshowTimeout(p)+10)}function _wppaStart(p,a){if(_wppaStopping[p])return _wppaStopping[p]--,void setTimeout(function(){_wppaStart(p,a)},(wppaAnimationSpeed+wppaGetSlideshowTimeout(p))/10);_wppaSSRuns[p]||("icons"==wppaSlideshowNavigationType?_wppaStartIcons:_wppaStartText)(p,a)}function _wppaStartIcons(p,a){if(-2==a){var e=0;if(a=0,_wppaSkipRated[p]=!0,0!=_wppaMyr[p][e])for(;e<_wppaSlides[p].length;)0==a&&0==_wppaMyr[p][e]&&(a=e),e++}var t=wppaIconSize(p,"1.5em",!1);-1<a?(jQuery("#startstop-"+p).html(wppaSvgHtml("Play-Button",t,!1,!0,"0","10","20","50")),jQuery("#speed0-"+p).hide(),jQuery("#speed1-"+p).hide(),_wppaNxtIdx[p]=a,_wppaCurIdx[p]=a,_wppaNextSlide(p,0),_wppaShowMetaData(p,"show")):(_wppaSSRuns[p]=!0,_wppaNextSlide(p,0),jQuery("#startstop-"+p).html(wppaSvgHtml("Pause-Button",t,!1,!0,"0","10","20","50")),jQuery("#speed0-"+p).show(),jQuery("#speed1-"+p).show(),_wppaShowMetaData(p,"hide"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(wppaSlideShow)),_wppaSetRatingDisplay(p)}function _wppaStartText(p,a){if(-2==a){var e=0;if(a=0,_wppaSkipRated[p]=!0,0!=_wppaMyr[p][e])for(;e<_wppaSlides[p].length;)0==a&&0==_wppaMyr[p][e]&&(a=e),e++}-1<a?(jQuery("#startstop-"+p).html(wppaStart+" "+wppaSlideShow),jQuery("#speed0-"+p).css("display","none"),jQuery("#speed1-"+p).css("display","none"),_wppaNxtIdx[p]=a,_wppaCurIdx[p]=a,_wppaNextSlide(p,0),_wppaShowMetaData(p,"show")):(_wppaSSRuns[p]=!0,_wppaNextSlide(p,0),jQuery("#startstop-"+p).html(wppaStop),jQuery("#speed0-"+p).css("display","inline"),jQuery("#speed1-"+p).css("display","inline"),_wppaShowMetaData(p,"hide"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(wppaSlideShow)),_wppaSetRatingDisplay(p)}function _wppaStop(p){_wppaStopping[p]=12,("icons"==wppaSlideshowNavigationType?_wppaStopIcons:_wppaStopText)(p)}function _wppaStopIcons(p){_wppaSSRuns[p]=!1,jQuery("#startstop-"+p).html(wppaSvgHtml("Play-Button",wppaIconSize(p,"1.5em",!1),!1,!0)),jQuery("#speed0-"+p).hide(),jQuery("#speed1-"+p).hide(),_wppaShowMetaData(p,"show"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(_wppaNames[p][_wppaCurIdx[p]])}function _wppaStopText(p){_wppaSSRuns[p]=!1,jQuery("#startstop-"+p).html(wppaStart+" "+wppaSlideShow),jQuery("#speed0-"+p).css("display","none"),jQuery("#speed1-"+p).css("display","none"),_wppaShowMetaData(p,"show"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(_wppaNames[p][_wppaCurIdx[p]])}function _wppaSpeed(p,a){"random"!=_wppaTimeOut[p]&&(a?500<_wppaTimeOut[p]&&(_wppaTimeOut[p]/=1.5):_wppaTimeOut[p]<6e4&&(_wppaTimeOut[p]*=1.5))}function _wppaLoadSpinner(p){}function _wppaUnloadSpinner(p){jQuery("#wppa-slide-spin-"+p).stop().fadeOut(),setTimeout(function(){jQuery("#wppa-slide-spin-"+p).stop().fadeOut()},1e3)}function _wppaCheckRewind(p){var a,e;document.getElementById("wppa-filmstrip-"+p)&&((e=Math.abs(_wppaCurIdx[p]-_wppaNxtIdx[p]))<=wppaFilmPageSize[p]||(1+wppaFilmStripLength[p]/wppaThumbnailPitch[p])/2<=e&&(a=wppaThumbnailPitch[p]*_wppaSlides[p].length,wppaFilmShowGlue&&(a+=2+2*wppaFilmStripMargin[p]),e=parseInt(jQuery("#wppa-filmstrip-"+p).css("margin-left")),_wppaNxtIdx[p]>_wppaCurIdx[p]?e-=a:e+=a,jQuery("#wppa-filmstrip-"+p).css("margin-left",e+"px")))}function _wppaSetRatingDisplay(p){if(document.getElementById("wppa-rating-"+p)){var a,e,t=_wppaAvg[p][_wppaCurIdx[p]];if(void 0!==t){if("likes"==wppaRatingDisplayType){"void"==(e=_wppaMyr[p][_wppaCurIdx[p]])?(jQuery("#wppa-dislike-imgdiv-"+p).hide(),jQuery("#wppa-like-imgdiv-"+p).hide()):(jQuery("#wppa-dislike-imgdiv-"+p).show(),jQuery("#wppa-like-imgdiv-"+p).show());var w=t.split("|");return jQuery("#wppa-like-"+p).attr("title",w[0]),jQuery("#wppa-liketext-"+p).html(w[1]),void("1"==_wppaMyr[p][_wppaCurIdx[p]]?jQuery("#wppa-like-"+p).attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-"+p).attr("src",wppaImageDirectory+"thumbup.png"))}if(t=(a=t.split("|"))[0],w=a[1],a=_wppaDisc[p][_wppaCurIdx[p]],e=_wppaMyr[p][_wppaCurIdx[p]],"void"==a)jQuery("#wppa-rating-"+p).hide();else{if(jQuery("#wppa-rating-"+p).show(),"graphic"==wppaRatingDisplayType)_wppaSetRd(p,t,"#wppa-avg-"),_wppaSetRd(p,e,"#wppa-rate-"),0==e?(jQuery("#wppa-dislike-"+p).css("display","inline"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","inline"),document.getElementById("wppa-dislike-"+p)&&jQuery("#wppa-filler-"+p).css("display","none"),jQuery("#wppa-dislike-"+p).stop().fadeTo(100,wppaStarOpacity)):(jQuery("#wppa-dislike-"+p).css("display","none"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","none"),jQuery("#wppa-filler-"+p).css("display","inline"),jQuery("#wppa-filler-"+p).stop().fadeTo(100,wppaStarOpacity),jQuery("#wppa-filler-"+p).attr("title",a));else{if(jQuery("#wppa-numrate-avg-"+p).html(t+" ( "+w+" ) "),jQuery(".wppa-my-rat-"+p).show(),"void"==e)jQuery("#wppa-numrate-mine-"+p).html(""),jQuery(".wppa-my-rat-"+p).hide();else if(wppaRatingOnce&&0<e)jQuery("#wppa-numrate-mine-"+p).html(e);else if(e<0)jQuery("#wppa-numrate-mine-"+p).html(" dislike");else{var r="";for(i=1;i<=wppaRatingMax;i++)e==i?r+='<span class="wppa-rating-numeric-mine" style="cursor:pointer; font-weight:bold;" onclick="_wppaRateIt( '+p+", "+i+' )"> '+i+" </span>":(e>i-1&&e<i&&(r+=" ( "+e+" ) "),r+='<span class="wppa-rating-numeric" style="cursor:pointer;" onclick="_wppaRateIt( '+p+", "+i+' )" onmouseover="this.style.fontWeight=\'bold\'" onmouseout="this.style.fontWeight=\'normal\'" > '+i+" </span>");jQuery("#wppa-numrate-mine-"+p).html(r)}0==e?(jQuery("#wppa-dislike-"+p).css("display","inline"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","inline"),jQuery("#wppa-filler-"+p).css("display","none"),jQuery("#wppa-dislike-"+p).stop().fadeTo(100,wppaStarOpacity)):(jQuery("#wppa-dislike-"+p).css("display","none"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","none"),jQuery("#wppa-filler-"+p).css("display","inline")),jQuery("#wppa-discount-"+p).html(a+"• "),jQuery("#wppa-filler-"+p).css("display","none")}0==e?jQuery("#wppa-vote-button-"+p).val(wppaVoteForMe):jQuery("#wppa-vote-button-"+p).val(wppaVotedForMe),jQuery("#wppa-vote-count-"+p).html(w)}}}}function wppaGetDislikeText(p,a,e){return p}function _wppaSetRd(p,a,e){var t=parseInt(a),i=t+1,w=wppaStarOpacity+(a-t)*(1-wppaStarOpacity),r=wppaRatingMax;if("void"==a)jQuery("#wppa-my-rat-"+p).hide(),jQuery(".wppa-my-rat-"+p).hide(),jQuery(".wppa-rate-"+p).hide(),jQuery(".wppa-ratingthumb").hide(),jQuery("#wppa-numrate-mine-"+p).hide();else for(jQuery("#wppa-my-rat-"+p).show(),jQuery(".wppa-my-rat-"+p).show(),jQuery(".wppa-rate-"+p).show(),jQuery(".wppa-ratingthumb").show(),jQuery("#wppa-numrate-mine-"+p).show(),idx=1;idx<=r;idx++)"#wppa-rate-"!=e&&".wppa-rate-"!=e||jQuery(e+p+"-"+idx).attr("src")!=wppaImageDirectory+"star.ico"&&jQuery(e+p+"-"+idx).attr("src",wppaImageDirectory+"star.ico"),idx<=t?jQuery(e+p+"-"+idx).stop().fadeTo(100,1):idx==i?jQuery(e+p+"-"+idx).stop().fadeTo(100,w):jQuery(e+p+"-"+idx).stop().fadeTo(100,wppaStarOpacity)}function _wppaFollowMe(p,a){_wppaSSRuns[p]||0!=_wppaMyr[p][_wppaCurIdx[p]]&&wppaRatingOnce||_wppaMyr[p][_wppaCurIdx[p]]<0||_wppaVoteInProgress||_wppaSetRd(p,a,"#wppa-rate-")}function wppaOvlFollowMe(p,a,e){e||_wppaSetRd(p,a,".wppa-rate-")}function _wppaLeaveMe(p,a){_wppaSSRuns[p]||0!=_wppaMyr[p][_wppaCurIdx[p]]&&wppaRatingOnce||_wppaMyr[p][_wppaCurIdx[p]]<0||_wppaVoteInProgress||_wppaSetRd(p,_wppaMyr[p][_wppaCurIdx[p]],"#wppa-rate-")}function wppaOvlLeaveMe(p,a,e){_wppaSetRd(p,e,".wppa-rate-")}function _wppaValidateComment(p,a){if(a=a||_wppaId[p][_wppaCurIdx[p]],jQuery("#wppa-comname-"+p).val().length<1)return alert(wppaPleaseName),!1;if("required"==wppaEmailRequired||"optional"==wppaEmailRequired){var e=jQuery("#wppa-comemail-"+p).val();if("optional"==wppaEmailRequired&&0==e.length)return!0;var t=e.indexOf("@"),a=e.lastIndexOf(".");if(t<1||a<t+2||a+2>=e.length)return alert(wppaPleaseEmail),!1}return!(jQuery("#wppa-comment-"+p).val().length<1)||(alert(wppaPleaseComment),!1)}function _wppaGo(p){document.location=p}function _wppaBbb(p,a,e){if(!_wppaSSRuns[p]){var t="#bbb-"+p+"-"+a;switch(e){case"show":"l"==a&&jQuery(t).attr("title",wppaPreviousPhoto),"r"==a&&jQuery(t).attr("title",wppaNextPhoto),jQuery(".bbb-"+p).css("cursor","pointer");break;case"hide":jQuery(".bbb-"+p).removeAttr("title"),jQuery(".bbb-"+p).css("cursor","default");break;case"click":"l"==a&&wppaPrev(p),"r"==a&&wppaNext(p);break;default:alert("Unimplemented instruction: "+e+" on: "+t)}}}function _wppaUbb(p,a,e){var t="#ubb-"+p+"-"+a;switch(e){case"show":"l"==a&&jQuery(t).attr("title",wppaPreviousPhoto),"r"==a&&jQuery(t).attr("title",wppaNextPhoto),jQuery(".ubb-"+p).css("cursor","pointer"),jQuery(".ubb-"+p).stop().fadeTo(200,.8),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,.8);break;case"hide":jQuery(".ubb-"+p).removeAttr("title"),jQuery(".ubb-"+p).css("cursor","default"),wppaIsMobile?jQuery(".ubb-"+p).stop().fadeTo(200,.1):jQuery(".ubb-"+p).stop().fadeTo(200,0),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,0);break;case"click":wppaIsMobile&&(jQuery(".ubb-"+p).stop().fadeTo(200,1).fadeTo(1e3,0),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,1).fadeTo(1e3,0)),"l"==a&&wppaPrev(p),"r"==a&&wppaNext(p);break;default:alert("Unimplemented instruction: "+e+" on: "+t)}}function wppaOpenComments(p){_wppaSSRuns[p]&&_wppaStop(p),jQuery("#wppa-comtable-wrap-"+p).css("display","block"),jQuery("#wppa-comform-wrap-"+p).css("display","block"),jQuery("#wppa-comfooter-wrap-"+p).css("display","none"),wppaColWidth[p]=0,setTimeout("_wppaDoAutocol( "+p+" )",100)}function _wppaShowMetaData(p,a){_wppaSlides[p]&&(_wppaSSRuns[p]||__wppaOverruleRun?"show"==a?wppaFotomotoHideWhenRunning||wppaFotomotoToolbar(p,_wppaHiresUrl[p][_wppaCurIdx[p]]):wppaShareHideWhenRunning&&jQuery("#wppa-share-"+p).css("display","none"):"show"==a?(wppaAutoOpenComments&&(jQuery("#wppa-comtable-wrap-"+p).css("display","block"),jQuery("#wppa-comform-wrap-"+p).css("display","block"),jQuery("#wppa-comfooter-wrap-"+p).css("display","none")),0!=_wppaCurIdx[p]&&jQuery(".wppa-first-"+p).show(),_wppaCurIdx[p]!=_wppaSlides[p].length-1&&jQuery(".wppa-last-"+p).show(),wppaShareHideWhenRunning&&jQuery("#wppa-share-"+p).css("display",""),wppaFotomotoToolbar(p,_wppaHiresUrl[p][_wppaCurIdx[p]])):(jQuery("#wppa-comtable-wrap-"+p).css("display","none"),jQuery("#wppa-comform-wrap-"+p).css("display","none"),jQuery("#wppa-comfooter-wrap-"+p).css("display","block"),wppaFotomotoHide(p)),"show"==a?(jQuery("#imagedesc-"+p).css("visibility","visible"),jQuery("#imagetitle-"+p).css("visibility","visible"),jQuery("#counter-"+p).css("visibility","visible"),jQuery("#iptccontent-"+p).css("visibility","visible"),jQuery("#exifcontent-"+p).css("visibility","visible")):(jQuery("#counter-"+p).css("visibility","hidden"),jQuery(".wppa-first-"+p).hide(),jQuery(".wppa-last-"+p).hide(),jQuery("#iptccontent-"+p).css("visibility","hidden"),jQuery("#exifcontent-"+p).css("visibility","hidden")))}function wppaGetSlideshowTimeout(p){var a,e;return"random"==_wppaTimeOut[p]?(a=2*wppaAnimationSpeed,e=7*wppaAnimationSpeed,Math.floor(Math.random()*(e-a+1))+a):_wppaTimeOut[p]}function wppaIsSlidshowVisible(p){for(var a,e=["slide_frame-"+p,"filmwindow-"+p],t=e.length,i=0;i<t;i++)if(a=document.getElementById(e[i]),a&&(a.getBoundingClientRect(),wppaIsElementInViewport(a)))return!0;return wppaFilmInit[p]=!1}
|
7 |
// wppa-ajax-front
|
8 |
var wppaJsAjaxVersion="8.1.09.003";function wppaDoAjaxRender(o,a,r,p){""!=wppaLang&&(a+="&lang="+wppaLang),wppaAutoColumnWidth[o]&&(a+="&resp=1"),p&&_wppaCurIdx[o]&&_wppaId[o][_wppaCurIdx[o]]&&(a+="&wppa-hilite="+_wppaId[o][_wppaCurIdx[o]]),wppaCanAjaxRender||!r?jQuery.ajax({url:a,async:!0,type:"GET",timeout:6e4,beforeSend:function(a){_wppaSSRuns[o]&&_wppaStop(o),jQuery("#wppa-ajax-spin-"+o).fadeIn()},success:function(a,p,e){var a=JSON.parse(a),t=a.html+"<script>"+a.js+"<\/script>";wppaRenderModal&&r?(a={modal:!0,resizable:!0,width:wppaGetContainerWidth(o),show:{effect:"fadeIn",duration:400},closeText:""},jQuery("#wppa-modal-container-"+o).html(t).dialog(a).dialog("open"),jQuery(".ui-dialog").css({boxShadow:"0px 0px 5px 5px #aaaaaa",borderRadius:wppaBoxRadius+"px",padding:"8px",backgroundColor:wppaModalBgColor,boxSizing:"content-box",zIndex:1e5}),jQuery(".ui-dialog-titlebar").css({lineHeight:"0px",height:"32px"}),jQuery(".ui-button").css({backgroundImage:wppaModalQuitImg,padding:0,position:"absolute",right:"8px",top:"8px",width:"16px",height:"16px"}),jQuery(".ui-button").attr("title","Close"),jQuery(".ui-button").on("click",function(){_wppaStop(o)}),jQuery(".wppa-ajax-spin").stop().fadeOut()):(jQuery("#wppa-container-"+o).html(t),jQuery("#wppa-button-hide-"+o).show()),wppaCanPushState&&wppaUpdateAddressLine&&r&&(wppaHis++,r=r.split("&").join("&"),jQuery(document).ready(function(){setTimeout(function(){try{history.pushState({page:wppaHis,occur:o,type:"html",html:t},"",r),wppaConsoleLog("Pushed history stack on ajax call","force")}catch(a){try{history.replaceState({page:wppaHis,occur:o,type:"html"},"",r),wppaConsoleLog("History replaced on ajax call","force")}catch(a){wppaConsoleLog("Ajax rendering: History stack update and replace failed","force")}}},1e3)}),0==wppaFirstOccur&&(wppaFirstOccur=o)),wppaUpdateLightboxes(),"undefined"!=typeof wppaQRUpdate&&wppaQRUpdate(r),wppaColWidth[o]=0,_wppaDoAutocol(o,"ajax")},error:function(a,p,e){wppaConsoleLog("wppaDoAjaxRender failed. Error = "+e+", status = "+p,"force"),r?document.location.href=r:document.location.reload(!0)},complete:function(a,p,e){!wppaRenderModal&&wppaAjaxScroll&&jQuery("html, body").animate({scrollTop:jQuery("#wppa-container-"+o).offset().top-32-wppaStickyHeaderHeight},1e3),jQuery(".wppa-ajax-spin").stop().fadeOut(),window.dispatchEvent(new Event("resize")),wppaProtect()}}):(document.location.href=r,wppaColWidth[o]=0,_wppaDoAutocol(o,"nonajax"))}function wppaAjaxApprovePhoto(t){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=approve&photo-id="+t,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){"OK"==a?jQuery(".wppa-approve-"+t).css("display","none"):alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxApprovePhoto failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxRemovePhoto(t,o,r){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=remove&photo-id="+o,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){rtxt=a.split("||"),"OK"==rtxt[0]?r?(jQuery("#wppa-film-"+_wppaCurIdx[t]+"-"+t).attr("src",""),jQuery("#wppa-pre-"+_wppaCurIdx[t]+"-"+t).attr("src",""),jQuery("#wppa-film-"+_wppaCurIdx[t]+"-"+t).attr("alt","removed"),jQuery("#wppa-pre-"+_wppaCurIdx[t]+"-"+t).attr("alt","removed"),wppaNext(t)):(jQuery(".wppa-approve-"+o).css("display","none"),jQuery(".thumbnail-frame-photo-"+o).css("display","none")):rtxt[3]?(alert(rtxt[3]),jQuery("#wppa-delete-"+o).css("text-decoration","line-through")):alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxRemovePhoto failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxApproveComment(t){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=approve&comment-id="+t,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){"OK"==a?jQuery(".wppa-approve-"+t).css("display","none"):alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxApproveComment failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxRemoveComment(t){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=remove&comment-id="+t,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){"OK"==a.split("||")[0]?(jQuery(".wppa-approve-"+t).css("display","none"),jQuery(".wppa-comment-"+t).css("display","none")):alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxRemoveComment failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxAddPhotoToZip(o,r,n){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=addtozip&photo-id="+r,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){var t=a.split("||");"OK"==t[0]?(jQuery("#admin-choice-"+r+"-"+o).html(t[2]),jQuery("#admin-choice-"+r+"-"+o).val(t[2]),jQuery("#admin-choice-"+r+"-"+o).prop("disabled",!0)):wppaConsoleLog("NOT OK "+a),alert(t[1]),n&&document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxAddPhotoToZip failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxRemovePhotoFromZip(o,r,n){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=removefromzip&photo-id="+r,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){var t=a.split("||");"OK"==t[0]?(jQuery("#admin-choice-rem-"+r+"-"+o).val(t[1]),jQuery("#admin-choice-rem-"+r+"-"+o).prop("disabled",!0),jQuery("#admin-choice-rem-"+r+"-"+o).css("text-decoration","")):alert(a),n&&document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxRemovePhotoFromZip failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxDeleteMyZip(){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=delmyzip",async:!0,type:"GET",timeout:6e4,success:function(a,p,e){document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxDeleteMyZip failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxRequestInfo(a,p,e){dialogHtml="<h3>"+wppaRequestInfoDialogText+'</h3><textarea id="wppa-request-info-text-'+a+'" style="width:98%;" ></textarea><div style="clear:both;" ></div><input type="button" style="float:left;margin-top:8px;margin-right:8px;" value="Send" onclick="wppaAjaxRequestInfoSend( '+a+", "+p+", "+e+' )" /><input type="button" style="float:left;margin-top:8px;margin-right:8px;" value="Cancel" onclick="jQuery( \'#wppa-modal-container-'+a+"' ).dialog( 'close' );\" /><div style=\"clear:both;\" ></div>";e={modal:!0,resizable:!0,width:wppaGetContainerWidth(a),show:{effect:"fadeIn",duration:400},closeText:""};jQuery("#wppa-modal-container-"+a).html(dialogHtml).dialog(e).dialog("open"),jQuery(".ui-dialog").css({boxShadow:"0px 0px 5px 5px #aaaaaa",borderRadius:wppaBoxRadius+"px",padding:"8px",backgroundColor:wppaModalBgColor,boxSizing:"content-box",zIndex:1e5}),jQuery(".ui-dialog-titlebar").css({lineHeight:"0px",height:"24px"}),jQuery(".ui-button").css({backgroundImage:wppaModalQuitImg,padding:0,position:"absolute",right:"8px",top:"8px",width:"16px",height:"16px"}),jQuery(".ui-button").attr("title","Close")}function wppaAjaxRequestInfoSend(o,r,n){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=requestinfo&photo-id="+r+"&emailtext="+jQuery("#wppa-request-info-text-"+o).val(),async:!0,type:"GET",timeout:6e4,success:function(a,p,e){var t=a.split("||");"OK"==t[0]?(jQuery("#request-info-"+r+"-"+o).val(t[1]),jQuery("#request-info-"+r+"-"+o).prop("disabled",!0),jQuery("#wppa-modal-container-"+o).dialog("close")):alert(a),n&&document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxRequestInfoSend failed. Error = "+e+", status = "+p,"force")}})}function wppaEditPhoto(o,a){var p=String(a),a=wppaEditPhotoWidth;screen.availWidth<a&&(a=screen.availWidth),jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=front-edit&photo-id="+p+"&occur="+o,async:!0,type:"POST",timeout:6e4,beforeSend:function(a){},success:function(a,p,e){var t={modal:!0,resizable:!0,width:wppaGetContainerWidth(o),show:{effect:"fadeIn",duration:400},closeText:""};jQuery("#wppa-modal-container-"+o).html(a).dialog(t).dialog("open"),jQuery(".ui-dialog").css({boxShadow:"0px 0px 5px 5px #aaaaaa",borderRadius:wppaBoxRadius+"px",padding:"8px",backgroundColor:wppaModalBgColor,boxSizing:"content-box",zIndex:1e5}),jQuery(".ui-dialog-titlebar").css({lineHeight:"0px",height:"24px"}),jQuery(".ui-button").css({backgroundImage:wppaModalQuitImg,padding:0,position:"absolute",right:"8px",top:"8px",width:"16px",height:"16px"}),jQuery(".ui-button").attr("title","Close"),jQuery(document).trigger("resize")},error:function(a,p,e){wppaConsoleLog("wppaEditPhoto failed. Error = "+e+", status = "+p,"force")},complete:function(a,p,e){}})}function wppaPrevTags(a,p,e,t){for(var o,r=jQuery("."+a),n=[],i=jQuery("#"+e).val(),c=0,u=0,a="";c<r.length;)r[c].selected&&(n[u]=r[c].value,u++),c++;""!=(o=jQuery("#"+p).val())&&(n[u]=o),a=n.join(),""==o&&""==e||jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=sanitizetags&tags="+a+"&album="+i,async:!0,type:"GET",timeout:6e4,beforeSend:function(a){jQuery("#"+t).html("Working...")},success:function(a,p,e){jQuery("#"+t).html(wppaTrim(a,","))},error:function(a,p,e){jQuery("#"+t).html('<span style="color:red" >'+e+"</span>"),wppaConsoleLog("wppaPrevTags failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxDestroyAlbum(a,p){return confirm("Are you sure you want to delete this album?")&&jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=destroyalbum&album="+a+"&nonce="+p,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){alert(a+"\nPage will be reloaded"),document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxDestroyAlbum failed. Error = "+e+", status = "+p,"force")}}),!1}function _bumpClickCount(a){wppaBumpClickCount&&jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=bumpclickcount&wppa-photo="+a+"&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!1,type:"GET",timeout:6e4,success:function(a,p,e){},error:function(a,p,e){wppaConsoleLog("_bumpClickCount failed. Error = "+e+", status = "+p,"force")}})}function _bumpViewCount(t){wppaBumpViewCount&&(wppaPhotoView[t]||jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=bumpviewcount&wppa-photo="+t+"&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!0,type:"GET",timeout:6e4,success:function(a,p,e){wppaPhotoView[t]=!0},error:function(a,p,e){wppaConsoleLog("_bumpViewCount failed. Error = "+e+", status = "+p,"force")}}))}function wppaVoteThumb(t,o){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=rate&wppa-rating=1&wppa-rating-id="+o+"&wppa-occur="+t+"&wppa-index=0&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!0,type:"GET",timeout:6e4,success:function(a,p,e){jQuery("#wppa-vote-button-"+t+"-"+o).val(wppaVotedForMe)},error:function(a,p,e){wppaConsoleLog("wppaVoteThumb failed. Error = "+e+", status = "+p,"force")}})}function _wppaRateIt(o,p){var a,e,t;0!=p&&(_wppaSSRuns[o]||(a=_wppaId[o][_wppaCurIdx[o]],e=_wppaMyr[o][_wppaCurIdx[o]],0<(t=_wppaWaitTexts[o][_wppaCurIdx[o]]).length?alert(t):0!=e&&wppaRatingOnce||e<0||(_wppaVoteInProgress=!0,jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=rate&wppa-rating="+p+"&wppa-rating-id="+a+"&wppa-occur="+o+"&wppa-index="+_wppaCurIdx[o]+"&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!0,type:"GET",timeout:6e4,beforeSend:function(a){jQuery("#wppa-rate-"+o+"-"+p).attr("src",wppaImageDirectory+"tick.png"),jQuery("#wppa-rate-"+o+"-"+p).stop().fadeTo(100,1),jQuery("#wppa-like-"+o).attr("src",wppaImageDirectory+"spinner.gif")},success:function(a,p,e){var t=a.split("||");0==t[0]?900==t[1]?(alert(t[2]),_wppaSetRatingDisplay(o)):alert("Error Code="+t[1]+"\n\n"+t[2]):(t[7]&&"likes"==t[7]?(a=t[4].split("|"),jQuery("#wppa-like-"+o).attr("title",a[0]),jQuery("#wppa-liketext-"+o).html(a[1]),"1"==t[3]?jQuery("#wppa-like-"+o).attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-"+o).attr("src",wppaImageDirectory+"thumbup.png"),_wppaMyr[t[0]][t[2]]=t[3],_wppaAvg[t[0]][t[2]]=t[4]):(_wppaMyr[t[0]][t[2]]=t[3],_wppaAvg[t[0]][t[2]]=t[4],_wppaDisc[t[0]][t[2]]=t[5],_wppaSetRatingDisplay(o),wppaCommentRequiredAfterVote&&0==t[6]&&alert(t[7])),wppaNextOnCallback&&_wppaNextOnCallback(o))},error:function(a,p,e){wppaConsoleLog("_wppaRateIt failed. Error = "+e+", status = "+p,"force")}}))))}function _wppaOvlRateIt(o,r,n,i){0!=r&&jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=rate&wppa-rating="+r+"&wppa-rating-id="+o+"&wppa-occur=1&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!0,type:"GET",timeout:6e4,beforeSend:function(a){jQuery(".wppa-rate-"+n+"-"+r).attr("src",wppaImageDirectory+"tick.png"),jQuery(".wppa-rate-"+n+"-"+r).stop().fadeTo(100,1),jQuery("#wppa-like-"+o+"-"+n).attr("src",wppaImageDirectory+"spinner.gif"),jQuery("#wppa-like-0").attr("src",wppaImageDirectory+"spinner.gif")},success:function(a,p,e){var t=a.split("||");if(0==t[0])900==t[1]?alert(t[2]):alert("Error Code="+t[1]+"\n\n"+t[2]),jQuery(".wppa-rate-"+n+"-"+r).attr("src",wppaImageDirectory+"cross.png");else{if(t[7]&&"likes"==t[7]){a=t[4].split("|");return jQuery("#wppa-like-0").attr("title",a[0]),jQuery("#wppa-liketext-0").html(a[1]),"1"==t[3]?jQuery("#wppa-like-0").attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-0").attr("src",wppaImageDirectory+"thumbup.png"),jQuery("#wppa-like-"+o+"-"+n).attr("title",a[0]),jQuery("#wppa-liketext-"+o+"-"+n).html(a[1]),void("1"==t[3]?jQuery("#wppa-like-"+o+"-"+n).attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-"+o+"-"+n).attr("src",wppaImageDirectory+"thumbup.png"))}_wppaSetRd(n,t[4],".wppa-avg-"),_wppaSetRd(n,t[3],".wppa-rate-"),i||wppaNextOnCallback&&wppaOvlShowNext()}},error:function(a,p,e){wppaConsoleLog("_wppaOvlRateIt failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxMakeOrigName(a,p){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=makeorigname&photo-id="+p+"&from=fsname",async:!0,type:"GET",timeout:6e4,beforeSend:function(a){},success:function(a,p,e){a=a.split("||");"0"==a[1]?(wppaIsSafari?"file"==wppaArtMonkyLink&&(wppaWindowReference.location=a[2]):"file"==wppaArtMonkyLink&&window.open(a[2]),"zip"==wppaArtMonkyLink&&(document.location=a[2])):(wppaIsSafari&&"file"==wppaArtMonkyLink&&wppaWindowReference.close(),alert("Error: "+a[1]+"\n\n"+a[2]))},error:function(a,p,e){wppaConsoleLog("wppaAjaxMakeOrigName failed. Error = "+e+", status = "+p,"force")},complete:function(a,p,e){}})}function wppaAjaxDownloadAlbum(t,o){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=downloadalbum&album-id="+o,async:!0,type:"GET",timeout:6e4,beforeSend:function(a){jQuery("#dwnspin-"+t+"-"+o).css("display","")},success:function(a,p,e){var t=a.split("||"),o=t[0],r=t[1],a=t[2];3==t.length&&""!=a&&alert("Attention:\n\n"+a),"OK"==r?document.location=o:alert("The server could not complete the request.\nPlease try again.")},error:function(a,p,e){alert("An error occurred:\n"+e+"\nPlease try again")},complete:function(a,p,e){jQuery("#dwnspin-"+t+"-"+o).css("display","none")}})}function wppaAjaxComment(t,a){_wppaValidateComment(t,a)&&(a="action=wppa&wppa-action=do-comment&photo-id="+a+"&comname="+jQuery("#wppa-comname-"+t).val()+"&comment="+wppaEncode(jQuery("#wppa-comment-"+t).val())+"&wppa-captcha="+jQuery("#wppa-captcha-"+t).val()+"&wppa-nonce="+jQuery("#wppa-nonce-"+t).val()+"&occur="+t,void 0!==jQuery("#wppa-comemail-"+t).val()&&(a+="&comemail="+jQuery("#wppa-comemail-"+t).val()),void 0!==jQuery("#wppa-comment-edit-"+t).val()&&(a+="&comment-edit="+jQuery("#wppa-comment-edit-"+t).val()),void 0!==jQuery("#wppa-returnurl-"+t).val()&&(a+="&returnurl="+encodeURIComponent(jQuery("#wppa-returnurl-"+t).val())),jQuery("#db-agree-"+t).prop("checked")&&(a+="&db-agree=yes"),jQuery.ajax({url:wppaAjaxUrl,data:a,async:!0,type:"POST",timeout:6e4,beforeSend:function(a){jQuery("#wppa-comment-spin-"+t).css("display","inline")},success:function(a,p,e){a=a.replace(/\\/g,""),jQuery("#wppa-comments-"+t).html(a),_wppaCurIdx[t]&&(_wppaCommentHtml[t][_wppaCurIdx[t]]=a),wppaOpenComments(t)},error:function(a,p,e){wppaConsoleLog("wppaAjaxComment failed. Error = "+e+", status = "+p,"force")},complete:function(a,p,e){jQuery("#wppa-comment-spin-"+t).css("display","none")}}))}function wppaUpdatePhotoNew(a,t){for(var p=["upn-name","upn-description","upn-tags","custom_0","custom_1","custom_2","custom_3","custom_4","custom_5","custom_6","custom_7","custom_8","custom_9"],e="action=wppa&wppa-action=update-photo-new&photo-id="+a+"&wppa-nonce="+jQuery("#wppa-nonce-"+a).val(),o=0;o<p.length;)void 0!==jQuery("#"+p[o]).val()&&(e+="&"+p[o]+"="+jQuery("#"+p[o]).val()),o++;jQuery.ajax({url:wppaAjaxUrl,data:e,async:!1,type:"POST",timeout:1e4,beforeSend:function(a){},success:function(a,p,e){a=a.split("||"),a=JSON.parse(a[2]);jQuery(".sdd-"+t).html(a.desc),jQuery(".sdn-"+t).html(a.name),jQuery(".sdf-"+t).html(a.fullname),_wppaNames[t]&&(_wppaNames[t][_wppaCurIdx[t]]=wppaFixHtml(a.name),_wppaFullNames[t][_wppaCurIdx[t]]=wppaFixHtml(a.fullname),_wppaDsc[t][_wppaCurIdx[t]]=wppaFixHtml(a.desc),jQuery("#imagetitle-"+t).html(wppaMakeNameHtml(t)))},error:function(a,p,e){wppaConsoleLog("wppaUpdatePhotoNew failed. Error = "+e+", status = "+p,"force")},complete:function(a,p,e){jQuery("#wppa-modal-container-"+t).dialog("close")}})}function wppaFixHtml(a){return a=(a=(a=(a=a.replace(/\[/g,"<")).replace(/\]/g,">")).replace(/"/g,'"')).replace(/\\n/g," ")}var wppaLastQrcodeUrl="";function wppaAjaxSetQrCodeSrc(a,t){0!=jQuery(t).length&&wppaLastQrcodeUrl!=a&&(wppaLastQrcodeUrl=a,a="action=wppa&wppa-action=getqrcode&wppa-qr-nonce="+jQuery("#wppa-qr-nonce").val()+"&url="+encodeURIComponent(a),jQuery.ajax({url:wppaAjaxUrl,data:a,async:!0,type:"POST",timeout:1e4,success:function(a,p,e){a=a.split("|");jQuery(t).attr("src",a[0]),jQuery(t).attr("title",a[1])},error:function(a,p,e){wppaConsoleLog("wppaAjaxSetQrCodeSrc failed. Error = "+e+", status = "+p,"force")}}))}function wppaAjaxNotify(a,p){a=jQuery(a).prop("checked")?"on":"off",a="action=wppa&wppa-action=mailinglist&wppa-ntfy-nonce="+jQuery("#wppa-ntfy-nonce").val()+"&list="+p+"&onoff="+a;jQuery.ajax({url:wppaAjaxUrl,data:a,async:!0,type:"POST",timeout:1e4,success:function(a,p,e){alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxNotify failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxGetSsIptcList(a,p,e,t){wppaAjaxGetSsIptcExifList(a,p,e,t,"iptc")}function wppaAjaxGetSsExifList(a,p,e,t){wppaAjaxGetSsIptcExifList(a,p,e,t,"exif")}function wppaAjaxGetSsIptcExifList(t,o,r,n,i){ajaxurl=wppaAjaxUrl,ajaxurl+="?action=wppa&wppa-action=getss"+i+"list&"+i+"tag="+o+"&occur="+t,jQuery.ajax({url:ajaxurl,async:!0,type:"GET",timeout:1e4,beforeSend:function(a){jQuery("#wppa-ss-spinner-"+t).css("display","")},success:function(a,p,e){jQuery("#"+r).html(a),jQuery("#wppa-ss-"+i+"opts-"+t).css("display",""),wppaSuperSearchSelect(t),setTimeout('wppaSetIptcExifSize( ".wppa-'+i+"list-"+t+'", "#'+r+'" )',10),n&&wppaConsoleLog("wppaAjaxGetSs"+i+"List success after retry.","force")},error:function(a,p,e){wppaConsoleLog("wppaAjaxGetSs"+i+"List failed. Error = "+e+", status = "+p,"force"),n||wppaAjaxGetSsIptcExifList(t,o,r,!0,i)},complete:function(a,p,e){jQuery("#wppa-ss-spinner-"+t).css("display","none")}})}
|
9 |
// wppa-lightbox
|
@@ -13,6 +13,8 @@ var wppaJsPopupVersion="8.0.07.004";function wppaPopUp(p,t,i,e,a,n,o,r,d,s){wppa
|
|
13 |
// wppa-touch
|
14 |
var wppaJsTouchVersion="8.0.01006";function wppaStartTime(){var p=(new Date).getTime();return wppaMobileTimeStart=p,!0}function wppaInTime(){return(new Date).getTime()-wppaMobileTimeStart<250}function wppaTapLink(p,e){wppaInTime()&&(_bumpClickCount(p),document.location.href=e)}function wppaTouchStart(p,e,a){-1==(wppaSwipeMocc=a)&&(wppaSwipeOnLightbox=!0,p.preventDefault()),wppaFingerCount=p.touches.length,1==wppaFingerCount?(wppaStartX=p.touches[0].pageX,wppaStartY=p.touches[0].pageY,wppaTriggerElementID=e):wppaTouchCancel()}function wppaTouchMove(p){wppaSwipeOnLightbox&&p.preventDefault(),1==p.touches.length?(wppaCurX=p.touches[0].pageX,wppaCurY=p.touches[0].pageY):wppaTouchCancel()}function wppaTouchEnd(p){wppaSwipeOnLightbox&&p.preventDefault(),1==wppaFingerCount&&0!=wppaCurX&&(wppaSwipeLength=Math.round(Math.sqrt(Math.pow(wppaCurX-wppaStartX,2)+Math.pow(wppaCurY-wppaStartY,2))),wppaSwipeLength>=wppaMinLength&&(wppaCalculateAngle(),wppaDetermineSwipeDirection(),wppaProcessingRoutine())),wppaTouchCancel()}function wppaTouchCancel(){wppaFingerCount=0,wppaStartX=0,wppaStartY=0,wppaCurX=0,wppaCurY=0,wppaDeltaX=0,wppaDeltaY=0,wppaHorzDiff=0,wppaVertDiff=0,wppaSwipeLength=0,wppaSwipeAngle=null,wppaSwipeDirection=null,wppaTriggerElementID=null,wppaSwipeOnLightbox=!1,wppaSwipeMocc=0}function wppaCalculateAngle(){var p=wppaStartX-wppaCurX,e=wppaCurY-wppaStartY,p=(Math.round(Math.sqrt(Math.pow(p,2)+Math.pow(e,2))),Math.atan2(e,p));wppaSwipeAngle=Math.round(180*p/Math.PI),wppaSwipeAngle<0&&(wppaSwipeAngle=360-Math.abs(wppaSwipeAngle))}function wppaDetermineSwipeDirection(){wppaSwipeDirection=wppaSwipeAngle<=45&&0<=wppaSwipeAngle||wppaSwipeAngle<=360&&315<=wppaSwipeAngle?"left":135<=wppaSwipeAngle&&wppaSwipeAngle<=225?"right":45<wppaSwipeAngle&&wppaSwipeAngle<135?"down":"up"}function wppaProcessingRoutine(){document.getElementById(wppaTriggerElementID);if(wppaSwipeOnLightbox)"left"==wppaSwipeDirection?wppaOvlShowNext():"right"==wppaSwipeDirection&&wppaOvlShowPrev();else{if("right"==wppaSwipeDirection){if(idx=_wppaCurIdx[wppaSwipeMocc]-1,idx<0){if(!wppaSlideWrap)return;idx=_wppaSlides[wppaSwipeMocc].length-1}wppaGotoKeepState(wppaSwipeMocc,idx)}if("left"==wppaSwipeDirection){if(idx=_wppaCurIdx[wppaSwipeMocc]+1,idx==_wppaSlides[wppaSwipeMocc].length){if(!wppaSlideWrap)return;idx=0}wppaGotoKeepState(wppaSwipeMocc,idx)}else"up"==wppaSwipeDirection||wppaSwipeDirection}wppaTouchCancel()}
|
15 |
// wppa-zoom
|
16 |
-
var wppaJsZoomVersion="8.
|
17 |
// wppa-spheric
|
18 |
var wppaJsSphericVersion="8.1.09.001";function wppaDoSphericPan(n,e){var t;e&&((t=new Image).src=e.url,t.onload=function(){_wppaDoSphericPan(n,e)})}function _wppaDoSphericPan(t,n){var s=jQuery;n&&(wppaSphericData[t]=n);var w=f(t,w);function l(n){var e=f(n);!e.manCtrl&&b()<e.time+25||(f(n,{time:b()}),e.isLightbox&&(!wppaOvlOpen||wppaOvlActivePanorama!=e.id||wppaGlobalOvlPanoramaId>e.uId)&&(abort=!0),e.abort||((e.butDown||e.manCtrl)&&e.autorun&&(e.autorun=!1,e.dX=0),0==e.dX&&0==e.dY&&0==e.dFov&&(e.pause=!0),e.butDown&&(e.pause=!1),e.fov+=e.dFov,e.fov=Math.max(20,Math.min(120,e.fov)),e.wppaCamera=new THREE.PerspectiveCamera(e.fov,e.aspect,1,1e3),e.wppaCamera.target=new THREE.Vector3(0,0,0),e.lon+=e.dX,e.lat+=e.dY,e.lat=Math.max(-85,Math.min(85,e.lat)),e.wppaCamera.target.x=500*Math.sin(THREE.Math.degToRad(90-e.lat))*Math.cos(THREE.Math.degToRad(e.lon)),e.wppaCamera.target.y=500*Math.cos(THREE.Math.degToRad(90-e.lat)),e.wppaCamera.target.z=500*Math.sin(THREE.Math.degToRad(90-e.lat))*Math.sin(THREE.Math.degToRad(e.lon)),e.wppaCamera.lookAt(e.wppaCamera.target),e.wppaRenderer&&e.wppaRenderer.render(e.wppaScene,e.wppaCamera),wppaAdjustControlbar(),s("#wppa-ovl-spin").hide(),e.manCtrl,(e.autorun||!e.pause&&(e.manCtrl||e.butDown))&&e.wppaRenderer&&(e.timer=setTimeout(function(){l(n)},25)),f(n,e)))}function e(n,e){var t=!wppaIsFs();if(w=f(n)){if(w.isLightbox){if(!wppaOvlOpen)return;s("#wppa-overlay-pc").show(),s("#wppa-overlay-pc").css("width","");var a,o,p=(t=!wppaIsFs())?(o=window.innerWidth||screen.width,window.innerHeight||screen.height):(o=screen.width,screen.height),i=8,r=8+(w.controls?w.icsize+10:0)+30;t&&(i+=2*w.borderWidth,r+=2*w.borderWidth),a=(o-i)/2+r<p,r=t?a?(p-(c=(u=o-i)/2)-r)/2+20:(u=2*(c=p-r),20):(u=screen.width,c=screen.height,0),w.aspect=u/c,s("#wppa-ovl-sphericpan-container").css({top:r}),s("#wppa-overlay-pc").css({top:0}),t?(s("#wppa-ovl-sphericpan-container").css({backgroundColor:w.backgroundColor,padding:w.padding+"px",borderRadius:w.borderRadius+"px",width:u}),a?s("#wppa-overlay-pc").css({left:4}):s("#wppa-overlay-pc").css({left:(o-u)/2})):s("#wppa-ovl-sphericpan-container").css({backgroundColor:"transparent",padding:0,borderRadius:"0px",width:u,left:(o-u)/2}),w.wppaRenderer.setSize(u,c)}else{if("force"!=e&&0<w.width&&w.width==u&&w.height==c)return;var u=s(w.div).parent().width(),c=parseInt(u/2);if(!w.wppaRenderer)return;w.wppaRenderer.setSize(u,c)}w.width=u,w.height=c,f(n,w),w.timer=setTimeout(function(){l(n)},250)}}function a(n,e){e.preventDefault(),e.stopPropagation(),w=f(n,{manCtrl:!0,butDown:!1,autorun:!1,dX:0}),e.touches?f(n,{sX:e.touches[0].clientX,sY:e.touches[0].clientY}):f(n,{sX:e.clientX,sY:e.clientY}),f(n,{sLon:w.lon,sLat:w.lat}),l(n)}function o(n,e){e.preventDefault(),e.stopPropagation(),(w=f(n)).manCtrl&&(e.touches?f(n,{lon:.1*(w.sX-e.touches[0].clientX)+w.sLon,lat:.1*(e.touches[0].clientY-w.sY)+w.sLat,pause:!1}):f(n,{lon:.1*(w.sX-e.clientX)+w.sLon,lat:.1*(e.clientY-w.sY)+w.sLat,pause:!1}),l(n))}function p(n){f(n,{manCtrl:!1})}function i(n){w=f(n),f(n,{dFov:-.4*w.mFakt,butDown:!0}),l(n)}function r(n){w=f(n),f(n,{dFov:.4*w.mFakt,butDown:!0}),l(n)}function u(n){w=f(n),f(n,{dX:.2*w.mFakt,butDown:!0}),l(n)}function c(n){w=f(n),f(n,{dX:-.2*w.mFakt,butDown:!0}),l(n)}function h(n){w=f(n),f(n,{dY:.2*w.mFakt,butDown:!0}),l(n)}function m(n){w=f(n),f(n,{dY:-.2*w.mFakt,butDown:!0}),l(n)}function v(n){w=f(n),f(n,{dX:0,dY:0,dFov:0,butDown:!1,manCtrl:!1})}function f(n,e){if(!wppaSphericData[n])return!1;if(e)for(var t in e)wppaSphericData[n][t]=e[t];return wppaSphericData[n]}function b(){return d=new Date,d.getTime()}w.initialized||w.abort||w.isLightbox&&!wppaOvlOpen||(w.wppaRenderer&&(w.wppaRenderer.state.reset(),w.wppaSphere.dispose(),w.wppaSphereMaterial.dispose(),w.texture.dispose()),w.isLightbox&&wppaOvlOpen&&(s("#wppa-ovl-spin").show(),s("#wppa-overlay-ic").html("")),w.manCtrl=!1,w.butDown=!1,w.lon=180,w.lat=0,w.dFov=0,w.abort=!1,w.aspect=2,w.div=s("#wppa-pan-div-"+t),w.left=s("#wppa-pctl-left-"+t),w.right=s("#wppa-pctl-right-"+t),w.up=s("#wppa-pctl-up-"+t),w.down=s("#wppa-pctl-down-"+t),w.zoomin=s("#wppa-pctl-zoomin-"+t),w.zoomout=s("#wppa-pctl-zoomout-"+t),w.prev=s("#wppa-pctl-prev-"+t),w.next=s("#wppa-pctl-next-"+t),w.pause=!1,w.mFakt=wppaIsMobile?"2":"1",w.time=0,w.isLightbox&&(wppaGlobalOvlPanoramaId++,w.uId=wppaGlobalOvlPanoramaId),s(w.div).html(""),w.wppaRenderer||(w.wppaRenderer=new THREE.WebGLRenderer),w.wppaRenderer.setSize(w.width,w.height),s(w.div).append(w.wppaRenderer.domElement),w.wppaScene=new THREE.Scene,w.wppaSphere=new THREE.SphereGeometry(100,100,40),w.wppaSphere.applyMatrix4((new THREE.Matrix4).makeScale(-1,1,1)),w.texture=(new THREE.TextureLoader).load(w.url),w.wppaSphereMaterial=new THREE.MeshBasicMaterial({map:w.texture}),w.wppaSphereMesh=new THREE.Mesh(w.wppaSphere,w.wppaSphereMaterial),w.wppaScene.add(w.wppaSphereMesh),w.right.on("touchstart",function(n){u(t)}),w.right.on("touchend",function(n){v(t)}),w.left.on("touchstart",function(n){c(t)}),w.left.on("touchend",function(n){v(t)}),w.up.on("touchstart",function(n){h(t)}),w.up.on("touchend",function(n){v(t)}),w.down.on("touchstart",function(n){m(t)}),w.down.on("touchend",function(n){v(t)}),w.zoomin.on("touchstart",function(n){i(t)}),w.zoomin.on("touchend",function(n){v(t)}),w.zoomout.on("touchstart",function(n){r(t)}),w.zoomout.on("touchend",function(n){v(t)}),w.enableManual&&0<s("#wppa-pan-div-"+t+" canvas").length&&(s("#wppa-pan-div-"+t+" canvas")[0].addEventListener("touchstart",function(n){a(t,n)}),s("#wppa-pan-div-"+t+" canvas")[0].addEventListener("touchmove",function(n){o(t,n)}),s("#wppa-pan-div-"+t+" canvas")[0].addEventListener("touchend",function(n){p(t)})),w.right.on("mousedown",function(n){u(t)}),w.right.on("mouseup",function(n){v(t)}),w.left.on("mousedown",function(n){c(t)}),w.left.on("mouseup",function(n){v(t)}),w.up.on("mousedown",function(n){h(t)}),w.up.on("mouseup",function(n){v(t)}),w.down.on("mousedown",function(n){m(t)}),w.down.on("mouseup",function(n){v(t)}),w.zoomin.off("mousedown"),w.zoomin.on("mousedown",function(n){i(t)}),w.zoomin.off("mouseup"),w.zoomin.on("mouseup",function(n){v(t)}),w.zoomout.on("mousedown",function(n){r(t)}),w.zoomout.on("mouseup",function(n){v(t)}),w.enableManual&&0<s("#wppa-pan-div-"+t+" canvas").length&&(s("#wppa-pan-div-"+t+" canvas").on("mousedown",function(n){a(t,n)}),s("#wppa-pan-div-"+t+" canvas").on("mousemove",function(n){o(t,n)}),s("#wppa-pan-div-"+t+" canvas").on("mouseup",function(n){p(t)}),s("#wppa-pan-div-"+t+" canvas")[0].addEventListener("wheel",function(n){var e;e=t,(n=n).preventDefault(),n.stopPropagation(),w=f(e),f(e,{manCtrl:!1,butDown:!1,autorun:!1,dX:0,dFov:-n.deltaY*w.zoomsensitivity/60}),l(e),setTimeout(function(){f(e,{dFov:0})},25)})),w.isLightbox&&(s("body").on("quitimage",function(n){var e;w=f(e=t,{abort:!0,autorun:!1}),clearTimeout(w.timer),clearInterval(w.intervalTimer),s("#wppa-pan-div-"+e+" canvas").hide(),s("#wppa-pctl-div-"+e).hide(),s("#wppa-overlay-pc").hide()}),s("#wppa-pctl-div-"+t).on("click",function(n){wppaKillEvent(n)})),f(t,w),s(window).on("wpparesizeend",function(n){e(t,n)}),wppaProtect(),s(document).on("tabbychange",function(n){var e;e=t,w.wppaRenderer.state.reset(),w=f(e,{initialized:!1,abort:!0}),setTimeout(function(){f(e,{abort:!1}),wppaDoSphericPan(e)},200)}),e(t,"force"))}
|
|
|
|
3 |
// wppa
|
4 |
function wppaTabbyClick(){jQuery(window).trigger("resize"),jQuery(document).trigger("tabbychange"),jQuery(window).trigger("orientationchange"),wppaAdjustAllFilmstrips(wppaEasingSlide)}function wppaQRUpdate(e){wppaAjaxSetQrCodeSrc(e,"#wppa-qr-img")}function wppaDoInit(){_wppaTextDelay=wppaAnimationSpeed,wppaFadeInAfterFadeOut&&(_wppaTextDelay*=2),wppaIsMobile&&wppaNoAnimateOnMobile&&(_wppaTextDelay=10),jQuery(".wppa-ajax-spin").hide(),jQuery(".wppa-ovl-spin").hide(),setTimeout(function(){jQuery(".wppa-ubb").each(function(){var e=jQuery(this).attr("id").substr(6);wppaUbb(e,"l","hide"),wppaUbb(e,"r","hide")})},3e3),jQuery(window).on("DOMContentLoaded load resize wppascrollend orientationchange",wppaDoAllAutocols),jQuery(window).on("DOMContentLoaded load resize scroll wheel orientationchange",wppaSizeArea),jQuery(window).on("DOMContentLoaded load resize wppascrollend orientationchange",function(){wppaMakeLazyVisibleScrollEnd("doinitwindowon")}),jQuery(".wppa-divnicewrap").on("DOMContentLoaded load resize wppascrollend wheelend orientationchange",function(){wppaMakeLazyVisibleScrollEnd("doinitnicewrapon")}),jQuery(window).on("DOMContentLoaded load resize wppascrollend orientationchange",wppaInitMasonryPlus),jQuery(window).on("resize",function(){wppaAdjustAllFilmstrips(wppaEasingSlide)}),jQuery(window).on("DOMContentLoaded load resize wppascrollend orientationchange",function(){setTimeout(function(){wppaResizeNice()},1e3)}),jQuery(window).trigger("resize"),wppaProtect(),setTimeout(function(){jQuery(".responsive-tabs__heading").on("click",wppaTabbyClick),jQuery(".responsive-tabs__list__item").on("click",wppaTabbyClick)},10),jQuery(document).on("tabbychange",function(){void 0!==jQuery("div").getNiceScroll&&setTimeout(function(){jQuery("div").getNiceScroll().resize(),wppaDoAllAutocols()},500),setTimeout(function(){wppaDoAllAutocols(),jQuery(window).trigger("resize"),jQuery("#wppa-ovl-spin").hide(),wppaMakeLazyVisibleScrollEnd("tabbychange")},1500)}),wppaOvlGlobal&&jQuery("a").each(function(){var e=jQuery(this).attr("href");e&&("jpg"!=(e=(e=e.split("."))[e.length-1])&&"jpeg"!=e&&"png"!=e||jQuery(this).attr("data-rel")||(jQuery(this).attr("data-rel",wppaOvlGlobal),jQuery(this).css("cursor","wait")))}),jQuery("div").on("touchmove",wppaMakeLazyVisibleScrollEnd)}var wppaResizeNiceTimer,wppaResizeEndTimer,wppaScrollEndTimer;function wppaResizeNice(){clearTimeout(wppaResizeNiceTimer),wppaResizeNiceTimer=setTimeout(function(){_wppaResizeNice()},200)}function _wppaResizeNice(){"function"==typeof jQuery("body").getNiceScroll&&jQuery("body").getNiceScroll().resize(),jQuery("div").each(function(){"function"==typeof jQuery(this).getNiceScroll&&jQuery(this).getNiceScroll().resize()})}function wppaSizeAutoDiv(){jQuery(".wppa-autodiv").each(function(e){var p=jQuery(window).height(),a=jQuery(this).attr("data-max-height");jQuery(this).css({maxHeight:p*a})})}wppaWppaVer="8.1.07.001",jQuery(document).ready(function(){wppaConsoleLog("Document.ready","force")}),jQuery(document).ready(function(){wppaDoInit()}),jQuery(document).ready(function(){wppaQRUpdate(document.location.href)}),window.onpopstate=function(e){wppaQRUpdate(document.location.href)},jQuery(document).ready(function(){jQuery(window).on("resize load",function(){clearTimeout(wppaResizeEndTimer),wppaResizeEndTimer=setTimeout(function(){jQuery(window).trigger("wpparesizeend")},wppaResizeEndDelay)})}),jQuery(document).ready(function(){jQuery(window).on("scroll wheel touchmove",function(){clearTimeout(wppaScrollEndTimer),wppaScrollEndTimer=setTimeout(function(){jQuery(window).trigger("wppascrollend")},wppaScrollEndDelay)})}),jQuery(document).ready(function(){jQuery(window).on("DOMContentLoaded load resize scroll wheel orientationchange",wppaSizeAutoDiv)});var wppaLastAllAutocols=0,wppaLastAllAutocolsTimer=0;function wppaDoAllAutocols(e){wppaTimNow()<wppaLastAllAutocols+200?wppaLastAllAutocolsTimer=wppaLastAllAutocolsTimer||setTimeout(wppaDoAllAutocols,200):(clearTimeout(wppaLastAllAutocolsTimer),wppaLastAllAutocols=wppaTimNow(),_wppaDoAllAutocols(0))}function _wppaDoAllAutocols(p){return jQuery(".wppa-container").each(function(){var e=jQuery(this).attr("id").substr(15);wppaAutoColumnWidth[e]&&_wppaDoAutocol(e,p)}),(p<wppaExtendedResizeCount||-1==wppaExtendedResizeCount)&&setTimeout(function(){_wppaDoAllAutocols(p+1)},wppaExtendedResizeDelay),!0}function wppaProtect(){wppaHideRightClick&&(jQuery("img").bind("contextmenu",function(e){return!1}),jQuery("video").bind("contextmenu",function(e){return!1}),jQuery("canvas").bind("contextmenu",function(e){return!1}))}function wppaUpdateLightboxes(){"function"==typeof wppaInitOverlay&&wppaInitOverlay(),"undefined"!=typeof myLightbox&&"function"==typeof myLightbox.updateImageList&&myLightbox.updateImageList(),jQuery().prettyPhoto&&jQuery("a[rel^='prettyPhoto']").prettyPhoto({deeplinking:!1})}function wppaStopVideo(e){var p,a,t=[];for(t[1]="wppa-overlay-img",t[2]="theimg0-"+e,t[3]="theimg1-"+e,a=0;a<3;)1==++a&&0!=e||(p=document.getElementById(t[a]))&&"function"==typeof p.pause&&p.pause()}function wppaStopAudio(e){if("number"==typeof e)jQuery("#audio-"+e).pause&&jQuery("#audio-"+e).pause();else{var p=jQuery("audio");if(0<p.length)for(var a=0;a<p.length;)"wppa"==jQuery(p[a]).attr("data-from")&&p[a].pause(),a++}}function wppaMakeFullsizeUrl(e){var p,a;e=(p=(e=e.replace("/thumbs/","/")).split("//"))[1]?(a=p[1].split("/"),p[0]+"//"):(a=p[0].split("/"),"");for(var t=0;t<a.length;){var o=a[t];"w"!=o.split("_")[0]&&(0!=t&&(e+="/"),e+=o),t++}return e}function wppaGetContainerWidth(e){var p=document.getElementById("wppa-container-"+e);if(p){var a=0;if(!wppaAutoColumnWidth[e])return p.clientWidth;for(;0==a;)p=p.parentNode,a=jQuery(p).width();return parseInt(a)}}function _wppaDoAutocol(e,p){if(!wppaAutoColumnWidth[e])return!0;var a,t,o=wppaGetContainerWidth(e);if(document.getElementById("wppa-container-"+e)){if(wppaCoverImageResponsive[e]||1<(a=jQuery(".wppa-asym-text-frame-"+e)).length&&(jQuery(a[0]).width(),0==wppaResponseSpeed?(jQuery(".wppa-asym-text-frame-"+e).css({width:o-wppaTextFrameDelta}),jQuery(".wppa-cover-box-"+e).css({width:o})):(wppaAnimate(".wppa-asym-text-frame-"+e,{width:o-wppaTextFrameDelta},wppaResponseSpeed,wppaEasingDefault),wppaAnimate(".wppa-cover-box-"+e,{width:o},wppaResponseSpeed,wppaEasingDefault))),1<(a=jQuery(".wppa-cover-box-mcr-"+e)).length){var r=document.getElementById("wppa-albumlist-"+e).clientWidth,n=parseInt((r+wppaCoverSpacing)/(wppaMaxCoverWidth+wppaCoverSpacing))+1,s=n-1,i=parseInt((r+wppaCoverSpacing)/n-wppaCoverSpacing);if(wppaColWidth[e]!=r||wppaMCRWidth[e]!=i){wppaColWidth[e]=r,wppaMCRWidth[e]=i;for(var l=0;l<a.length;){switch(l%n){case 0:jQuery(a[l]).css({marginLeft:"0px",clear:"both",float:"left"});break;case s:jQuery(a[l]).css({marginLeft:"0px",clear:"none",float:"right"});break;default:jQuery(a[l]).css({marginLeft:wppaCoverSpacing,clear:"none",float:"left"})}l++}wppaCoverImageResponsive[e]||wppaAnimate(".wppa-asym-text-frame-mcr-"+e,{width:i-wppaTextFrameDelta},wppaResponseSpeed,wppaEasingDefault),jQuery(a[0]).width(),wppaAnimate(".wppa-cover-box-mcr-"+e,{width:i},wppaResponseSpeed,wppaEasingDefault)}}else 1==a.length&&(wppaCoverImageResponsive[e]||(wppaAnimate(".wppa-asym-text-frame-mcr-"+e,{width:o-wppaTextFrameDelta},wppaResponseSpeed,wppaEasingDefault),jQuery(".wppa-cover-box-mcr-"+e).css({marginLeft:"0px",float:"left"})));0<jQuery(".wppa-album-cover-grid-"+e).length&&(jQuery("#wppa-container-"+e).css("line-height","0"),(t=parseInt(o/wppaMaxCoverWidth+.9999))<1&&(t=1),jQuery(".wppa-album-cover-grid-"+e).css({width:100/t+"%"})),!wppaThumbSpaceAuto||(r=parseInt(jQuery(".thumbnail-frame-"+e).css("width")))&&(i=wppaMinThumbSpace,t=o-wppaThumbnailAreaDelta-7,i=Math.max(1,parseInt(t/(r+i))),i=parseInt((t-i*r)/(i+1)),jQuery(".thumbnail-frame-"+e).css({marginLeft:i})),jQuery(".thumbnail-frame-comalt-"+e).css("width",o-wppaThumbnailAreaDelta),jQuery(".wppa-com-alt-"+e).css("width",o-wppaThumbnailAreaDelta-wppaComAltSize-16);for(var u,c=1,w=jQuery("#wppa-mas-h-"+c+"-"+e).attr("data-height-perc");w;)u=w*(o-wppaThumbnailAreaDelta)/100,jQuery("#wppa-mas-h-"+c+"-"+e).css("height",u),c++,w=jQuery("#wppa-mas-h-"+c+"-"+e).attr("data-height-perc");return wppaSetMasHorFrameWidthsForIeAndChrome(e),document.getElementById("slide_frame-"+e)&&wppaFormatSlide(e),jQuery("#audio-slide-"+e).css("width",o-wppaBoxDelta-6),jQuery(".wppa-comment-textarea-"+e).css("width",.7*o),wppaFilmStripLength[e]=o-wppaFilmStripAreaDelta[e],jQuery("#filmwindow-"+e).css("width",wppaFilmStripLength[e]),_wppaAdjustFilmstrip(e,wppaEasingSlide),wppaIsMini[e]||void 0===_wppaSlides[e]||(wppaColWidth[e]<wppaMiniTreshold?(jQuery("#wppa-avg-rat-"+e).html(wppaAvgRat),jQuery("#wppa-my-rat-"+e).html(wppaMyRat),jQuery("#counter-"+e).html(_wppaCurIdx[e]+1+" / "+_wppaSlides[e].length)):(jQuery("#wppa-avg-rat-"+e).html(wppaAvgRating),jQuery("#wppa-my-rat-"+e).html(wppaMyRating),jQuery("#counter-"+e).html(wppaPhoto+" "+(_wppaCurIdx[e]+1)+" "+wppaOf+" "+_wppaSlides[e].length))),jQuery(".wppa-sphoto-"+e).css("width",o),jQuery(".wppa-simg-"+e).css("width",o-2*wppaSlideBorderWidth),jQuery(".wppa-simg-"+e).css("height",""),jQuery(".wppa-mphoto-"+e).css("width",o+10),jQuery(".wppa-mimg-"+e).css("width",o),jQuery(".wppa-mimg-"+e).css("height",""),jQuery(".smxpdf-"+e).css("height",.8*wppaWindowHeight()),0<wppaSearchBoxSelItems[e]&&(o/wppaSearchBoxSelItems[e]<125?jQuery(".wppa-searchsel-item-"+e).css("width","100%"):jQuery(".wppa-searchsel-item-"+e).css("width",100/wppaSearchBoxSelItems[e]+"%")),jQuery(".wppa-upload-album-"+e).css("maxWidth",.6*o),wppaSetRealCalendarHeights(e),!0}}function wppaSetRealCalendarHeights(p){var a,t,o,e=jQuery("#wppa-real-calendar-"+p).width();0<e&&(a=!0,t=e*wppaThumbAspect/7,jQuery(".wppa-real-calendar-day-"+p).css({height:t}),e=e/50+2,jQuery("#wppa-real-calendar-"+p).css({fontSize:e}),e=e/4,jQuery(".wppa-real-calendar-head-td-"+p).css({marginTop:e,marginBottom:e}),o=t/2,jQuery(".wppa-realcalimg-"+p).each(function(){var e;0==this.height?a=!1:(e=jQuery(this).attr("data-day"),thisb=o-(t-this.height)/2,jQuery(".wppa-real-calendar-day-content-"+e+"-"+p).css({bottom:thisb}))}),a||setTimeout(function(){wppaSetRealCalendarHeights(p)},100))}function wppaSetMasHorFrameWidthsForIeAndChrome(e){for(var p=jQuery(".wppa-mas-h-"+e),a=wppaMinThumbSpace,t=0;t<p.length;t++){var o=wppaGetChildI(p[t]);if(o){if("IMG"==o.nodeName&&!o.complete)return void setTimeout("wppaSetMasHorFrameWidthsForIeAndChrome( "+e+" )",400);o=o.naturalWidth/o.naturalHeight*o.height+a;jQuery(p[t]).css({width:o})}}}function wppaGetChildI(e){for(var p=e.childNodes,a=0;a<p.length;a++){var t=p[a];if(t.id&&"i-"==t.id.substr(0,2))return t;t=wppaGetChildI(t);if(t)return t}return!1}jQuery(document).ready(function(e){if(wppaAllowAjax&&jQuery.ajax&&(wppaCanAjaxRender=!0),void 0!==history.pushState){for(var p=1;p<=wppaMaxOccur;)wppaStartHtml[p]=jQuery("#wppa-container-"+p).html(),p++;wppaCanPushState=!0}});var wppaFotomotoLoaded=!1,wppaFotomotoToolbarIds=[];function fotomoto_loaded(){wppaFotomotoLoaded=!0}function wppaFotomotoToolbar(e,p){if(!(wppaColWidth[e]>=wppaFotomotoMinWidth))return jQuery("#wppa-fotomoto-container-"+e).css("display","none"),void jQuery("#wppa-fotomoto-checkout-"+e).css("display","none");jQuery("#wppa-fotomoto-container-"+e).css("display","inline"),jQuery("#wppa-fotomoto-checkout-"+e).css("display","inline"),wppaFotomoto&&document.getElementById("wppa-fotomoto-container-"+e)&&(wppaFotomotoLoaded?(FOTOMOTO.API.checkinImage(p),wppaFotomotoToolbarIds[e]=FOTOMOTO.API.showToolbar("wppa-fotomoto-container-"+e,p)):setTimeout("wppaFotomotoToolbar( "+e+',"'+p+'" )',200))}function wppaFotomotoHide(e){jQuery("#wppa-fotomoto-container-"+e).css("display","none"),jQuery("#wppa-fotomoto-checkout-"+e).css("display","none")}function wppaStringContainsForbiddenChars(e){for(var p=["?","&","#","/",'"',"'"],a=0;a<p.length;){if(-1!=e.indexOf(p[a]))return!0;a++}return!1}function wppaPushStateSlide(e,p,a){wppaIsMini[e]||wppaCanPushState&&wppaUpdateAddressLine&&""!=a&&jQuery(document).ready(function(){setTimeout(function(){try{history.pushState({page:wppaHis,occur:e,type:"slide",slide:p},"---",a),wppaQRUpdate(a),wppaConsoleLog("Pushed history stack","force")}catch(e){wppaConsoleLog("Slide history stack update failed")}},1e3)})}function wppaRepairScriptTags(e){if(void 0===e)return"";for(;-1!=e.indexOf("[script");)e=e.replace("[script","<script");for(;-1!=e.indexOf("[/script");)e=e.replace("[/script","</script");return e}function wppaRepairBrTags(e){return void 0===e?"":e.replace("[br /]","<br />").replace("[a","<a").replace(/"/g,'"').replace('"]','">').replace("[/a]","</a>").replace("[img","<img").replace("/]","/>")}function wppaTrimAlt(e){return void 0===e?"":13<e.length?e.substr(0,10)+"...":e}var wppaFbInitBusy=!1;function wppaFbInit(){wppaFbInitBusy||("undefined"!=typeof FB?(wppaFbInitBusy=!0,setTimeout("_wppaFbInit()",10)):setTimeout("wppaFbInit()",200))}function _wppaFbInit(){FB.init({status:!0,xfbml:!0}),wppaFbInitBusy=!1}function wppaInsertAtCursor(e,p){var a,t;document.selection?(e.focus(),sel=document.selection.createRange(),sel.text=p):e.selectionStart||"0"==e.selectionStart?(a=e.selectionStart,t=e.selectionEnd,e.value=e.value.substring(0,a)+p+e.value.substring(t,e.value.length),e.selectionStart=a+p.length,e.selectionEnd=a+p.length):e.value+=p}function wppaGeoInit(e,p,a){var t,o;document.getElementById("map-canvas-"+e)&&(p=new google.maps.LatLng(p,a),a={disableDefaultUI:!1,panControl:!1,zoomControl:!0,mapTypeControl:!0,scaleControl:!0,streetViewControl:!0,overviewMapControl:!0,zoom:wppaGeoZoom,center:p},t=new google.maps.Map(document.getElementById("map-canvas-"+e),a),o=new google.maps.Marker({position:p,map:t,title:""}),google.maps.event.addListener(t,"center_changed",function(){window.setTimeout(function(){t.panTo(o.getPosition())},1e3)}))}function wppaEncode(e){if(void 0!==e){for(var p=(t=(t=String(e).replace(/#/g,"||HASH||")).replace(/&/g,"||AMP||")).split("+"),a=0,t="";a<p.length;)t+=p[a],++a<p.length&&(t+="||PLUS||");return t}}function wppaUrlToId(e){var p=e.split("/wppa/");return 1==p.length&&(p=e.split("/upload/")),1==p.length?0:p=(p=(p=(p=(p=(p=(p=p[1]).split("."))[0].replace("/","")).replace("/","")).replace("/","")).replace("/","")).replace("/","")}function wppaSuperSearchSelect(e,p){jQuery("#wppa-ss-albumopt-"+e).css("display","none"),jQuery("#wppa-ss-albumcat-"+e).css("display","none"),jQuery("#wppa-ss-albumname-"+e).css("display","none"),jQuery("#wppa-ss-albumtext-"+e).css("display","none"),jQuery("#wppa-ss-photoopt-"+e).css("display","none"),jQuery("#wppa-ss-photoname-"+e).css("display","none"),jQuery("#wppa-ss-photoowner-"+e).css("display","none"),jQuery("#wppa-ss-phototag-"+e).css("display","none"),jQuery("#wppa-ss-phototext-"+e).css("display","none"),jQuery("#wppa-ss-photoexif-"+e).css("display","none"),jQuery("#wppa-ss-photoiptc-"+e).css("display","none"),jQuery("#wppa-ss-exifopts-"+e).css("display","none"),jQuery("#wppa-ss-iptcopts-"+e).css("display","none"),jQuery("#wppa-ss-spinner-"+e).css("display","none"),jQuery("#wppa-ss-button-"+e).css("display","none");var a=jQuery("#wppa-ss-pa-"+e).val(),t="",o="",r="";switch(a){case"a":switch(jQuery("#wppa-ss-albumopt-"+e).css("display",""),t=jQuery("#wppa-ss-albumopt-"+e).val()){case"c":jQuery("#wppa-ss-albumcat-"+e).css("display","");var n=jQuery(".wppa-ss-albumcat-"+e),r="";for(s=0;s<n.length;s++)jQuery(n[s]).prop("selected")&&(r+="."+jQuery(n[s]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"n":jQuery("#wppa-ss-albumname-"+e).css("display",""),null!=(r=jQuery("#wppa-ss-albumname-"+e).val())&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"t":jQuery("#wppa-ss-albumtext-"+e).css("display","");n=jQuery(".wppa-ss-albumtext-"+e);for(r="",s=0;s<n.length;s++)jQuery(n[s]).prop("selected")&&(r+="."+jQuery(n[s]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+e).css("display","")}break;case"p":switch(jQuery("#wppa-ss-photoopt-"+e).css("display",""),t=jQuery("#wppa-ss-photoopt-"+e).val()){case"n":jQuery("#wppa-ss-photoname-"+e).css("display",""),null!=(r=jQuery("#wppa-ss-photoname-"+e).val())&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"o":jQuery("#wppa-ss-photoowner-"+e).css("display",""),null!=(r=jQuery("#wppa-ss-photoowner-"+e).val())&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"g":jQuery("#wppa-ss-phototag-"+e).css("display","");n=jQuery(".wppa-ss-phototag-"+e);for(r="",s=0;s<n.length;s++)jQuery(n[s]).prop("selected")&&(r+="."+jQuery(n[s]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"t":jQuery("#wppa-ss-phototext-"+e).css("display","");var s,n=jQuery(".wppa-ss-phototext-"+e);for(r="",s=0;s<n.length;s++)jQuery(n[s]).prop("selected")&&(r+="."+jQuery(n[s]).val());""!=(r=r.substr(1))&&jQuery("#wppa-ss-button-"+e).css("display","");break;case"i":jQuery("#wppa-ss-photoiptc-"+e).css("display",""),(o=jQuery("#wppa-ss-photoiptc-"+e).val())&&(2<o.length&&(o=o.replace("#","H")),""!=o&&(jQuery("#wppa-ss-iptcopts-"+e).css("display",""),wppaLastIptc!=o?(wppaAjaxGetSsIptcList(e,o,"wppa-ss-iptcopts-"+e),wppaLastIptc=o):null!=(r=jQuery("#wppa-ss-iptcopts-"+e).val())&&""!=r&&jQuery("#wppa-ss-button-"+e).css("display","")));break;case"e":jQuery("#wppa-ss-photoexif-"+e).css("display",""),(o=jQuery("#wppa-ss-photoexif-"+e).val())&&(2<o.length&&(o=o.replace("#","H")),""!=o&&(jQuery("#wppa-ss-exifopts-"+e).css("display",""),wppaLastExif!=o?(wppaAjaxGetSsExifList(e,o,"wppa-ss-exifopts-"+e),wppaLastExif=o):null!=(r=jQuery("#wppa-ss-exifopts-"+e).val())&&""!=r&&jQuery("#wppa-ss-button-"+e).css("display","")))}}p&&(-1==(p=jQuery("#wppa-ss-pageurl-"+e).val()).indexOf("?")?p+="?":p+="&",p+="occur=1&wppa-supersearch="+a+","+t+","+o+","+r,document.location.href=p)}function wppaSetIptcExifSize(e,p){e=jQuery(e).length;6<e&&(e=6),e<2&&(e=2),jQuery(p).attr("size",e)}function wppaUpdateSearchRoot(e,p){for(var a=jQuery(".wppa-search-root"),t=0;t<a.length;)jQuery(a[t]).html(e),t++;for(a=jQuery(".wppa-rootbox"),t=0;t<a.length;)p?(jQuery(a[t]).prop("checked",!1),jQuery(a[t]).prop("disabled",!1)):(jQuery(a[t]).prop("checked",!0),jQuery(a[t]).prop("disabled",!0)),t++;for(a=jQuery(".wppa-search-root-id"),t=0;t<a.length;)jQuery(a[t]).val(p),t++}function wppaSubboxChange(e){jQuery(e).prop("checked")&&jQuery(".wppa-rootbox").each(function(e){jQuery(this).prop("checked",!0)})}function wppaClearSubsearch(){for(var e=jQuery(".wppa-display-searchstring"),p=0;p<e.length;)jQuery(e[p]).html(""),p++;for(e=jQuery(".wppa-search-sub-box"),p=0;p<e.length;)jQuery(e[p]).prop("disabled",!0),p++}function wppaEnableSubsearch(){for(var e=jQuery(".wppa-search-sub-box"),p=0;p<e.length;)jQuery(e[p]).removeAttr("disabled"),p++}function wppaDisplaySelectedFiles(e){for(var p=jQuery("#"+e),a=0,t="";a<p[0].files.length;)t+=p[0].files[a].name+" ",a++;jQuery("#"+e+"-display").val(t)}function wppaIsEmpty(e){return null==e||(void 0===e||(""==e||(0==e||(0==e||void 0))))}function wppaGetUploadOptions(yalb,mocc,where,onComplete){var options={beforeSend:function(){jQuery("#progress-"+yalb+"-"+mocc).show(),jQuery("#bar-"+yalb+"-"+mocc).width("0%"),jQuery("#message-"+yalb+"-"+mocc).html(""),jQuery("#percent-"+yalb+"-"+mocc).html("")},uploadProgress:function(e,p,a,t){jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#7F7"),jQuery("#bar-"+yalb+"-"+mocc).width(t+"%"),t<95?jQuery("#percent-"+yalb+"-"+mocc).html(t+"%"):jQuery("#percent-"+yalb+"-"+mocc).html(wppaProcessing)},success:function(){jQuery("#bar-"+yalb+"-"+mocc).width("100%"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaDone),jQuery(".wppa-upload-button").val(wppaUploadButtonText)},complete:function(response){-1!=response.responseText.indexOf(wppaUploadFailed)?(jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#F77"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaUploadFailed),jQuery("#message-"+yalb+"-"+mocc).html('<span style="font-size: 10px;" >'+response.responseText+"</span>")):(jQuery("#message-"+yalb+"-"+mocc).html('<span style="font-size: 10px;" >'+response.responseText+"</span>"),"thumb"!=where&&"cover"!=where||eval(onComplete))},error:function(){jQuery("#message-"+yalb+"-"+mocc).html('<span style="color: red;" >'+wppaServerError+"</span>"),jQuery("#bar-"+yalb+"-"+mocc).css("backgroundColor","#F77"),jQuery("#percent-"+yalb+"-"+mocc).html(wppaUploadFailed)}};return options}function wppaInitMasonryPlus(){jQuery(".grid-masonryplus").each(function(){var e=jQuery(this).attr("id").substr(5),p=wppaGetContainerWidth(e)-wppaThumbnailAreaDelta,p=p/parseInt((p+wppaTfMargin)/(.75*wppaThumbSize+wppaTfMargin));jQuery(".grid-item").css("visibility","visible"),jQuery(".grid-item-"+e).css("width",p+"px"),jQuery("#grid-"+e).masonry({itemSelector:".grid-item-"+e,columnWidth:p,fitWidth:!0})})}function wppaFsChange(){wppaFsShow(),wppaOvlShowSame()}function wppaGlobalFS(){if(wppaIsIpad)return!1;if(wppaIsSafari)return!1;var e=parseInt(wppaGlobalFsIconSize/4),p=e;!wppaIsMobile&&0<jQuery("#wpadminbar").length&&(e+=jQuery("#wpadminbar").height()),jQuery("body").append('<div id="wppa-fulls-btn-1" class="wppa-fulls-btn" style="position:fixed;top:'+e+"px;right:"+p+'px;display:none;" title="Enter fullscreen" onclick="wppaFsOn()" >'+wppaSvgHtml("Full-Screen",wppaGlobalFsIconSize+"px",!0,!1,"0","0","0","0")+"</div>"),jQuery("body").append('<div id="wppa-exit-fulls-btn-1" class="wppa-exit-fulls-btn" style="position:fixed;top:'+e+"px;right:"+p+'px;display:none;" title="Leave fullscreen" onclick="wppaFsOff()" >'+wppaSvgHtml("Exit-Full-Screen",wppaGlobalFsIconSize+"px",!0,!1,"0","0","0","0")+"</div>"),wppaFsShow()}function wppaFsOn(){var e=document.documentElement;e.requestFullscreen?e.requestFullscreen():e.mozRequestFullScreen?e.mozRequestFullScreen():e.webkitRequestFullScreen&&e.webkitRequestFullScreen()}function wppaFsOff(){document.exitFullscreen?document.exitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():document.webkitCancelFullScreen&&document.webkitCancelFullScreen()}function wppaIsFs(){return!wppaIsIpad&&(!wppaIsSafari&&null!==document.fullscreenElement)}function wppaFsShow(){wppaIsFs()?(jQuery(".wppa-fulls-btn").hide(),jQuery(".wppa-exit-fulls-btn").show()):(jQuery(".wppa-fulls-btn").show(),jQuery(".wppa-exit-fulls-btn").hide())}jQuery(document).ready(function(){jQuery(".wppa-ss-button").each(function(){mocc=jQuery(this).attr("data-mocc"),wppaSuperSearchSelect(mocc)})}),jQuery(document).ready(function(){"global"==wppaFsPolicy&&wppaGlobalFS(),jQuery(window).on("DOMContentLoaded load",wppaFsShow),jQuery(document).on("fullscreenchange mozfullscreenchange webkitfullscreenchange msfullscreenchange",wppaFsChange)});
|
5 |
// wppa-slideshow
|
6 |
+
var wppaJsSlideshowVersion="8.2.01.001";function wppaStoreSlideInfo(p,a,e,t,i,w,r,n,o,l,s,d,u,_,m,c,h,y,S,g,x,f,I,j,Q,b,v,T,N,C,k,R,F){o=wppaRepairScriptTags(o),_wppaSlides[p]&&"0"!=a||(_wppaSlides[p]=[],_wppaNames[p]=[],_wppaFilmThumbTitles[p]=[],_wppaFullNames[p]=[],_wppaDsc[p]=[],_wppaOgDsc[p]=[],_wppaCurIdx[p]=-1,_wppaNxtIdx[p]=0,"random"==S?_wppaTimeOut[p]="random":0<parseInt(S)?_wppaTimeOut[p]=parseInt(S):_wppaTimeOut[p]=wppaSlideShowTimeOut,_wppaSSRuns[p]=!1,_wppaTP[p]=-2,_wppaFg[p]=0,_wppaIsBusy[p]=!1,_wppaFirst[p]=!0,_wppaId[p]=[],_wppaRealId[p]=[],_wppaAvg[p]=[],_wppaDisc[p]=[],_wppaMyr[p]=[],_wppaVRU[p]=[],_wppaLinkUrl[p]=[],_wppaLinkTitle[p]=[],_wppaLinkTarget[p]=[],_wppaCommentHtml[p]=[],_wppaIptcHtml[p]=[],_wppaExifHtml[p]=[],_wppaUrl[p]=[],_wppaSkipRated[p]=!1,_wppaLbTitle[p]=[],_wppaDidGoto[p]=!1,wppaSlidePause[p]=!1,_wppaShareUrl[p]=[],_wppaShareHtml[p]=[],_wppaFilmNoMove[p]=!1,_wppaHiresUrl[p]=[],_wppaIsVideo[p]=[],_wppaVideoHtml[p]=[],_wppaAudioHtml[p]=[],_wppaVideoNatWidth[p]=[],_wppaVideoNatHeight[p]=[],wppaVideoPlaying[p]=!1,wppaAudioPlaying[p]=!1,_wppaWaitTexts[p]=[],_wppaImageAlt[p]=[],_wppaFilename[p]=[]),S="default",""!=c?S="pointer":""!=wppaLightBox[p]&&(S="url( "+wppaImageDirectory+wppaMagnifierCursor+" ),pointer"),_wppaIsVideo[p][a]=""!=T,_wppaIsVideo[p][a]?(_wppaSlides[p][a]=' alt="'+k+'" class="theimg theimg-'+p+' big" ',wppaSlideVideoStart&&""==wppaLightBox[p]&&(_wppaSlides[p][a]+=" autoplay "),0<R.length&&(_wppaSlides[p][a]+=' poster="'+R+'" ')):_wppaSlides[p][a]=' src="'+e+'" alt="'+k+'" class="theimg theimg-'+p+' big stereo" ',wppaSlideSwipe&&(_wppaSlides[p][a]+=' ontouchstart="wppaTouchStart( event, this.id, '+p+' );" ontouchend="wppaTouchEnd( event );" ontouchmove="wppaTouchMove( event );" ontouchcancel="wppaTouchCancel( event );" '),wppaAutoColumnWidth[p]||(_wppaSlides[p][a]+='width="'+i+'" height="'+w+'" '),_wppaIsVideo[p][a]?(R="wppa"==wppaLightBox[p]?"":"controls",_wppaSlides[p][a]+='style="'+t+"; cursor:"+S+'; display:none;" '+R+">"+T+"</video>"):_wppaSlides[p][a]+='style="'+t+"; cursor:"+S+'; display:none; vertical-align:middle;">',_wppaFullNames[p][a]='<span class="sdf-'+p+'" >'+wppaRepairBrTags(r)+"</span>",_wppaNames[p][a]='<span class="sdn-'+p+'" >'+n+"</span>",_wppaFilmThumbTitles[p][a]=n,_wppaDsc[p][a]=o,_wppaOgDsc[p][a]=b,_wppaId[p][a]=l,_wppaRealId[p][a]=s,_wppaAvg[p][a]=d,_wppaDisc[p][a]=u,_wppaMyr[p][a]=_,_wppaVRU[p][a]=m,_wppaLinkUrl[p][a]=c,_wppaLinkTitle[p][a]=h,""!=y?_wppaLinkTarget[p][a]=y:wppaSlideBlank[p]?_wppaLinkTarget[p][a]="_blank":_wppaLinkTarget[p][a]="_self",_wppaCommentHtml[p][a]=g,_wppaIptcHtml[p][a]=x,_wppaExifHtml[p][a]=f,_wppaUrl[p][a]=e,_wppaLbTitle[p][a]=wppaRepairScriptTags(I),_wppaShareUrl[p][a]=j,_wppaShareHtml[p][a]=wppaRepairScriptTags(Q),_wppaHiresUrl[p][a]=v,_wppaVideoHtml[p][a]=T,_wppaAudioHtml[p][a]=N,_wppaVideoNatWidth[p][a]=i,_wppaVideoNatHeight[p][a]=w,_wppaWaitTexts[p][a]=C,_wppaImageAlt[p][a]=k,_wppaFilename[p][a]=F}function wppaSpeed(p,a){_wppaSSRuns[p]&&_wppaSpeed(p,a)}function wppaStopShow(p){_wppaSSRuns[p]&&_wppaStop(p)}function wppaStartStop(p,a){wppaSlideInitRunning[p]&&("start"==wppaSlideInitRunning[p]?a=-1:"stopprev"==wppaSlideInitRunning[p]?a=_wppaSlides[p].length-1:"stopnext"==wppaSlideInitRunning[p]&&(a=0),wppaSlideInitRunning[p]=""),_wppaIsBusy[p]&&(_wppaTP[p]=a),_wppaSSRuns[p]?_wppaStop(p):_wppaStart(p,a),wppaIsMobile&&(jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(10,1).fadeTo(3e3,0),jQuery(".ubb-"+p).stop().fadeTo(10,1).fadeTo(3e3,0))}function wppaBbb(p,a,e){_wppaSSRuns[p]||_wppaBbb(p,a,e)}function wppaUbb(p,a,e){_wppaUbb(p,a,e)}function wppaRateIt(p,a){_wppaRateIt(p,a)}function wppaOvlRateIt(p,a,e,t){_wppaOvlRateIt(p,a,e,t)}function wppaPrev(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaPrev(p)}function wppaPrevN(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaPrevN(p,a)}function wppaFirst(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,0)}function wppaNext(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaNext(p)}function wppaNextN(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaNextN(p,a)}function wppaLast(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,_wppaSlides[p].length-1)}function wppaFollowMe(p,a){_wppaSSRuns[p]||_wppaFollowMe(p,a)}function wppaLeaveMe(p,a){_wppaSSRuns[p]||_wppaLeaveMe(p,a)}function wppaGoto(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,a)}function wppaGotoFilmNoMove(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||(_wppaFilmNoMove[p]=!0,_wppaGoto(p,a))}function wppaGotoKeepState(p,a){_wppaNxtIdx[p]!=a&&(_wppaDidGoto[p]=!0,_wppaGotoKeepState(p,a))}function _wppaGotoKeepState(p,a){(_wppaSSRuns[p]?_wppaGotoRunning:_wppaGoto)(p,a)}function wppaGotoRunning(p,a){_wppaDidGoto[p]=!0,_wppaGotoRunning(p,a)}function wppaValidateComment(p){return _wppaValidateComment(p)}function _wppaNextSlide(p,a){var e=!document.getElementById("slide_frame-"+p);if(_wppaStopping[p])_wppaStopping[p]=0;else{if(!e&&!wppaIsSlidshowVisible(p))return wppaFilmInit[p]=!1,void setTimeout(function(){_wppaNextSlide(p,a)},400);if(_wppaLastIdx[p]=_wppaCurIdx[p],!document.getElementById("slide_frame-"+p)&&document.getElementById("filmwindow-"+p)&&wppaFilmonlyContinuous)return _wppaSSRuns[p]?(_wppaCurIdx[p]++,_wppaCurIdx[p]==_wppaSlides[p].length&&(_wppaCurIdx[p]=0),_wppaAdjustFilmstrip(p,"linear"),_wppaNxtIdx[p]=_wppaCurIdx[p],void setTimeout("_wppaNextSlide( "+p+", '"+a+"' )",wppaAnimationSpeed)):(_wppaCurIdx[p]=_wppaNxtIdx[p],wppaFilmInit[p]=!1,void _wppaAdjustFilmstrip(p,"linear"));if(document.getElementById("slide_frame-"+p)||document.getElementById("filmwindow-"+p)){var t=_wppaFg[p],e=1-t;if((wppaVideoPlaying[p]||wppaAudioPlaying[p])&&_wppaSSRuns[p])setTimeout("_wppaNextSlide( "+p+", '"+a+"' )",500);else{if(wppaStopVideo(p),wppaStopAudio(p),"auto"==a){if(wppaSlidePause[p])return jQuery("#theimg"+t+"-"+p).attr("title",wppaSlidePause[p]),jQuery("#slide_frame-"+p).attr("title",wppaSlidePause[p]),void setTimeout("_wppaNextSlide( "+p+', "auto" )',250)}else jQuery("#slide_frame-"+p).removeAttr("title");if((_wppaSSRuns[p]||"auto"!=a)&&_wppaSlides[p]&&(!(_wppaSlides[p].length<2)||_wppaFirst[p])){if(_wppaSSRuns[p]||"reset"!=a||(_wppaSSRuns[p]=!0,__wppaOverruleRun=!1),_wppaVoteInProgress=!1,_wppaIsBusy[p]=!0,_wppaSSRuns[p]&&_wppaShowMetaData(p,"hide"),_wppaSSRuns[p]&&(_wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length&&(_wppaNxtIdx[p]=0)),jQuery("#geodiv-"+p+"-"+_wppaId[p][_wppaCurIdx[p]]).css({display:"none"}),jQuery("#geodiv-"+p+"-"+_wppaId[p][_wppaNxtIdx[p]]).css({display:""}),"undefined"!=typeof _wppaLat&&_wppaLat[p]?(n=_wppaRealId[p],_wppaLat[p][n[_wppaNxtIdx[p]]]?(jQuery("#map-canvas-"+p).css("display",""),wppaGeoInit(p,_wppaLat[p][n[_wppaNxtIdx[p]]],_wppaLon[p][n[_wppaNxtIdx[p]]])):jQuery("#map-canvas-"+p).css("display","none")):jQuery("#map-canvas-"+p).css("display","none"),jQuery("[id^=wppa-numbar-"+p+"-]").css({backgroundColor:wppaBGcolorNumbar,borderColor:wppaBcolorNumbar,fontFamily:wppaFontFamilyNumbar,fontSize:wppaFontSizeNumbar,color:wppaFontColorNumbar,fontWeight:wppaFontWeightNumbar}),jQuery("#wppa-numbar-"+p+"-"+_wppaNxtIdx[p]).css({backgroundColor:wppaBGcolorNumbarActive,borderColor:wppaBcolorNumbarActive,fontFamily:wppaFontFamilyNumbarActive,fontSize:wppaFontSizeNumbarActive,color:wppaFontColorNumbarActive,fontWeight:wppaFontWeightNumbarActive}),_wppaSlides[p].length>wppaNumbarMax){var i,w,r=_wppaSlides[p].length-1,n=_wppaNxtIdx[p],o=(wppaNumbarMax-1)/2;n<o?(i=0,w=wppaNumbarMax-1-1,jQuery("#wppa-nbar-"+p+"-lodots").css({display:"none"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})):r-o<n?(i=(w=r)-wppaNumbarMax+1+1,jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"none"})):(w=n+o+.5-1,(i=n-o+1)<2?(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"none"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})):r-1<w?(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"none"})):(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})));for(var l=0;l<_wppaSlides[p].length;)0!=l&&l!=r&&(l<i||w<l)?jQuery("#wppa-numbar-"+p+"-"+l).css({display:"none"}):jQuery("#wppa-numbar-"+p+"-"+l).css({display:"block"}),l++}_wppaFirst[p]?(-1!=_wppaCurIdx[p]&&wppaMakeTheSlideHtml(p,"0",_wppaCurIdx[p]),wppaMakeTheSlideHtml(p,"1",_wppaNxtIdx[p]),jQuery("#imagedesc-"+p).html(_wppaDsc[p][_wppaCurIdx[p]]),jQuery("#imagetitle-"+p).html(wppaMakeNameHtml(p)),"void"==_wppaCommentHtml[p][_wppaCurIdx[p]]?(jQuery("#wppa-comments-"+p).hide(),jQuery("#wppa-comments-"+p).html("")):(jQuery("#wppa-comments-"+p).show(),jQuery("#wppa-comments-"+p).html(_wppaCommentHtml[p][_wppaCurIdx[p]])),jQuery("#iptc-"+p).html(_wppaIptcHtml[p][_wppaCurIdx[p]]),jQuery("#exif-"+p).html(_wppaExifHtml[p][_wppaCurIdx[p]]),"icons"==wppaSlideshowNavigationType?(o=wppaIconSize(p,"1.5em",!1),jQuery("#prev-arrow-"+p).html(wppaSvgHtml("Prev-Button",o,!1,!0)),jQuery("#next-arrow-"+p).html(wppaSvgHtml("Next-Button",o,!1,!0))):wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?(jQuery("#prev-arrow-"+p).html("« "+wppaPrevP),jQuery("#next-arrow-"+p).html(wppaNextP+" »")):(jQuery("#prev-arrow-"+p).html("« "+wppaPreviousPhoto),jQuery("#next-arrow-"+p).html(wppaNextPhoto+" »")),wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRat),jQuery("#wppa-my-rat-"+p).html(wppaMyRat)):(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRating),jQuery("#wppa-my-rat-"+p).html(wppaMyRating))):wppaMakeTheSlideHtml(p,e,_wppaNxtIdx[p]),_wppaLoadSpinner(p),_wppaFirst[p]=!1,_wppaCheckRewind(p),setTimeout("_wppaNextSlide_2( "+p+" )",10)}}}}}function _wppaNextSlide_2(p){var a=_wppaFg[p],e=1-a,t=document.getElementById("theimg"+e+"-"+p);!t||1!=t.nodeType||"IMG"!=t.nodeName||t.complete?(wppaUpdateLightboxes(),_wppaUnloadSpinner(p),-1!=_wppaSSRuns[p]&&(_wppaToTheSame||_wppaShowMetaData(p,"hide")),_wppaFg[p]=1-_wppaFg[p],_wppaFg[p],setTimeout("_wppaNextSlide_3( "+p+" )",10)):setTimeout("_wppaNextSlide_2( "+p+" )",200)}function _wppaNextSlide_3(p){var a=_wppaFg[p],e=1-a,t=_wppaCurIdx[p],i=_wppaNxtIdx[p],w="#theslide"+e+"-"+p,r="#theslide"+a+"-"+p,n="#theimg"+e+"-"+p,o="#theimg"+a+"-"+p,l=parseInt(jQuery(w).css("width")),s=t==i+1?"right":t==i-1?"left":t==i?"none":"nil";switch(t==_wppaSlides[p].length-1&&0==i&&wppaSlideWrap[p]&&(s="left"),0==t&&i==_wppaSlides[p].length-1&&wppaSlideWrap[p]&&(s="right"),"nil"==s&&(s=t<i?"left":"right"),jQuery(w).css({marginLeft:0,width:l}),jQuery(r).css({marginLeft:0,width:l}),wppaFormatSlide(p),wppaAnimationType){case"fadeafter":wppaFadeOut(n,wppaAnimationSpeed),setTimeout(wppaFadeIn(o,wppaAnimationSpeed,_wppaNextSlide_4(p)),wppaAnimationSpeed);break;case"swipe":switch(s){case"left":wppaAnimate(w,{marginLeft:-l},wppaAnimationSpeed,wppaEasingSlide),jQuery(r).css({marginLeft:l}),wppaFadeIn(o,10),wppaAnimate(r,{marginLeft:0},wppaAnimationSpeed,wppaEasingSlide,_wppaNextSlide_4(p));break;case"right":wppaAnimate(w,{marginLeft:l},wppaAnimationSpeed,wppaEasingSlide),jQuery(r).css({marginLeft:-l}),wppaFadeIn(o,10),wppaAnimate(r,{marginLeft:0},wppaAnimationSpeed,wppaEasingSlide,_wppaNextSlide_4(p));break;case"none":wppaFadeIn(o,10),setTimeout("_wppaNextSlide_4( "+p+" )",10)}break;default:wppaFadeOut(n,wppaAnimationSpeed),wppaFadeIn(o,wppaAnimationSpeed,_wppaNextSlide_4(p))}}function _wppaNextSlide_4(p){var a=_wppaFg[p],e="#theslide"+a+"-"+p;jQuery("#theslide"+(1-a)+"-"+p).css({zIndex:80}),jQuery(e).css({zIndex:81}),_wppaCurIdx[p]=_wppaNxtIdx[p],wppaFormatSlide(p),wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?jQuery("#counter-"+p).html(_wppaCurIdx[p]+1+" / "+_wppaSlides[p].length):jQuery("#counter-"+p).html(wppaPhoto+" "+(_wppaCurIdx[p]+1)+" "+wppaOf+" "+_wppaSlides[p].length),jQuery("#bc-pname-modal-"+p).html(_wppaNames[p][_wppaCurIdx[p]]),jQuery("#bc-pname-"+p).html(_wppaNames[p][_wppaCurIdx[p]]),_wppaAdjustFilmstrip(p,wppaEasingSlide),_wppaSetRatingDisplay(p),setTimeout("_wppaNextSlide_5( "+p+" )",_wppaTextDelay)}function _wppaNextSlide_5(p){var a,e,t;if(_wppaToTheSame||(a=_wppaDsc[p][_wppaCurIdx[p]],jQuery("#imagedesc-"+p).html(a),wppaHideWhenEmpty&&(""==(a=_wppaDsc[p][_wppaCurIdx[p]])||" "==a?jQuery("#descbox-"+p).css("display","none"):jQuery("#descbox-"+p).css("display","")),jQuery("#imagetitle-"+p).html(wppaMakeNameHtml(p)),"void"==_wppaCommentHtml[p][_wppaCurIdx[p]]?(jQuery("#wppa-comments-"+p).hide(),jQuery("#wppa-comments-"+p).html("")):(jQuery("#wppa-comments-"+p).show(),jQuery("#wppa-comments-"+p).html(_wppaCommentHtml[p][_wppaCurIdx[p]])),jQuery("#iptc-"+p).html(_wppaIptcHtml[p][_wppaCurIdx[p]]),jQuery("#exif-"+p).html(_wppaExifHtml[p][_wppaCurIdx[p]]),jQuery("#wppa-share-"+p).html(_wppaShareHtml[p][_wppaCurIdx[p]])),_wppaToTheSame=!1,wppaThumbPageSize?wppaThumbPage[p]=parseInt(((0|wppaSlideOffset[p])+_wppaCurIdx[p])/wppaThumbPageSize)+1:wppaThumbPage[p]=1,_wppaSSRuns[p]&&!wppaSlideWrap[p]&&_wppaCurIdx[p]+1==_wppaSlides[p].length)return _wppaIsBusy[p]=!1,void _wppaStop(p);if(_wppaShowMetaData(p,"show"),-2!=_wppaTP[p]){var i=_wppaTP[p];return _wppaTP[p]=-2,_wppaDidGoto[p]=!1,_wppaIsBusy[p]=!1,wppaIsMini[p]||_bumpViewCount(_wppaId[p][_wppaCurIdx[p]]),_wppaDoAutocol(p,"next_5"),void wppaStartStop(p,i)}wppaUpdateLightboxes(),wppaIsMini[p]||(i=_wppaShareUrl[p][_wppaCurIdx[p]],"undefined"!=typeof wppaQRUpdate&&wppaQRUpdate(_wppaShareUrl[p][_wppaCurIdx[p]]),1<_wppaSlides[p].length&&wppaPushStateSlide(p,_wppaCurIdx[p],i)),_wppaSSRuns[p]?_wppaCurIdx[p]+1==_wppaSlides[p].length?(t=jQuery("#wppa-next-pagelink-"+p),e=jQuery("#wppa-first-pagelink-"+p),0<t.length&&"hidden"!=jQuery(t).css("visibility")?setTimeout(function(){wppaSlideInitRunning[p]="start",jQuery("#wppa-next-pagelink-"+p).trigger("click")},wppaGetSlideshowTimeout(p)):0<e.length?setTimeout(function(){jQuery(e).trigger("click")},wppaGetSlideshowTimeout(p)):setTimeout("_wppaNextSlide( "+p+', "auto" )',wppaGetSlideshowTimeout(p))):setTimeout("_wppaNextSlide( "+p+', "auto" )',wppaGetSlideshowTimeout(p)):_wppaStopping[p]=!1,jQuery(document).trigger("glossaryTooltipReady"),_wppaDidGoto[p]=!1,_wppaIsBusy[p]=!1,wppaIsMini[p]||_bumpViewCount(_wppaId[p][_wppaCurIdx[p]]),wppaStopAudio(p),!wppaSlideAudioStart||0<(t=jQuery(".wppa-audio-"+_wppaId[p][_wppaCurIdx[p]]+"-"+p)).length&&((t=t[t.length-1])&&(wppaAudioPlaying[p]||t.play())),wppaProtect()}function wppaFormatSlide(p){var a="theimg"+_wppaFg[p]+"-"+p,e=document.getElementById(a);if(e){var t="theslide"+_wppaFg[p]+"-"+p,i="slide_frame-"+p,w=jQuery("#wppa-container-"+p).width();wppaColWidth[p]=w;var r=jQuery(".wppa-audio-"+p),n=e.naturalWidth;void 0===n&&(n=parseInt(e.style.maxWidth));var o=e.naturalHeight;void 0===o&&(o=parseInt(e.style.maxHeight));var l=wppaAspectRatio[p],s=wppaFullSize[p],d=wppaFullFrameDelta[p],u=wppaPortraitOnly[p],_=wppaFullValign[p];void 0===_&&(_="none");var m=wppaFullHalign[p];void 0===m&&(m="none");var c,h,y,S,g,x,f,e=wppaStretch;if(u)j=w-d,y=h=0,x=S=w,f=g=(c=parseInt(j*o/n))+d,jQuery("#"+i).css({width:x,height:f}),jQuery("#"+t).css({width:S,height:g}),jQuery("#"+a).css({width:j,height:c});else{if(s<(x=w)&&(x=s),S=x,g=f=parseInt(x*l),e||x-d<=n||f-d<=o?l<(o+d)/(n+d)?(c=f-d,j=parseInt(c*n/o)):(j=x-d,c=parseInt(j*o/n)):(j=n,c=o),"default"!=_&&"none"!=_){switch(_){case"top":y=0;break;case"center":y=parseInt((f-(c+d))/2);break;case"bottom":y=f-(c+d);break;case"fit":y=0,g=f=c+d}jQuery("#"+a).css({marginTop:y,marginBottom:0})}if(jQuery("#"+i).css({width:x,height:f}),jQuery("#"+t).css({width:S,height:g}),jQuery("#"+a).css({width:j,height:c}),"default"!=_&&"none"!=_&&"none"!=m&&"default"!=m){switch(m){case"left":h=0;break;case"center":h=parseInt((w-x)/2);break;case"right":h=w-x}h<0&&(h=0),jQuery("#"+a).css({marginLeft:"auto",marginRight:"auto"}),jQuery("#"+i).css({marginLeft:h})}var i=jQuery(r).height(),I=(x-j)/2;i&&0<i&&(wppaAudioHeight=i,jQuery(r).css({height:wppaAudioHeight,width:j,left:I}))}var j=parseInt(x/3),I=2*j,r=0<r.length?f-wppaAudioHeight-wppaSlideBorderWidth-y:f;jQuery("#bbb-"+p+"-l").css({height:r,width:j,left:0}),jQuery("#bbb-"+p+"-r").css({height:r,width:j,left:I})}}function wppaMakeNameHtml(p){var a,e,t="";if(_wppaCurIdx[p]<0)return"";if("void"==_wppaFullNames[p][_wppaCurIdx[p]])return jQuery("#namebox-"+p).hide(),"";if(jQuery("#namebox-"+p).show(),wppaIsMini[p]||_wppaIsVideo[p][_wppaCurIdx[p]])t=_wppaFullNames[p][_wppaCurIdx[p]];else switch(wppaArtMonkyLink){case"file":case"zip":t=wppaArtMonkeyButton?_wppaFullNames[p][_wppaCurIdx[p]]?(a=-1!=_wppaFullNames[p][_wppaCurIdx[p]].indexOf("plus.png"),e=_wppaFullNames[p][_wppaCurIdx[p]].replace(/(<([^>]+)>)/gi,""),e=a?e.replace(" )"," +)"):e.replace(" )",")"),'<input type="button" title="Download" style="cursor:pointer;margin-bottom:0px;max-width:'+(wppaGetContainerWidth(p)-24)+'px;" class="wppa-download-button" onclick="'+(wppaIsSafari&&"file"==wppaArtMonkyLink?"wppaWindowReference = window.open();":"")+"wppaAjaxMakeOrigName( "+p+", '"+_wppaId[p][_wppaCurIdx[p]]+'\' );" value="'+wppaDownLoad+": "+e+'" />'):"":wppaArtmonkeyFileNotSource?'<a href="'+_wppaUrl[p][_wppaCurIdx[p]]+'" title="Download" style="cursor:pointer;" download="'+_wppaFilename[p][_wppaCurIdx[p]]+'" >'+wppaDownLoad+": "+_wppaFullNames[p][_wppaCurIdx[p]]+"</a>":'<a title="Download" style="cursor:pointer;" onclick="'+(wppaIsSafari&&"file"==wppaArtMonkyLink?"wppaWindowReference = window.open();":"")+"wppaAjaxMakeOrigName( "+p+", '"+_wppaId[p][_wppaCurIdx[p]]+"' );\" >"+wppaDownLoad+": "+_wppaFullNames[p][_wppaCurIdx[p]]+"</a>";break;case"none":case"new":t=_wppaFullNames[p][_wppaCurIdx[p]];break;default:t=""}return t=wppaRepairBrTags(t)}function wppaMakeTheSlideHtml(p,a,e){var t,i,w=_wppaIsVideo[p][e]?"video":"img",r="title";"wppa"==wppaLightBox[p]&&(r="data-lbtitle");var n,o,l=""==wppaLightBox[p]?' onpause="wppaVideoPlaying['+p+'] = false;" onplay="wppaVideoPlaying['+p+'] = true;"':"";if(""!=_wppaLinkUrl[p][e])t=wppaSlideToFullpopup?'<a onclick="wppaStopAudio();wppaStopShow('+p+");"+_wppaLinkUrl[p][e]+'" target="'+_wppaLinkTarget[p][e]+'" title="'+_wppaLinkTitle[p][e]+'"><'+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e]+"</a>":"<a onclick=\"_bumpClickCount('"+_wppaId[p][e]+"');wppaStopAudio();wppaStopShow("+p+");window.open('"+_wppaLinkUrl[p][e]+"', '"+_wppaLinkTarget[p][e]+'\');" title="'+_wppaLinkTitle[p][e]+'"><'+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e]+"</a>";else if(""==wppaLightBox[p])t="<"+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e];else{for(var s="",d=0,u=wppaLightboxSingle[p]?"":"[slide-"+p+"-"+a+"]";d<e;)i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][d]:wppaMakeFullsizeUrl(_wppaUrl[p][d]),o=".pdf"==(n=_wppaHiresUrl[p][d]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][d]+'" data-videonatheight="'+_wppaVideoNatHeight[p][d]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][d])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][d])+'"':"")+" "+r+'="'+_wppaLbTitle[p][d]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+"></a>",d++;for(i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][e]:wppaMakeFullsizeUrl(_wppaUrl[p][e]),o=".pdf"==(n=_wppaHiresUrl[p][e]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(wppaSlideLinkEqual?' onclick="wppaStopAudio();wppaStopShow('+p+");jQuery('#wppa-film-"+e+"-"+p+"').trigger('click');return false;\"":' onclick="wppaStopAudio();wppaStopShow('+p+');"')+' style="cursor:pointer;" target="'+_wppaLinkTarget[p][e]+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][e]+'" data-videonatheight="'+_wppaVideoNatHeight[p][e]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][e])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][e])+'"':"")+" "+r+'="'+_wppaLbTitle[p][e]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+">"+(o?"<iframe "+l+' src="'+n+'" title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" style="width:100%;height:100%;" ></iframe>':"<"+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e])+"</a>",d=e+1;d<_wppaUrl[p].length;)i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][d]:wppaMakeFullsizeUrl(_wppaUrl[p][d]),o=".pdf"==(n=_wppaHiresUrl[p][d]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][d]+'" data-videonatheight="'+_wppaVideoNatHeight[p][d]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][d])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][d])+'"':"")+" "+r+'="'+_wppaLbTitle[p][d]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+"></a>",d++;t=s}""!=_wppaAudioHtml[p][e]&&(t+='<audio controls id="wppa-audio-'+_wppaId[p][e]+"-"+p+'" class="wppa-audio-'+p+" wppa-audio-"+_wppaId[p][e]+"-"+p+'" data-from="wppa" onplay="wppaAudioPlaying['+p+'] = true;" onpause="wppaAudioPlaying['+p+'] = false" style="position:relative;top:-'+(wppaAudioHeight+wppaSlideBorderWidth)+"px;z-index:10;width:"+_wppaVideoNatWidth[p][e]+'px;padding:0;box-sizing:border-box;" >'+_wppaAudioHtml[p][e]+"</audio>"),t=t.replace(/title=""/g,""),jQuery("#theslide"+a+"-"+p).html(t)}function wppaAdjustAllFilmstrips(p){jQuery(".wppa-filmstrip").each(function(){_wppaAdjustFilmstrip(jQuery(this).attr("id").substr(15),p)})}var wppaLastAnimFilmLoc=[];function _wppaAdjustFilmstrip(p,a){if("linear"!=a&&(a=wppaEasingSlide),document.getElementById("wppa-filmstrip-"+p)&&_wppaSlides[p]){var e,t,i,w,r=!document.getElementById("slide_frame-"+p);if(wppaLastAnimFilmLoc[p]||(wppaLastAnimFilmLoc[p]=0),r){var n=jQuery("#wppa-filmstrip-"+p);if(!wppaIsElementInViewport(n))return}if(r||jQuery(".wppa-film-"+p).removeClass("wppa-filmthumb-active"),_wppaFilmNoMove[p]&&wppaFilmInit[p]?_wppaFilmNoMove[p]=!1:(e=wppaFilmStripLength[p]/2-(_wppaCurIdx[p]+.5+wppaPreambule[p])*wppaThumbnailPitch[p]-wppaFilmStripMargin[p],wppaFilmShowGlue&&(e-=2*wppaFilmStripMargin[p]+2),i=e+wppaThumbnailPitch[p],w=e-wppaThumbnailPitch[p],t=wppaAnimationSpeed,wppaFilmInit[p]||(t=1),0==_wppaCurIdx[p]&&_wppaLastIdx[p]==_wppaSlides[p].length-1?(jQuery("#wppa-filmstrip-"+p).css({marginLeft:i+"px"}),wppaLastAnimFilmLoc[p]!=e&&(wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e)):0==_wppaLastIdx[p]&&_wppaCurIdx[p]==_wppaSlides[p].length-1?(jQuery("#wppa-filmstrip-"+p).css({marginLeft:w}),wppaLastAnimFilmLoc[p]!=e&&(wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e)):(n=parseInt(jQuery("#wppa-filmstrip-"+p).css("margin-left")),i=parseInt(e),w=wppaThumbnailPitch[p],_wppaSSRuns[p]?(n<i?2:i<n-2*w?1:0)&&jQuery("#wppa-filmstrip-"+p).css({marginLeft:i+w}):(i<n-1.5*w||n+1.5*w<i)&&jQuery("#wppa-filmstrip-"+p).css({marginLeft:i}),wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e,wppaFilmInit[p]=!0),_wppaLastIdx[p]=_wppaCurIdx[p]),wppaMakeLazyVisible("filmstripmocc="+p),!r&&-1!=_wppaCurIdx[p]){_wppaCurIdx[p];_wppaCurIdx[p]+10>_wppaSlides[p].length&&_wppaSlides[p].length;for(var o=0;o<_wppaSlides[p].length;)jQuery("#film_wppatnf_"+_wppaId[p][o]+"_"+p).html()&&(""!=jQuery("#wppa-film-"+o+"-"+p).attr("data-title")?(jQuery("#wppa-film-"+o+"-"+p).attr("title",jQuery("#wppa-film-"+o+"-"+p).attr("data-title")),jQuery("#wppa-pre-"+o+"-"+p).attr("title",jQuery("#wppa-film-"+o+"-"+p).attr("data-title"))):""!=wppaFilmThumbTitle&&_wppaCurIdx[p]==o?(jQuery("#wppa-film-"+o+"-"+p).attr("title",wppaFilmThumbTitle),jQuery("#wppa-pre-"+o+"-"+p).attr("title",wppaFilmThumbTitle)):(jQuery("#wppa-film-"+o+"-"+p).attr("title",wppaClickToView+" "+_wppaFilmThumbTitles[p][o]),jQuery("#wppa-pre-"+o+"-"+p).attr("title",wppaClickToView+" "+_wppaFilmThumbTitles[p][o]))),o++}r||jQuery("#wppa-film-"+_wppaCurIdx[p]+"-"+p).addClass("wppa-filmthumb-active")}}function _wppaNext(p){var a,e;!wppaSlideWrap[p]&&_wppaCurIdx[p]==_wppaSlides[p].length-1||(_wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length?(a=jQuery("#wppa-next-pagelink-"+p),e=jQuery("#wppa-first-pagelink-"+p),0<a.length&&"hidden"!=jQuery(a).css("visibility")?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopnext",jQuery("#wppa-next-pagelink-"+p).trigger("click")):0<e.length?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopnext",jQuery(e).trigger("click")):_wppaNextSlide(p,_wppaNxtIdx[p]=0)):_wppaNextSlide(p,0))}function _wppaNextN(p,a){if(wppaSlideWrap[p]||!(_wppaCurIdx[p]>=_wppaSlides[p].length-a)){for(_wppaNxtIdx[p]=_wppaCurIdx[p]+a;_wppaNxtIdx[p]>=_wppaSlides[p].length;)_wppaNxtIdx[p]-=_wppaSlides[p].length;_wppaNextSlide(p,0)}}function _wppaNextOnCallback(p){if(wppaSlideWrap[p]||_wppaCurIdx[p]!=_wppaSlides[p].length-1){if(_wppaSkipRated[p]){var a=_wppaCurIdx[p]+1;a==_wppaSlides[p].length&&(a=0);var e=a;if(0!=_wppaMyr[p][e]){for(++a==_wppaSlides[p].length&&(a=0);a!=e&&0!=_wppaMyr[p][a];)++a==_wppaSlides[p].length&&(a=0);e=a}_wppaNxtIdx[p]=e}else _wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length&&(_wppaNxtIdx[p]=0);_wppaNextSlide(p,0)}}function _wppaPrev(p){!wppaSlideWrap[p]&&0==_wppaCurIdx[p]||(_wppaNxtIdx[p]=_wppaCurIdx[p]-1,_wppaNxtIdx[p]<0?jQuery("#wppa-prev-page-last-item-"+p).length?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopprev",jQuery("#wppa-prev-page-last-item-"+p).trigger("click")):(_wppaNxtIdx[p]+=_wppaSlides[p].length,_wppaNextSlide(p,0)):_wppaNextSlide(p,0))}function _wppaPrevN(p,a){if(wppaSlideWrap[p]||!(_wppaCurIdx[p]<a)){for(_wppaNxtIdx[p]=_wppaCurIdx[p]-a;_wppaNxtIdx[p]<0;)_wppaNxtIdx[p]+=_wppaSlides[p].length;_wppaNextSlide(p,0)}}function _wppaGoto(p,a){_wppaToTheSame=_wppaNxtIdx[p]==a,_wppaNxtIdx[p]=a,_wppaNextSlide(p,0)}function _wppaGotoRunning(p,a){_wppaIsBusy[p]?setTimeout("_wppaGotoRunning( "+p+","+a+" )",10):(_wppaSSRuns[p]=!1,_wppaToTheSame=_wppaNxtIdx[p]==a,_wppaNxtIdx[p]=a,__wppaOverruleRun=!0,_wppaNextSlide(p,"manual"),_wppaGotoContinue(p))}function _wppaGotoContinue(p){_wppaIsBusy[p]?setTimeout("_wppaGotoContinue( "+p+" )",10):setTimeout("_wppaNextSlide( "+p+', "reset" )',wppaGetSlideshowTimeout(p)+10)}function _wppaStart(p,a){if(_wppaStopping[p])return _wppaStopping[p]--,void setTimeout(function(){_wppaStart(p,a)},(wppaAnimationSpeed+wppaGetSlideshowTimeout(p))/10);_wppaSSRuns[p]||(("icons"==wppaSlideshowNavigationType?_wppaStartIcons:_wppaStartText)(p,a),jQuery("#wppa-startstop-icon-"+p).html(wppaSvgHtml("Pause-Button",wppaIconSize(p,"48px",!0),!1,!0,"0","10","50","50")))}function _wppaStartIcons(p,a){if(-2==a){var e=0;if(a=0,_wppaSkipRated[p]=!0,0!=_wppaMyr[p][e])for(;e<_wppaSlides[p].length;)0==a&&0==_wppaMyr[p][e]&&(a=e),e++}var t=wppaIconSize(p,"1.5em",!1);-1<a?(jQuery("#startstop-"+p).html(wppaSvgHtml("Play-Button",t,!1,!0,"0","10","20","50")),jQuery("#speed0-"+p).hide(),jQuery("#speed1-"+p).hide(),_wppaNxtIdx[p]=a,_wppaCurIdx[p]=a,_wppaNextSlide(p,0),_wppaShowMetaData(p,"show")):(_wppaSSRuns[p]=!0,_wppaNextSlide(p,0),jQuery("#startstop-"+p).html(wppaSvgHtml("Pause-Button",t,!1,!0,"0","10","20","50")),jQuery("#speed0-"+p).show(),jQuery("#speed1-"+p).show(),_wppaShowMetaData(p,"hide"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(wppaSlideShow)),_wppaSetRatingDisplay(p)}function _wppaStartText(p,a){if(-2==a){var e=0;if(a=0,_wppaSkipRated[p]=!0,0!=_wppaMyr[p][e])for(;e<_wppaSlides[p].length;)0==a&&0==_wppaMyr[p][e]&&(a=e),e++}-1<a?(jQuery("#startstop-"+p).html(wppaStart+" "+wppaSlideShow),jQuery("#speed0-"+p).css("display","none"),jQuery("#speed1-"+p).css("display","none"),_wppaNxtIdx[p]=a,_wppaCurIdx[p]=a,_wppaNextSlide(p,0),_wppaShowMetaData(p,"show")):(_wppaSSRuns[p]=!0,_wppaNextSlide(p,0),jQuery("#startstop-"+p).html(wppaStop),jQuery("#speed0-"+p).css("display","inline"),jQuery("#speed1-"+p).css("display","inline"),_wppaShowMetaData(p,"hide"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(wppaSlideShow)),_wppaSetRatingDisplay(p)}function _wppaStop(p){_wppaStopping[p]=12,("icons"==wppaSlideshowNavigationType?_wppaStopIcons:_wppaStopText)(p),jQuery("#wppa-startstop-icon-"+p).html(wppaSvgHtml("Play-Button",wppaIconSize(p,"48px",!0),!1,!0,"0","10","50","50"))}function _wppaStopIcons(p){_wppaSSRuns[p]=!1,jQuery("#startstop-"+p).html(wppaSvgHtml("Play-Button",wppaIconSize(p,"1.5em",!1),!1,!0)),jQuery("#speed0-"+p).hide(),jQuery("#speed1-"+p).hide(),_wppaShowMetaData(p,"show"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(_wppaNames[p][_wppaCurIdx[p]])}function _wppaStopText(p){_wppaSSRuns[p]=!1,jQuery("#startstop-"+p).html(wppaStart+" "+wppaSlideShow),jQuery("#speed0-"+p).css("display","none"),jQuery("#speed1-"+p).css("display","none"),_wppaShowMetaData(p,"show"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(_wppaNames[p][_wppaCurIdx[p]])}function _wppaSpeed(p,a){"random"!=_wppaTimeOut[p]&&(a?500<_wppaTimeOut[p]&&(_wppaTimeOut[p]/=1.5):_wppaTimeOut[p]<6e4&&(_wppaTimeOut[p]*=1.5))}function _wppaLoadSpinner(p){}function _wppaUnloadSpinner(p){jQuery("#wppa-slide-spin-"+p).stop().fadeOut(),setTimeout(function(){jQuery("#wppa-slide-spin-"+p).stop().fadeOut()},1e3)}function _wppaCheckRewind(p){var a,e;document.getElementById("wppa-filmstrip-"+p)&&((e=Math.abs(_wppaCurIdx[p]-_wppaNxtIdx[p]))<=wppaFilmPageSize[p]||(1+wppaFilmStripLength[p]/wppaThumbnailPitch[p])/2<=e&&(a=wppaThumbnailPitch[p]*_wppaSlides[p].length,wppaFilmShowGlue&&(a+=2+2*wppaFilmStripMargin[p]),e=parseInt(jQuery("#wppa-filmstrip-"+p).css("margin-left")),_wppaNxtIdx[p]>_wppaCurIdx[p]?e-=a:e+=a,jQuery("#wppa-filmstrip-"+p).css("margin-left",e+"px")))}function _wppaSetRatingDisplay(p){if(document.getElementById("wppa-rating-"+p)){var a,e,t=_wppaAvg[p][_wppaCurIdx[p]];if(void 0!==t){if("likes"==wppaRatingDisplayType){"void"==(e=_wppaMyr[p][_wppaCurIdx[p]])?(jQuery("#wppa-dislike-imgdiv-"+p).hide(),jQuery("#wppa-like-imgdiv-"+p).hide()):(jQuery("#wppa-dislike-imgdiv-"+p).show(),jQuery("#wppa-like-imgdiv-"+p).show());var w=t.split("|");return jQuery("#wppa-like-"+p).attr("title",w[0]),jQuery("#wppa-liketext-"+p).html(w[1]),void("1"==_wppaMyr[p][_wppaCurIdx[p]]?jQuery("#wppa-like-"+p).attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-"+p).attr("src",wppaImageDirectory+"thumbup.png"))}if(t=(a=t.split("|"))[0],w=a[1],a=_wppaDisc[p][_wppaCurIdx[p]],e=_wppaMyr[p][_wppaCurIdx[p]],"void"==a)jQuery("#wppa-rating-"+p).hide();else{if(jQuery("#wppa-rating-"+p).show(),"graphic"==wppaRatingDisplayType)_wppaSetRd(p,t,"#wppa-avg-"),_wppaSetRd(p,e,"#wppa-rate-"),0==e?(jQuery("#wppa-dislike-"+p).css("display","inline"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","inline"),document.getElementById("wppa-dislike-"+p)&&jQuery("#wppa-filler-"+p).css("display","none"),jQuery("#wppa-dislike-"+p).stop().fadeTo(100,wppaStarOpacity)):(jQuery("#wppa-dislike-"+p).css("display","none"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","none"),jQuery("#wppa-filler-"+p).css("display","inline"),jQuery("#wppa-filler-"+p).stop().fadeTo(100,wppaStarOpacity),jQuery("#wppa-filler-"+p).attr("title",a));else{if(jQuery("#wppa-numrate-avg-"+p).html(t+" ( "+w+" ) "),jQuery(".wppa-my-rat-"+p).show(),"void"==e)jQuery("#wppa-numrate-mine-"+p).html(""),jQuery(".wppa-my-rat-"+p).hide();else if(wppaRatingOnce&&0<e)jQuery("#wppa-numrate-mine-"+p).html(e);else if(e<0)jQuery("#wppa-numrate-mine-"+p).html(" dislike");else{var r="";for(i=1;i<=wppaRatingMax;i++)e==i?r+='<span class="wppa-rating-numeric-mine" style="cursor:pointer; font-weight:bold;" onclick="_wppaRateIt( '+p+", "+i+' )"> '+i+" </span>":(e>i-1&&e<i&&(r+=" ( "+e+" ) "),r+='<span class="wppa-rating-numeric" style="cursor:pointer;" onclick="_wppaRateIt( '+p+", "+i+' )" onmouseover="this.style.fontWeight=\'bold\'" onmouseout="this.style.fontWeight=\'normal\'" > '+i+" </span>");jQuery("#wppa-numrate-mine-"+p).html(r)}0==e?(jQuery("#wppa-dislike-"+p).css("display","inline"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","inline"),jQuery("#wppa-filler-"+p).css("display","none"),jQuery("#wppa-dislike-"+p).stop().fadeTo(100,wppaStarOpacity)):(jQuery("#wppa-dislike-"+p).css("display","none"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","none"),jQuery("#wppa-filler-"+p).css("display","inline")),jQuery("#wppa-discount-"+p).html(a+"• "),jQuery("#wppa-filler-"+p).css("display","none")}0==e?jQuery("#wppa-vote-button-"+p).val(wppaVoteForMe):jQuery("#wppa-vote-button-"+p).val(wppaVotedForMe),jQuery("#wppa-vote-count-"+p).html(w)}}}}function wppaGetDislikeText(p,a,e){return p}function _wppaSetRd(p,a,e){var t=parseInt(a),i=t+1,w=wppaStarOpacity+(a-t)*(1-wppaStarOpacity),r=wppaRatingMax;if("void"==a)jQuery("#wppa-my-rat-"+p).hide(),jQuery(".wppa-my-rat-"+p).hide(),jQuery(".wppa-rate-"+p).hide(),jQuery(".wppa-ratingthumb").hide(),jQuery("#wppa-numrate-mine-"+p).hide();else for(jQuery("#wppa-my-rat-"+p).show(),jQuery(".wppa-my-rat-"+p).show(),jQuery(".wppa-rate-"+p).show(),jQuery(".wppa-ratingthumb").show(),jQuery("#wppa-numrate-mine-"+p).show(),idx=1;idx<=r;idx++)"#wppa-rate-"!=e&&".wppa-rate-"!=e||jQuery(e+p+"-"+idx).attr("src")!=wppaImageDirectory+"star.ico"&&jQuery(e+p+"-"+idx).attr("src",wppaImageDirectory+"star.ico"),idx<=t?jQuery(e+p+"-"+idx).stop().fadeTo(100,1):idx==i?jQuery(e+p+"-"+idx).stop().fadeTo(100,w):jQuery(e+p+"-"+idx).stop().fadeTo(100,wppaStarOpacity)}function _wppaFollowMe(p,a){_wppaSSRuns[p]||0!=_wppaMyr[p][_wppaCurIdx[p]]&&wppaRatingOnce||_wppaMyr[p][_wppaCurIdx[p]]<0||_wppaVoteInProgress||_wppaSetRd(p,a,"#wppa-rate-")}function wppaOvlFollowMe(p,a,e){e||_wppaSetRd(p,a,".wppa-rate-")}function _wppaLeaveMe(p,a){_wppaSSRuns[p]||0!=_wppaMyr[p][_wppaCurIdx[p]]&&wppaRatingOnce||_wppaMyr[p][_wppaCurIdx[p]]<0||_wppaVoteInProgress||_wppaSetRd(p,_wppaMyr[p][_wppaCurIdx[p]],"#wppa-rate-")}function wppaOvlLeaveMe(p,a,e){_wppaSetRd(p,e,".wppa-rate-")}function _wppaValidateComment(p,a){if(a=a||_wppaId[p][_wppaCurIdx[p]],jQuery("#wppa-comname-"+p).val().length<1)return alert(wppaPleaseName),!1;if("required"==wppaEmailRequired||"optional"==wppaEmailRequired){var e=jQuery("#wppa-comemail-"+p).val();if("optional"==wppaEmailRequired&&0==e.length)return!0;var t=e.indexOf("@"),a=e.lastIndexOf(".");if(t<1||a<t+2||a+2>=e.length)return alert(wppaPleaseEmail),!1}return!(jQuery("#wppa-comment-"+p).val().length<1)||(alert(wppaPleaseComment),!1)}function _wppaGo(p){document.location=p}function _wppaBbb(p,a,e){if(!_wppaSSRuns[p]){var t="#bbb-"+p+"-"+a;switch(e){case"show":"l"==a&&jQuery(t).attr("title",wppaPreviousPhoto),"r"==a&&jQuery(t).attr("title",wppaNextPhoto),jQuery(".bbb-"+p).css("cursor","pointer");break;case"hide":jQuery(".bbb-"+p).removeAttr("title"),jQuery(".bbb-"+p).css("cursor","default");break;case"click":"l"==a&&wppaPrev(p),"r"==a&&wppaNext(p);break;default:alert("Unimplemented instruction: "+e+" on: "+t)}}}function _wppaUbb(p,a,e){var t="#ubb-"+p+"-"+a;switch(e){case"show":"l"==a&&jQuery(t).attr("title",wppaPreviousPhoto),"r"==a&&jQuery(t).attr("title",wppaNextPhoto),jQuery(".ubb-"+p).css("cursor","pointer"),jQuery(".ubb-"+p).stop().fadeTo(200,.8),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,.8);break;case"hide":jQuery(".ubb-"+p).removeAttr("title"),jQuery(".ubb-"+p).css("cursor","default"),wppaIsMobile?jQuery(".ubb-"+p).stop().fadeTo(200,.1):jQuery(".ubb-"+p).stop().fadeTo(200,0),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,0);break;case"click":wppaIsMobile&&(jQuery(".ubb-"+p).stop().fadeTo(200,1).fadeTo(1e3,0),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,1).fadeTo(1e3,0)),"l"==a&&wppaPrev(p),"r"==a&&wppaNext(p);break;default:alert("Unimplemented instruction: "+e+" on: "+t)}}function wppaOpenComments(p){_wppaSSRuns[p]&&_wppaStop(p),jQuery("#wppa-comtable-wrap-"+p).css("display","block"),jQuery("#wppa-comform-wrap-"+p).css("display","block"),jQuery("#wppa-comfooter-wrap-"+p).css("display","none"),wppaColWidth[p]=0,setTimeout("_wppaDoAutocol( "+p+" )",100)}function _wppaShowMetaData(p,a){_wppaSlides[p]&&(_wppaSSRuns[p]||__wppaOverruleRun?"show"==a?wppaFotomotoHideWhenRunning||wppaFotomotoToolbar(p,_wppaHiresUrl[p][_wppaCurIdx[p]]):wppaShareHideWhenRunning&&jQuery("#wppa-share-"+p).css("display","none"):"show"==a?(wppaAutoOpenComments&&(jQuery("#wppa-comtable-wrap-"+p).css("display","block"),jQuery("#wppa-comform-wrap-"+p).css("display","block"),jQuery("#wppa-comfooter-wrap-"+p).css("display","none")),0!=_wppaCurIdx[p]&&jQuery(".wppa-first-"+p).show(),_wppaCurIdx[p]!=_wppaSlides[p].length-1&&jQuery(".wppa-last-"+p).show(),wppaShareHideWhenRunning&&jQuery("#wppa-share-"+p).css("display",""),wppaFotomotoToolbar(p,_wppaHiresUrl[p][_wppaCurIdx[p]])):(jQuery("#wppa-comtable-wrap-"+p).css("display","none"),jQuery("#wppa-comform-wrap-"+p).css("display","none"),jQuery("#wppa-comfooter-wrap-"+p).css("display","block"),wppaFotomotoHide(p)),"show"==a?(jQuery("#imagedesc-"+p).css("visibility","visible"),jQuery("#imagetitle-"+p).css("visibility","visible"),jQuery("#counter-"+p).css("visibility","visible"),jQuery("#iptccontent-"+p).css("visibility","visible"),jQuery("#exifcontent-"+p).css("visibility","visible")):(jQuery("#counter-"+p).css("visibility","hidden"),jQuery(".wppa-first-"+p).hide(),jQuery(".wppa-last-"+p).hide(),jQuery("#iptccontent-"+p).css("visibility","hidden"),jQuery("#exifcontent-"+p).css("visibility","hidden")))}function wppaGetSlideshowTimeout(p){var a,e;return"random"==_wppaTimeOut[p]?(a=2*wppaAnimationSpeed,e=7*wppaAnimationSpeed,Math.floor(Math.random()*(e-a+1))+a):_wppaTimeOut[p]}function wppaIsSlidshowVisible(p){for(var a,e=["slide_frame-"+p,"filmwindow-"+p],t=e.length,i=0;i<t;i++)if(a=document.getElementById(e[i]),a&&(a.getBoundingClientRect(),wppaIsElementInViewport(a)))return!0;return wppaFilmInit[p]=!1}
|
7 |
// wppa-ajax-front
|
8 |
var wppaJsAjaxVersion="8.1.09.003";function wppaDoAjaxRender(o,a,r,p){""!=wppaLang&&(a+="&lang="+wppaLang),wppaAutoColumnWidth[o]&&(a+="&resp=1"),p&&_wppaCurIdx[o]&&_wppaId[o][_wppaCurIdx[o]]&&(a+="&wppa-hilite="+_wppaId[o][_wppaCurIdx[o]]),wppaCanAjaxRender||!r?jQuery.ajax({url:a,async:!0,type:"GET",timeout:6e4,beforeSend:function(a){_wppaSSRuns[o]&&_wppaStop(o),jQuery("#wppa-ajax-spin-"+o).fadeIn()},success:function(a,p,e){var a=JSON.parse(a),t=a.html+"<script>"+a.js+"<\/script>";wppaRenderModal&&r?(a={modal:!0,resizable:!0,width:wppaGetContainerWidth(o),show:{effect:"fadeIn",duration:400},closeText:""},jQuery("#wppa-modal-container-"+o).html(t).dialog(a).dialog("open"),jQuery(".ui-dialog").css({boxShadow:"0px 0px 5px 5px #aaaaaa",borderRadius:wppaBoxRadius+"px",padding:"8px",backgroundColor:wppaModalBgColor,boxSizing:"content-box",zIndex:1e5}),jQuery(".ui-dialog-titlebar").css({lineHeight:"0px",height:"32px"}),jQuery(".ui-button").css({backgroundImage:wppaModalQuitImg,padding:0,position:"absolute",right:"8px",top:"8px",width:"16px",height:"16px"}),jQuery(".ui-button").attr("title","Close"),jQuery(".ui-button").on("click",function(){_wppaStop(o)}),jQuery(".wppa-ajax-spin").stop().fadeOut()):(jQuery("#wppa-container-"+o).html(t),jQuery("#wppa-button-hide-"+o).show()),wppaCanPushState&&wppaUpdateAddressLine&&r&&(wppaHis++,r=r.split("&").join("&"),jQuery(document).ready(function(){setTimeout(function(){try{history.pushState({page:wppaHis,occur:o,type:"html",html:t},"",r),wppaConsoleLog("Pushed history stack on ajax call","force")}catch(a){try{history.replaceState({page:wppaHis,occur:o,type:"html"},"",r),wppaConsoleLog("History replaced on ajax call","force")}catch(a){wppaConsoleLog("Ajax rendering: History stack update and replace failed","force")}}},1e3)}),0==wppaFirstOccur&&(wppaFirstOccur=o)),wppaUpdateLightboxes(),"undefined"!=typeof wppaQRUpdate&&wppaQRUpdate(r),wppaColWidth[o]=0,_wppaDoAutocol(o,"ajax")},error:function(a,p,e){wppaConsoleLog("wppaDoAjaxRender failed. Error = "+e+", status = "+p,"force"),r?document.location.href=r:document.location.reload(!0)},complete:function(a,p,e){!wppaRenderModal&&wppaAjaxScroll&&jQuery("html, body").animate({scrollTop:jQuery("#wppa-container-"+o).offset().top-32-wppaStickyHeaderHeight},1e3),jQuery(".wppa-ajax-spin").stop().fadeOut(),window.dispatchEvent(new Event("resize")),wppaProtect()}}):(document.location.href=r,wppaColWidth[o]=0,_wppaDoAutocol(o,"nonajax"))}function wppaAjaxApprovePhoto(t){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=approve&photo-id="+t,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){"OK"==a?jQuery(".wppa-approve-"+t).css("display","none"):alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxApprovePhoto failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxRemovePhoto(t,o,r){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=remove&photo-id="+o,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){rtxt=a.split("||"),"OK"==rtxt[0]?r?(jQuery("#wppa-film-"+_wppaCurIdx[t]+"-"+t).attr("src",""),jQuery("#wppa-pre-"+_wppaCurIdx[t]+"-"+t).attr("src",""),jQuery("#wppa-film-"+_wppaCurIdx[t]+"-"+t).attr("alt","removed"),jQuery("#wppa-pre-"+_wppaCurIdx[t]+"-"+t).attr("alt","removed"),wppaNext(t)):(jQuery(".wppa-approve-"+o).css("display","none"),jQuery(".thumbnail-frame-photo-"+o).css("display","none")):rtxt[3]?(alert(rtxt[3]),jQuery("#wppa-delete-"+o).css("text-decoration","line-through")):alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxRemovePhoto failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxApproveComment(t){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=approve&comment-id="+t,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){"OK"==a?jQuery(".wppa-approve-"+t).css("display","none"):alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxApproveComment failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxRemoveComment(t){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=remove&comment-id="+t,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){"OK"==a.split("||")[0]?(jQuery(".wppa-approve-"+t).css("display","none"),jQuery(".wppa-comment-"+t).css("display","none")):alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxRemoveComment failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxAddPhotoToZip(o,r,n){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=addtozip&photo-id="+r,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){var t=a.split("||");"OK"==t[0]?(jQuery("#admin-choice-"+r+"-"+o).html(t[2]),jQuery("#admin-choice-"+r+"-"+o).val(t[2]),jQuery("#admin-choice-"+r+"-"+o).prop("disabled",!0)):wppaConsoleLog("NOT OK "+a),alert(t[1]),n&&document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxAddPhotoToZip failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxRemovePhotoFromZip(o,r,n){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=removefromzip&photo-id="+r,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){var t=a.split("||");"OK"==t[0]?(jQuery("#admin-choice-rem-"+r+"-"+o).val(t[1]),jQuery("#admin-choice-rem-"+r+"-"+o).prop("disabled",!0),jQuery("#admin-choice-rem-"+r+"-"+o).css("text-decoration","")):alert(a),n&&document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxRemovePhotoFromZip failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxDeleteMyZip(){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=delmyzip",async:!0,type:"GET",timeout:6e4,success:function(a,p,e){document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxDeleteMyZip failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxRequestInfo(a,p,e){dialogHtml="<h3>"+wppaRequestInfoDialogText+'</h3><textarea id="wppa-request-info-text-'+a+'" style="width:98%;" ></textarea><div style="clear:both;" ></div><input type="button" style="float:left;margin-top:8px;margin-right:8px;" value="Send" onclick="wppaAjaxRequestInfoSend( '+a+", "+p+", "+e+' )" /><input type="button" style="float:left;margin-top:8px;margin-right:8px;" value="Cancel" onclick="jQuery( \'#wppa-modal-container-'+a+"' ).dialog( 'close' );\" /><div style=\"clear:both;\" ></div>";e={modal:!0,resizable:!0,width:wppaGetContainerWidth(a),show:{effect:"fadeIn",duration:400},closeText:""};jQuery("#wppa-modal-container-"+a).html(dialogHtml).dialog(e).dialog("open"),jQuery(".ui-dialog").css({boxShadow:"0px 0px 5px 5px #aaaaaa",borderRadius:wppaBoxRadius+"px",padding:"8px",backgroundColor:wppaModalBgColor,boxSizing:"content-box",zIndex:1e5}),jQuery(".ui-dialog-titlebar").css({lineHeight:"0px",height:"24px"}),jQuery(".ui-button").css({backgroundImage:wppaModalQuitImg,padding:0,position:"absolute",right:"8px",top:"8px",width:"16px",height:"16px"}),jQuery(".ui-button").attr("title","Close")}function wppaAjaxRequestInfoSend(o,r,n){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=requestinfo&photo-id="+r+"&emailtext="+jQuery("#wppa-request-info-text-"+o).val(),async:!0,type:"GET",timeout:6e4,success:function(a,p,e){var t=a.split("||");"OK"==t[0]?(jQuery("#request-info-"+r+"-"+o).val(t[1]),jQuery("#request-info-"+r+"-"+o).prop("disabled",!0),jQuery("#wppa-modal-container-"+o).dialog("close")):alert(a),n&&document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxRequestInfoSend failed. Error = "+e+", status = "+p,"force")}})}function wppaEditPhoto(o,a){var p=String(a),a=wppaEditPhotoWidth;screen.availWidth<a&&(a=screen.availWidth),jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=front-edit&photo-id="+p+"&occur="+o,async:!0,type:"POST",timeout:6e4,beforeSend:function(a){},success:function(a,p,e){var t={modal:!0,resizable:!0,width:wppaGetContainerWidth(o),show:{effect:"fadeIn",duration:400},closeText:""};jQuery("#wppa-modal-container-"+o).html(a).dialog(t).dialog("open"),jQuery(".ui-dialog").css({boxShadow:"0px 0px 5px 5px #aaaaaa",borderRadius:wppaBoxRadius+"px",padding:"8px",backgroundColor:wppaModalBgColor,boxSizing:"content-box",zIndex:1e5}),jQuery(".ui-dialog-titlebar").css({lineHeight:"0px",height:"24px"}),jQuery(".ui-button").css({backgroundImage:wppaModalQuitImg,padding:0,position:"absolute",right:"8px",top:"8px",width:"16px",height:"16px"}),jQuery(".ui-button").attr("title","Close"),jQuery(document).trigger("resize")},error:function(a,p,e){wppaConsoleLog("wppaEditPhoto failed. Error = "+e+", status = "+p,"force")},complete:function(a,p,e){}})}function wppaPrevTags(a,p,e,t){for(var o,r=jQuery("."+a),n=[],i=jQuery("#"+e).val(),c=0,u=0,a="";c<r.length;)r[c].selected&&(n[u]=r[c].value,u++),c++;""!=(o=jQuery("#"+p).val())&&(n[u]=o),a=n.join(),""==o&&""==e||jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=sanitizetags&tags="+a+"&album="+i,async:!0,type:"GET",timeout:6e4,beforeSend:function(a){jQuery("#"+t).html("Working...")},success:function(a,p,e){jQuery("#"+t).html(wppaTrim(a,","))},error:function(a,p,e){jQuery("#"+t).html('<span style="color:red" >'+e+"</span>"),wppaConsoleLog("wppaPrevTags failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxDestroyAlbum(a,p){return confirm("Are you sure you want to delete this album?")&&jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=destroyalbum&album="+a+"&nonce="+p,async:!0,type:"GET",timeout:6e4,success:function(a,p,e){alert(a+"\nPage will be reloaded"),document.location.reload(!0)},error:function(a,p,e){wppaConsoleLog("wppaAjaxDestroyAlbum failed. Error = "+e+", status = "+p,"force")}}),!1}function _bumpClickCount(a){wppaBumpClickCount&&jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=bumpclickcount&wppa-photo="+a+"&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!1,type:"GET",timeout:6e4,success:function(a,p,e){},error:function(a,p,e){wppaConsoleLog("_bumpClickCount failed. Error = "+e+", status = "+p,"force")}})}function _bumpViewCount(t){wppaBumpViewCount&&(wppaPhotoView[t]||jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=bumpviewcount&wppa-photo="+t+"&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!0,type:"GET",timeout:6e4,success:function(a,p,e){wppaPhotoView[t]=!0},error:function(a,p,e){wppaConsoleLog("_bumpViewCount failed. Error = "+e+", status = "+p,"force")}}))}function wppaVoteThumb(t,o){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=rate&wppa-rating=1&wppa-rating-id="+o+"&wppa-occur="+t+"&wppa-index=0&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!0,type:"GET",timeout:6e4,success:function(a,p,e){jQuery("#wppa-vote-button-"+t+"-"+o).val(wppaVotedForMe)},error:function(a,p,e){wppaConsoleLog("wppaVoteThumb failed. Error = "+e+", status = "+p,"force")}})}function _wppaRateIt(o,p){var a,e,t;0!=p&&(_wppaSSRuns[o]||(a=_wppaId[o][_wppaCurIdx[o]],e=_wppaMyr[o][_wppaCurIdx[o]],0<(t=_wppaWaitTexts[o][_wppaCurIdx[o]]).length?alert(t):0!=e&&wppaRatingOnce||e<0||(_wppaVoteInProgress=!0,jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=rate&wppa-rating="+p+"&wppa-rating-id="+a+"&wppa-occur="+o+"&wppa-index="+_wppaCurIdx[o]+"&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!0,type:"GET",timeout:6e4,beforeSend:function(a){jQuery("#wppa-rate-"+o+"-"+p).attr("src",wppaImageDirectory+"tick.png"),jQuery("#wppa-rate-"+o+"-"+p).stop().fadeTo(100,1),jQuery("#wppa-like-"+o).attr("src",wppaImageDirectory+"spinner.gif")},success:function(a,p,e){var t=a.split("||");0==t[0]?900==t[1]?(alert(t[2]),_wppaSetRatingDisplay(o)):alert("Error Code="+t[1]+"\n\n"+t[2]):(t[7]&&"likes"==t[7]?(a=t[4].split("|"),jQuery("#wppa-like-"+o).attr("title",a[0]),jQuery("#wppa-liketext-"+o).html(a[1]),"1"==t[3]?jQuery("#wppa-like-"+o).attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-"+o).attr("src",wppaImageDirectory+"thumbup.png"),_wppaMyr[t[0]][t[2]]=t[3],_wppaAvg[t[0]][t[2]]=t[4]):(_wppaMyr[t[0]][t[2]]=t[3],_wppaAvg[t[0]][t[2]]=t[4],_wppaDisc[t[0]][t[2]]=t[5],_wppaSetRatingDisplay(o),wppaCommentRequiredAfterVote&&0==t[6]&&alert(t[7])),wppaNextOnCallback&&_wppaNextOnCallback(o))},error:function(a,p,e){wppaConsoleLog("_wppaRateIt failed. Error = "+e+", status = "+p,"force")}}))))}function _wppaOvlRateIt(o,r,n,i){0!=r&&jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=rate&wppa-rating="+r+"&wppa-rating-id="+o+"&wppa-occur=1&wppa-nonce="+jQuery("#wppa-nonce").val(),async:!0,type:"GET",timeout:6e4,beforeSend:function(a){jQuery(".wppa-rate-"+n+"-"+r).attr("src",wppaImageDirectory+"tick.png"),jQuery(".wppa-rate-"+n+"-"+r).stop().fadeTo(100,1),jQuery("#wppa-like-"+o+"-"+n).attr("src",wppaImageDirectory+"spinner.gif"),jQuery("#wppa-like-0").attr("src",wppaImageDirectory+"spinner.gif")},success:function(a,p,e){var t=a.split("||");if(0==t[0])900==t[1]?alert(t[2]):alert("Error Code="+t[1]+"\n\n"+t[2]),jQuery(".wppa-rate-"+n+"-"+r).attr("src",wppaImageDirectory+"cross.png");else{if(t[7]&&"likes"==t[7]){a=t[4].split("|");return jQuery("#wppa-like-0").attr("title",a[0]),jQuery("#wppa-liketext-0").html(a[1]),"1"==t[3]?jQuery("#wppa-like-0").attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-0").attr("src",wppaImageDirectory+"thumbup.png"),jQuery("#wppa-like-"+o+"-"+n).attr("title",a[0]),jQuery("#wppa-liketext-"+o+"-"+n).html(a[1]),void("1"==t[3]?jQuery("#wppa-like-"+o+"-"+n).attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-"+o+"-"+n).attr("src",wppaImageDirectory+"thumbup.png"))}_wppaSetRd(n,t[4],".wppa-avg-"),_wppaSetRd(n,t[3],".wppa-rate-"),i||wppaNextOnCallback&&wppaOvlShowNext()}},error:function(a,p,e){wppaConsoleLog("_wppaOvlRateIt failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxMakeOrigName(a,p){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=makeorigname&photo-id="+p+"&from=fsname",async:!0,type:"GET",timeout:6e4,beforeSend:function(a){},success:function(a,p,e){a=a.split("||");"0"==a[1]?(wppaIsSafari?"file"==wppaArtMonkyLink&&(wppaWindowReference.location=a[2]):"file"==wppaArtMonkyLink&&window.open(a[2]),"zip"==wppaArtMonkyLink&&(document.location=a[2])):(wppaIsSafari&&"file"==wppaArtMonkyLink&&wppaWindowReference.close(),alert("Error: "+a[1]+"\n\n"+a[2]))},error:function(a,p,e){wppaConsoleLog("wppaAjaxMakeOrigName failed. Error = "+e+", status = "+p,"force")},complete:function(a,p,e){}})}function wppaAjaxDownloadAlbum(t,o){jQuery.ajax({url:wppaAjaxUrl,data:"action=wppa&wppa-action=downloadalbum&album-id="+o,async:!0,type:"GET",timeout:6e4,beforeSend:function(a){jQuery("#dwnspin-"+t+"-"+o).css("display","")},success:function(a,p,e){var t=a.split("||"),o=t[0],r=t[1],a=t[2];3==t.length&&""!=a&&alert("Attention:\n\n"+a),"OK"==r?document.location=o:alert("The server could not complete the request.\nPlease try again.")},error:function(a,p,e){alert("An error occurred:\n"+e+"\nPlease try again")},complete:function(a,p,e){jQuery("#dwnspin-"+t+"-"+o).css("display","none")}})}function wppaAjaxComment(t,a){_wppaValidateComment(t,a)&&(a="action=wppa&wppa-action=do-comment&photo-id="+a+"&comname="+jQuery("#wppa-comname-"+t).val()+"&comment="+wppaEncode(jQuery("#wppa-comment-"+t).val())+"&wppa-captcha="+jQuery("#wppa-captcha-"+t).val()+"&wppa-nonce="+jQuery("#wppa-nonce-"+t).val()+"&occur="+t,void 0!==jQuery("#wppa-comemail-"+t).val()&&(a+="&comemail="+jQuery("#wppa-comemail-"+t).val()),void 0!==jQuery("#wppa-comment-edit-"+t).val()&&(a+="&comment-edit="+jQuery("#wppa-comment-edit-"+t).val()),void 0!==jQuery("#wppa-returnurl-"+t).val()&&(a+="&returnurl="+encodeURIComponent(jQuery("#wppa-returnurl-"+t).val())),jQuery("#db-agree-"+t).prop("checked")&&(a+="&db-agree=yes"),jQuery.ajax({url:wppaAjaxUrl,data:a,async:!0,type:"POST",timeout:6e4,beforeSend:function(a){jQuery("#wppa-comment-spin-"+t).css("display","inline")},success:function(a,p,e){a=a.replace(/\\/g,""),jQuery("#wppa-comments-"+t).html(a),_wppaCurIdx[t]&&(_wppaCommentHtml[t][_wppaCurIdx[t]]=a),wppaOpenComments(t)},error:function(a,p,e){wppaConsoleLog("wppaAjaxComment failed. Error = "+e+", status = "+p,"force")},complete:function(a,p,e){jQuery("#wppa-comment-spin-"+t).css("display","none")}}))}function wppaUpdatePhotoNew(a,t){for(var p=["upn-name","upn-description","upn-tags","custom_0","custom_1","custom_2","custom_3","custom_4","custom_5","custom_6","custom_7","custom_8","custom_9"],e="action=wppa&wppa-action=update-photo-new&photo-id="+a+"&wppa-nonce="+jQuery("#wppa-nonce-"+a).val(),o=0;o<p.length;)void 0!==jQuery("#"+p[o]).val()&&(e+="&"+p[o]+"="+jQuery("#"+p[o]).val()),o++;jQuery.ajax({url:wppaAjaxUrl,data:e,async:!1,type:"POST",timeout:1e4,beforeSend:function(a){},success:function(a,p,e){a=a.split("||"),a=JSON.parse(a[2]);jQuery(".sdd-"+t).html(a.desc),jQuery(".sdn-"+t).html(a.name),jQuery(".sdf-"+t).html(a.fullname),_wppaNames[t]&&(_wppaNames[t][_wppaCurIdx[t]]=wppaFixHtml(a.name),_wppaFullNames[t][_wppaCurIdx[t]]=wppaFixHtml(a.fullname),_wppaDsc[t][_wppaCurIdx[t]]=wppaFixHtml(a.desc),jQuery("#imagetitle-"+t).html(wppaMakeNameHtml(t)))},error:function(a,p,e){wppaConsoleLog("wppaUpdatePhotoNew failed. Error = "+e+", status = "+p,"force")},complete:function(a,p,e){jQuery("#wppa-modal-container-"+t).dialog("close")}})}function wppaFixHtml(a){return a=(a=(a=(a=a.replace(/\[/g,"<")).replace(/\]/g,">")).replace(/"/g,'"')).replace(/\\n/g," ")}var wppaLastQrcodeUrl="";function wppaAjaxSetQrCodeSrc(a,t){0!=jQuery(t).length&&wppaLastQrcodeUrl!=a&&(wppaLastQrcodeUrl=a,a="action=wppa&wppa-action=getqrcode&wppa-qr-nonce="+jQuery("#wppa-qr-nonce").val()+"&url="+encodeURIComponent(a),jQuery.ajax({url:wppaAjaxUrl,data:a,async:!0,type:"POST",timeout:1e4,success:function(a,p,e){a=a.split("|");jQuery(t).attr("src",a[0]),jQuery(t).attr("title",a[1])},error:function(a,p,e){wppaConsoleLog("wppaAjaxSetQrCodeSrc failed. Error = "+e+", status = "+p,"force")}}))}function wppaAjaxNotify(a,p){a=jQuery(a).prop("checked")?"on":"off",a="action=wppa&wppa-action=mailinglist&wppa-ntfy-nonce="+jQuery("#wppa-ntfy-nonce").val()+"&list="+p+"&onoff="+a;jQuery.ajax({url:wppaAjaxUrl,data:a,async:!0,type:"POST",timeout:1e4,success:function(a,p,e){alert(a)},error:function(a,p,e){wppaConsoleLog("wppaAjaxNotify failed. Error = "+e+", status = "+p,"force")}})}function wppaAjaxGetSsIptcList(a,p,e,t){wppaAjaxGetSsIptcExifList(a,p,e,t,"iptc")}function wppaAjaxGetSsExifList(a,p,e,t){wppaAjaxGetSsIptcExifList(a,p,e,t,"exif")}function wppaAjaxGetSsIptcExifList(t,o,r,n,i){ajaxurl=wppaAjaxUrl,ajaxurl+="?action=wppa&wppa-action=getss"+i+"list&"+i+"tag="+o+"&occur="+t,jQuery.ajax({url:ajaxurl,async:!0,type:"GET",timeout:1e4,beforeSend:function(a){jQuery("#wppa-ss-spinner-"+t).css("display","")},success:function(a,p,e){jQuery("#"+r).html(a),jQuery("#wppa-ss-"+i+"opts-"+t).css("display",""),wppaSuperSearchSelect(t),setTimeout('wppaSetIptcExifSize( ".wppa-'+i+"list-"+t+'", "#'+r+'" )',10),n&&wppaConsoleLog("wppaAjaxGetSs"+i+"List success after retry.","force")},error:function(a,p,e){wppaConsoleLog("wppaAjaxGetSs"+i+"List failed. Error = "+e+", status = "+p,"force"),n||wppaAjaxGetSsIptcExifList(t,o,r,!0,i)},complete:function(a,p,e){jQuery("#wppa-ss-spinner-"+t).css("display","none")}})}
|
9 |
// wppa-lightbox
|
13 |
// wppa-touch
|
14 |
var wppaJsTouchVersion="8.0.01006";function wppaStartTime(){var p=(new Date).getTime();return wppaMobileTimeStart=p,!0}function wppaInTime(){return(new Date).getTime()-wppaMobileTimeStart<250}function wppaTapLink(p,e){wppaInTime()&&(_bumpClickCount(p),document.location.href=e)}function wppaTouchStart(p,e,a){-1==(wppaSwipeMocc=a)&&(wppaSwipeOnLightbox=!0,p.preventDefault()),wppaFingerCount=p.touches.length,1==wppaFingerCount?(wppaStartX=p.touches[0].pageX,wppaStartY=p.touches[0].pageY,wppaTriggerElementID=e):wppaTouchCancel()}function wppaTouchMove(p){wppaSwipeOnLightbox&&p.preventDefault(),1==p.touches.length?(wppaCurX=p.touches[0].pageX,wppaCurY=p.touches[0].pageY):wppaTouchCancel()}function wppaTouchEnd(p){wppaSwipeOnLightbox&&p.preventDefault(),1==wppaFingerCount&&0!=wppaCurX&&(wppaSwipeLength=Math.round(Math.sqrt(Math.pow(wppaCurX-wppaStartX,2)+Math.pow(wppaCurY-wppaStartY,2))),wppaSwipeLength>=wppaMinLength&&(wppaCalculateAngle(),wppaDetermineSwipeDirection(),wppaProcessingRoutine())),wppaTouchCancel()}function wppaTouchCancel(){wppaFingerCount=0,wppaStartX=0,wppaStartY=0,wppaCurX=0,wppaCurY=0,wppaDeltaX=0,wppaDeltaY=0,wppaHorzDiff=0,wppaVertDiff=0,wppaSwipeLength=0,wppaSwipeAngle=null,wppaSwipeDirection=null,wppaTriggerElementID=null,wppaSwipeOnLightbox=!1,wppaSwipeMocc=0}function wppaCalculateAngle(){var p=wppaStartX-wppaCurX,e=wppaCurY-wppaStartY,p=(Math.round(Math.sqrt(Math.pow(p,2)+Math.pow(e,2))),Math.atan2(e,p));wppaSwipeAngle=Math.round(180*p/Math.PI),wppaSwipeAngle<0&&(wppaSwipeAngle=360-Math.abs(wppaSwipeAngle))}function wppaDetermineSwipeDirection(){wppaSwipeDirection=wppaSwipeAngle<=45&&0<=wppaSwipeAngle||wppaSwipeAngle<=360&&315<=wppaSwipeAngle?"left":135<=wppaSwipeAngle&&wppaSwipeAngle<=225?"right":45<wppaSwipeAngle&&wppaSwipeAngle<135?"down":"up"}function wppaProcessingRoutine(){document.getElementById(wppaTriggerElementID);if(wppaSwipeOnLightbox)"left"==wppaSwipeDirection?wppaOvlShowNext():"right"==wppaSwipeDirection&&wppaOvlShowPrev();else{if("right"==wppaSwipeDirection){if(idx=_wppaCurIdx[wppaSwipeMocc]-1,idx<0){if(!wppaSlideWrap)return;idx=_wppaSlides[wppaSwipeMocc].length-1}wppaGotoKeepState(wppaSwipeMocc,idx)}if("left"==wppaSwipeDirection){if(idx=_wppaCurIdx[wppaSwipeMocc]+1,idx==_wppaSlides[wppaSwipeMocc].length){if(!wppaSlideWrap)return;idx=0}wppaGotoKeepState(wppaSwipeMocc,idx)}else"up"==wppaSwipeDirection||wppaSwipeDirection}wppaTouchCancel()}
|
15 |
// wppa-zoom
|
16 |
+
var wppaJsZoomVersion="8.2.01.001";function wppaDoZoomPan(n,t){var p=jQuery;wppaZoomData[n]=t;var o=l(n,{image:document.getElementById("wppa-"+t.itemId)});function h(t){var a,n,o,e,i,s=l(t);s.canvas&&(Y()<s.time+10||(l(t,{time:Y()}),(s.isLightbox&&!wppaOvlOpen||!s.isLightbox&&wppaOvlOpen)&&(s=l(0,{abort:!0})),s.abort?l(t,{manual:!1,buttondown:!1,pause:!1,ctx:null}):s.busy||(wppaDebugCounter++,e=(s=l(t,{busy:!0})).fromX,i=s.fromY,s.manual||(s.fromX+=s.deltaX,s.fromY+=s.deltaY,a=s.fromHeight/s.deltaFactor,n=s.fromWidth/s.deltaFactor,50<a&&(wppaIsFs()||a<=s.image.height)?(s.fromX-=(n-s.fromWidth)/2,s.fromY-=(a-s.fromHeight)/2,s.fromWidth=n,s.fromHeight=a):s.buttondown=!1),s.fromX=Math.max(0,Math.min(s.image.width-s.fromWidth,s.fromX)),s.fromY=Math.max(0,Math.min(s.image.height-s.fromHeight,s.fromY)),e==s.fromX&&i==s.fromY&&1==s.deltaFactor&&(s.buttondown=!1),o=screen.width/screen.height,e=(1-s.image.width/s.fromWidth)*s.canvas.width/2,i=(1-s.image.height/s.fromHeight)*s.canvas.height/2,s.ctx=s.canvas.getContext("2d"),o>s.imageRatio&&a>s.image.height&&wppaIsFs()||o<=s.imageRatio&&n>s.image.width&&wppaIsFs()?(s.enableManual=!1,s.ctx.clearRect(0,0,s.canvas.width,s.canvas.height),s.ctx.drawImage(s.image,s.fromX,s.fromY,s.fromWidth,s.fromHeight,e,i,s.canvas.width,s.canvas.height),jQuery(s.canvas).css({cursor:"default"})):(s.enableManual=!0,s.ctx.drawImage(s.image,s.fromX,s.fromY,s.fromWidth,s.fromHeight,0,0,s.canvas.width,s.canvas.height),jQuery(s.canvas).css({cursor:"grab"})),wppaIsFs()?(s.fsMaskTop=i-(s.canvas.height-screen.height)/2,s.fsMaskLeft=e-(s.canvas.width-screen.width)/2,s.fsMaskBottom=screen.height-s.fsMaskTop,s.fsMaskRight=screen.width-s.fsMaskLeft):(s.fsMaskTop=0,s.fsMaskLeft=0,s.fsMaskBottom=0,s.fsMaskRight=0),s.ctrlbarUpdate&&(wppaAdjustControlbar(),s.ctrlbarUpdate=!1),s.busy=!1,wppaIsElementInViewport(s.canvas)||(s.buttondown=!1),l(t,s),s.pause||!s.manual&&!s.buttondown||setTimeout(function(){h(t)},10),s.pause&&l(t,{pause:!1}))))}function a(t,a){var n,o=l(t);if(o){if(o.isLightbox){p("#wppa-overlay-zpc").css("display","");var e,i,s,r=!wppaIsFs(),c=r?(e=window.innerWidth||screen.width,window.innerHeight||screen.height):(e=screen.width,screen.height),d=0,u=8,m=8+(o.controls?o.icsize+10:0)+10;r?(u+=2*o.borderWidth,m+=2*o.borderWidth):u=40,n=r?c-m>(e-u)/o.imageRatio:(screenRatio=screen.width/screen.height,screenRatio<o.imageRatio),r&&n&&(d=(c-(s=(i=e-u)/o.imageRatio)-m)/2+20),r&&!n&&(s=(i=o.imageRatio*(c-(o.controls?o.icsize:0)-48))/o.imageRatio,d=20),!r&&n&&(i=(s=screen.height)*o.imageRatio,d=0),r||n||(s=(i=screen.width)/o.imageRatio,d=(screen.height-s)/2),p("#wppa-ovl-zoom-container").css({top:d}),p("#wppa-overlay-zpc").css({top:0,left:0}),o.canvasWidth=i,o.canvasHeight=s,o.canvas.width=o.canvasWidth,o.canvas.height=o.canvasHeight,r?(p("#wppa-ovl-zoom-container").css({backgroundColor:o.backgroundColor,padding:o.padding,borderRadius:o.borderRadius+"px",borderWidth:o.borderWidth+"px",width:i,marginLeft:0}),n?p("#wppa-overlay-zpc").css({left:4}):p("#wppa-overlay-zpc").css({left:(e-i)/2})):(p("#wppa-overlay-zpc").css({marginLeft:0}),p("#wppa-ovl-zoom-container").css({backgroundColor:"transparent",padding:0,borderRadius:"0px",borderWidth:"0px",width:i,left:(e-i)/2,position:"fixed"})),o.ctrlbarUpdate=!0}else{if("force"!=a&&o.canvasWidth==p(o.div).parent().width())return;o.canvasWidth=p(o.div).parent().width(),o.canvasHeight=o.canvasWidth/o.imageRatio,o.canvas.width=o.canvasWidth,o.canvas.height=o.canvasHeight,o.ctrlbarUpdate=!0}l(t,o),setTimeout(function(){h(t)},1),p("#wppa-ovl-zoom-container").show()}}function e(t){var a=l(t),a=a.image.naturalWidth/a.canvas.width;a<1.5&&(a=1.5),l(t,{deltaX:a*=1.5,buttondown:!0,manual:!1}),h(t)}function i(t){var a=l(t),a=a.image.naturalWidth/a.canvas.width;a<1.5&&(a=1.5),l(t,{deltaX:-(a*=1.5),buttondown:!0,manual:!1}),h(t)}function s(t){var a=l(t),a=a.image.naturalHeight/a.canvas.height;a<1.5&&(a=1.5),l(t,{deltaY:-(a*=1.5),buttondown:!0,manual:!1}),h(t)}function r(t){var a=l(t),a=a.image.naturalHeight/a.canvas.height;a<1.5&&(a=1.5),l(t,{deltaY:a*=1.5,buttondown:!0,manual:!1}),h(t)}function c(t){l(t,{deltaFactor:1.005,buttondown:!0,manual:!1}),h(t)}function u(t){l(t,{deltaFactor:.995,buttondown:!0,manual:!1}),h(t)}function m(t){l(t,{deltaX:0,deltaY:0,deltaFactor:1,buttondown:!1})}function f(t,a){var n=l(t),o=g(a).X,e=g(a).Y;if(wppaIsFs()&&n.isLightbox&&(o<n.fsMaskLeft||o>n.fsMaskRight||e<n.fsMaskTop||e>n.fsMaskBottom))return l(0,{abort:!0}),void jQuery("#wppa-overlay-bg").trigger("click");n.enableManual&&(l(t,{manual:!0,savedCanvasX:o=b(t,a).X,savedCanvasY:e=b(t,a).Y,buttondown:!1}),h(t))}function w(t,a){a.preventDefault(),a.stopPropagation();var n,o=l(t),e=b(t,a).X,i=b(t,a).Y;o.manual&&(n=o.canvas.width/o.fromWidth,a=(o.savedCanvasX-e)/n+o.fromX,n=(o.savedCanvasY-i)/n+o.fromY,0<a&&0<n&&a+o.fromWidth<o.image.width&&n+o.fromHeight<o.image.height&&l(t,{fromX:a,fromY:n,savedCanvasX:e,savedCanvasY:i}))}function v(t){l(t,{manual:!1})}function l(t,a){if(!wppaZoomData[t])return!1;if(a)for(var n in a)wppaZoomData[t][n]=a[n];return wppaZoomData[t]}function g(t){var a;return t=t.touches?(a=t.touches[0].screenX,t.touches[0].screenY):(a=t.screenX,t.screenY),{X:a,Y:t}}function b(t,a){var n;return a=a.touches?(t=l(t),n=a.touches[0].screenX-t.fsMaskLeft,a.touches[0].screenY-t.fsMaskTop):(n=a.offsetX,a.offsetY),{X:n,Y:a}}function Y(){return d=new Date,d.getTime()}o.manual=!1,o.deltaX=0,o.deltaY=0,o.deltaFactor=1,o.busy=!1,o.div=p("#wppa-pan-div-"+o.itemId),o.canvas=document.getElementById("wppa-pan-canvas-"+o.itemId),o.left=p("#wppa-pctl-left-"+o.itemId),o.right=p("#wppa-pctl-right-"+o.itemId),o.up=p("#wppa-pctl-up-"+o.itemId),o.down=p("#wppa-pctl-down-"+o.itemId),o.zoomin=p("#wppa-pctl-zoomin-"+o.itemId),o.zoomout=p("#wppa-pctl-zoomout-"+o.itemId),o.prev=p("#wppa-pctl-prev-"+o.itemId),o.next=p("#wppa-pctl-next-"+o.itemId),o.exit=p("#wppa-exit-btn-2"),o.canvasWidth=o.width,o.canvasHeight=o.height,o.savedCanvasX=0,o.savedCanvasY=0,o.fromHeight=o.image.height,o.fromWidth=o.image.width,o.imageRatio=o.image.width/o.image.height,o.fromX=0,o.fromY=0,o.centerX=o.fromX+o.fromWidth/2,o.centerY=o.fromY+o.fromHeight/2,o.ctx=null,o.buttondown=!1,o.enableManual=!0,o.ctrlbarUpdate=!0,o.pause=!1,o.time=0,o.right.on("touchstart",function(t){e(n)}),o.right.on("touchend",function(t){m(n)}),o.left.on("touchstart",function(t){i(n)}),o.left.on("touchend",function(t){m(n)}),o.up.on("touchstart",function(t){s(n)}),o.up.on("touchend",function(t){m(n)}),o.down.on("touchstart",function(t){r(n)}),o.down.on("touchend",function(t){m(n)}),o.zoomin.on("touchstart",function(t){c(n)}),o.zoomin.on("touchend",function(t){m(n)}),o.zoomout.on("touchstart",function(t){u(n)}),o.zoomout.on("touchend",function(t){m(n)}),o.canvas.addEventListener("touchstart",function(t){f(n,t)}),o.canvas.addEventListener("touchmove",function(t){w(n,t)}),o.canvas.addEventListener("touchend",function(t){v(n)}),o.canvas.addEventListener("mousedown",function(t){f(n,t)}),o.canvas.addEventListener("mousemove",function(t){w(n,t)}),o.canvas.addEventListener("mouseup",function(t){v(n)}),o.canvas.addEventListener("mouseleave",function(t){(o=l(n)).manual&&l(n,{pause:!0})}),o.canvas.addEventListener("mouseenter",function(t){var a;l(a=n,{pause:!1}).manual&&h(a)}),document.getElementById("wppa-pan-canvas-"+o.itemId).addEventListener("wheel",function(t){var a;a=n,(t=t).preventDefault(),t.stopPropagation(),o=l(a),l(a,{deltaFactor:1+t.deltaY*o.zoomsensitivity/1e4,manual:!1,burrondown:!1}),h(a),setTimeout(function(){l(a,{deltaFactor:1})},25)}),o.right.on("mousedown",function(t){e(n)}),o.right.on("mouseup",function(t){m(n)}),o.left.on("mousedown",function(t){i(n)}),o.left.on("mouseup",function(t){m(n)}),o.up.on("mousedown",function(t){s(n)}),o.up.on("mouseup",function(t){m(n)}),o.down.on("mousedown",function(t){r(n)}),o.down.on("mouseup",function(t){m(n)}),o.zoomin.off("mousedown"),o.zoomin.on("mousedown",function(t){c(n)}),o.zoomin.off("mouseup"),o.zoomin.on("mouseup",function(t){m(n)}),o.zoomout.on("mousedown",function(t){u(n)}),o.zoomout.on("mouseup",function(t){m(n)}),o.isLightbox&&(p("body").on("quitimage",function(t){o=l(n,{abort:!0}),p(o.canvas).hide(),p("#wppa-pctl-div-"+o.itemId).hide(),p("#wppa-ovl-zoom-container").hide()}),p("#wppa-pctl-div-"+o.itemId).on("click",function(t){wppaKillEvent(t)})),o.isLightbox?(p(window).off("resize",wppaOvlShowSame),p(window).on("resize",wppaOvlShowSame)):p(window).on("wpparesizeend",function(t){a(n,t)}),a(n,"force"),o.initialized=!0,l(n,o),p("#wppa-ovl-spin").hide(),wppaProtect()}
|
17 |
// wppa-spheric
|
18 |
var wppaJsSphericVersion="8.1.09.001";function wppaDoSphericPan(n,e){var t;e&&((t=new Image).src=e.url,t.onload=function(){_wppaDoSphericPan(n,e)})}function _wppaDoSphericPan(t,n){var s=jQuery;n&&(wppaSphericData[t]=n);var w=f(t,w);function l(n){var e=f(n);!e.manCtrl&&b()<e.time+25||(f(n,{time:b()}),e.isLightbox&&(!wppaOvlOpen||wppaOvlActivePanorama!=e.id||wppaGlobalOvlPanoramaId>e.uId)&&(abort=!0),e.abort||((e.butDown||e.manCtrl)&&e.autorun&&(e.autorun=!1,e.dX=0),0==e.dX&&0==e.dY&&0==e.dFov&&(e.pause=!0),e.butDown&&(e.pause=!1),e.fov+=e.dFov,e.fov=Math.max(20,Math.min(120,e.fov)),e.wppaCamera=new THREE.PerspectiveCamera(e.fov,e.aspect,1,1e3),e.wppaCamera.target=new THREE.Vector3(0,0,0),e.lon+=e.dX,e.lat+=e.dY,e.lat=Math.max(-85,Math.min(85,e.lat)),e.wppaCamera.target.x=500*Math.sin(THREE.Math.degToRad(90-e.lat))*Math.cos(THREE.Math.degToRad(e.lon)),e.wppaCamera.target.y=500*Math.cos(THREE.Math.degToRad(90-e.lat)),e.wppaCamera.target.z=500*Math.sin(THREE.Math.degToRad(90-e.lat))*Math.sin(THREE.Math.degToRad(e.lon)),e.wppaCamera.lookAt(e.wppaCamera.target),e.wppaRenderer&&e.wppaRenderer.render(e.wppaScene,e.wppaCamera),wppaAdjustControlbar(),s("#wppa-ovl-spin").hide(),e.manCtrl,(e.autorun||!e.pause&&(e.manCtrl||e.butDown))&&e.wppaRenderer&&(e.timer=setTimeout(function(){l(n)},25)),f(n,e)))}function e(n,e){var t=!wppaIsFs();if(w=f(n)){if(w.isLightbox){if(!wppaOvlOpen)return;s("#wppa-overlay-pc").show(),s("#wppa-overlay-pc").css("width","");var a,o,p=(t=!wppaIsFs())?(o=window.innerWidth||screen.width,window.innerHeight||screen.height):(o=screen.width,screen.height),i=8,r=8+(w.controls?w.icsize+10:0)+30;t&&(i+=2*w.borderWidth,r+=2*w.borderWidth),a=(o-i)/2+r<p,r=t?a?(p-(c=(u=o-i)/2)-r)/2+20:(u=2*(c=p-r),20):(u=screen.width,c=screen.height,0),w.aspect=u/c,s("#wppa-ovl-sphericpan-container").css({top:r}),s("#wppa-overlay-pc").css({top:0}),t?(s("#wppa-ovl-sphericpan-container").css({backgroundColor:w.backgroundColor,padding:w.padding+"px",borderRadius:w.borderRadius+"px",width:u}),a?s("#wppa-overlay-pc").css({left:4}):s("#wppa-overlay-pc").css({left:(o-u)/2})):s("#wppa-ovl-sphericpan-container").css({backgroundColor:"transparent",padding:0,borderRadius:"0px",width:u,left:(o-u)/2}),w.wppaRenderer.setSize(u,c)}else{if("force"!=e&&0<w.width&&w.width==u&&w.height==c)return;var u=s(w.div).parent().width(),c=parseInt(u/2);if(!w.wppaRenderer)return;w.wppaRenderer.setSize(u,c)}w.width=u,w.height=c,f(n,w),w.timer=setTimeout(function(){l(n)},250)}}function a(n,e){e.preventDefault(),e.stopPropagation(),w=f(n,{manCtrl:!0,butDown:!1,autorun:!1,dX:0}),e.touches?f(n,{sX:e.touches[0].clientX,sY:e.touches[0].clientY}):f(n,{sX:e.clientX,sY:e.clientY}),f(n,{sLon:w.lon,sLat:w.lat}),l(n)}function o(n,e){e.preventDefault(),e.stopPropagation(),(w=f(n)).manCtrl&&(e.touches?f(n,{lon:.1*(w.sX-e.touches[0].clientX)+w.sLon,lat:.1*(e.touches[0].clientY-w.sY)+w.sLat,pause:!1}):f(n,{lon:.1*(w.sX-e.clientX)+w.sLon,lat:.1*(e.clientY-w.sY)+w.sLat,pause:!1}),l(n))}function p(n){f(n,{manCtrl:!1})}function i(n){w=f(n),f(n,{dFov:-.4*w.mFakt,butDown:!0}),l(n)}function r(n){w=f(n),f(n,{dFov:.4*w.mFakt,butDown:!0}),l(n)}function u(n){w=f(n),f(n,{dX:.2*w.mFakt,butDown:!0}),l(n)}function c(n){w=f(n),f(n,{dX:-.2*w.mFakt,butDown:!0}),l(n)}function h(n){w=f(n),f(n,{dY:.2*w.mFakt,butDown:!0}),l(n)}function m(n){w=f(n),f(n,{dY:-.2*w.mFakt,butDown:!0}),l(n)}function v(n){w=f(n),f(n,{dX:0,dY:0,dFov:0,butDown:!1,manCtrl:!1})}function f(n,e){if(!wppaSphericData[n])return!1;if(e)for(var t in e)wppaSphericData[n][t]=e[t];return wppaSphericData[n]}function b(){return d=new Date,d.getTime()}w.initialized||w.abort||w.isLightbox&&!wppaOvlOpen||(w.wppaRenderer&&(w.wppaRenderer.state.reset(),w.wppaSphere.dispose(),w.wppaSphereMaterial.dispose(),w.texture.dispose()),w.isLightbox&&wppaOvlOpen&&(s("#wppa-ovl-spin").show(),s("#wppa-overlay-ic").html("")),w.manCtrl=!1,w.butDown=!1,w.lon=180,w.lat=0,w.dFov=0,w.abort=!1,w.aspect=2,w.div=s("#wppa-pan-div-"+t),w.left=s("#wppa-pctl-left-"+t),w.right=s("#wppa-pctl-right-"+t),w.up=s("#wppa-pctl-up-"+t),w.down=s("#wppa-pctl-down-"+t),w.zoomin=s("#wppa-pctl-zoomin-"+t),w.zoomout=s("#wppa-pctl-zoomout-"+t),w.prev=s("#wppa-pctl-prev-"+t),w.next=s("#wppa-pctl-next-"+t),w.pause=!1,w.mFakt=wppaIsMobile?"2":"1",w.time=0,w.isLightbox&&(wppaGlobalOvlPanoramaId++,w.uId=wppaGlobalOvlPanoramaId),s(w.div).html(""),w.wppaRenderer||(w.wppaRenderer=new THREE.WebGLRenderer),w.wppaRenderer.setSize(w.width,w.height),s(w.div).append(w.wppaRenderer.domElement),w.wppaScene=new THREE.Scene,w.wppaSphere=new THREE.SphereGeometry(100,100,40),w.wppaSphere.applyMatrix4((new THREE.Matrix4).makeScale(-1,1,1)),w.texture=(new THREE.TextureLoader).load(w.url),w.wppaSphereMaterial=new THREE.MeshBasicMaterial({map:w.texture}),w.wppaSphereMesh=new THREE.Mesh(w.wppaSphere,w.wppaSphereMaterial),w.wppaScene.add(w.wppaSphereMesh),w.right.on("touchstart",function(n){u(t)}),w.right.on("touchend",function(n){v(t)}),w.left.on("touchstart",function(n){c(t)}),w.left.on("touchend",function(n){v(t)}),w.up.on("touchstart",function(n){h(t)}),w.up.on("touchend",function(n){v(t)}),w.down.on("touchstart",function(n){m(t)}),w.down.on("touchend",function(n){v(t)}),w.zoomin.on("touchstart",function(n){i(t)}),w.zoomin.on("touchend",function(n){v(t)}),w.zoomout.on("touchstart",function(n){r(t)}),w.zoomout.on("touchend",function(n){v(t)}),w.enableManual&&0<s("#wppa-pan-div-"+t+" canvas").length&&(s("#wppa-pan-div-"+t+" canvas")[0].addEventListener("touchstart",function(n){a(t,n)}),s("#wppa-pan-div-"+t+" canvas")[0].addEventListener("touchmove",function(n){o(t,n)}),s("#wppa-pan-div-"+t+" canvas")[0].addEventListener("touchend",function(n){p(t)})),w.right.on("mousedown",function(n){u(t)}),w.right.on("mouseup",function(n){v(t)}),w.left.on("mousedown",function(n){c(t)}),w.left.on("mouseup",function(n){v(t)}),w.up.on("mousedown",function(n){h(t)}),w.up.on("mouseup",function(n){v(t)}),w.down.on("mousedown",function(n){m(t)}),w.down.on("mouseup",function(n){v(t)}),w.zoomin.off("mousedown"),w.zoomin.on("mousedown",function(n){i(t)}),w.zoomin.off("mouseup"),w.zoomin.on("mouseup",function(n){v(t)}),w.zoomout.on("mousedown",function(n){r(t)}),w.zoomout.on("mouseup",function(n){v(t)}),w.enableManual&&0<s("#wppa-pan-div-"+t+" canvas").length&&(s("#wppa-pan-div-"+t+" canvas").on("mousedown",function(n){a(t,n)}),s("#wppa-pan-div-"+t+" canvas").on("mousemove",function(n){o(t,n)}),s("#wppa-pan-div-"+t+" canvas").on("mouseup",function(n){p(t)}),s("#wppa-pan-div-"+t+" canvas")[0].addEventListener("wheel",function(n){var e;e=t,(n=n).preventDefault(),n.stopPropagation(),w=f(e),f(e,{manCtrl:!1,butDown:!1,autorun:!1,dX:0,dFov:-n.deltaY*w.zoomsensitivity/60}),l(e),setTimeout(function(){f(e,{dFov:0})},25)})),w.isLightbox&&(s("body").on("quitimage",function(n){var e;w=f(e=t,{abort:!0,autorun:!1}),clearTimeout(w.timer),clearInterval(w.intervalTimer),s("#wppa-pan-div-"+e+" canvas").hide(),s("#wppa-pctl-div-"+e).hide(),s("#wppa-overlay-pc").hide()}),s("#wppa-pctl-div-"+t).on("click",function(n){wppaKillEvent(n)})),f(t,w),s(window).on("wpparesizeend",function(n){e(t,n)}),wppaProtect(),s(document).on("tabbychange",function(n){var e;e=t,w.wppaRenderer.state.reset(),w=f(e,{initialized:!1,abort:!0}),setTimeout(function(){f(e,{abort:!1}),wppaDoSphericPan(e)},200)}),e(t,"force"))}
|
19 |
+
// wppa-flatpan
|
20 |
+
var wppaJsFlatPanVersion="8.2.01.001";function wppaDoFlatPanorama(i,t){var u=jQuery;wppaZoomData[i]=t;var a=l(i,{image:document.getElementById("wppa-"+t.itemId)});function s(t){var n,a,o,e=l(t);if(e.canvas){if(e.isLightbox)wppaOvlOpen||(e.abort=!0);else if(!wppaIsElementInViewport(e.canvas))return void setTimeout(function(){s(t)},200);e.abort?l(t,{ctx:null,prevctx:null}):0!=e.run&&(d=new Date,n=d.getTime(),e.autorun&&n<e.wppaFlatLastRenderTime+25||(e.wppaFlatLastRenderTime=n,e.manualControl||(e.fromX+=e.deltaX,e.fromY+=e.deltaY,o=e.fromHeight/e.deltaFactor,a=e.fromWidth/e.deltaFactor,1!=e.deltaFactor&&o<=e.image.height&&50<o&&(e.fromX-=(a-e.fromWidth)/2,e.fromY-=(o-e.fromHeight)/2,e.fromWidth=a,e.fromHeight=o)),e.fromX=Math.max(0,Math.min(e.image.width-e.fromWidth,e.fromX)),e.fromY=Math.max(0,Math.min(e.image.height-e.fromHeight,e.fromY)),e.autorun&&(0!=e.fromX&&e.fromX!=e.image.width-e.fromWidth||(e.deltaX*=-1)),e.canvas.getContext("2d").drawImage(e.image,e.fromX,e.fromY,e.fromWidth,e.fromHeight,0,0,e.canvas.width,e.canvas.height),(a=e.prevCanvas.getContext("2d")).clearRect(0,0,e.prevCanvas.width,e.prevCanvas.height),a.drawImage(e.image,0,0,e.image.width,e.image.height,0,0,e.prevCanvas.width,e.prevCanvas.height),o=e.prevCanvas.width/e.image.width,a.strokeRect(o*e.fromX,o*e.fromY,o*e.fromWidth,o*e.fromHeight),0<e.run&&(timer=setTimeout(function(){s(t)},25)),e.run<5&&e.run--,setTimeout(function(){jQuery("#wppa-pctl-div-"+t).css({visibility:"visible"})},100),l(t,e)))}}function n(t){var n,a,o,e,i,r,d=l(t);d.abort||(d.isLightbox?(u("#wppa-overlay-fpc").css("display",""),e=(a=!wppaIsFs())?(o=window.innerWidth||screen.width,window.innerHeight||screen.height):(o=screen.width,screen.height),i=8,r=24+(d.controls?d.icsize:0)+o*d.height/d.width+40,a&&(i+=2*d.padding,r+=2*d.padding),e=(n=o/2+r<e)?(newWidth=o-i,newHeight=newWidth/2,(e-newHeight-r)/2+20):(newWidth=2*(e-(d.controls?d.icsize:0)-24-40)/(1+2*d.height/d.width),newHeight=newWidth/2,20),u("#wppa-ovl-flatpan-container").css({top:e,marginTop:0}),d.canvas.width=newWidth,d.canvas.height=newHeight,d.prevCanvas.width=newWidth,d.prevCanvas.height=newWidth*d.height/d.width,a?(u("#wppa-ovl-flatpan-container").css({backgroundColor:d.backgroundColor,padding:d.padding,borderRadius:d.borderRadius,width:newWidth,marginLeft:0}),n?u("#wppa-overlay-fpc").css({left:4}):u("#wppa-overlay-fpc").css({left:(o-newWidth)/2})):(u("#wppa-overlay-fpc").css({marginLeft:0}),u("#wppa-ovl-flatpan-container").css({backgroundColor:"transparent",padding:0,borderRadius:0,width:newWidth,left:(o-newWidth)/2})),wppaAdjustControlbar()):(d.canvasWidth=u(d.div).parent().width(),d.canvasHeight=d.canvasWidth/2,d.canvas.width=d.canvasWidth,d.canvas.height=d.canvasHeight,d.prevCanvas.width=d.canvasWidth,d.prevCanvas.height=d.canvasWidth*d.height/d.width),d.run=d.autorun?5:4,l(t,d),s(t))}function o(t){l(t,{autorun:!1,run:5,deltaX:3,deltaY:0}),s(t)}function e(t){l(t,{autorun:!1,run:5,deltaX:-3,deltaY:0}),s(t)}function r(t){l(t,{autorun:!1,run:5,deltaX:0,deltaY:-3}),s(t)}function f(t){l(t,{autorun:!1,run:5,deltaX:0,deltaY:3}),s(t)}function p(t){l(t,{deltaX:0,deltaY:0,autorun:!1,run:5,deltaFactor:1.005}),s(t)}function c(t){l(t,{deltaX:0,deltaY:0,autorun:!1,run:5,deltaFactor:.995}),s(t)}function m(t,n){n.preventDefault(),l(t,{autorun:!1,deltaX:0,deltaY:0,deltaFactor:1,run:4})}function h(t,n){n.preventDefault(),l(t,{manualControl:!0,autorun:!1,deltaX:0,savedCanvasX:n.offsetX,savedCanvasY:n.offsetY,run:5}),s(t)}function v(t){l(t).manualControl&&l(t,{run:4,manualControl:!1})}function l(t,n){if(!wppaZoomData[t])return!1;if(n)for(var a in n)wppaZoomData[t][a]=n[a];return wppaZoomData[t]}a.manualControl=!1,a.deltaY=0,a.deltaFactor=1,a.run=a.deltaX?5:4,a.abort=!1,a.div=u("#wppa-pan-div-"+i),a.canvas=document.getElementById("wppa-pan-canvas-"+i),a.prevCanvas=document.getElementById("wppa-pan-prev-canvas-"+i),a.left=u("#wppa-pctl-left-"+i),a.right=u("#wppa-pctl-right-"+i),a.up=u("#wppa-pctl-up-"+i),a.down=u("#wppa-pctl-down-"+i),a.zoomin=u("#wppa-pctl-zoomin-"+i),a.zoomout=u("#wppa-pctl-zoomout-"+i),a.prev=u("#wppa-pctl-prev-"+i),a.next=u("#wppa-pctl-next-"+i),a.canvasWidth=u(a.div).parent().width(),a.canvasHeight=a.canvasWidth/2,a.savedCanvasX=0,a.savedCanvasY=0,a.fromHeight=a.image.height/2,a.fromWidth=2*a.fromHeight,a.fromX=(a.image.width-a.fromWidth)/2,a.fromY=(a.image.height-a.fromHeight)/2,a.centerX=a.fromX+a.fromWidth/2,a.centerY=a.fromY+a.fromHeight/2,a.wppaFlatLastRenderTime=0,a.right.on("touchstart",function(t){o(i)}),a.right.on("touchend",function(t){m(i,t)}),a.left.on("touchstart",function(t){e(i)}),a.left.on("touchend",function(t){m(i,t)}),a.up.on("touchstart",function(t){r(i)}),a.up.on("touchend",function(t){m(i,t)}),a.down.on("touchstart",function(t){f(i)}),a.down.on("touchend",function(t){m(i,t)}),a.zoomin.on("touchstart",function(t){p(i)}),a.zoomin.on("touchend",function(t){m(i,t)}),a.zoomout.on("touchstart",function(t){c(i)}),a.zoomout.on("touchend",function(t){m(i,t)}),a.manual&&(a.canvas.addEventListener("mousedown",function(t){h(i,t)}),a.canvas.addEventListener("mousemove",function(t){var n,a,o,e;a=t,(e=l(n=i)).manualControl&&(l(n,{autorun:!1,deltaX:0}),o=e.canvas.width/e.fromWidth,t=(e.savedCanvasX-a.offsetX)/o+e.fromX,o=(e.savedCanvasY-a.offsetY)/o+e.fromY,0<t&&0<o&&t+e.fromWidth<e.image.width&&o+e.fromHeight<e.image.height&&l(n,{fromX:t,fromY:o,savedCanvasX:a.offsetX,savedCanvasY:a.offsetY}))}),a.canvas.addEventListener("mouseup",function(t){v(i)}),a.canvas.addEventListener("mouseout",function(t){v(i)}),document.getElementById("wppa-pan-canvas-"+i).addEventListener("wheel",function(t){!function(t,n){n.preventDefault(),n.stopPropagation();var a=l(t);l(t,{deltaX:0,deltaY:0,autorun:!1,run:4,deltaFactor:1+n.deltaY*a.zoomsensitivity/1e4}),s(t),setTimeout(function(){l(t,{deltaFactor:1})},25)}(i,t)}),a.prevCanvas.addEventListener("mousedown",function(t){h(i,t)}),a.prevCanvas.addEventListener("mousemove",function(t){var n,a,o;a=t,o=l(n=i),t=o.prevCanvas.width/o.image.width,a.offsetX>t*o.fromX&&a.offsetX<t*(o.fromX+o.fromWidth)&&a.offsetY>t*o.fromY&&a.offsetY<t*(o.fromY+o.fromHeight)?u(o.prevCanvas).css("cursor","grab"):u(o.prevCanvas).css("cursor","default"),o.manualControl&&(o.autorun=!1,o.deltaX=0,a.offsetX>t*o.fromX&&a.offsetX<t*(o.fromX+o.fromWidth)&&a.offsetY>t*o.fromY&&a.offsetY<t*(o.fromY+o.fromHeight)&&(o.fromX=(a.offsetX-o.savedCanvasX)/t+o.fromX,o.fromY=(a.offsetY-o.savedCanvasY)/t+o.fromY,o.savedCanvasX=a.offsetX,o.savedCanvasY=a.offsetY)),l(n,o)}),a.prevCanvas.addEventListener("mouseup",function(t){v(i)}),a.prevCanvas.addEventListener("mouseout",function(t){v(i)})),a.right.on("mousedown",function(t){o(i)}),a.right.on("mouseup",function(t){m(i,t)}),a.left.on("mousedown",function(t){e(i)}),a.left.on("mouseup",function(t){m(i,t)}),a.up.on("mousedown",function(t){r(i)}),a.up.on("mouseup",function(t){m(i,t)}),a.down.on("mousedown",function(t){f(i)}),a.down.on("mouseup",function(t){m(i,t)}),a.zoomin.on("mousedown",function(t){p(i)}),a.zoomin.on("mouseup",function(t){m(i,t)}),a.zoomout.on("mousedown",function(t){c(i)}),a.zoomout.on("mouseup",function(t){m(i,t)}),a.isLightbox&&(u("body").on("quitimage",function(t){var n;a=l(n=i,{abort:!0,run:0,autorun:!1}),clearTimeout(a.timer),u(a.canvas).hide(),u(a.prevCanvas).hide(),u("#wppa-pctl-div-"+n).hide()}),u("#wppa-pctl-div-"+a.itemId).on("click",function(t){wppaKillEvent(t)})),a.isLightbox?(u(window).off("resize",wppaOvlShowSame),u(window).on("resize",wppaOvlShowSame)):u(window).on("wpparesizeend",function(t){n(i)}),l(i,a),n(i),u("#wppa-ovl-spin").hide(),wppaProtect()}
|
js/wppa-flatpan.js
ADDED
@@ -0,0 +1,553 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
// wppa-flatpan.js
|
2 |
+
//
|
3 |
+
// contains wppa functions for flat panorama images
|
4 |
+
//
|
5 |
+
var wppaJsFlatPanVersion = '8.2.01.001';
|
6 |
+
|
7 |
+
// The main proccedure
|
8 |
+
function wppaDoFlatPanorama(mocc, xdata) {
|
9 |
+
|
10 |
+
// Handy shorthand
|
11 |
+
var $ = jQuery;
|
12 |
+
|
13 |
+
// Store the data
|
14 |
+
wppaZoomData[mocc] = xdata;
|
15 |
+
|
16 |
+
// Update data with image
|
17 |
+
var data = update(mocc,{image:document.getElementById( "wppa-"+xdata.itemId )});
|
18 |
+
|
19 |
+
// Find additional data
|
20 |
+
data.manualControl = false;
|
21 |
+
data.deltaY = 0;
|
22 |
+
data.deltaFactor = 1.0;
|
23 |
+
data.run = data.deltaX ? 5 : 4;
|
24 |
+
data.abort = false;
|
25 |
+
data.div = $("#wppa-pan-div-"+mocc);
|
26 |
+
data.canvas = document.getElementById("wppa-pan-canvas-"+mocc);
|
27 |
+
data.prevCanvas = document.getElementById("wppa-pan-prev-canvas-"+mocc);
|
28 |
+
data.left = $("#wppa-pctl-left-"+mocc);
|
29 |
+
data.right = $("#wppa-pctl-right-"+mocc);
|
30 |
+
data.up = $("#wppa-pctl-up-"+mocc);
|
31 |
+
data.down = $("#wppa-pctl-down-"+mocc);
|
32 |
+
data.zoomin = $("#wppa-pctl-zoomin-"+mocc);
|
33 |
+
data.zoomout = $("#wppa-pctl-zoomout-"+mocc);
|
34 |
+
data.prev = $("#wppa-pctl-prev-"+mocc);
|
35 |
+
data.next = $("#wppa-pctl-next-"+mocc);
|
36 |
+
data.canvasWidth = $(data.div).parent().width();
|
37 |
+
data.canvasHeight = data.canvasWidth / 2;
|
38 |
+
data.savedCanvasX = 0;
|
39 |
+
data.savedCanvasY = 0;
|
40 |
+
data.fromHeight = data.image.height / 2;
|
41 |
+
data.fromWidth = data.fromHeight * 2;
|
42 |
+
data.fromX = ( data.image.width - data.fromWidth ) / 2,
|
43 |
+
data.fromY = ( data.image.height - data.fromHeight ) / 2,
|
44 |
+
data.centerX = data.fromX + data.fromWidth / 2,
|
45 |
+
data.centerY = data.fromY + data.fromHeight / 2,
|
46 |
+
data.wppaFlatLastRenderTime = 0;
|
47 |
+
|
48 |
+
// Install listeners
|
49 |
+
data.right.on("touchstart", function(e){rightDown(mocc, e)});
|
50 |
+
data.right.on("touchend", function(e){buttonUp(mocc, e)});
|
51 |
+
data.left.on("touchstart", function(e){leftDown(mocc, e)});
|
52 |
+
data.left.on("touchend", function(e){buttonUp(mocc, e)});
|
53 |
+
data.up.on("touchstart", function(e){upDown(mocc, e)});
|
54 |
+
data.up.on("touchend", function(e){buttonUp(mocc, e)});
|
55 |
+
data.down.on("touchstart", function(e){downDown(mocc, e)});
|
56 |
+
data.down.on("touchend", function(e){buttonUp(mocc, e)});
|
57 |
+
data.zoomin.on("touchstart", function(e){zoomInDown(mocc, e)});
|
58 |
+
data.zoomin.on("touchend", function(e){buttonUp(mocc, e)});
|
59 |
+
data.zoomout.on("touchstart", function(e){zoomOutDown(mocc, e)});
|
60 |
+
data.zoomout.on("touchend", function(e){buttonUp(mocc, e)});
|
61 |
+
|
62 |
+
if ( data.manual ) {
|
63 |
+
data.canvas.addEventListener("mousedown", function(e){onCanvasMouseDown(mocc, e)});
|
64 |
+
data.canvas.addEventListener("mousemove", function(e){onCanvasMouseMove(mocc, e)});
|
65 |
+
data.canvas.addEventListener("mouseup", function(e){onCanvasMouseUp(mocc, e)});
|
66 |
+
data.canvas.addEventListener("mouseout", function(e){onCanvasMouseUp(mocc, e)});
|
67 |
+
document.getElementById("wppa-pan-canvas-"+mocc).addEventListener("wheel", function(e){onDivWheel(mocc, e)});
|
68 |
+
data.prevCanvas.addEventListener("mousedown", function(e){onCanvasMouseDown(mocc, e)});
|
69 |
+
data.prevCanvas.addEventListener("mousemove", function(e){onPrevCanvasMouseMove(mocc, e)});
|
70 |
+
data.prevCanvas.addEventListener("mouseup", function(e){onCanvasMouseUp(mocc, e)});
|
71 |
+
data.prevCanvas.addEventListener("mouseout", function(e){onCanvasMouseUp(mocc, e)});
|
72 |
+
}
|
73 |
+
|
74 |
+
data.right.on("mousedown", function(e){rightDown(mocc, e)});
|
75 |
+
data.right.on("mouseup", function(e){buttonUp(mocc, e)});
|
76 |
+
data.left.on("mousedown", function(e){leftDown(mocc, e)});
|
77 |
+
data.left.on("mouseup", function(e){buttonUp(mocc, e)});
|
78 |
+
data.up.on("mousedown", function(e){upDown(mocc, e)});
|
79 |
+
data.up.on("mouseup", function(e){buttonUp(mocc, e)});
|
80 |
+
data.down.on("mousedown", function(e){downDown(mocc, e)});
|
81 |
+
data.down.on("mouseup", function(e){buttonUp(mocc, e)});
|
82 |
+
data.zoomin.on("mousedown", function(e){zoomInDown(mocc, e)});
|
83 |
+
data.zoomin.on("mouseup", function(e){buttonUp(mocc, e)});
|
84 |
+
data.zoomout.on("mousedown", function(e){zoomOutDown(mocc, e)});
|
85 |
+
data.zoomout.on("mouseup", function(e){buttonUp(mocc, e)});
|
86 |
+
|
87 |
+
// Common event handlers
|
88 |
+
if ( data.isLightbox ) {
|
89 |
+
$("body").on("quitimage", function(e){quitImage(mocc,e)});
|
90 |
+
$("#wppa-pctl-div-"+data.itemId).on("click", function(e){wppaKillEvent(e)});
|
91 |
+
}
|
92 |
+
|
93 |
+
// Install Resize handler
|
94 |
+
if ( data.isLightbox ) {
|
95 |
+
$(window).off("resize",wppaOvlShowSame);
|
96 |
+
$(window).on("resize",wppaOvlShowSame);
|
97 |
+
}
|
98 |
+
else {
|
99 |
+
$(window).on("wpparesizeend",function(e){resize(mocc,e)});
|
100 |
+
}
|
101 |
+
|
102 |
+
// Store data
|
103 |
+
update(mocc,data);
|
104 |
+
|
105 |
+
// Resize
|
106 |
+
resize(mocc,'force');
|
107 |
+
|
108 |
+
// Remove spinner
|
109 |
+
$("#wppa-ovl-spin").hide();
|
110 |
+
|
111 |
+
// Optionally disable rightclick
|
112 |
+
wppaProtect();
|
113 |
+
|
114 |
+
// The render function
|
115 |
+
function render(mocc) {
|
116 |
+
|
117 |
+
var data = update(mocc);
|
118 |
+
|
119 |
+
if ( ! data.canvas ) {
|
120 |
+
return;
|
121 |
+
}
|
122 |
+
|
123 |
+
if ( data.isLightbox ) {
|
124 |
+
if (!wppaOvlOpen) {
|
125 |
+
data.abort=true;
|
126 |
+
}
|
127 |
+
}
|
128 |
+
else {
|
129 |
+
if (!wppaIsElementInViewport(data.canvas)) {
|
130 |
+
|
131 |
+
setTimeout(function(){render(mocc)},200);
|
132 |
+
return;
|
133 |
+
}
|
134 |
+
}
|
135 |
+
|
136 |
+
if ( data.abort ) {
|
137 |
+
update(mocc,{
|
138 |
+
ctx :null,
|
139 |
+
prevctx :null
|
140 |
+
});
|
141 |
+
return;
|
142 |
+
}
|
143 |
+
|
144 |
+
if (data.run==0) {
|
145 |
+
return;
|
146 |
+
}
|
147 |
+
|
148 |
+
// Duplicate loops?
|
149 |
+
var curTime = timnow();
|
150 |
+
if ( data.autorun && curTime < data.wppaFlatLastRenderTime + 25 ) {
|
151 |
+
return;
|
152 |
+
}
|
153 |
+
data.wppaFlatLastRenderTime = curTime;
|
154 |
+
|
155 |
+
// manualControl is true when a drag on the canvas is being performed
|
156 |
+
if(!data.manualControl){
|
157 |
+
|
158 |
+
// Panning
|
159 |
+
data.fromX += data.deltaX;
|
160 |
+
data.fromY += data.deltaY;
|
161 |
+
|
162 |
+
// Zooming
|
163 |
+
var newHeight = data.fromHeight / data.deltaFactor;
|
164 |
+
var newWidth = data.fromWidth / data.deltaFactor;
|
165 |
+
|
166 |
+
// Keep zooming in range
|
167 |
+
if ( data.deltaFactor != 1 && newHeight <= data.image.height && newHeight > 50 ) {
|
168 |
+
data.fromX -= ( newWidth - data.fromWidth ) / 2;
|
169 |
+
data.fromY -= ( newHeight - data.fromHeight ) / 2;
|
170 |
+
data.fromWidth = newWidth;
|
171 |
+
data.fromHeight = newHeight;
|
172 |
+
}
|
173 |
+
}
|
174 |
+
|
175 |
+
// Keep viewport within image boundaries
|
176 |
+
data.fromX = Math.max(0, Math.min(data.image.width - data.fromWidth, data.fromX));
|
177 |
+
data.fromY = Math.max(0, Math.min(data.image.height - data.fromHeight, data.fromY));
|
178 |
+
|
179 |
+
// Check for turningpoint in case autrun
|
180 |
+
if ( data.autorun ) {
|
181 |
+
if ( data.fromX == 0 || data.fromX == ( data.image.width - data.fromWidth ) ) {
|
182 |
+
data.deltaX *= -1;
|
183 |
+
}
|
184 |
+
}
|
185 |
+
|
186 |
+
// Draw the image
|
187 |
+
var ctx = data.canvas.getContext("2d");
|
188 |
+
ctx.drawImage(data.image, data.fromX, data.fromY, data.fromWidth, data.fromHeight, 0, 0, data.canvas.width, data.canvas.height);
|
189 |
+
|
190 |
+
// Draw the preview image
|
191 |
+
var prevctx = data.prevCanvas.getContext("2d");
|
192 |
+
prevctx.clearRect(0, 0, data.prevCanvas.width, data.prevCanvas.height);
|
193 |
+
prevctx.drawImage(data.image, 0, 0, data.image.width, data.image.height, 0, 0, data.prevCanvas.width, data.prevCanvas.height);
|
194 |
+
|
195 |
+
// Draw viewport rect on preview image
|
196 |
+
var factor = data.prevCanvas.width / data.image.width;
|
197 |
+
prevctx.strokeRect(factor * data.fromX, factor * data.fromY, factor * data.fromWidth, factor * data.fromHeight);
|
198 |
+
|
199 |
+
// Re-render if needed
|
200 |
+
if (data.run>0) {
|
201 |
+
timer = setTimeout(function(){render(mocc)},25);
|
202 |
+
}
|
203 |
+
if (data.run<5)data.run--;
|
204 |
+
|
205 |
+
// Make controlbar visible
|
206 |
+
setTimeout(function(){jQuery("#wppa-pctl-div-"+mocc).css({visibility:"visible"});}, 100);
|
207 |
+
|
208 |
+
update(mocc,data);
|
209 |
+
}
|
210 |
+
|
211 |
+
// When a (responsive) resize is required, we resize the wppaScene
|
212 |
+
function resize(mocc,e) {
|
213 |
+
|
214 |
+
var data = update(mocc);
|
215 |
+
|
216 |
+
if (data.abort) return;
|
217 |
+
|
218 |
+
if ( data.isLightbox) {
|
219 |
+
|
220 |
+
// Show image container
|
221 |
+
$("#wppa-overlay-fpc").css("display", "");
|
222 |
+
|
223 |
+
// There are 4 possiblilities: all combi of 'Width is the limit or not' and 'Mode is normal or fullscreen'
|
224 |
+
var widthIsLim,
|
225 |
+
modeIsNormal = ! wppaIsFs();
|
226 |
+
|
227 |
+
// First find container dimensions dependant of mode
|
228 |
+
var contWidth, contHeight;
|
229 |
+
|
230 |
+
if ( modeIsNormal ) {
|
231 |
+
contWidth = window.innerWidth ? window.innerWidth : screen.width;
|
232 |
+
contHeight = window.innerHeight ? window.innerHeight : screen.height;
|
233 |
+
}
|
234 |
+
else {
|
235 |
+
contWidth = screen.width;
|
236 |
+
contHeight = screen.height;
|
237 |
+
}
|
238 |
+
// newWidth = parseInt(newWidth);
|
239 |
+
// newHeight = parseInt(newHeight);
|
240 |
+
|
241 |
+
// Initialize new display sizes
|
242 |
+
var topMarg,
|
243 |
+
leftMarg,
|
244 |
+
extraX = 8,
|
245 |
+
extraY = 24 + ( data.controls ? data.icsize : 0 ) + contWidth * data.height / data.width + 40;
|
246 |
+
|
247 |
+
// Add borderwidth in case of mode == normal
|
248 |
+
if ( modeIsNormal ) {
|
249 |
+
extraX += 2 * data.padding;
|
250 |
+
extraY += 2 * data.padding;
|
251 |
+
}
|
252 |
+
|
253 |
+
// Find out if the width is the limitng dimension
|
254 |
+
widthIsLim = ( contHeight > ( ( contWidth / 2 ) + extraY ) );
|
255 |
+
|
256 |
+
// Compute new sizes and margins
|
257 |
+
if ( widthIsLim ) {
|
258 |
+
newWidth = contWidth - extraX;
|
259 |
+
newHeight = newWidth / 2;
|
260 |
+
topMarg = ( contHeight - newHeight - extraY ) / 2 + 20;
|
261 |
+
}
|
262 |
+
else {
|
263 |
+
newWidth = 2 * ( contHeight - ( data.controls ? data.icsize : 0 ) - 24 - 40 ) / ( 1 + 2 * data.height / data.width );
|
264 |
+
newHeight = newWidth / 2;
|
265 |
+
topMarg = 20;
|
266 |
+
}
|
267 |
+
|
268 |
+
// Set css common for all 4 situations
|
269 |
+
$("#wppa-ovl-flatpan-container").css({top:topMarg,marginTop:0});
|
270 |
+
|
271 |
+
data.canvas.width = newWidth;
|
272 |
+
data.canvas.height = newHeight;
|
273 |
+
data.prevCanvas.width = newWidth;
|
274 |
+
data.prevCanvas.height = newWidth * data.height / data.width;
|
275 |
+
|
276 |
+
// Now set css for all 4 situations: Mode is normal
|
277 |
+
if ( modeIsNormal ) {
|
278 |
+
|
279 |
+
// Common for mode normal
|
280 |
+
$("#wppa-ovl-flatpan-container").css({
|
281 |
+
backgroundColor:data.backgroundColor,
|
282 |
+
padding:data.padding,
|
283 |
+
borderRadius:data.borderRadius,
|
284 |
+
width:newWidth,
|
285 |
+
marginLeft:0
|
286 |
+
});
|
287 |
+
|
288 |
+
// Limit specific
|
289 |
+
if ( widthIsLim ) {
|
290 |
+
$("#wppa-overlay-fpc").css({left:4});
|
291 |
+
}
|
292 |
+
else {
|
293 |
+
$("#wppa-overlay-fpc").css({left:(contWidth-newWidth)/2});
|
294 |
+
}
|
295 |
+
wppaAdjustControlbar();
|
296 |
+
}
|
297 |
+
|
298 |
+
// Mode is fullscreen
|
299 |
+
else {
|
300 |
+
|
301 |
+
// Common for mode fullscreen
|
302 |
+
$("#wppa-overlay-fpc").css({marginLeft:0});
|
303 |
+
$("#wppa-ovl-flatpan-container").css({
|
304 |
+
backgroundColor:"transparent",
|
305 |
+
padding:0,
|
306 |
+
borderRadius:0,
|
307 |
+
width:newWidth,
|
308 |
+
left:(contWidth-newWidth)/2
|
309 |
+
});
|
310 |
+
wppaAdjustControlbar();
|
311 |
+
}
|
312 |
+
|
313 |
+
data.run=(data.autorun?5:4);
|
314 |
+
update(mocc,data);
|
315 |
+
render(mocc);
|
316 |
+
}
|
317 |
+
|
318 |
+
// Not lightbox
|
319 |
+
else {
|
320 |
+
data.canvasWidth = $(data.div).parent().width();
|
321 |
+
data.canvasHeight = data.canvasWidth / 2;
|
322 |
+
data.canvas.width = data.canvasWidth;
|
323 |
+
data.canvas.height = data.canvasHeight;
|
324 |
+
data.prevCanvas.width = data.canvasWidth;
|
325 |
+
data.prevCanvas.height = data.canvasWidth * data.height / data.width;
|
326 |
+
data.run=(data.autorun?5:4);
|
327 |
+
update(mocc,data);
|
328 |
+
render(mocc);
|
329 |
+
}
|
330 |
+
}
|
331 |
+
|
332 |
+
// Horizontal movement by button
|
333 |
+
function rightDown(mocc,e) {
|
334 |
+
|
335 |
+
update(mocc, {
|
336 |
+
autorun :false,
|
337 |
+
run :5,
|
338 |
+
deltaX :3,
|
339 |
+
deltaY :0
|
340 |
+
});
|
341 |
+
render(mocc);
|
342 |
+
}
|
343 |
+
|
344 |
+
function leftDown(mocc,e) {
|
345 |
+
|
346 |
+
update(mocc, {
|
347 |
+
autorun :false,
|
348 |
+
run :5,
|
349 |
+
deltaX :-3,
|
350 |
+
deltaY :0
|
351 |
+
});
|
352 |
+
render(mocc);
|
353 |
+
}
|
354 |
+
|
355 |
+
// Vertical movement by button
|
356 |
+
function upDown(mocc,e) {
|
357 |
+
|
358 |
+
update(mocc, {
|
359 |
+
autorun :false,
|
360 |
+
run :5,
|
361 |
+
deltaX :0,
|
362 |
+
deltaY :-3
|
363 |
+
});
|
364 |
+
render(mocc);
|
365 |
+
}
|
366 |
+
|
367 |
+
function downDown(mocc,e) {
|
368 |
+
|
369 |
+
update(mocc, {
|
370 |
+
autorun :false,
|
371 |
+
run :5,
|
372 |
+
deltaX :0,
|
373 |
+
deltaY :3
|
374 |
+
});
|
375 |
+
render(mocc);
|
376 |
+
}
|
377 |
+
|
378 |
+
// Zooming
|
379 |
+
function zoomInDown(mocc,e) {
|
380 |
+
|
381 |
+
update(mocc, {
|
382 |
+
deltaX :0,
|
383 |
+
deltaY :0,
|
384 |
+
autorun :false,
|
385 |
+
run :5,
|
386 |
+
deltaFactor :1.005
|
387 |
+
});
|
388 |
+
render(mocc);
|
389 |
+
}
|
390 |
+
|
391 |
+
function zoomOutDown(mocc,e) {
|
392 |
+
|
393 |
+
update(mocc, {
|
394 |
+
deltaX :0,
|
395 |
+
deltaY :0,
|
396 |
+
autorun :false,
|
397 |
+
run :5,
|
398 |
+
deltaFactor :0.995
|
399 |
+
});
|
400 |
+
render(mocc);
|
401 |
+
}
|
402 |
+
|
403 |
+
// Mouse wheel
|
404 |
+
function onDivWheel(mocc,e) {
|
405 |
+
|
406 |
+
e.preventDefault();
|
407 |
+
e.stopPropagation();
|
408 |
+
|
409 |
+
var data = update(mocc);
|
410 |
+
|
411 |
+
update(mocc, {
|
412 |
+
deltaX :0,
|
413 |
+
deltaY :0,
|
414 |
+
autorun :false,
|
415 |
+
run :4,
|
416 |
+
deltaFactor :1 + e.deltaY * data.zoomsensitivity / 10000
|
417 |
+
});
|
418 |
+
render(mocc);
|
419 |
+
|
420 |
+
setTimeout(function(){update(mocc, {deltaFactor:1});}, 25);
|
421 |
+
}
|
422 |
+
|
423 |
+
// When a navigation button is released, stop and reset all deltas
|
424 |
+
function buttonUp(mocc,e) {
|
425 |
+
|
426 |
+
e.preventDefault();
|
427 |
+
update(mocc, {
|
428 |
+
autorun :false,
|
429 |
+
deltaX :0,
|
430 |
+
deltaY :0,
|
431 |
+
deltaFactor :1,
|
432 |
+
run :4
|
433 |
+
});
|
434 |
+
}
|
435 |
+
|
436 |
+
// when the mouse is pressed on the canvas, we switch to manual control and save current coordinates
|
437 |
+
function onCanvasMouseDown(mocc,e) {
|
438 |
+
|
439 |
+
e.preventDefault();
|
440 |
+
|
441 |
+
update(mocc, {
|
442 |
+
manualControl :true,
|
443 |
+
autorun :false,
|
444 |
+
deltaX :0,
|
445 |
+
savedCanvasX :e.offsetX,
|
446 |
+
savedCanvasY :e.offsetY,
|
447 |
+
run :5
|
448 |
+
});
|
449 |
+
render(mocc);
|
450 |
+
}
|
451 |
+
|
452 |
+
function onCanvasMouseMove(mocc,e) {
|
453 |
+
|
454 |
+
var data = update(mocc);
|
455 |
+
|
456 |
+
if ( data.manualControl ) {
|
457 |
+
update(mocc, {
|
458 |
+
autorun :false,
|
459 |
+
deltaX :0
|
460 |
+
});
|
461 |
+
|
462 |
+
var factor = data.canvas.width / data.fromWidth;
|
463 |
+
var x = ( data.savedCanvasX - e.offsetX ) / factor + data.fromX;
|
464 |
+
var y = ( data.savedCanvasY - e.offsetY ) / factor + data.fromY;
|
465 |
+
|
466 |
+
if ( x > 0 && y > 0 && ( x + data.fromWidth ) < data.image.width && ( y + data.fromHeight ) < data.image.height ) {
|
467 |
+
update(mocc, {
|
468 |
+
fromX :x,
|
469 |
+
fromY :y,
|
470 |
+
savedCanvasX :e.offsetX,
|
471 |
+
savedCanvasY :e.offsetY
|
472 |
+
});
|
473 |
+
}
|
474 |
+
}
|
475 |
+
}
|
476 |
+
|
477 |
+
function onPrevCanvasMouseMove(mocc,e) {
|
478 |
+
|
479 |
+
var data = update(mocc);
|
480 |
+
|
481 |
+
var factor = data.prevCanvas.width / data.image.width;
|
482 |
+
|
483 |
+
if (e.offsetX > factor * data.fromX &&
|
484 |
+
e.offsetX < factor * ( data.fromX + data.fromWidth ) &&
|
485 |
+
e.offsetY > factor * data.fromY &&
|
486 |
+
e.offsetY < factor * ( data.fromY + data.fromHeight ) ) {
|
487 |
+
$(data.prevCanvas).css("cursor","grab");
|
488 |
+
}
|
489 |
+
else {
|
490 |
+
$(data.prevCanvas).css("cursor","default");
|
491 |
+
}
|
492 |
+
|
493 |
+
if ( data.manualControl ){
|
494 |
+
data.autorun=false;
|
495 |
+
data.deltaX=0;
|
496 |
+
if (e.offsetX > factor * data.fromX &&
|
497 |
+
e.offsetX < factor * ( data.fromX + data.fromWidth ) &&
|
498 |
+
e.offsetY > factor * data.fromY &&
|
499 |
+
e.offsetY < factor * ( data.fromY + data.fromHeight ) ) {
|
500 |
+
data.fromX = ( e.offsetX - data.savedCanvasX ) / factor + data.fromX;
|
501 |
+
data.fromY = ( e.offsetY - data.savedCanvasY ) / factor + data.fromY;
|
502 |
+
data.savedCanvasX = e.offsetX;
|
503 |
+
data.savedCanvasY = e.offsetY;
|
504 |
+
}
|
505 |
+
}
|
506 |
+
update(mocc,data);
|
507 |
+
}
|
508 |
+
|
509 |
+
function onCanvasMouseUp(mocc,e) {
|
510 |
+
|
511 |
+
var data = update(mocc);
|
512 |
+
|
513 |
+
if ( data.manualControl ) {
|
514 |
+
update(mocc, {
|
515 |
+
run: 4,
|
516 |
+
manualControl: false
|
517 |
+
});
|
518 |
+
}
|
519 |
+
}
|
520 |
+
|
521 |
+
// Update data
|
522 |
+
function update(mocc, data) {
|
523 |
+
|
524 |
+
if ( ! wppaZoomData[mocc] ) return false;
|
525 |
+
|
526 |
+
if (data) {
|
527 |
+
for (var property in data) {
|
528 |
+
wppaZoomData[mocc][property] = data[property];
|
529 |
+
}
|
530 |
+
}
|
531 |
+
|
532 |
+
return wppaZoomData[mocc];
|
533 |
+
}
|
534 |
+
|
535 |
+
function timnow() {
|
536 |
+
d = new Date();
|
537 |
+
return d.getTime();
|
538 |
+
}
|
539 |
+
|
540 |
+
// Clean up
|
541 |
+
function quitImage(mocc,e) {
|
542 |
+
|
543 |
+
data = update(mocc, {
|
544 |
+
abort :true,
|
545 |
+
run :0,
|
546 |
+
autorun :false
|
547 |
+
});
|
548 |
+
clearTimeout(data.timer);
|
549 |
+
$(data.canvas).hide();
|
550 |
+
$(data.prevCanvas).hide();
|
551 |
+
$("#wppa-pctl-div-"+mocc).hide();
|
552 |
+
}
|
553 |
+
}
|
js/wppa-flatpan.min.js
ADDED
@@ -0,0 +1 @@
|
|
|
1 |
+
var wppaJsFlatPanVersion="8.2.01.001";function wppaDoFlatPanorama(i,t){var u=jQuery;wppaZoomData[i]=t;var a=l(i,{image:document.getElementById("wppa-"+t.itemId)});function s(t){var n,a,o,e=l(t);if(e.canvas){if(e.isLightbox)wppaOvlOpen||(e.abort=!0);else if(!wppaIsElementInViewport(e.canvas))return void setTimeout(function(){s(t)},200);e.abort?l(t,{ctx:null,prevctx:null}):0!=e.run&&(d=new Date,n=d.getTime(),e.autorun&&n<e.wppaFlatLastRenderTime+25||(e.wppaFlatLastRenderTime=n,e.manualControl||(e.fromX+=e.deltaX,e.fromY+=e.deltaY,o=e.fromHeight/e.deltaFactor,a=e.fromWidth/e.deltaFactor,1!=e.deltaFactor&&o<=e.image.height&&50<o&&(e.fromX-=(a-e.fromWidth)/2,e.fromY-=(o-e.fromHeight)/2,e.fromWidth=a,e.fromHeight=o)),e.fromX=Math.max(0,Math.min(e.image.width-e.fromWidth,e.fromX)),e.fromY=Math.max(0,Math.min(e.image.height-e.fromHeight,e.fromY)),e.autorun&&(0!=e.fromX&&e.fromX!=e.image.width-e.fromWidth||(e.deltaX*=-1)),e.canvas.getContext("2d").drawImage(e.image,e.fromX,e.fromY,e.fromWidth,e.fromHeight,0,0,e.canvas.width,e.canvas.height),(a=e.prevCanvas.getContext("2d")).clearRect(0,0,e.prevCanvas.width,e.prevCanvas.height),a.drawImage(e.image,0,0,e.image.width,e.image.height,0,0,e.prevCanvas.width,e.prevCanvas.height),o=e.prevCanvas.width/e.image.width,a.strokeRect(o*e.fromX,o*e.fromY,o*e.fromWidth,o*e.fromHeight),0<e.run&&(timer=setTimeout(function(){s(t)},25)),e.run<5&&e.run--,setTimeout(function(){jQuery("#wppa-pctl-div-"+t).css({visibility:"visible"})},100),l(t,e)))}}function n(t){var n,a,o,e,i,r,d=l(t);d.abort||(d.isLightbox?(u("#wppa-overlay-fpc").css("display",""),e=(a=!wppaIsFs())?(o=window.innerWidth||screen.width,window.innerHeight||screen.height):(o=screen.width,screen.height),i=8,r=24+(d.controls?d.icsize:0)+o*d.height/d.width+40,a&&(i+=2*d.padding,r+=2*d.padding),e=(n=o/2+r<e)?(newWidth=o-i,newHeight=newWidth/2,(e-newHeight-r)/2+20):(newWidth=2*(e-(d.controls?d.icsize:0)-24-40)/(1+2*d.height/d.width),newHeight=newWidth/2,20),u("#wppa-ovl-flatpan-container").css({top:e,marginTop:0}),d.canvas.width=newWidth,d.canvas.height=newHeight,d.prevCanvas.width=newWidth,d.prevCanvas.height=newWidth*d.height/d.width,a?(u("#wppa-ovl-flatpan-container").css({backgroundColor:d.backgroundColor,padding:d.padding,borderRadius:d.borderRadius,width:newWidth,marginLeft:0}),n?u("#wppa-overlay-fpc").css({left:4}):u("#wppa-overlay-fpc").css({left:(o-newWidth)/2})):(u("#wppa-overlay-fpc").css({marginLeft:0}),u("#wppa-ovl-flatpan-container").css({backgroundColor:"transparent",padding:0,borderRadius:0,width:newWidth,left:(o-newWidth)/2})),wppaAdjustControlbar()):(d.canvasWidth=u(d.div).parent().width(),d.canvasHeight=d.canvasWidth/2,d.canvas.width=d.canvasWidth,d.canvas.height=d.canvasHeight,d.prevCanvas.width=d.canvasWidth,d.prevCanvas.height=d.canvasWidth*d.height/d.width),d.run=d.autorun?5:4,l(t,d),s(t))}function o(t){l(t,{autorun:!1,run:5,deltaX:3,deltaY:0}),s(t)}function e(t){l(t,{autorun:!1,run:5,deltaX:-3,deltaY:0}),s(t)}function r(t){l(t,{autorun:!1,run:5,deltaX:0,deltaY:-3}),s(t)}function f(t){l(t,{autorun:!1,run:5,deltaX:0,deltaY:3}),s(t)}function p(t){l(t,{deltaX:0,deltaY:0,autorun:!1,run:5,deltaFactor:1.005}),s(t)}function c(t){l(t,{deltaX:0,deltaY:0,autorun:!1,run:5,deltaFactor:.995}),s(t)}function m(t,n){n.preventDefault(),l(t,{autorun:!1,deltaX:0,deltaY:0,deltaFactor:1,run:4})}function h(t,n){n.preventDefault(),l(t,{manualControl:!0,autorun:!1,deltaX:0,savedCanvasX:n.offsetX,savedCanvasY:n.offsetY,run:5}),s(t)}function v(t){l(t).manualControl&&l(t,{run:4,manualControl:!1})}function l(t,n){if(!wppaZoomData[t])return!1;if(n)for(var a in n)wppaZoomData[t][a]=n[a];return wppaZoomData[t]}a.manualControl=!1,a.deltaY=0,a.deltaFactor=1,a.run=a.deltaX?5:4,a.abort=!1,a.div=u("#wppa-pan-div-"+i),a.canvas=document.getElementById("wppa-pan-canvas-"+i),a.prevCanvas=document.getElementById("wppa-pan-prev-canvas-"+i),a.left=u("#wppa-pctl-left-"+i),a.right=u("#wppa-pctl-right-"+i),a.up=u("#wppa-pctl-up-"+i),a.down=u("#wppa-pctl-down-"+i),a.zoomin=u("#wppa-pctl-zoomin-"+i),a.zoomout=u("#wppa-pctl-zoomout-"+i),a.prev=u("#wppa-pctl-prev-"+i),a.next=u("#wppa-pctl-next-"+i),a.canvasWidth=u(a.div).parent().width(),a.canvasHeight=a.canvasWidth/2,a.savedCanvasX=0,a.savedCanvasY=0,a.fromHeight=a.image.height/2,a.fromWidth=2*a.fromHeight,a.fromX=(a.image.width-a.fromWidth)/2,a.fromY=(a.image.height-a.fromHeight)/2,a.centerX=a.fromX+a.fromWidth/2,a.centerY=a.fromY+a.fromHeight/2,a.wppaFlatLastRenderTime=0,a.right.on("touchstart",function(t){o(i)}),a.right.on("touchend",function(t){m(i,t)}),a.left.on("touchstart",function(t){e(i)}),a.left.on("touchend",function(t){m(i,t)}),a.up.on("touchstart",function(t){r(i)}),a.up.on("touchend",function(t){m(i,t)}),a.down.on("touchstart",function(t){f(i)}),a.down.on("touchend",function(t){m(i,t)}),a.zoomin.on("touchstart",function(t){p(i)}),a.zoomin.on("touchend",function(t){m(i,t)}),a.zoomout.on("touchstart",function(t){c(i)}),a.zoomout.on("touchend",function(t){m(i,t)}),a.manual&&(a.canvas.addEventListener("mousedown",function(t){h(i,t)}),a.canvas.addEventListener("mousemove",function(t){var n,a,o,e;a=t,(e=l(n=i)).manualControl&&(l(n,{autorun:!1,deltaX:0}),o=e.canvas.width/e.fromWidth,t=(e.savedCanvasX-a.offsetX)/o+e.fromX,o=(e.savedCanvasY-a.offsetY)/o+e.fromY,0<t&&0<o&&t+e.fromWidth<e.image.width&&o+e.fromHeight<e.image.height&&l(n,{fromX:t,fromY:o,savedCanvasX:a.offsetX,savedCanvasY:a.offsetY}))}),a.canvas.addEventListener("mouseup",function(t){v(i)}),a.canvas.addEventListener("mouseout",function(t){v(i)}),document.getElementById("wppa-pan-canvas-"+i).addEventListener("wheel",function(t){!function(t,n){n.preventDefault(),n.stopPropagation();var a=l(t);l(t,{deltaX:0,deltaY:0,autorun:!1,run:4,deltaFactor:1+n.deltaY*a.zoomsensitivity/1e4}),s(t),setTimeout(function(){l(t,{deltaFactor:1})},25)}(i,t)}),a.prevCanvas.addEventListener("mousedown",function(t){h(i,t)}),a.prevCanvas.addEventListener("mousemove",function(t){var n,a,o;a=t,o=l(n=i),t=o.prevCanvas.width/o.image.width,a.offsetX>t*o.fromX&&a.offsetX<t*(o.fromX+o.fromWidth)&&a.offsetY>t*o.fromY&&a.offsetY<t*(o.fromY+o.fromHeight)?u(o.prevCanvas).css("cursor","grab"):u(o.prevCanvas).css("cursor","default"),o.manualControl&&(o.autorun=!1,o.deltaX=0,a.offsetX>t*o.fromX&&a.offsetX<t*(o.fromX+o.fromWidth)&&a.offsetY>t*o.fromY&&a.offsetY<t*(o.fromY+o.fromHeight)&&(o.fromX=(a.offsetX-o.savedCanvasX)/t+o.fromX,o.fromY=(a.offsetY-o.savedCanvasY)/t+o.fromY,o.savedCanvasX=a.offsetX,o.savedCanvasY=a.offsetY)),l(n,o)}),a.prevCanvas.addEventListener("mouseup",function(t){v(i)}),a.prevCanvas.addEventListener("mouseout",function(t){v(i)})),a.right.on("mousedown",function(t){o(i)}),a.right.on("mouseup",function(t){m(i,t)}),a.left.on("mousedown",function(t){e(i)}),a.left.on("mouseup",function(t){m(i,t)}),a.up.on("mousedown",function(t){r(i)}),a.up.on("mouseup",function(t){m(i,t)}),a.down.on("mousedown",function(t){f(i)}),a.down.on("mouseup",function(t){m(i,t)}),a.zoomin.on("mousedown",function(t){p(i)}),a.zoomin.on("mouseup",function(t){m(i,t)}),a.zoomout.on("mousedown",function(t){c(i)}),a.zoomout.on("mouseup",function(t){m(i,t)}),a.isLightbox&&(u("body").on("quitimage",function(t){var n;a=l(n=i,{abort:!0,run:0,autorun:!1}),clearTimeout(a.timer),u(a.canvas).hide(),u(a.prevCanvas).hide(),u("#wppa-pctl-div-"+n).hide()}),u("#wppa-pctl-div-"+a.itemId).on("click",function(t){wppaKillEvent(t)})),a.isLightbox?(u(window).off("resize",wppaOvlShowSame),u(window).on("resize",wppaOvlShowSame)):u(window).on("wpparesizeend",function(t){n(i)}),l(i,a),n(i),u("#wppa-ovl-spin").hide(),wppaProtect()}
|
js/wppa-slideshow.js
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
// Contains slideshow modules
|
4 |
// Dependancies: wppa.js and default wp jQuery library
|
5 |
//
|
6 |
-
var wppaJsSlideshowVersion = '8.
|
7 |
|
8 |
// This is an entrypoint to load the slide data
|
9 |
function wppaStoreSlideInfo(
|
@@ -219,26 +219,22 @@ function wppaStartStop( mocc, index ) {
|
|
219 |
// Remember there is a toggle pending
|
220 |
_wppaTP[mocc] = index;
|
221 |
}
|
222 |
-
else {
|
223 |
-
if ( _wppaSSRuns[mocc] ) {
|
224 |
|
225 |
-
|
226 |
-
|
227 |
-
jQuery( '#wppa-startstop-icon-' + mocc ).html( wppaSvgHtml( 'Play-Button', wppaIconSize( mocc, '48px', true ), false, true, '0', '10', '50', '50' ) );
|
228 |
-
}
|
229 |
-
else {
|
230 |
|
231 |
-
|
232 |
-
|
233 |
-
|
234 |
-
|
235 |
-
}
|
236 |
-
}
|
237 |
|
238 |
-
|
239 |
-
|
240 |
-
|
241 |
-
|
|
|
|
|
|
|
242 |
}
|
243 |
}
|
244 |
|
@@ -1724,6 +1720,7 @@ function _wppaStart( mocc, idx ) {
|
|
1724 |
else {
|
1725 |
_wppaStartText( mocc, idx );
|
1726 |
}
|
|
|
1727 |
}
|
1728 |
|
1729 |
function _wppaStartIcons( mocc, idx ) {
|
@@ -1819,6 +1816,7 @@ function _wppaStop( mocc ) {
|
|
1819 |
else {
|
1820 |
_wppaStopText( mocc );
|
1821 |
}
|
|
|
1822 |
}
|
1823 |
|
1824 |
function _wppaStopIcons( mocc ) {
|
3 |
// Contains slideshow modules
|
4 |
// Dependancies: wppa.js and default wp jQuery library
|
5 |
//
|
6 |
+
var wppaJsSlideshowVersion = '8.2.01.001';
|
7 |
|
8 |
// This is an entrypoint to load the slide data
|
9 |
function wppaStoreSlideInfo(
|
219 |
// Remember there is a toggle pending
|
220 |
_wppaTP[mocc] = index;
|
221 |
}
|
|
|
|
|
222 |
|
223 |
+
// Actually do it
|
224 |
+
if ( _wppaSSRuns[mocc] ) {
|
|
|
|
|
|
|
225 |
|
226 |
+
// Stop it
|
227 |
+
_wppaStop( mocc );
|
228 |
+
}
|
229 |
+
else {
|
|
|
|
|
230 |
|
231 |
+
// Start it
|
232 |
+
_wppaStart( mocc, index );
|
233 |
+
}
|
234 |
+
|
235 |
+
if ( wppaIsMobile ) {
|
236 |
+
jQuery( '#wppa-startstop-icon-' + mocc ).stop().fadeTo( 10, 1 ).fadeTo( 3000, 0 );
|
237 |
+
jQuery( '.ubb-'+mocc ).stop().fadeTo( 10, 1 ).fadeTo( 3000, 0 );
|
238 |
}
|
239 |
}
|
240 |
|
1720 |
else {
|
1721 |
_wppaStartText( mocc, idx );
|
1722 |
}
|
1723 |
+
jQuery( '#wppa-startstop-icon-' + mocc ).html( wppaSvgHtml( 'Pause-Button', wppaIconSize( mocc, '48px', true ), false, true, '0', '10', '50', '50' ) );
|
1724 |
}
|
1725 |
|
1726 |
function _wppaStartIcons( mocc, idx ) {
|
1816 |
else {
|
1817 |
_wppaStopText( mocc );
|
1818 |
}
|
1819 |
+
jQuery( '#wppa-startstop-icon-' + mocc ).html( wppaSvgHtml( 'Play-Button', wppaIconSize( mocc, '48px', true ), false, true, '0', '10', '50', '50' ) );
|
1820 |
}
|
1821 |
|
1822 |
function _wppaStopIcons( mocc ) {
|
js/wppa-slideshow.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
var wppaJsSlideshowVersion="8.1.07.001";function wppaStoreSlideInfo(p,a,e,t,i,w,r,n,o,l,s,d,u,_,m,c,h,y,S,g,x,f,I,j,Q,b,v,T,N,C,k,R,F){o=wppaRepairScriptTags(o),_wppaSlides[p]&&"0"!=a||(_wppaSlides[p]=[],_wppaNames[p]=[],_wppaFilmThumbTitles[p]=[],_wppaFullNames[p]=[],_wppaDsc[p]=[],_wppaOgDsc[p]=[],_wppaCurIdx[p]=-1,_wppaNxtIdx[p]=0,"random"==S?_wppaTimeOut[p]="random":0<parseInt(S)?_wppaTimeOut[p]=parseInt(S):_wppaTimeOut[p]=wppaSlideShowTimeOut,_wppaSSRuns[p]=!1,_wppaTP[p]=-2,_wppaFg[p]=0,_wppaIsBusy[p]=!1,_wppaFirst[p]=!0,_wppaId[p]=[],_wppaRealId[p]=[],_wppaAvg[p]=[],_wppaDisc[p]=[],_wppaMyr[p]=[],_wppaVRU[p]=[],_wppaLinkUrl[p]=[],_wppaLinkTitle[p]=[],_wppaLinkTarget[p]=[],_wppaCommentHtml[p]=[],_wppaIptcHtml[p]=[],_wppaExifHtml[p]=[],_wppaUrl[p]=[],_wppaSkipRated[p]=!1,_wppaLbTitle[p]=[],_wppaDidGoto[p]=!1,wppaSlidePause[p]=!1,_wppaShareUrl[p]=[],_wppaShareHtml[p]=[],_wppaFilmNoMove[p]=!1,_wppaHiresUrl[p]=[],_wppaIsVideo[p]=[],_wppaVideoHtml[p]=[],_wppaAudioHtml[p]=[],_wppaVideoNatWidth[p]=[],_wppaVideoNatHeight[p]=[],wppaVideoPlaying[p]=!1,wppaAudioPlaying[p]=!1,_wppaWaitTexts[p]=[],_wppaImageAlt[p]=[],_wppaFilename[p]=[]),S="default",""!=c?S="pointer":""!=wppaLightBox[p]&&(S="url( "+wppaImageDirectory+wppaMagnifierCursor+" ),pointer"),_wppaIsVideo[p][a]=""!=T,_wppaIsVideo[p][a]?(_wppaSlides[p][a]=' alt="'+k+'" class="theimg theimg-'+p+' big" ',wppaSlideVideoStart&&""==wppaLightBox[p]&&(_wppaSlides[p][a]+=" autoplay "),0<R.length&&(_wppaSlides[p][a]+=' poster="'+R+'" ')):_wppaSlides[p][a]=' src="'+e+'" alt="'+k+'" class="theimg theimg-'+p+' big stereo" ',wppaSlideSwipe&&(_wppaSlides[p][a]+=' ontouchstart="wppaTouchStart( event, this.id, '+p+' );" ontouchend="wppaTouchEnd( event );" ontouchmove="wppaTouchMove( event );" ontouchcancel="wppaTouchCancel( event );" '),wppaAutoColumnWidth[p]||(_wppaSlides[p][a]+='width="'+i+'" height="'+w+'" '),_wppaIsVideo[p][a]?(R="wppa"==wppaLightBox[p]?"":"controls",_wppaSlides[p][a]+='style="'+t+"; cursor:"+S+'; display:none;" '+R+">"+T+"</video>"):_wppaSlides[p][a]+='style="'+t+"; cursor:"+S+'; display:none; vertical-align:middle;">',_wppaFullNames[p][a]='<span class="sdf-'+p+'" >'+wppaRepairBrTags(r)+"</span>",_wppaNames[p][a]='<span class="sdn-'+p+'" >'+n+"</span>",_wppaFilmThumbTitles[p][a]=n,_wppaDsc[p][a]=o,_wppaOgDsc[p][a]=b,_wppaId[p][a]=l,_wppaRealId[p][a]=s,_wppaAvg[p][a]=d,_wppaDisc[p][a]=u,_wppaMyr[p][a]=_,_wppaVRU[p][a]=m,_wppaLinkUrl[p][a]=c,_wppaLinkTitle[p][a]=h,""!=y?_wppaLinkTarget[p][a]=y:wppaSlideBlank[p]?_wppaLinkTarget[p][a]="_blank":_wppaLinkTarget[p][a]="_self",_wppaCommentHtml[p][a]=g,_wppaIptcHtml[p][a]=x,_wppaExifHtml[p][a]=f,_wppaUrl[p][a]=e,_wppaLbTitle[p][a]=wppaRepairScriptTags(I),_wppaShareUrl[p][a]=j,_wppaShareHtml[p][a]=wppaRepairScriptTags(Q),_wppaHiresUrl[p][a]=v,_wppaVideoHtml[p][a]=T,_wppaAudioHtml[p][a]=N,_wppaVideoNatWidth[p][a]=i,_wppaVideoNatHeight[p][a]=w,_wppaWaitTexts[p][a]=C,_wppaImageAlt[p][a]=k,_wppaFilename[p][a]=F}function wppaSpeed(p,a){_wppaSSRuns[p]&&_wppaSpeed(p,a)}function wppaStopShow(p){_wppaSSRuns[p]&&_wppaStop(p)}function wppaStartStop(p,a){wppaSlideInitRunning[p]&&("start"==wppaSlideInitRunning[p]?a=-1:"stopprev"==wppaSlideInitRunning[p]?a=_wppaSlides[p].length-1:"stopnext"==wppaSlideInitRunning[p]&&(a=0),wppaSlideInitRunning[p]=""),_wppaIsBusy[p]?_wppaTP[p]=a:(_wppaSSRuns[p]?(_wppaStop(p),jQuery("#wppa-startstop-icon-"+p).html(wppaSvgHtml("Play-Button",wppaIconSize(p,"48px",!0),!1,!0,"0","10","50","50"))):(_wppaStart(p,a),-1==a&&jQuery("#wppa-startstop-icon-"+p).html(wppaSvgHtml("Pause-Button",wppaIconSize(p,"48px",!0),!1,!0,"0","10","50","50"))),wppaIsMobile&&(jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(10,1).fadeTo(3e3,0),jQuery(".ubb-"+p).stop().fadeTo(10,1).fadeTo(3e3,0)))}function wppaBbb(p,a,e){_wppaSSRuns[p]||_wppaBbb(p,a,e)}function wppaUbb(p,a,e){_wppaUbb(p,a,e)}function wppaRateIt(p,a){_wppaRateIt(p,a)}function wppaOvlRateIt(p,a,e,t){_wppaOvlRateIt(p,a,e,t)}function wppaPrev(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaPrev(p)}function wppaPrevN(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaPrevN(p,a)}function wppaFirst(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,0)}function wppaNext(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaNext(p)}function wppaNextN(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaNextN(p,a)}function wppaLast(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,_wppaSlides[p].length-1)}function wppaFollowMe(p,a){_wppaSSRuns[p]||_wppaFollowMe(p,a)}function wppaLeaveMe(p,a){_wppaSSRuns[p]||_wppaLeaveMe(p,a)}function wppaGoto(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,a)}function wppaGotoFilmNoMove(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||(_wppaFilmNoMove[p]=!0,_wppaGoto(p,a))}function wppaGotoKeepState(p,a){_wppaNxtIdx[p]!=a&&(_wppaDidGoto[p]=!0,_wppaGotoKeepState(p,a))}function _wppaGotoKeepState(p,a){(_wppaSSRuns[p]?_wppaGotoRunning:_wppaGoto)(p,a)}function wppaGotoRunning(p,a){_wppaDidGoto[p]=!0,_wppaGotoRunning(p,a)}function wppaValidateComment(p){return _wppaValidateComment(p)}function _wppaNextSlide(p,a){var e=!document.getElementById("slide_frame-"+p);if(_wppaStopping[p])_wppaStopping[p]=0;else{if(!e&&!wppaIsSlidshowVisible(p))return wppaFilmInit[p]=!1,void setTimeout(function(){_wppaNextSlide(p,a)},400);if(_wppaLastIdx[p]=_wppaCurIdx[p],!document.getElementById("slide_frame-"+p)&&document.getElementById("filmwindow-"+p)&&wppaFilmonlyContinuous)return _wppaSSRuns[p]?(_wppaCurIdx[p]++,_wppaCurIdx[p]==_wppaSlides[p].length&&(_wppaCurIdx[p]=0),_wppaAdjustFilmstrip(p,"linear"),_wppaNxtIdx[p]=_wppaCurIdx[p],void setTimeout("_wppaNextSlide( "+p+", '"+a+"' )",wppaAnimationSpeed)):(_wppaCurIdx[p]=_wppaNxtIdx[p],wppaFilmInit[p]=!1,void _wppaAdjustFilmstrip(p,"linear"));if(document.getElementById("slide_frame-"+p)||document.getElementById("filmwindow-"+p)){var t=_wppaFg[p],e=1-t;if((wppaVideoPlaying[p]||wppaAudioPlaying[p])&&_wppaSSRuns[p])setTimeout("_wppaNextSlide( "+p+", '"+a+"' )",500);else{if(wppaStopVideo(p),wppaStopAudio(p),"auto"==a){if(wppaSlidePause[p])return jQuery("#theimg"+t+"-"+p).attr("title",wppaSlidePause[p]),jQuery("#slide_frame-"+p).attr("title",wppaSlidePause[p]),void setTimeout("_wppaNextSlide( "+p+', "auto" )',250)}else jQuery("#slide_frame-"+p).removeAttr("title");if((_wppaSSRuns[p]||"auto"!=a)&&_wppaSlides[p]&&(!(_wppaSlides[p].length<2)||_wppaFirst[p])){if(_wppaSSRuns[p]||"reset"!=a||(_wppaSSRuns[p]=!0,__wppaOverruleRun=!1),_wppaVoteInProgress=!1,_wppaIsBusy[p]=!0,_wppaSSRuns[p]&&_wppaShowMetaData(p,"hide"),_wppaSSRuns[p]&&(_wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length&&(_wppaNxtIdx[p]=0)),jQuery("#geodiv-"+p+"-"+_wppaId[p][_wppaCurIdx[p]]).css({display:"none"}),jQuery("#geodiv-"+p+"-"+_wppaId[p][_wppaNxtIdx[p]]).css({display:""}),"undefined"!=typeof _wppaLat&&_wppaLat[p]?(n=_wppaRealId[p],_wppaLat[p][n[_wppaNxtIdx[p]]]?(jQuery("#map-canvas-"+p).css("display",""),wppaGeoInit(p,_wppaLat[p][n[_wppaNxtIdx[p]]],_wppaLon[p][n[_wppaNxtIdx[p]]])):jQuery("#map-canvas-"+p).css("display","none")):jQuery("#map-canvas-"+p).css("display","none"),jQuery("[id^=wppa-numbar-"+p+"-]").css({backgroundColor:wppaBGcolorNumbar,borderColor:wppaBcolorNumbar,fontFamily:wppaFontFamilyNumbar,fontSize:wppaFontSizeNumbar,color:wppaFontColorNumbar,fontWeight:wppaFontWeightNumbar}),jQuery("#wppa-numbar-"+p+"-"+_wppaNxtIdx[p]).css({backgroundColor:wppaBGcolorNumbarActive,borderColor:wppaBcolorNumbarActive,fontFamily:wppaFontFamilyNumbarActive,fontSize:wppaFontSizeNumbarActive,color:wppaFontColorNumbarActive,fontWeight:wppaFontWeightNumbarActive}),_wppaSlides[p].length>wppaNumbarMax){var i,w,r=_wppaSlides[p].length-1,n=_wppaNxtIdx[p],o=(wppaNumbarMax-1)/2;n<o?(i=0,w=wppaNumbarMax-1-1,jQuery("#wppa-nbar-"+p+"-lodots").css({display:"none"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})):r-o<n?(i=(w=r)-wppaNumbarMax+1+1,jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"none"})):(w=n+o+.5-1,(i=n-o+1)<2?(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"none"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})):r-1<w?(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"none"})):(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})));for(var l=0;l<_wppaSlides[p].length;)0!=l&&l!=r&&(l<i||w<l)?jQuery("#wppa-numbar-"+p+"-"+l).css({display:"none"}):jQuery("#wppa-numbar-"+p+"-"+l).css({display:"block"}),l++}_wppaFirst[p]?(-1!=_wppaCurIdx[p]&&wppaMakeTheSlideHtml(p,"0",_wppaCurIdx[p]),wppaMakeTheSlideHtml(p,"1",_wppaNxtIdx[p]),jQuery("#imagedesc-"+p).html(_wppaDsc[p][_wppaCurIdx[p]]),jQuery("#imagetitle-"+p).html(wppaMakeNameHtml(p)),"void"==_wppaCommentHtml[p][_wppaCurIdx[p]]?(jQuery("#wppa-comments-"+p).hide(),jQuery("#wppa-comments-"+p).html("")):(jQuery("#wppa-comments-"+p).show(),jQuery("#wppa-comments-"+p).html(_wppaCommentHtml[p][_wppaCurIdx[p]])),jQuery("#iptc-"+p).html(_wppaIptcHtml[p][_wppaCurIdx[p]]),jQuery("#exif-"+p).html(_wppaExifHtml[p][_wppaCurIdx[p]]),"icons"==wppaSlideshowNavigationType?(o=wppaIconSize(p,"1.5em",!1),jQuery("#prev-arrow-"+p).html(wppaSvgHtml("Prev-Button",o,!1,!0)),jQuery("#next-arrow-"+p).html(wppaSvgHtml("Next-Button",o,!1,!0))):wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?(jQuery("#prev-arrow-"+p).html("« "+wppaPrevP),jQuery("#next-arrow-"+p).html(wppaNextP+" »")):(jQuery("#prev-arrow-"+p).html("« "+wppaPreviousPhoto),jQuery("#next-arrow-"+p).html(wppaNextPhoto+" »")),wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRat),jQuery("#wppa-my-rat-"+p).html(wppaMyRat)):(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRating),jQuery("#wppa-my-rat-"+p).html(wppaMyRating))):wppaMakeTheSlideHtml(p,e,_wppaNxtIdx[p]),_wppaLoadSpinner(p),_wppaFirst[p]=!1,_wppaCheckRewind(p),setTimeout("_wppaNextSlide_2( "+p+" )",10)}}}}}function _wppaNextSlide_2(p){var a=_wppaFg[p],e=1-a,t=document.getElementById("theimg"+e+"-"+p);!t||1!=t.nodeType||"IMG"!=t.nodeName||t.complete?(wppaUpdateLightboxes(),_wppaUnloadSpinner(p),-1!=_wppaSSRuns[p]&&(_wppaToTheSame||_wppaShowMetaData(p,"hide")),_wppaFg[p]=1-_wppaFg[p],_wppaFg[p],setTimeout("_wppaNextSlide_3( "+p+" )",10)):setTimeout("_wppaNextSlide_2( "+p+" )",200)}function _wppaNextSlide_3(p){var a=_wppaFg[p],e=1-a,t=_wppaCurIdx[p],i=_wppaNxtIdx[p],w="#theslide"+e+"-"+p,r="#theslide"+a+"-"+p,n="#theimg"+e+"-"+p,o="#theimg"+a+"-"+p,l=parseInt(jQuery(w).css("width")),s=t==i+1?"right":t==i-1?"left":t==i?"none":"nil";switch(t==_wppaSlides[p].length-1&&0==i&&wppaSlideWrap[p]&&(s="left"),0==t&&i==_wppaSlides[p].length-1&&wppaSlideWrap[p]&&(s="right"),"nil"==s&&(s=t<i?"left":"right"),jQuery(w).css({marginLeft:0,width:l}),jQuery(r).css({marginLeft:0,width:l}),wppaFormatSlide(p),wppaAnimationType){case"fadeafter":wppaFadeOut(n,wppaAnimationSpeed),setTimeout(wppaFadeIn(o,wppaAnimationSpeed,_wppaNextSlide_4(p)),wppaAnimationSpeed);break;case"swipe":switch(s){case"left":wppaAnimate(w,{marginLeft:-l},wppaAnimationSpeed,wppaEasingSlide),jQuery(r).css({marginLeft:l}),wppaFadeIn(o,10),wppaAnimate(r,{marginLeft:0},wppaAnimationSpeed,wppaEasingSlide,_wppaNextSlide_4(p));break;case"right":wppaAnimate(w,{marginLeft:l},wppaAnimationSpeed,wppaEasingSlide),jQuery(r).css({marginLeft:-l}),wppaFadeIn(o,10),wppaAnimate(r,{marginLeft:0},wppaAnimationSpeed,wppaEasingSlide,_wppaNextSlide_4(p));break;case"none":wppaFadeIn(o,10),setTimeout("_wppaNextSlide_4( "+p+" )",10)}break;default:wppaFadeOut(n,wppaAnimationSpeed),wppaFadeIn(o,wppaAnimationSpeed,_wppaNextSlide_4(p))}}function _wppaNextSlide_4(p){var a=_wppaFg[p],e="#theslide"+a+"-"+p;jQuery("#theslide"+(1-a)+"-"+p).css({zIndex:80}),jQuery(e).css({zIndex:81}),_wppaCurIdx[p]=_wppaNxtIdx[p],wppaFormatSlide(p),wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?jQuery("#counter-"+p).html(_wppaCurIdx[p]+1+" / "+_wppaSlides[p].length):jQuery("#counter-"+p).html(wppaPhoto+" "+(_wppaCurIdx[p]+1)+" "+wppaOf+" "+_wppaSlides[p].length),jQuery("#bc-pname-modal-"+p).html(_wppaNames[p][_wppaCurIdx[p]]),jQuery("#bc-pname-"+p).html(_wppaNames[p][_wppaCurIdx[p]]),_wppaAdjustFilmstrip(p,wppaEasingSlide),_wppaSetRatingDisplay(p),setTimeout("_wppaNextSlide_5( "+p+" )",_wppaTextDelay)}function _wppaNextSlide_5(p){var a,e,t;if(_wppaToTheSame||(a=_wppaDsc[p][_wppaCurIdx[p]],jQuery("#imagedesc-"+p).html(a),wppaHideWhenEmpty&&(""==(a=_wppaDsc[p][_wppaCurIdx[p]])||" "==a?jQuery("#descbox-"+p).css("display","none"):jQuery("#descbox-"+p).css("display","")),jQuery("#imagetitle-"+p).html(wppaMakeNameHtml(p)),"void"==_wppaCommentHtml[p][_wppaCurIdx[p]]?(jQuery("#wppa-comments-"+p).hide(),jQuery("#wppa-comments-"+p).html("")):(jQuery("#wppa-comments-"+p).show(),jQuery("#wppa-comments-"+p).html(_wppaCommentHtml[p][_wppaCurIdx[p]])),jQuery("#iptc-"+p).html(_wppaIptcHtml[p][_wppaCurIdx[p]]),jQuery("#exif-"+p).html(_wppaExifHtml[p][_wppaCurIdx[p]]),jQuery("#wppa-share-"+p).html(_wppaShareHtml[p][_wppaCurIdx[p]])),_wppaToTheSame=!1,wppaThumbPageSize?wppaThumbPage[p]=parseInt(((0|wppaSlideOffset[p])+_wppaCurIdx[p])/wppaThumbPageSize)+1:wppaThumbPage[p]=1,_wppaSSRuns[p]&&!wppaSlideWrap[p]&&_wppaCurIdx[p]+1==_wppaSlides[p].length)return _wppaIsBusy[p]=!1,void _wppaStop(p);if(_wppaShowMetaData(p,"show"),-2!=_wppaTP[p]){var i=_wppaTP[p];return _wppaTP[p]=-2,_wppaDidGoto[p]=!1,_wppaIsBusy[p]=!1,wppaIsMini[p]||_bumpViewCount(_wppaId[p][_wppaCurIdx[p]]),_wppaDoAutocol(p,"next_5"),void wppaStartStop(p,i)}wppaUpdateLightboxes(),wppaIsMini[p]||(i=_wppaShareUrl[p][_wppaCurIdx[p]],"undefined"!=typeof wppaQRUpdate&&wppaQRUpdate(_wppaShareUrl[p][_wppaCurIdx[p]]),1<_wppaSlides[p].length&&wppaPushStateSlide(p,_wppaCurIdx[p],i)),_wppaSSRuns[p]?_wppaCurIdx[p]+1==_wppaSlides[p].length?(t=jQuery("#wppa-next-pagelink-"+p),e=jQuery("#wppa-first-pagelink-"+p),0<t.length&&"hidden"!=jQuery(t).css("visibility")?setTimeout(function(){wppaSlideInitRunning[p]="start",jQuery("#wppa-next-pagelink-"+p).trigger("click")},wppaGetSlideshowTimeout(p)):0<e.length?setTimeout(function(){jQuery(e).trigger("click")},wppaGetSlideshowTimeout(p)):setTimeout("_wppaNextSlide( "+p+', "auto" )',wppaGetSlideshowTimeout(p))):setTimeout("_wppaNextSlide( "+p+', "auto" )',wppaGetSlideshowTimeout(p)):_wppaStopping[p]=!1,jQuery(document).trigger("glossaryTooltipReady"),_wppaDidGoto[p]=!1,_wppaIsBusy[p]=!1,wppaIsMini[p]||_bumpViewCount(_wppaId[p][_wppaCurIdx[p]]),wppaStopAudio(p),!wppaSlideAudioStart||0<(t=jQuery(".wppa-audio-"+_wppaId[p][_wppaCurIdx[p]]+"-"+p)).length&&((t=t[t.length-1])&&(wppaAudioPlaying[p]||t.play())),wppaProtect()}function wppaFormatSlide(p){var a="theimg"+_wppaFg[p]+"-"+p,e=document.getElementById(a);if(e){var t="theslide"+_wppaFg[p]+"-"+p,i="slide_frame-"+p,w=jQuery("#wppa-container-"+p).width();wppaColWidth[p]=w;var r=jQuery(".wppa-audio-"+p),n=e.naturalWidth;void 0===n&&(n=parseInt(e.style.maxWidth));var o=e.naturalHeight;void 0===o&&(o=parseInt(e.style.maxHeight));var l=wppaAspectRatio[p],s=wppaFullSize[p],d=wppaFullFrameDelta[p],u=wppaPortraitOnly[p],_=wppaFullValign[p];void 0===_&&(_="none");var m=wppaFullHalign[p];void 0===m&&(m="none");var c,h,y,S,g,x,f,e=wppaStretch;if(u)j=w-d,y=h=0,x=S=w,f=g=(c=parseInt(j*o/n))+d,jQuery("#"+i).css({width:x,height:f}),jQuery("#"+t).css({width:S,height:g}),jQuery("#"+a).css({width:j,height:c});else{if(s<(x=w)&&(x=s),S=x,g=f=parseInt(x*l),e||x-d<=n||f-d<=o?l<(o+d)/(n+d)?(c=f-d,j=parseInt(c*n/o)):(j=x-d,c=parseInt(j*o/n)):(j=n,c=o),"default"!=_&&"none"!=_){switch(_){case"top":y=0;break;case"center":y=parseInt((f-(c+d))/2);break;case"bottom":y=f-(c+d);break;case"fit":y=0,g=f=c+d}jQuery("#"+a).css({marginTop:y,marginBottom:0})}if(jQuery("#"+i).css({width:x,height:f}),jQuery("#"+t).css({width:S,height:g}),jQuery("#"+a).css({width:j,height:c}),"default"!=_&&"none"!=_&&"none"!=m&&"default"!=m){switch(m){case"left":h=0;break;case"center":h=parseInt((w-x)/2);break;case"right":h=w-x}h<0&&(h=0),jQuery("#"+a).css({marginLeft:"auto",marginRight:"auto"}),jQuery("#"+i).css({marginLeft:h})}var i=jQuery(r).height(),I=(x-j)/2;i&&0<i&&(wppaAudioHeight=i,jQuery(r).css({height:wppaAudioHeight,width:j,left:I}))}var j=parseInt(x/3),I=2*j,r=0<r.length?f-wppaAudioHeight-wppaSlideBorderWidth-y:f;jQuery("#bbb-"+p+"-l").css({height:r,width:j,left:0}),jQuery("#bbb-"+p+"-r").css({height:r,width:j,left:I})}}function wppaMakeNameHtml(p){var a,e,t="";if(_wppaCurIdx[p]<0)return"";if("void"==_wppaFullNames[p][_wppaCurIdx[p]])return jQuery("#namebox-"+p).hide(),"";if(jQuery("#namebox-"+p).show(),wppaIsMini[p]||_wppaIsVideo[p][_wppaCurIdx[p]])t=_wppaFullNames[p][_wppaCurIdx[p]];else switch(wppaArtMonkyLink){case"file":case"zip":t=wppaArtMonkeyButton?_wppaFullNames[p][_wppaCurIdx[p]]?(a=-1!=_wppaFullNames[p][_wppaCurIdx[p]].indexOf("plus.png"),e=_wppaFullNames[p][_wppaCurIdx[p]].replace(/(<([^>]+)>)/gi,""),e=a?e.replace(" )"," +)"):e.replace(" )",")"),'<input type="button" title="Download" style="cursor:pointer;margin-bottom:0px;max-width:'+(wppaGetContainerWidth(p)-24)+'px;" class="wppa-download-button" onclick="'+(wppaIsSafari&&"file"==wppaArtMonkyLink?"wppaWindowReference = window.open();":"")+"wppaAjaxMakeOrigName( "+p+", '"+_wppaId[p][_wppaCurIdx[p]]+'\' );" value="'+wppaDownLoad+": "+e+'" />'):"":wppaArtmonkeyFileNotSource?'<a href="'+_wppaUrl[p][_wppaCurIdx[p]]+'" title="Download" style="cursor:pointer;" download="'+_wppaFilename[p][_wppaCurIdx[p]]+'" >'+wppaDownLoad+": "+_wppaFullNames[p][_wppaCurIdx[p]]+"</a>":'<a title="Download" style="cursor:pointer;" onclick="'+(wppaIsSafari&&"file"==wppaArtMonkyLink?"wppaWindowReference = window.open();":"")+"wppaAjaxMakeOrigName( "+p+", '"+_wppaId[p][_wppaCurIdx[p]]+"' );\" >"+wppaDownLoad+": "+_wppaFullNames[p][_wppaCurIdx[p]]+"</a>";break;case"none":case"new":t=_wppaFullNames[p][_wppaCurIdx[p]];break;default:t=""}return t=wppaRepairBrTags(t)}function wppaMakeTheSlideHtml(p,a,e){var t,i,w=_wppaIsVideo[p][e]?"video":"img",r="title";"wppa"==wppaLightBox[p]&&(r="data-lbtitle");var n,o,l=""==wppaLightBox[p]?' onpause="wppaVideoPlaying['+p+'] = false;" onplay="wppaVideoPlaying['+p+'] = true;"':"";if(""!=_wppaLinkUrl[p][e])t=wppaSlideToFullpopup?'<a onclick="wppaStopAudio();wppaStopShow('+p+");"+_wppaLinkUrl[p][e]+'" target="'+_wppaLinkTarget[p][e]+'" title="'+_wppaLinkTitle[p][e]+'"><'+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e]+"</a>":"<a onclick=\"_bumpClickCount('"+_wppaId[p][e]+"');wppaStopAudio();wppaStopShow("+p+");window.open('"+_wppaLinkUrl[p][e]+"', '"+_wppaLinkTarget[p][e]+'\');" title="'+_wppaLinkTitle[p][e]+'"><'+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e]+"</a>";else if(""==wppaLightBox[p])t="<"+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e];else{for(var s="",d=0,u=wppaLightboxSingle[p]?"":"[slide-"+p+"-"+a+"]";d<e;)i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][d]:wppaMakeFullsizeUrl(_wppaUrl[p][d]),o=".pdf"==(n=_wppaHiresUrl[p][d]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][d]+'" data-videonatheight="'+_wppaVideoNatHeight[p][d]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][d])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][d])+'"':"")+" "+r+'="'+_wppaLbTitle[p][d]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+"></a>",d++;for(i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][e]:wppaMakeFullsizeUrl(_wppaUrl[p][e]),o=".pdf"==(n=_wppaHiresUrl[p][e]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(wppaSlideLinkEqual?' onclick="wppaStopAudio();wppaStopShow('+p+");jQuery('#wppa-film-"+e+"-"+p+"').trigger('click');return false;\"":' onclick="wppaStopAudio();wppaStopShow('+p+');"')+' style="cursor:pointer;" target="'+_wppaLinkTarget[p][e]+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][e]+'" data-videonatheight="'+_wppaVideoNatHeight[p][e]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][e])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][e])+'"':"")+" "+r+'="'+_wppaLbTitle[p][e]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+">"+(o?"<iframe "+l+' src="'+n+'" title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" style="width:100%;height:100%;" ></iframe>':"<"+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e])+"</a>",d=e+1;d<_wppaUrl[p].length;)i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][d]:wppaMakeFullsizeUrl(_wppaUrl[p][d]),o=".pdf"==(n=_wppaHiresUrl[p][d]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][d]+'" data-videonatheight="'+_wppaVideoNatHeight[p][d]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][d])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][d])+'"':"")+" "+r+'="'+_wppaLbTitle[p][d]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+"></a>",d++;t=s}""!=_wppaAudioHtml[p][e]&&(t+='<audio controls id="wppa-audio-'+_wppaId[p][e]+"-"+p+'" class="wppa-audio-'+p+" wppa-audio-"+_wppaId[p][e]+"-"+p+'" data-from="wppa" onplay="wppaAudioPlaying['+p+'] = true;" onpause="wppaAudioPlaying['+p+'] = false" style="position:relative;top:-'+(wppaAudioHeight+wppaSlideBorderWidth)+"px;z-index:10;width:"+_wppaVideoNatWidth[p][e]+'px;padding:0;box-sizing:border-box;" >'+_wppaAudioHtml[p][e]+"</audio>"),t=t.replace(/title=""/g,""),jQuery("#theslide"+a+"-"+p).html(t)}function wppaAdjustAllFilmstrips(p){jQuery(".wppa-filmstrip").each(function(){_wppaAdjustFilmstrip(jQuery(this).attr("id").substr(15),p)})}var wppaLastAnimFilmLoc=[];function _wppaAdjustFilmstrip(p,a){if("linear"!=a&&(a=wppaEasingSlide),document.getElementById("wppa-filmstrip-"+p)&&_wppaSlides[p]){var e,t,i,w,r=!document.getElementById("slide_frame-"+p);if(wppaLastAnimFilmLoc[p]||(wppaLastAnimFilmLoc[p]=0),r){var n=jQuery("#wppa-filmstrip-"+p);if(!wppaIsElementInViewport(n))return}if(r||jQuery(".wppa-film-"+p).removeClass("wppa-filmthumb-active"),_wppaFilmNoMove[p]&&wppaFilmInit[p]?_wppaFilmNoMove[p]=!1:(e=wppaFilmStripLength[p]/2-(_wppaCurIdx[p]+.5+wppaPreambule[p])*wppaThumbnailPitch[p]-wppaFilmStripMargin[p],wppaFilmShowGlue&&(e-=2*wppaFilmStripMargin[p]+2),i=e+wppaThumbnailPitch[p],w=e-wppaThumbnailPitch[p],t=wppaAnimationSpeed,wppaFilmInit[p]||(t=1),0==_wppaCurIdx[p]&&_wppaLastIdx[p]==_wppaSlides[p].length-1?(jQuery("#wppa-filmstrip-"+p).css({marginLeft:i+"px"}),wppaLastAnimFilmLoc[p]!=e&&(wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e)):0==_wppaLastIdx[p]&&_wppaCurIdx[p]==_wppaSlides[p].length-1?(jQuery("#wppa-filmstrip-"+p).css({marginLeft:w}),wppaLastAnimFilmLoc[p]!=e&&(wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e)):(n=parseInt(jQuery("#wppa-filmstrip-"+p).css("margin-left")),i=parseInt(e),w=wppaThumbnailPitch[p],_wppaSSRuns[p]?(n<i?2:i<n-2*w?1:0)&&jQuery("#wppa-filmstrip-"+p).css({marginLeft:i+w}):(i<n-1.5*w||n+1.5*w<i)&&jQuery("#wppa-filmstrip-"+p).css({marginLeft:i}),wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e,wppaFilmInit[p]=!0),_wppaLastIdx[p]=_wppaCurIdx[p]),wppaMakeLazyVisible("filmstripmocc="+p),!r&&-1!=_wppaCurIdx[p]){_wppaCurIdx[p];_wppaCurIdx[p]+10>_wppaSlides[p].length&&_wppaSlides[p].length;for(var o=0;o<_wppaSlides[p].length;)jQuery("#film_wppatnf_"+_wppaId[p][o]+"_"+p).html()&&(""!=jQuery("#wppa-film-"+o+"-"+p).attr("data-title")?(jQuery("#wppa-film-"+o+"-"+p).attr("title",jQuery("#wppa-film-"+o+"-"+p).attr("data-title")),jQuery("#wppa-pre-"+o+"-"+p).attr("title",jQuery("#wppa-film-"+o+"-"+p).attr("data-title"))):""!=wppaFilmThumbTitle&&_wppaCurIdx[p]==o?(jQuery("#wppa-film-"+o+"-"+p).attr("title",wppaFilmThumbTitle),jQuery("#wppa-pre-"+o+"-"+p).attr("title",wppaFilmThumbTitle)):(jQuery("#wppa-film-"+o+"-"+p).attr("title",wppaClickToView+" "+_wppaFilmThumbTitles[p][o]),jQuery("#wppa-pre-"+o+"-"+p).attr("title",wppaClickToView+" "+_wppaFilmThumbTitles[p][o]))),o++}r||jQuery("#wppa-film-"+_wppaCurIdx[p]+"-"+p).addClass("wppa-filmthumb-active")}}function _wppaNext(p){var a,e;!wppaSlideWrap[p]&&_wppaCurIdx[p]==_wppaSlides[p].length-1||(_wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length?(a=jQuery("#wppa-next-pagelink-"+p),e=jQuery("#wppa-first-pagelink-"+p),0<a.length&&"hidden"!=jQuery(a).css("visibility")?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopnext",jQuery("#wppa-next-pagelink-"+p).trigger("click")):0<e.length?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopnext",jQuery(e).trigger("click")):_wppaNextSlide(p,_wppaNxtIdx[p]=0)):_wppaNextSlide(p,0))}function _wppaNextN(p,a){if(wppaSlideWrap[p]||!(_wppaCurIdx[p]>=_wppaSlides[p].length-a)){for(_wppaNxtIdx[p]=_wppaCurIdx[p]+a;_wppaNxtIdx[p]>=_wppaSlides[p].length;)_wppaNxtIdx[p]-=_wppaSlides[p].length;_wppaNextSlide(p,0)}}function _wppaNextOnCallback(p){if(wppaSlideWrap[p]||_wppaCurIdx[p]!=_wppaSlides[p].length-1){if(_wppaSkipRated[p]){var a=_wppaCurIdx[p]+1;a==_wppaSlides[p].length&&(a=0);var e=a;if(0!=_wppaMyr[p][e]){for(++a==_wppaSlides[p].length&&(a=0);a!=e&&0!=_wppaMyr[p][a];)++a==_wppaSlides[p].length&&(a=0);e=a}_wppaNxtIdx[p]=e}else _wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length&&(_wppaNxtIdx[p]=0);_wppaNextSlide(p,0)}}function _wppaPrev(p){!wppaSlideWrap[p]&&0==_wppaCurIdx[p]||(_wppaNxtIdx[p]=_wppaCurIdx[p]-1,_wppaNxtIdx[p]<0?jQuery("#wppa-prev-page-last-item-"+p).length?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopprev",jQuery("#wppa-prev-page-last-item-"+p).trigger("click")):(_wppaNxtIdx[p]+=_wppaSlides[p].length,_wppaNextSlide(p,0)):_wppaNextSlide(p,0))}function _wppaPrevN(p,a){if(wppaSlideWrap[p]||!(_wppaCurIdx[p]<a)){for(_wppaNxtIdx[p]=_wppaCurIdx[p]-a;_wppaNxtIdx[p]<0;)_wppaNxtIdx[p]+=_wppaSlides[p].length;_wppaNextSlide(p,0)}}function _wppaGoto(p,a){_wppaToTheSame=_wppaNxtIdx[p]==a,_wppaNxtIdx[p]=a,_wppaNextSlide(p,0)}function _wppaGotoRunning(p,a){_wppaIsBusy[p]?setTimeout("_wppaGotoRunning( "+p+","+a+" )",10):(_wppaSSRuns[p]=!1,_wppaToTheSame=_wppaNxtIdx[p]==a,_wppaNxtIdx[p]=a,__wppaOverruleRun=!0,_wppaNextSlide(p,"manual"),_wppaGotoContinue(p))}function _wppaGotoContinue(p){_wppaIsBusy[p]?setTimeout("_wppaGotoContinue( "+p+" )",10):setTimeout("_wppaNextSlide( "+p+', "reset" )',wppaGetSlideshowTimeout(p)+10)}function _wppaStart(p,a){if(_wppaStopping[p])return _wppaStopping[p]--,void setTimeout(function(){_wppaStart(p,a)},(wppaAnimationSpeed+wppaGetSlideshowTimeout(p))/10);_wppaSSRuns[p]||("icons"==wppaSlideshowNavigationType?_wppaStartIcons:_wppaStartText)(p,a)}function _wppaStartIcons(p,a){if(-2==a){var e=0;if(a=0,_wppaSkipRated[p]=!0,0!=_wppaMyr[p][e])for(;e<_wppaSlides[p].length;)0==a&&0==_wppaMyr[p][e]&&(a=e),e++}var t=wppaIconSize(p,"1.5em",!1);-1<a?(jQuery("#startstop-"+p).html(wppaSvgHtml("Play-Button",t,!1,!0,"0","10","20","50")),jQuery("#speed0-"+p).hide(),jQuery("#speed1-"+p).hide(),_wppaNxtIdx[p]=a,_wppaCurIdx[p]=a,_wppaNextSlide(p,0),_wppaShowMetaData(p,"show")):(_wppaSSRuns[p]=!0,_wppaNextSlide(p,0),jQuery("#startstop-"+p).html(wppaSvgHtml("Pause-Button",t,!1,!0,"0","10","20","50")),jQuery("#speed0-"+p).show(),jQuery("#speed1-"+p).show(),_wppaShowMetaData(p,"hide"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(wppaSlideShow)),_wppaSetRatingDisplay(p)}function _wppaStartText(p,a){if(-2==a){var e=0;if(a=0,_wppaSkipRated[p]=!0,0!=_wppaMyr[p][e])for(;e<_wppaSlides[p].length;)0==a&&0==_wppaMyr[p][e]&&(a=e),e++}-1<a?(jQuery("#startstop-"+p).html(wppaStart+" "+wppaSlideShow),jQuery("#speed0-"+p).css("display","none"),jQuery("#speed1-"+p).css("display","none"),_wppaNxtIdx[p]=a,_wppaCurIdx[p]=a,_wppaNextSlide(p,0),_wppaShowMetaData(p,"show")):(_wppaSSRuns[p]=!0,_wppaNextSlide(p,0),jQuery("#startstop-"+p).html(wppaStop),jQuery("#speed0-"+p).css("display","inline"),jQuery("#speed1-"+p).css("display","inline"),_wppaShowMetaData(p,"hide"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(wppaSlideShow)),_wppaSetRatingDisplay(p)}function _wppaStop(p){_wppaStopping[p]=12,("icons"==wppaSlideshowNavigationType?_wppaStopIcons:_wppaStopText)(p)}function _wppaStopIcons(p){_wppaSSRuns[p]=!1,jQuery("#startstop-"+p).html(wppaSvgHtml("Play-Button",wppaIconSize(p,"1.5em",!1),!1,!0)),jQuery("#speed0-"+p).hide(),jQuery("#speed1-"+p).hide(),_wppaShowMetaData(p,"show"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(_wppaNames[p][_wppaCurIdx[p]])}function _wppaStopText(p){_wppaSSRuns[p]=!1,jQuery("#startstop-"+p).html(wppaStart+" "+wppaSlideShow),jQuery("#speed0-"+p).css("display","none"),jQuery("#speed1-"+p).css("display","none"),_wppaShowMetaData(p,"show"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(_wppaNames[p][_wppaCurIdx[p]])}function _wppaSpeed(p,a){"random"!=_wppaTimeOut[p]&&(a?500<_wppaTimeOut[p]&&(_wppaTimeOut[p]/=1.5):_wppaTimeOut[p]<6e4&&(_wppaTimeOut[p]*=1.5))}function _wppaLoadSpinner(p){}function _wppaUnloadSpinner(p){jQuery("#wppa-slide-spin-"+p).stop().fadeOut(),setTimeout(function(){jQuery("#wppa-slide-spin-"+p).stop().fadeOut()},1e3)}function _wppaCheckRewind(p){var a,e;document.getElementById("wppa-filmstrip-"+p)&&((e=Math.abs(_wppaCurIdx[p]-_wppaNxtIdx[p]))<=wppaFilmPageSize[p]||(1+wppaFilmStripLength[p]/wppaThumbnailPitch[p])/2<=e&&(a=wppaThumbnailPitch[p]*_wppaSlides[p].length,wppaFilmShowGlue&&(a+=2+2*wppaFilmStripMargin[p]),e=parseInt(jQuery("#wppa-filmstrip-"+p).css("margin-left")),_wppaNxtIdx[p]>_wppaCurIdx[p]?e-=a:e+=a,jQuery("#wppa-filmstrip-"+p).css("margin-left",e+"px")))}function _wppaSetRatingDisplay(p){if(document.getElementById("wppa-rating-"+p)){var a,e,t=_wppaAvg[p][_wppaCurIdx[p]];if(void 0!==t){if("likes"==wppaRatingDisplayType){"void"==(e=_wppaMyr[p][_wppaCurIdx[p]])?(jQuery("#wppa-dislike-imgdiv-"+p).hide(),jQuery("#wppa-like-imgdiv-"+p).hide()):(jQuery("#wppa-dislike-imgdiv-"+p).show(),jQuery("#wppa-like-imgdiv-"+p).show());var w=t.split("|");return jQuery("#wppa-like-"+p).attr("title",w[0]),jQuery("#wppa-liketext-"+p).html(w[1]),void("1"==_wppaMyr[p][_wppaCurIdx[p]]?jQuery("#wppa-like-"+p).attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-"+p).attr("src",wppaImageDirectory+"thumbup.png"))}if(t=(a=t.split("|"))[0],w=a[1],a=_wppaDisc[p][_wppaCurIdx[p]],e=_wppaMyr[p][_wppaCurIdx[p]],"void"==a)jQuery("#wppa-rating-"+p).hide();else{if(jQuery("#wppa-rating-"+p).show(),"graphic"==wppaRatingDisplayType)_wppaSetRd(p,t,"#wppa-avg-"),_wppaSetRd(p,e,"#wppa-rate-"),0==e?(jQuery("#wppa-dislike-"+p).css("display","inline"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","inline"),document.getElementById("wppa-dislike-"+p)&&jQuery("#wppa-filler-"+p).css("display","none"),jQuery("#wppa-dislike-"+p).stop().fadeTo(100,wppaStarOpacity)):(jQuery("#wppa-dislike-"+p).css("display","none"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","none"),jQuery("#wppa-filler-"+p).css("display","inline"),jQuery("#wppa-filler-"+p).stop().fadeTo(100,wppaStarOpacity),jQuery("#wppa-filler-"+p).attr("title",a));else{if(jQuery("#wppa-numrate-avg-"+p).html(t+" ( "+w+" ) "),jQuery(".wppa-my-rat-"+p).show(),"void"==e)jQuery("#wppa-numrate-mine-"+p).html(""),jQuery(".wppa-my-rat-"+p).hide();else if(wppaRatingOnce&&0<e)jQuery("#wppa-numrate-mine-"+p).html(e);else if(e<0)jQuery("#wppa-numrate-mine-"+p).html(" dislike");else{var r="";for(i=1;i<=wppaRatingMax;i++)e==i?r+='<span class="wppa-rating-numeric-mine" style="cursor:pointer; font-weight:bold;" onclick="_wppaRateIt( '+p+", "+i+' )"> '+i+" </span>":(e>i-1&&e<i&&(r+=" ( "+e+" ) "),r+='<span class="wppa-rating-numeric" style="cursor:pointer;" onclick="_wppaRateIt( '+p+", "+i+' )" onmouseover="this.style.fontWeight=\'bold\'" onmouseout="this.style.fontWeight=\'normal\'" > '+i+" </span>");jQuery("#wppa-numrate-mine-"+p).html(r)}0==e?(jQuery("#wppa-dislike-"+p).css("display","inline"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","inline"),jQuery("#wppa-filler-"+p).css("display","none"),jQuery("#wppa-dislike-"+p).stop().fadeTo(100,wppaStarOpacity)):(jQuery("#wppa-dislike-"+p).css("display","none"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","none"),jQuery("#wppa-filler-"+p).css("display","inline")),jQuery("#wppa-discount-"+p).html(a+"• "),jQuery("#wppa-filler-"+p).css("display","none")}0==e?jQuery("#wppa-vote-button-"+p).val(wppaVoteForMe):jQuery("#wppa-vote-button-"+p).val(wppaVotedForMe),jQuery("#wppa-vote-count-"+p).html(w)}}}}function wppaGetDislikeText(p,a,e){return p}function _wppaSetRd(p,a,e){var t=parseInt(a),i=t+1,w=wppaStarOpacity+(a-t)*(1-wppaStarOpacity),r=wppaRatingMax;if("void"==a)jQuery("#wppa-my-rat-"+p).hide(),jQuery(".wppa-my-rat-"+p).hide(),jQuery(".wppa-rate-"+p).hide(),jQuery(".wppa-ratingthumb").hide(),jQuery("#wppa-numrate-mine-"+p).hide();else for(jQuery("#wppa-my-rat-"+p).show(),jQuery(".wppa-my-rat-"+p).show(),jQuery(".wppa-rate-"+p).show(),jQuery(".wppa-ratingthumb").show(),jQuery("#wppa-numrate-mine-"+p).show(),idx=1;idx<=r;idx++)"#wppa-rate-"!=e&&".wppa-rate-"!=e||jQuery(e+p+"-"+idx).attr("src")!=wppaImageDirectory+"star.ico"&&jQuery(e+p+"-"+idx).attr("src",wppaImageDirectory+"star.ico"),idx<=t?jQuery(e+p+"-"+idx).stop().fadeTo(100,1):idx==i?jQuery(e+p+"-"+idx).stop().fadeTo(100,w):jQuery(e+p+"-"+idx).stop().fadeTo(100,wppaStarOpacity)}function _wppaFollowMe(p,a){_wppaSSRuns[p]||0!=_wppaMyr[p][_wppaCurIdx[p]]&&wppaRatingOnce||_wppaMyr[p][_wppaCurIdx[p]]<0||_wppaVoteInProgress||_wppaSetRd(p,a,"#wppa-rate-")}function wppaOvlFollowMe(p,a,e){e||_wppaSetRd(p,a,".wppa-rate-")}function _wppaLeaveMe(p,a){_wppaSSRuns[p]||0!=_wppaMyr[p][_wppaCurIdx[p]]&&wppaRatingOnce||_wppaMyr[p][_wppaCurIdx[p]]<0||_wppaVoteInProgress||_wppaSetRd(p,_wppaMyr[p][_wppaCurIdx[p]],"#wppa-rate-")}function wppaOvlLeaveMe(p,a,e){_wppaSetRd(p,e,".wppa-rate-")}function _wppaValidateComment(p,a){if(a=a||_wppaId[p][_wppaCurIdx[p]],jQuery("#wppa-comname-"+p).val().length<1)return alert(wppaPleaseName),!1;if("required"==wppaEmailRequired||"optional"==wppaEmailRequired){var e=jQuery("#wppa-comemail-"+p).val();if("optional"==wppaEmailRequired&&0==e.length)return!0;var t=e.indexOf("@"),a=e.lastIndexOf(".");if(t<1||a<t+2||a+2>=e.length)return alert(wppaPleaseEmail),!1}return!(jQuery("#wppa-comment-"+p).val().length<1)||(alert(wppaPleaseComment),!1)}function _wppaGo(p){document.location=p}function _wppaBbb(p,a,e){if(!_wppaSSRuns[p]){var t="#bbb-"+p+"-"+a;switch(e){case"show":"l"==a&&jQuery(t).attr("title",wppaPreviousPhoto),"r"==a&&jQuery(t).attr("title",wppaNextPhoto),jQuery(".bbb-"+p).css("cursor","pointer");break;case"hide":jQuery(".bbb-"+p).removeAttr("title"),jQuery(".bbb-"+p).css("cursor","default");break;case"click":"l"==a&&wppaPrev(p),"r"==a&&wppaNext(p);break;default:alert("Unimplemented instruction: "+e+" on: "+t)}}}function _wppaUbb(p,a,e){var t="#ubb-"+p+"-"+a;switch(e){case"show":"l"==a&&jQuery(t).attr("title",wppaPreviousPhoto),"r"==a&&jQuery(t).attr("title",wppaNextPhoto),jQuery(".ubb-"+p).css("cursor","pointer"),jQuery(".ubb-"+p).stop().fadeTo(200,.8),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,.8);break;case"hide":jQuery(".ubb-"+p).removeAttr("title"),jQuery(".ubb-"+p).css("cursor","default"),wppaIsMobile?jQuery(".ubb-"+p).stop().fadeTo(200,.1):jQuery(".ubb-"+p).stop().fadeTo(200,0),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,0);break;case"click":wppaIsMobile&&(jQuery(".ubb-"+p).stop().fadeTo(200,1).fadeTo(1e3,0),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,1).fadeTo(1e3,0)),"l"==a&&wppaPrev(p),"r"==a&&wppaNext(p);break;default:alert("Unimplemented instruction: "+e+" on: "+t)}}function wppaOpenComments(p){_wppaSSRuns[p]&&_wppaStop(p),jQuery("#wppa-comtable-wrap-"+p).css("display","block"),jQuery("#wppa-comform-wrap-"+p).css("display","block"),jQuery("#wppa-comfooter-wrap-"+p).css("display","none"),wppaColWidth[p]=0,setTimeout("_wppaDoAutocol( "+p+" )",100)}function _wppaShowMetaData(p,a){_wppaSlides[p]&&(_wppaSSRuns[p]||__wppaOverruleRun?"show"==a?wppaFotomotoHideWhenRunning||wppaFotomotoToolbar(p,_wppaHiresUrl[p][_wppaCurIdx[p]]):wppaShareHideWhenRunning&&jQuery("#wppa-share-"+p).css("display","none"):"show"==a?(wppaAutoOpenComments&&(jQuery("#wppa-comtable-wrap-"+p).css("display","block"),jQuery("#wppa-comform-wrap-"+p).css("display","block"),jQuery("#wppa-comfooter-wrap-"+p).css("display","none")),0!=_wppaCurIdx[p]&&jQuery(".wppa-first-"+p).show(),_wppaCurIdx[p]!=_wppaSlides[p].length-1&&jQuery(".wppa-last-"+p).show(),wppaShareHideWhenRunning&&jQuery("#wppa-share-"+p).css("display",""),wppaFotomotoToolbar(p,_wppaHiresUrl[p][_wppaCurIdx[p]])):(jQuery("#wppa-comtable-wrap-"+p).css("display","none"),jQuery("#wppa-comform-wrap-"+p).css("display","none"),jQuery("#wppa-comfooter-wrap-"+p).css("display","block"),wppaFotomotoHide(p)),"show"==a?(jQuery("#imagedesc-"+p).css("visibility","visible"),jQuery("#imagetitle-"+p).css("visibility","visible"),jQuery("#counter-"+p).css("visibility","visible"),jQuery("#iptccontent-"+p).css("visibility","visible"),jQuery("#exifcontent-"+p).css("visibility","visible")):(jQuery("#counter-"+p).css("visibility","hidden"),jQuery(".wppa-first-"+p).hide(),jQuery(".wppa-last-"+p).hide(),jQuery("#iptccontent-"+p).css("visibility","hidden"),jQuery("#exifcontent-"+p).css("visibility","hidden")))}function wppaGetSlideshowTimeout(p){var a,e;return"random"==_wppaTimeOut[p]?(a=2*wppaAnimationSpeed,e=7*wppaAnimationSpeed,Math.floor(Math.random()*(e-a+1))+a):_wppaTimeOut[p]}function wppaIsSlidshowVisible(p){for(var a,e=["slide_frame-"+p,"filmwindow-"+p],t=e.length,i=0;i<t;i++)if(a=document.getElementById(e[i]),a&&(a.getBoundingClientRect(),wppaIsElementInViewport(a)))return!0;return wppaFilmInit[p]=!1}
|
1 |
+
var wppaJsSlideshowVersion="8.2.01.001";function wppaStoreSlideInfo(p,a,e,t,i,w,r,n,o,l,s,d,u,_,m,c,h,y,S,g,x,f,I,j,Q,b,v,T,N,C,k,R,F){o=wppaRepairScriptTags(o),_wppaSlides[p]&&"0"!=a||(_wppaSlides[p]=[],_wppaNames[p]=[],_wppaFilmThumbTitles[p]=[],_wppaFullNames[p]=[],_wppaDsc[p]=[],_wppaOgDsc[p]=[],_wppaCurIdx[p]=-1,_wppaNxtIdx[p]=0,"random"==S?_wppaTimeOut[p]="random":0<parseInt(S)?_wppaTimeOut[p]=parseInt(S):_wppaTimeOut[p]=wppaSlideShowTimeOut,_wppaSSRuns[p]=!1,_wppaTP[p]=-2,_wppaFg[p]=0,_wppaIsBusy[p]=!1,_wppaFirst[p]=!0,_wppaId[p]=[],_wppaRealId[p]=[],_wppaAvg[p]=[],_wppaDisc[p]=[],_wppaMyr[p]=[],_wppaVRU[p]=[],_wppaLinkUrl[p]=[],_wppaLinkTitle[p]=[],_wppaLinkTarget[p]=[],_wppaCommentHtml[p]=[],_wppaIptcHtml[p]=[],_wppaExifHtml[p]=[],_wppaUrl[p]=[],_wppaSkipRated[p]=!1,_wppaLbTitle[p]=[],_wppaDidGoto[p]=!1,wppaSlidePause[p]=!1,_wppaShareUrl[p]=[],_wppaShareHtml[p]=[],_wppaFilmNoMove[p]=!1,_wppaHiresUrl[p]=[],_wppaIsVideo[p]=[],_wppaVideoHtml[p]=[],_wppaAudioHtml[p]=[],_wppaVideoNatWidth[p]=[],_wppaVideoNatHeight[p]=[],wppaVideoPlaying[p]=!1,wppaAudioPlaying[p]=!1,_wppaWaitTexts[p]=[],_wppaImageAlt[p]=[],_wppaFilename[p]=[]),S="default",""!=c?S="pointer":""!=wppaLightBox[p]&&(S="url( "+wppaImageDirectory+wppaMagnifierCursor+" ),pointer"),_wppaIsVideo[p][a]=""!=T,_wppaIsVideo[p][a]?(_wppaSlides[p][a]=' alt="'+k+'" class="theimg theimg-'+p+' big" ',wppaSlideVideoStart&&""==wppaLightBox[p]&&(_wppaSlides[p][a]+=" autoplay "),0<R.length&&(_wppaSlides[p][a]+=' poster="'+R+'" ')):_wppaSlides[p][a]=' src="'+e+'" alt="'+k+'" class="theimg theimg-'+p+' big stereo" ',wppaSlideSwipe&&(_wppaSlides[p][a]+=' ontouchstart="wppaTouchStart( event, this.id, '+p+' );" ontouchend="wppaTouchEnd( event );" ontouchmove="wppaTouchMove( event );" ontouchcancel="wppaTouchCancel( event );" '),wppaAutoColumnWidth[p]||(_wppaSlides[p][a]+='width="'+i+'" height="'+w+'" '),_wppaIsVideo[p][a]?(R="wppa"==wppaLightBox[p]?"":"controls",_wppaSlides[p][a]+='style="'+t+"; cursor:"+S+'; display:none;" '+R+">"+T+"</video>"):_wppaSlides[p][a]+='style="'+t+"; cursor:"+S+'; display:none; vertical-align:middle;">',_wppaFullNames[p][a]='<span class="sdf-'+p+'" >'+wppaRepairBrTags(r)+"</span>",_wppaNames[p][a]='<span class="sdn-'+p+'" >'+n+"</span>",_wppaFilmThumbTitles[p][a]=n,_wppaDsc[p][a]=o,_wppaOgDsc[p][a]=b,_wppaId[p][a]=l,_wppaRealId[p][a]=s,_wppaAvg[p][a]=d,_wppaDisc[p][a]=u,_wppaMyr[p][a]=_,_wppaVRU[p][a]=m,_wppaLinkUrl[p][a]=c,_wppaLinkTitle[p][a]=h,""!=y?_wppaLinkTarget[p][a]=y:wppaSlideBlank[p]?_wppaLinkTarget[p][a]="_blank":_wppaLinkTarget[p][a]="_self",_wppaCommentHtml[p][a]=g,_wppaIptcHtml[p][a]=x,_wppaExifHtml[p][a]=f,_wppaUrl[p][a]=e,_wppaLbTitle[p][a]=wppaRepairScriptTags(I),_wppaShareUrl[p][a]=j,_wppaShareHtml[p][a]=wppaRepairScriptTags(Q),_wppaHiresUrl[p][a]=v,_wppaVideoHtml[p][a]=T,_wppaAudioHtml[p][a]=N,_wppaVideoNatWidth[p][a]=i,_wppaVideoNatHeight[p][a]=w,_wppaWaitTexts[p][a]=C,_wppaImageAlt[p][a]=k,_wppaFilename[p][a]=F}function wppaSpeed(p,a){_wppaSSRuns[p]&&_wppaSpeed(p,a)}function wppaStopShow(p){_wppaSSRuns[p]&&_wppaStop(p)}function wppaStartStop(p,a){wppaSlideInitRunning[p]&&("start"==wppaSlideInitRunning[p]?a=-1:"stopprev"==wppaSlideInitRunning[p]?a=_wppaSlides[p].length-1:"stopnext"==wppaSlideInitRunning[p]&&(a=0),wppaSlideInitRunning[p]=""),_wppaIsBusy[p]&&(_wppaTP[p]=a),_wppaSSRuns[p]?_wppaStop(p):_wppaStart(p,a),wppaIsMobile&&(jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(10,1).fadeTo(3e3,0),jQuery(".ubb-"+p).stop().fadeTo(10,1).fadeTo(3e3,0))}function wppaBbb(p,a,e){_wppaSSRuns[p]||_wppaBbb(p,a,e)}function wppaUbb(p,a,e){_wppaUbb(p,a,e)}function wppaRateIt(p,a){_wppaRateIt(p,a)}function wppaOvlRateIt(p,a,e,t){_wppaOvlRateIt(p,a,e,t)}function wppaPrev(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaPrev(p)}function wppaPrevN(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaPrevN(p,a)}function wppaFirst(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,0)}function wppaNext(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaNext(p)}function wppaNextN(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaNextN(p,a)}function wppaLast(p){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,_wppaSlides[p].length-1)}function wppaFollowMe(p,a){_wppaSSRuns[p]||_wppaFollowMe(p,a)}function wppaLeaveMe(p,a){_wppaSSRuns[p]||_wppaLeaveMe(p,a)}function wppaGoto(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||_wppaGoto(p,a)}function wppaGotoFilmNoMove(p,a){_wppaDidGoto[p]=!0,_wppaSSRuns[p]||(_wppaFilmNoMove[p]=!0,_wppaGoto(p,a))}function wppaGotoKeepState(p,a){_wppaNxtIdx[p]!=a&&(_wppaDidGoto[p]=!0,_wppaGotoKeepState(p,a))}function _wppaGotoKeepState(p,a){(_wppaSSRuns[p]?_wppaGotoRunning:_wppaGoto)(p,a)}function wppaGotoRunning(p,a){_wppaDidGoto[p]=!0,_wppaGotoRunning(p,a)}function wppaValidateComment(p){return _wppaValidateComment(p)}function _wppaNextSlide(p,a){var e=!document.getElementById("slide_frame-"+p);if(_wppaStopping[p])_wppaStopping[p]=0;else{if(!e&&!wppaIsSlidshowVisible(p))return wppaFilmInit[p]=!1,void setTimeout(function(){_wppaNextSlide(p,a)},400);if(_wppaLastIdx[p]=_wppaCurIdx[p],!document.getElementById("slide_frame-"+p)&&document.getElementById("filmwindow-"+p)&&wppaFilmonlyContinuous)return _wppaSSRuns[p]?(_wppaCurIdx[p]++,_wppaCurIdx[p]==_wppaSlides[p].length&&(_wppaCurIdx[p]=0),_wppaAdjustFilmstrip(p,"linear"),_wppaNxtIdx[p]=_wppaCurIdx[p],void setTimeout("_wppaNextSlide( "+p+", '"+a+"' )",wppaAnimationSpeed)):(_wppaCurIdx[p]=_wppaNxtIdx[p],wppaFilmInit[p]=!1,void _wppaAdjustFilmstrip(p,"linear"));if(document.getElementById("slide_frame-"+p)||document.getElementById("filmwindow-"+p)){var t=_wppaFg[p],e=1-t;if((wppaVideoPlaying[p]||wppaAudioPlaying[p])&&_wppaSSRuns[p])setTimeout("_wppaNextSlide( "+p+", '"+a+"' )",500);else{if(wppaStopVideo(p),wppaStopAudio(p),"auto"==a){if(wppaSlidePause[p])return jQuery("#theimg"+t+"-"+p).attr("title",wppaSlidePause[p]),jQuery("#slide_frame-"+p).attr("title",wppaSlidePause[p]),void setTimeout("_wppaNextSlide( "+p+', "auto" )',250)}else jQuery("#slide_frame-"+p).removeAttr("title");if((_wppaSSRuns[p]||"auto"!=a)&&_wppaSlides[p]&&(!(_wppaSlides[p].length<2)||_wppaFirst[p])){if(_wppaSSRuns[p]||"reset"!=a||(_wppaSSRuns[p]=!0,__wppaOverruleRun=!1),_wppaVoteInProgress=!1,_wppaIsBusy[p]=!0,_wppaSSRuns[p]&&_wppaShowMetaData(p,"hide"),_wppaSSRuns[p]&&(_wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length&&(_wppaNxtIdx[p]=0)),jQuery("#geodiv-"+p+"-"+_wppaId[p][_wppaCurIdx[p]]).css({display:"none"}),jQuery("#geodiv-"+p+"-"+_wppaId[p][_wppaNxtIdx[p]]).css({display:""}),"undefined"!=typeof _wppaLat&&_wppaLat[p]?(n=_wppaRealId[p],_wppaLat[p][n[_wppaNxtIdx[p]]]?(jQuery("#map-canvas-"+p).css("display",""),wppaGeoInit(p,_wppaLat[p][n[_wppaNxtIdx[p]]],_wppaLon[p][n[_wppaNxtIdx[p]]])):jQuery("#map-canvas-"+p).css("display","none")):jQuery("#map-canvas-"+p).css("display","none"),jQuery("[id^=wppa-numbar-"+p+"-]").css({backgroundColor:wppaBGcolorNumbar,borderColor:wppaBcolorNumbar,fontFamily:wppaFontFamilyNumbar,fontSize:wppaFontSizeNumbar,color:wppaFontColorNumbar,fontWeight:wppaFontWeightNumbar}),jQuery("#wppa-numbar-"+p+"-"+_wppaNxtIdx[p]).css({backgroundColor:wppaBGcolorNumbarActive,borderColor:wppaBcolorNumbarActive,fontFamily:wppaFontFamilyNumbarActive,fontSize:wppaFontSizeNumbarActive,color:wppaFontColorNumbarActive,fontWeight:wppaFontWeightNumbarActive}),_wppaSlides[p].length>wppaNumbarMax){var i,w,r=_wppaSlides[p].length-1,n=_wppaNxtIdx[p],o=(wppaNumbarMax-1)/2;n<o?(i=0,w=wppaNumbarMax-1-1,jQuery("#wppa-nbar-"+p+"-lodots").css({display:"none"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})):r-o<n?(i=(w=r)-wppaNumbarMax+1+1,jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"none"})):(w=n+o+.5-1,(i=n-o+1)<2?(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"none"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})):r-1<w?(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"none"})):(jQuery("#wppa-nbar-"+p+"-lodots").css({display:"block"}),jQuery("#wppa-nbar-"+p+"-hidots").css({display:"block"})));for(var l=0;l<_wppaSlides[p].length;)0!=l&&l!=r&&(l<i||w<l)?jQuery("#wppa-numbar-"+p+"-"+l).css({display:"none"}):jQuery("#wppa-numbar-"+p+"-"+l).css({display:"block"}),l++}_wppaFirst[p]?(-1!=_wppaCurIdx[p]&&wppaMakeTheSlideHtml(p,"0",_wppaCurIdx[p]),wppaMakeTheSlideHtml(p,"1",_wppaNxtIdx[p]),jQuery("#imagedesc-"+p).html(_wppaDsc[p][_wppaCurIdx[p]]),jQuery("#imagetitle-"+p).html(wppaMakeNameHtml(p)),"void"==_wppaCommentHtml[p][_wppaCurIdx[p]]?(jQuery("#wppa-comments-"+p).hide(),jQuery("#wppa-comments-"+p).html("")):(jQuery("#wppa-comments-"+p).show(),jQuery("#wppa-comments-"+p).html(_wppaCommentHtml[p][_wppaCurIdx[p]])),jQuery("#iptc-"+p).html(_wppaIptcHtml[p][_wppaCurIdx[p]]),jQuery("#exif-"+p).html(_wppaExifHtml[p][_wppaCurIdx[p]]),"icons"==wppaSlideshowNavigationType?(o=wppaIconSize(p,"1.5em",!1),jQuery("#prev-arrow-"+p).html(wppaSvgHtml("Prev-Button",o,!1,!0)),jQuery("#next-arrow-"+p).html(wppaSvgHtml("Next-Button",o,!1,!0))):wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?(jQuery("#prev-arrow-"+p).html("« "+wppaPrevP),jQuery("#next-arrow-"+p).html(wppaNextP+" »")):(jQuery("#prev-arrow-"+p).html("« "+wppaPreviousPhoto),jQuery("#next-arrow-"+p).html(wppaNextPhoto+" »")),wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRat),jQuery("#wppa-my-rat-"+p).html(wppaMyRat)):(jQuery("#wppa-avg-rat-"+p).html(wppaAvgRating),jQuery("#wppa-my-rat-"+p).html(wppaMyRating))):wppaMakeTheSlideHtml(p,e,_wppaNxtIdx[p]),_wppaLoadSpinner(p),_wppaFirst[p]=!1,_wppaCheckRewind(p),setTimeout("_wppaNextSlide_2( "+p+" )",10)}}}}}function _wppaNextSlide_2(p){var a=_wppaFg[p],e=1-a,t=document.getElementById("theimg"+e+"-"+p);!t||1!=t.nodeType||"IMG"!=t.nodeName||t.complete?(wppaUpdateLightboxes(),_wppaUnloadSpinner(p),-1!=_wppaSSRuns[p]&&(_wppaToTheSame||_wppaShowMetaData(p,"hide")),_wppaFg[p]=1-_wppaFg[p],_wppaFg[p],setTimeout("_wppaNextSlide_3( "+p+" )",10)):setTimeout("_wppaNextSlide_2( "+p+" )",200)}function _wppaNextSlide_3(p){var a=_wppaFg[p],e=1-a,t=_wppaCurIdx[p],i=_wppaNxtIdx[p],w="#theslide"+e+"-"+p,r="#theslide"+a+"-"+p,n="#theimg"+e+"-"+p,o="#theimg"+a+"-"+p,l=parseInt(jQuery(w).css("width")),s=t==i+1?"right":t==i-1?"left":t==i?"none":"nil";switch(t==_wppaSlides[p].length-1&&0==i&&wppaSlideWrap[p]&&(s="left"),0==t&&i==_wppaSlides[p].length-1&&wppaSlideWrap[p]&&(s="right"),"nil"==s&&(s=t<i?"left":"right"),jQuery(w).css({marginLeft:0,width:l}),jQuery(r).css({marginLeft:0,width:l}),wppaFormatSlide(p),wppaAnimationType){case"fadeafter":wppaFadeOut(n,wppaAnimationSpeed),setTimeout(wppaFadeIn(o,wppaAnimationSpeed,_wppaNextSlide_4(p)),wppaAnimationSpeed);break;case"swipe":switch(s){case"left":wppaAnimate(w,{marginLeft:-l},wppaAnimationSpeed,wppaEasingSlide),jQuery(r).css({marginLeft:l}),wppaFadeIn(o,10),wppaAnimate(r,{marginLeft:0},wppaAnimationSpeed,wppaEasingSlide,_wppaNextSlide_4(p));break;case"right":wppaAnimate(w,{marginLeft:l},wppaAnimationSpeed,wppaEasingSlide),jQuery(r).css({marginLeft:-l}),wppaFadeIn(o,10),wppaAnimate(r,{marginLeft:0},wppaAnimationSpeed,wppaEasingSlide,_wppaNextSlide_4(p));break;case"none":wppaFadeIn(o,10),setTimeout("_wppaNextSlide_4( "+p+" )",10)}break;default:wppaFadeOut(n,wppaAnimationSpeed),wppaFadeIn(o,wppaAnimationSpeed,_wppaNextSlide_4(p))}}function _wppaNextSlide_4(p){var a=_wppaFg[p],e="#theslide"+a+"-"+p;jQuery("#theslide"+(1-a)+"-"+p).css({zIndex:80}),jQuery(e).css({zIndex:81}),_wppaCurIdx[p]=_wppaNxtIdx[p],wppaFormatSlide(p),wppaIsMini[p]||wppaGetContainerWidth(p)<wppaMiniTreshold?jQuery("#counter-"+p).html(_wppaCurIdx[p]+1+" / "+_wppaSlides[p].length):jQuery("#counter-"+p).html(wppaPhoto+" "+(_wppaCurIdx[p]+1)+" "+wppaOf+" "+_wppaSlides[p].length),jQuery("#bc-pname-modal-"+p).html(_wppaNames[p][_wppaCurIdx[p]]),jQuery("#bc-pname-"+p).html(_wppaNames[p][_wppaCurIdx[p]]),_wppaAdjustFilmstrip(p,wppaEasingSlide),_wppaSetRatingDisplay(p),setTimeout("_wppaNextSlide_5( "+p+" )",_wppaTextDelay)}function _wppaNextSlide_5(p){var a,e,t;if(_wppaToTheSame||(a=_wppaDsc[p][_wppaCurIdx[p]],jQuery("#imagedesc-"+p).html(a),wppaHideWhenEmpty&&(""==(a=_wppaDsc[p][_wppaCurIdx[p]])||" "==a?jQuery("#descbox-"+p).css("display","none"):jQuery("#descbox-"+p).css("display","")),jQuery("#imagetitle-"+p).html(wppaMakeNameHtml(p)),"void"==_wppaCommentHtml[p][_wppaCurIdx[p]]?(jQuery("#wppa-comments-"+p).hide(),jQuery("#wppa-comments-"+p).html("")):(jQuery("#wppa-comments-"+p).show(),jQuery("#wppa-comments-"+p).html(_wppaCommentHtml[p][_wppaCurIdx[p]])),jQuery("#iptc-"+p).html(_wppaIptcHtml[p][_wppaCurIdx[p]]),jQuery("#exif-"+p).html(_wppaExifHtml[p][_wppaCurIdx[p]]),jQuery("#wppa-share-"+p).html(_wppaShareHtml[p][_wppaCurIdx[p]])),_wppaToTheSame=!1,wppaThumbPageSize?wppaThumbPage[p]=parseInt(((0|wppaSlideOffset[p])+_wppaCurIdx[p])/wppaThumbPageSize)+1:wppaThumbPage[p]=1,_wppaSSRuns[p]&&!wppaSlideWrap[p]&&_wppaCurIdx[p]+1==_wppaSlides[p].length)return _wppaIsBusy[p]=!1,void _wppaStop(p);if(_wppaShowMetaData(p,"show"),-2!=_wppaTP[p]){var i=_wppaTP[p];return _wppaTP[p]=-2,_wppaDidGoto[p]=!1,_wppaIsBusy[p]=!1,wppaIsMini[p]||_bumpViewCount(_wppaId[p][_wppaCurIdx[p]]),_wppaDoAutocol(p,"next_5"),void wppaStartStop(p,i)}wppaUpdateLightboxes(),wppaIsMini[p]||(i=_wppaShareUrl[p][_wppaCurIdx[p]],"undefined"!=typeof wppaQRUpdate&&wppaQRUpdate(_wppaShareUrl[p][_wppaCurIdx[p]]),1<_wppaSlides[p].length&&wppaPushStateSlide(p,_wppaCurIdx[p],i)),_wppaSSRuns[p]?_wppaCurIdx[p]+1==_wppaSlides[p].length?(t=jQuery("#wppa-next-pagelink-"+p),e=jQuery("#wppa-first-pagelink-"+p),0<t.length&&"hidden"!=jQuery(t).css("visibility")?setTimeout(function(){wppaSlideInitRunning[p]="start",jQuery("#wppa-next-pagelink-"+p).trigger("click")},wppaGetSlideshowTimeout(p)):0<e.length?setTimeout(function(){jQuery(e).trigger("click")},wppaGetSlideshowTimeout(p)):setTimeout("_wppaNextSlide( "+p+', "auto" )',wppaGetSlideshowTimeout(p))):setTimeout("_wppaNextSlide( "+p+', "auto" )',wppaGetSlideshowTimeout(p)):_wppaStopping[p]=!1,jQuery(document).trigger("glossaryTooltipReady"),_wppaDidGoto[p]=!1,_wppaIsBusy[p]=!1,wppaIsMini[p]||_bumpViewCount(_wppaId[p][_wppaCurIdx[p]]),wppaStopAudio(p),!wppaSlideAudioStart||0<(t=jQuery(".wppa-audio-"+_wppaId[p][_wppaCurIdx[p]]+"-"+p)).length&&((t=t[t.length-1])&&(wppaAudioPlaying[p]||t.play())),wppaProtect()}function wppaFormatSlide(p){var a="theimg"+_wppaFg[p]+"-"+p,e=document.getElementById(a);if(e){var t="theslide"+_wppaFg[p]+"-"+p,i="slide_frame-"+p,w=jQuery("#wppa-container-"+p).width();wppaColWidth[p]=w;var r=jQuery(".wppa-audio-"+p),n=e.naturalWidth;void 0===n&&(n=parseInt(e.style.maxWidth));var o=e.naturalHeight;void 0===o&&(o=parseInt(e.style.maxHeight));var l=wppaAspectRatio[p],s=wppaFullSize[p],d=wppaFullFrameDelta[p],u=wppaPortraitOnly[p],_=wppaFullValign[p];void 0===_&&(_="none");var m=wppaFullHalign[p];void 0===m&&(m="none");var c,h,y,S,g,x,f,e=wppaStretch;if(u)j=w-d,y=h=0,x=S=w,f=g=(c=parseInt(j*o/n))+d,jQuery("#"+i).css({width:x,height:f}),jQuery("#"+t).css({width:S,height:g}),jQuery("#"+a).css({width:j,height:c});else{if(s<(x=w)&&(x=s),S=x,g=f=parseInt(x*l),e||x-d<=n||f-d<=o?l<(o+d)/(n+d)?(c=f-d,j=parseInt(c*n/o)):(j=x-d,c=parseInt(j*o/n)):(j=n,c=o),"default"!=_&&"none"!=_){switch(_){case"top":y=0;break;case"center":y=parseInt((f-(c+d))/2);break;case"bottom":y=f-(c+d);break;case"fit":y=0,g=f=c+d}jQuery("#"+a).css({marginTop:y,marginBottom:0})}if(jQuery("#"+i).css({width:x,height:f}),jQuery("#"+t).css({width:S,height:g}),jQuery("#"+a).css({width:j,height:c}),"default"!=_&&"none"!=_&&"none"!=m&&"default"!=m){switch(m){case"left":h=0;break;case"center":h=parseInt((w-x)/2);break;case"right":h=w-x}h<0&&(h=0),jQuery("#"+a).css({marginLeft:"auto",marginRight:"auto"}),jQuery("#"+i).css({marginLeft:h})}var i=jQuery(r).height(),I=(x-j)/2;i&&0<i&&(wppaAudioHeight=i,jQuery(r).css({height:wppaAudioHeight,width:j,left:I}))}var j=parseInt(x/3),I=2*j,r=0<r.length?f-wppaAudioHeight-wppaSlideBorderWidth-y:f;jQuery("#bbb-"+p+"-l").css({height:r,width:j,left:0}),jQuery("#bbb-"+p+"-r").css({height:r,width:j,left:I})}}function wppaMakeNameHtml(p){var a,e,t="";if(_wppaCurIdx[p]<0)return"";if("void"==_wppaFullNames[p][_wppaCurIdx[p]])return jQuery("#namebox-"+p).hide(),"";if(jQuery("#namebox-"+p).show(),wppaIsMini[p]||_wppaIsVideo[p][_wppaCurIdx[p]])t=_wppaFullNames[p][_wppaCurIdx[p]];else switch(wppaArtMonkyLink){case"file":case"zip":t=wppaArtMonkeyButton?_wppaFullNames[p][_wppaCurIdx[p]]?(a=-1!=_wppaFullNames[p][_wppaCurIdx[p]].indexOf("plus.png"),e=_wppaFullNames[p][_wppaCurIdx[p]].replace(/(<([^>]+)>)/gi,""),e=a?e.replace(" )"," +)"):e.replace(" )",")"),'<input type="button" title="Download" style="cursor:pointer;margin-bottom:0px;max-width:'+(wppaGetContainerWidth(p)-24)+'px;" class="wppa-download-button" onclick="'+(wppaIsSafari&&"file"==wppaArtMonkyLink?"wppaWindowReference = window.open();":"")+"wppaAjaxMakeOrigName( "+p+", '"+_wppaId[p][_wppaCurIdx[p]]+'\' );" value="'+wppaDownLoad+": "+e+'" />'):"":wppaArtmonkeyFileNotSource?'<a href="'+_wppaUrl[p][_wppaCurIdx[p]]+'" title="Download" style="cursor:pointer;" download="'+_wppaFilename[p][_wppaCurIdx[p]]+'" >'+wppaDownLoad+": "+_wppaFullNames[p][_wppaCurIdx[p]]+"</a>":'<a title="Download" style="cursor:pointer;" onclick="'+(wppaIsSafari&&"file"==wppaArtMonkyLink?"wppaWindowReference = window.open();":"")+"wppaAjaxMakeOrigName( "+p+", '"+_wppaId[p][_wppaCurIdx[p]]+"' );\" >"+wppaDownLoad+": "+_wppaFullNames[p][_wppaCurIdx[p]]+"</a>";break;case"none":case"new":t=_wppaFullNames[p][_wppaCurIdx[p]];break;default:t=""}return t=wppaRepairBrTags(t)}function wppaMakeTheSlideHtml(p,a,e){var t,i,w=_wppaIsVideo[p][e]?"video":"img",r="title";"wppa"==wppaLightBox[p]&&(r="data-lbtitle");var n,o,l=""==wppaLightBox[p]?' onpause="wppaVideoPlaying['+p+'] = false;" onplay="wppaVideoPlaying['+p+'] = true;"':"";if(""!=_wppaLinkUrl[p][e])t=wppaSlideToFullpopup?'<a onclick="wppaStopAudio();wppaStopShow('+p+");"+_wppaLinkUrl[p][e]+'" target="'+_wppaLinkTarget[p][e]+'" title="'+_wppaLinkTitle[p][e]+'"><'+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e]+"</a>":"<a onclick=\"_bumpClickCount('"+_wppaId[p][e]+"');wppaStopAudio();wppaStopShow("+p+");window.open('"+_wppaLinkUrl[p][e]+"', '"+_wppaLinkTarget[p][e]+'\');" title="'+_wppaLinkTitle[p][e]+'"><'+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e]+"</a>";else if(""==wppaLightBox[p])t="<"+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e];else{for(var s="",d=0,u=wppaLightboxSingle[p]?"":"[slide-"+p+"-"+a+"]";d<e;)i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][d]:wppaMakeFullsizeUrl(_wppaUrl[p][d]),o=".pdf"==(n=_wppaHiresUrl[p][d]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][d]+'" data-videonatheight="'+_wppaVideoNatHeight[p][d]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][d])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][d])+'"':"")+" "+r+'="'+_wppaLbTitle[p][d]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+"></a>",d++;for(i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][e]:wppaMakeFullsizeUrl(_wppaUrl[p][e]),o=".pdf"==(n=_wppaHiresUrl[p][e]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(wppaSlideLinkEqual?' onclick="wppaStopAudio();wppaStopShow('+p+");jQuery('#wppa-film-"+e+"-"+p+"').trigger('click');return false;\"":' onclick="wppaStopAudio();wppaStopShow('+p+');"')+' style="cursor:pointer;" target="'+_wppaLinkTarget[p][e]+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][e]+'" data-videonatheight="'+_wppaVideoNatHeight[p][e]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][e])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][e])+'"':"")+" "+r+'="'+_wppaLbTitle[p][e]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+">"+(o?"<iframe "+l+' src="'+n+'" title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" style="width:100%;height:100%;" ></iframe>':"<"+w+l+' title="'+_wppaLinkTitle[p][e]+'" id="theimg'+a+"-"+p+'" '+_wppaSlides[p][e])+"</a>",d=e+1;d<_wppaUrl[p].length;)i=wppaOvlHires||"wppa"!=wppaLightBox[p]?_wppaHiresUrl[p][d]:wppaMakeFullsizeUrl(_wppaUrl[p][d]),o=".pdf"==(n=_wppaHiresUrl[p][d]).substr(n.length-4,n.length),s+='<a href="'+i+'"'+(_wppaIsVideo[p][d]?' data-videonatwidth="'+_wppaVideoNatWidth[p][d]+'" data-videonatheight="'+_wppaVideoNatHeight[p][d]+'" data-videohtml="'+encodeURI(_wppaVideoHtml[p][d])+'"':"")+(o?" data-pdfhtml=\"src='"+n+"'\"":"")+(""!=_wppaAudioHtml[p][d]?' data-audiohtml="'+encodeURI(_wppaAudioHtml[p][d])+'"':"")+" "+r+'="'+_wppaLbTitle[p][d]+'" '+(wppaSlideLinkEqual?"":wppaRel+'="'+wppaLightBox[p]+u+'"')+"></a>",d++;t=s}""!=_wppaAudioHtml[p][e]&&(t+='<audio controls id="wppa-audio-'+_wppaId[p][e]+"-"+p+'" class="wppa-audio-'+p+" wppa-audio-"+_wppaId[p][e]+"-"+p+'" data-from="wppa" onplay="wppaAudioPlaying['+p+'] = true;" onpause="wppaAudioPlaying['+p+'] = false" style="position:relative;top:-'+(wppaAudioHeight+wppaSlideBorderWidth)+"px;z-index:10;width:"+_wppaVideoNatWidth[p][e]+'px;padding:0;box-sizing:border-box;" >'+_wppaAudioHtml[p][e]+"</audio>"),t=t.replace(/title=""/g,""),jQuery("#theslide"+a+"-"+p).html(t)}function wppaAdjustAllFilmstrips(p){jQuery(".wppa-filmstrip").each(function(){_wppaAdjustFilmstrip(jQuery(this).attr("id").substr(15),p)})}var wppaLastAnimFilmLoc=[];function _wppaAdjustFilmstrip(p,a){if("linear"!=a&&(a=wppaEasingSlide),document.getElementById("wppa-filmstrip-"+p)&&_wppaSlides[p]){var e,t,i,w,r=!document.getElementById("slide_frame-"+p);if(wppaLastAnimFilmLoc[p]||(wppaLastAnimFilmLoc[p]=0),r){var n=jQuery("#wppa-filmstrip-"+p);if(!wppaIsElementInViewport(n))return}if(r||jQuery(".wppa-film-"+p).removeClass("wppa-filmthumb-active"),_wppaFilmNoMove[p]&&wppaFilmInit[p]?_wppaFilmNoMove[p]=!1:(e=wppaFilmStripLength[p]/2-(_wppaCurIdx[p]+.5+wppaPreambule[p])*wppaThumbnailPitch[p]-wppaFilmStripMargin[p],wppaFilmShowGlue&&(e-=2*wppaFilmStripMargin[p]+2),i=e+wppaThumbnailPitch[p],w=e-wppaThumbnailPitch[p],t=wppaAnimationSpeed,wppaFilmInit[p]||(t=1),0==_wppaCurIdx[p]&&_wppaLastIdx[p]==_wppaSlides[p].length-1?(jQuery("#wppa-filmstrip-"+p).css({marginLeft:i+"px"}),wppaLastAnimFilmLoc[p]!=e&&(wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e)):0==_wppaLastIdx[p]&&_wppaCurIdx[p]==_wppaSlides[p].length-1?(jQuery("#wppa-filmstrip-"+p).css({marginLeft:w}),wppaLastAnimFilmLoc[p]!=e&&(wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e)):(n=parseInt(jQuery("#wppa-filmstrip-"+p).css("margin-left")),i=parseInt(e),w=wppaThumbnailPitch[p],_wppaSSRuns[p]?(n<i?2:i<n-2*w?1:0)&&jQuery("#wppa-filmstrip-"+p).css({marginLeft:i+w}):(i<n-1.5*w||n+1.5*w<i)&&jQuery("#wppa-filmstrip-"+p).css({marginLeft:i}),wppaAnimate("#wppa-filmstrip-"+p,{marginLeft:e},t,a),wppaLastAnimFilmLoc[p]=e,wppaFilmInit[p]=!0),_wppaLastIdx[p]=_wppaCurIdx[p]),wppaMakeLazyVisible("filmstripmocc="+p),!r&&-1!=_wppaCurIdx[p]){_wppaCurIdx[p];_wppaCurIdx[p]+10>_wppaSlides[p].length&&_wppaSlides[p].length;for(var o=0;o<_wppaSlides[p].length;)jQuery("#film_wppatnf_"+_wppaId[p][o]+"_"+p).html()&&(""!=jQuery("#wppa-film-"+o+"-"+p).attr("data-title")?(jQuery("#wppa-film-"+o+"-"+p).attr("title",jQuery("#wppa-film-"+o+"-"+p).attr("data-title")),jQuery("#wppa-pre-"+o+"-"+p).attr("title",jQuery("#wppa-film-"+o+"-"+p).attr("data-title"))):""!=wppaFilmThumbTitle&&_wppaCurIdx[p]==o?(jQuery("#wppa-film-"+o+"-"+p).attr("title",wppaFilmThumbTitle),jQuery("#wppa-pre-"+o+"-"+p).attr("title",wppaFilmThumbTitle)):(jQuery("#wppa-film-"+o+"-"+p).attr("title",wppaClickToView+" "+_wppaFilmThumbTitles[p][o]),jQuery("#wppa-pre-"+o+"-"+p).attr("title",wppaClickToView+" "+_wppaFilmThumbTitles[p][o]))),o++}r||jQuery("#wppa-film-"+_wppaCurIdx[p]+"-"+p).addClass("wppa-filmthumb-active")}}function _wppaNext(p){var a,e;!wppaSlideWrap[p]&&_wppaCurIdx[p]==_wppaSlides[p].length-1||(_wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length?(a=jQuery("#wppa-next-pagelink-"+p),e=jQuery("#wppa-first-pagelink-"+p),0<a.length&&"hidden"!=jQuery(a).css("visibility")?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopnext",jQuery("#wppa-next-pagelink-"+p).trigger("click")):0<e.length?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopnext",jQuery(e).trigger("click")):_wppaNextSlide(p,_wppaNxtIdx[p]=0)):_wppaNextSlide(p,0))}function _wppaNextN(p,a){if(wppaSlideWrap[p]||!(_wppaCurIdx[p]>=_wppaSlides[p].length-a)){for(_wppaNxtIdx[p]=_wppaCurIdx[p]+a;_wppaNxtIdx[p]>=_wppaSlides[p].length;)_wppaNxtIdx[p]-=_wppaSlides[p].length;_wppaNextSlide(p,0)}}function _wppaNextOnCallback(p){if(wppaSlideWrap[p]||_wppaCurIdx[p]!=_wppaSlides[p].length-1){if(_wppaSkipRated[p]){var a=_wppaCurIdx[p]+1;a==_wppaSlides[p].length&&(a=0);var e=a;if(0!=_wppaMyr[p][e]){for(++a==_wppaSlides[p].length&&(a=0);a!=e&&0!=_wppaMyr[p][a];)++a==_wppaSlides[p].length&&(a=0);e=a}_wppaNxtIdx[p]=e}else _wppaNxtIdx[p]=_wppaCurIdx[p]+1,_wppaNxtIdx[p]==_wppaSlides[p].length&&(_wppaNxtIdx[p]=0);_wppaNextSlide(p,0)}}function _wppaPrev(p){!wppaSlideWrap[p]&&0==_wppaCurIdx[p]||(_wppaNxtIdx[p]=_wppaCurIdx[p]-1,_wppaNxtIdx[p]<0?jQuery("#wppa-prev-page-last-item-"+p).length?(wppaSlideInitRunning[p]=_wppaSSRuns[p]?"start":"stopprev",jQuery("#wppa-prev-page-last-item-"+p).trigger("click")):(_wppaNxtIdx[p]+=_wppaSlides[p].length,_wppaNextSlide(p,0)):_wppaNextSlide(p,0))}function _wppaPrevN(p,a){if(wppaSlideWrap[p]||!(_wppaCurIdx[p]<a)){for(_wppaNxtIdx[p]=_wppaCurIdx[p]-a;_wppaNxtIdx[p]<0;)_wppaNxtIdx[p]+=_wppaSlides[p].length;_wppaNextSlide(p,0)}}function _wppaGoto(p,a){_wppaToTheSame=_wppaNxtIdx[p]==a,_wppaNxtIdx[p]=a,_wppaNextSlide(p,0)}function _wppaGotoRunning(p,a){_wppaIsBusy[p]?setTimeout("_wppaGotoRunning( "+p+","+a+" )",10):(_wppaSSRuns[p]=!1,_wppaToTheSame=_wppaNxtIdx[p]==a,_wppaNxtIdx[p]=a,__wppaOverruleRun=!0,_wppaNextSlide(p,"manual"),_wppaGotoContinue(p))}function _wppaGotoContinue(p){_wppaIsBusy[p]?setTimeout("_wppaGotoContinue( "+p+" )",10):setTimeout("_wppaNextSlide( "+p+', "reset" )',wppaGetSlideshowTimeout(p)+10)}function _wppaStart(p,a){if(_wppaStopping[p])return _wppaStopping[p]--,void setTimeout(function(){_wppaStart(p,a)},(wppaAnimationSpeed+wppaGetSlideshowTimeout(p))/10);_wppaSSRuns[p]||(("icons"==wppaSlideshowNavigationType?_wppaStartIcons:_wppaStartText)(p,a),jQuery("#wppa-startstop-icon-"+p).html(wppaSvgHtml("Pause-Button",wppaIconSize(p,"48px",!0),!1,!0,"0","10","50","50")))}function _wppaStartIcons(p,a){if(-2==a){var e=0;if(a=0,_wppaSkipRated[p]=!0,0!=_wppaMyr[p][e])for(;e<_wppaSlides[p].length;)0==a&&0==_wppaMyr[p][e]&&(a=e),e++}var t=wppaIconSize(p,"1.5em",!1);-1<a?(jQuery("#startstop-"+p).html(wppaSvgHtml("Play-Button",t,!1,!0,"0","10","20","50")),jQuery("#speed0-"+p).hide(),jQuery("#speed1-"+p).hide(),_wppaNxtIdx[p]=a,_wppaCurIdx[p]=a,_wppaNextSlide(p,0),_wppaShowMetaData(p,"show")):(_wppaSSRuns[p]=!0,_wppaNextSlide(p,0),jQuery("#startstop-"+p).html(wppaSvgHtml("Pause-Button",t,!1,!0,"0","10","20","50")),jQuery("#speed0-"+p).show(),jQuery("#speed1-"+p).show(),_wppaShowMetaData(p,"hide"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(wppaSlideShow)),_wppaSetRatingDisplay(p)}function _wppaStartText(p,a){if(-2==a){var e=0;if(a=0,_wppaSkipRated[p]=!0,0!=_wppaMyr[p][e])for(;e<_wppaSlides[p].length;)0==a&&0==_wppaMyr[p][e]&&(a=e),e++}-1<a?(jQuery("#startstop-"+p).html(wppaStart+" "+wppaSlideShow),jQuery("#speed0-"+p).css("display","none"),jQuery("#speed1-"+p).css("display","none"),_wppaNxtIdx[p]=a,_wppaCurIdx[p]=a,_wppaNextSlide(p,0),_wppaShowMetaData(p,"show")):(_wppaSSRuns[p]=!0,_wppaNextSlide(p,0),jQuery("#startstop-"+p).html(wppaStop),jQuery("#speed0-"+p).css("display","inline"),jQuery("#speed1-"+p).css("display","inline"),_wppaShowMetaData(p,"hide"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(wppaSlideShow)),_wppaSetRatingDisplay(p)}function _wppaStop(p){_wppaStopping[p]=12,("icons"==wppaSlideshowNavigationType?_wppaStopIcons:_wppaStopText)(p),jQuery("#wppa-startstop-icon-"+p).html(wppaSvgHtml("Play-Button",wppaIconSize(p,"48px",!0),!1,!0,"0","10","50","50"))}function _wppaStopIcons(p){_wppaSSRuns[p]=!1,jQuery("#startstop-"+p).html(wppaSvgHtml("Play-Button",wppaIconSize(p,"1.5em",!1),!1,!0)),jQuery("#speed0-"+p).hide(),jQuery("#speed1-"+p).hide(),_wppaShowMetaData(p,"show"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(_wppaNames[p][_wppaCurIdx[p]])}function _wppaStopText(p){_wppaSSRuns[p]=!1,jQuery("#startstop-"+p).html(wppaStart+" "+wppaSlideShow),jQuery("#speed0-"+p).css("display","none"),jQuery("#speed1-"+p).css("display","none"),_wppaShowMetaData(p,"show"),(jQuery("#bc-pname-modal-"+p)?jQuery("#bc-pname-modal-"+p):jQuery("#bc-pname-"+p)).html(_wppaNames[p][_wppaCurIdx[p]])}function _wppaSpeed(p,a){"random"!=_wppaTimeOut[p]&&(a?500<_wppaTimeOut[p]&&(_wppaTimeOut[p]/=1.5):_wppaTimeOut[p]<6e4&&(_wppaTimeOut[p]*=1.5))}function _wppaLoadSpinner(p){}function _wppaUnloadSpinner(p){jQuery("#wppa-slide-spin-"+p).stop().fadeOut(),setTimeout(function(){jQuery("#wppa-slide-spin-"+p).stop().fadeOut()},1e3)}function _wppaCheckRewind(p){var a,e;document.getElementById("wppa-filmstrip-"+p)&&((e=Math.abs(_wppaCurIdx[p]-_wppaNxtIdx[p]))<=wppaFilmPageSize[p]||(1+wppaFilmStripLength[p]/wppaThumbnailPitch[p])/2<=e&&(a=wppaThumbnailPitch[p]*_wppaSlides[p].length,wppaFilmShowGlue&&(a+=2+2*wppaFilmStripMargin[p]),e=parseInt(jQuery("#wppa-filmstrip-"+p).css("margin-left")),_wppaNxtIdx[p]>_wppaCurIdx[p]?e-=a:e+=a,jQuery("#wppa-filmstrip-"+p).css("margin-left",e+"px")))}function _wppaSetRatingDisplay(p){if(document.getElementById("wppa-rating-"+p)){var a,e,t=_wppaAvg[p][_wppaCurIdx[p]];if(void 0!==t){if("likes"==wppaRatingDisplayType){"void"==(e=_wppaMyr[p][_wppaCurIdx[p]])?(jQuery("#wppa-dislike-imgdiv-"+p).hide(),jQuery("#wppa-like-imgdiv-"+p).hide()):(jQuery("#wppa-dislike-imgdiv-"+p).show(),jQuery("#wppa-like-imgdiv-"+p).show());var w=t.split("|");return jQuery("#wppa-like-"+p).attr("title",w[0]),jQuery("#wppa-liketext-"+p).html(w[1]),void("1"==_wppaMyr[p][_wppaCurIdx[p]]?jQuery("#wppa-like-"+p).attr("src",wppaImageDirectory+"thumbdown.png"):jQuery("#wppa-like-"+p).attr("src",wppaImageDirectory+"thumbup.png"))}if(t=(a=t.split("|"))[0],w=a[1],a=_wppaDisc[p][_wppaCurIdx[p]],e=_wppaMyr[p][_wppaCurIdx[p]],"void"==a)jQuery("#wppa-rating-"+p).hide();else{if(jQuery("#wppa-rating-"+p).show(),"graphic"==wppaRatingDisplayType)_wppaSetRd(p,t,"#wppa-avg-"),_wppaSetRd(p,e,"#wppa-rate-"),0==e?(jQuery("#wppa-dislike-"+p).css("display","inline"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","inline"),document.getElementById("wppa-dislike-"+p)&&jQuery("#wppa-filler-"+p).css("display","none"),jQuery("#wppa-dislike-"+p).stop().fadeTo(100,wppaStarOpacity)):(jQuery("#wppa-dislike-"+p).css("display","none"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","none"),jQuery("#wppa-filler-"+p).css("display","inline"),jQuery("#wppa-filler-"+p).stop().fadeTo(100,wppaStarOpacity),jQuery("#wppa-filler-"+p).attr("title",a));else{if(jQuery("#wppa-numrate-avg-"+p).html(t+" ( "+w+" ) "),jQuery(".wppa-my-rat-"+p).show(),"void"==e)jQuery("#wppa-numrate-mine-"+p).html(""),jQuery(".wppa-my-rat-"+p).hide();else if(wppaRatingOnce&&0<e)jQuery("#wppa-numrate-mine-"+p).html(e);else if(e<0)jQuery("#wppa-numrate-mine-"+p).html(" dislike");else{var r="";for(i=1;i<=wppaRatingMax;i++)e==i?r+='<span class="wppa-rating-numeric-mine" style="cursor:pointer; font-weight:bold;" onclick="_wppaRateIt( '+p+", "+i+' )"> '+i+" </span>":(e>i-1&&e<i&&(r+=" ( "+e+" ) "),r+='<span class="wppa-rating-numeric" style="cursor:pointer;" onclick="_wppaRateIt( '+p+", "+i+' )" onmouseover="this.style.fontWeight=\'bold\'" onmouseout="this.style.fontWeight=\'normal\'" > '+i+" </span>");jQuery("#wppa-numrate-mine-"+p).html(r)}0==e?(jQuery("#wppa-dislike-"+p).css("display","inline"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","inline"),jQuery("#wppa-filler-"+p).css("display","none"),jQuery("#wppa-dislike-"+p).stop().fadeTo(100,wppaStarOpacity)):(jQuery("#wppa-dislike-"+p).css("display","none"),jQuery("#wppa-dislike-imgdiv-"+p).css("display","none"),jQuery("#wppa-filler-"+p).css("display","inline")),jQuery("#wppa-discount-"+p).html(a+"• "),jQuery("#wppa-filler-"+p).css("display","none")}0==e?jQuery("#wppa-vote-button-"+p).val(wppaVoteForMe):jQuery("#wppa-vote-button-"+p).val(wppaVotedForMe),jQuery("#wppa-vote-count-"+p).html(w)}}}}function wppaGetDislikeText(p,a,e){return p}function _wppaSetRd(p,a,e){var t=parseInt(a),i=t+1,w=wppaStarOpacity+(a-t)*(1-wppaStarOpacity),r=wppaRatingMax;if("void"==a)jQuery("#wppa-my-rat-"+p).hide(),jQuery(".wppa-my-rat-"+p).hide(),jQuery(".wppa-rate-"+p).hide(),jQuery(".wppa-ratingthumb").hide(),jQuery("#wppa-numrate-mine-"+p).hide();else for(jQuery("#wppa-my-rat-"+p).show(),jQuery(".wppa-my-rat-"+p).show(),jQuery(".wppa-rate-"+p).show(),jQuery(".wppa-ratingthumb").show(),jQuery("#wppa-numrate-mine-"+p).show(),idx=1;idx<=r;idx++)"#wppa-rate-"!=e&&".wppa-rate-"!=e||jQuery(e+p+"-"+idx).attr("src")!=wppaImageDirectory+"star.ico"&&jQuery(e+p+"-"+idx).attr("src",wppaImageDirectory+"star.ico"),idx<=t?jQuery(e+p+"-"+idx).stop().fadeTo(100,1):idx==i?jQuery(e+p+"-"+idx).stop().fadeTo(100,w):jQuery(e+p+"-"+idx).stop().fadeTo(100,wppaStarOpacity)}function _wppaFollowMe(p,a){_wppaSSRuns[p]||0!=_wppaMyr[p][_wppaCurIdx[p]]&&wppaRatingOnce||_wppaMyr[p][_wppaCurIdx[p]]<0||_wppaVoteInProgress||_wppaSetRd(p,a,"#wppa-rate-")}function wppaOvlFollowMe(p,a,e){e||_wppaSetRd(p,a,".wppa-rate-")}function _wppaLeaveMe(p,a){_wppaSSRuns[p]||0!=_wppaMyr[p][_wppaCurIdx[p]]&&wppaRatingOnce||_wppaMyr[p][_wppaCurIdx[p]]<0||_wppaVoteInProgress||_wppaSetRd(p,_wppaMyr[p][_wppaCurIdx[p]],"#wppa-rate-")}function wppaOvlLeaveMe(p,a,e){_wppaSetRd(p,e,".wppa-rate-")}function _wppaValidateComment(p,a){if(a=a||_wppaId[p][_wppaCurIdx[p]],jQuery("#wppa-comname-"+p).val().length<1)return alert(wppaPleaseName),!1;if("required"==wppaEmailRequired||"optional"==wppaEmailRequired){var e=jQuery("#wppa-comemail-"+p).val();if("optional"==wppaEmailRequired&&0==e.length)return!0;var t=e.indexOf("@"),a=e.lastIndexOf(".");if(t<1||a<t+2||a+2>=e.length)return alert(wppaPleaseEmail),!1}return!(jQuery("#wppa-comment-"+p).val().length<1)||(alert(wppaPleaseComment),!1)}function _wppaGo(p){document.location=p}function _wppaBbb(p,a,e){if(!_wppaSSRuns[p]){var t="#bbb-"+p+"-"+a;switch(e){case"show":"l"==a&&jQuery(t).attr("title",wppaPreviousPhoto),"r"==a&&jQuery(t).attr("title",wppaNextPhoto),jQuery(".bbb-"+p).css("cursor","pointer");break;case"hide":jQuery(".bbb-"+p).removeAttr("title"),jQuery(".bbb-"+p).css("cursor","default");break;case"click":"l"==a&&wppaPrev(p),"r"==a&&wppaNext(p);break;default:alert("Unimplemented instruction: "+e+" on: "+t)}}}function _wppaUbb(p,a,e){var t="#ubb-"+p+"-"+a;switch(e){case"show":"l"==a&&jQuery(t).attr("title",wppaPreviousPhoto),"r"==a&&jQuery(t).attr("title",wppaNextPhoto),jQuery(".ubb-"+p).css("cursor","pointer"),jQuery(".ubb-"+p).stop().fadeTo(200,.8),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,.8);break;case"hide":jQuery(".ubb-"+p).removeAttr("title"),jQuery(".ubb-"+p).css("cursor","default"),wppaIsMobile?jQuery(".ubb-"+p).stop().fadeTo(200,.1):jQuery(".ubb-"+p).stop().fadeTo(200,0),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,0);break;case"click":wppaIsMobile&&(jQuery(".ubb-"+p).stop().fadeTo(200,1).fadeTo(1e3,0),jQuery("#wppa-startstop-icon-"+p).stop().fadeTo(200,1).fadeTo(1e3,0)),"l"==a&&wppaPrev(p),"r"==a&&wppaNext(p);break;default:alert("Unimplemented instruction: "+e+" on: "+t)}}function wppaOpenComments(p){_wppaSSRuns[p]&&_wppaStop(p),jQuery("#wppa-comtable-wrap-"+p).css("display","block"),jQuery("#wppa-comform-wrap-"+p).css("display","block"),jQuery("#wppa-comfooter-wrap-"+p).css("display","none"),wppaColWidth[p]=0,setTimeout("_wppaDoAutocol( "+p+" )",100)}function _wppaShowMetaData(p,a){_wppaSlides[p]&&(_wppaSSRuns[p]||__wppaOverruleRun?"show"==a?wppaFotomotoHideWhenRunning||wppaFotomotoToolbar(p,_wppaHiresUrl[p][_wppaCurIdx[p]]):wppaShareHideWhenRunning&&jQuery("#wppa-share-"+p).css("display","none"):"show"==a?(wppaAutoOpenComments&&(jQuery("#wppa-comtable-wrap-"+p).css("display","block"),jQuery("#wppa-comform-wrap-"+p).css("display","block"),jQuery("#wppa-comfooter-wrap-"+p).css("display","none")),0!=_wppaCurIdx[p]&&jQuery(".wppa-first-"+p).show(),_wppaCurIdx[p]!=_wppaSlides[p].length-1&&jQuery(".wppa-last-"+p).show(),wppaShareHideWhenRunning&&jQuery("#wppa-share-"+p).css("display",""),wppaFotomotoToolbar(p,_wppaHiresUrl[p][_wppaCurIdx[p]])):(jQuery("#wppa-comtable-wrap-"+p).css("display","none"),jQuery("#wppa-comform-wrap-"+p).css("display","none"),jQuery("#wppa-comfooter-wrap-"+p).css("display","block"),wppaFotomotoHide(p)),"show"==a?(jQuery("#imagedesc-"+p).css("visibility","visible"),jQuery("#imagetitle-"+p).css("visibility","visible"),jQuery("#counter-"+p).css("visibility","visible"),jQuery("#iptccontent-"+p).css("visibility","visible"),jQuery("#exifcontent-"+p).css("visibility","visible")):(jQuery("#counter-"+p).css("visibility","hidden"),jQuery(".wppa-first-"+p).hide(),jQuery(".wppa-last-"+p).hide(),jQuery("#iptccontent-"+p).css("visibility","hidden"),jQuery("#exifcontent-"+p).css("visibility","hidden")))}function wppaGetSlideshowTimeout(p){var a,e;return"random"==_wppaTimeOut[p]?(a=2*wppaAnimationSpeed,e=7*wppaAnimationSpeed,Math.floor(Math.random()*(e-a+1))+a):_wppaTimeOut[p]}function wppaIsSlidshowVisible(p){for(var a,e=["slide_frame-"+p,"filmwindow-"+p],t=e.length,i=0;i<t;i++)if(a=document.getElementById(e[i]),a&&(a.getBoundingClientRect(),wppaIsElementInViewport(a)))return!0;return wppaFilmInit[p]=!1}
|
js/wppa-zoom.js
CHANGED
@@ -2,39 +2,20 @@
|
|
2 |
//
|
3 |
// contains wppa functions for simple zoomable photos
|
4 |
//
|
5 |
-
var wppaJsZoomVersion = '8.
|
6 |
|
7 |
// The main proccedure
|
8 |
function wppaDoZoomPan(mocc, xdata) {
|
9 |
|
10 |
-
|
11 |
-
|
12 |
-
|
13 |
-
|
14 |
-
|
15 |
-
if ( data.initialized ) return;
|
16 |
-
if ( data.abort ) return;
|
17 |
-
|
18 |
-
// If lightbox, show spinner
|
19 |
-
if ( data.isLightbox ) {
|
20 |
-
$("#wppa-ovl-spin").show();
|
21 |
-
$("#wppa-ovl-zoom-container").hide();
|
22 |
-
}
|
23 |
-
|
24 |
-
// Wait until the image file has been completely loaded
|
25 |
-
if ( ! data.image.complete ) {
|
26 |
-
setTimeout( function() {wppaDoZoomPan(mocc)}, 200 );
|
27 |
-
return;
|
28 |
-
}
|
29 |
-
|
30 |
-
// Make sure css does not spoil the sizes
|
31 |
-
$(image).css({
|
32 |
-
width :image.naturalWidth,
|
33 |
-
height :image.naturalHeight,
|
34 |
-
maxWidth :image.naturalWidth,
|
35 |
-
maxHeight :image.naturalHeight
|
36 |
-
});
|
37 |
|
|
|
|
|
|
|
38 |
// Find additional data
|
39 |
data.manual = false;
|
40 |
data.deltaX = 0;
|
@@ -71,51 +52,44 @@ function wppaDoZoomPan(mocc, xdata) {
|
|
71 |
data.time = 0;
|
72 |
|
73 |
// Install event listeners
|
74 |
-
|
75 |
-
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
-
|
86 |
-
|
87 |
-
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
-
|
96 |
-
|
97 |
-
|
98 |
-
|
99 |
-
|
100 |
-
|
101 |
-
|
102 |
-
|
103 |
-
|
104 |
-
|
105 |
-
|
106 |
-
|
107 |
-
|
108 |
-
|
109 |
-
|
110 |
-
|
111 |
-
|
112 |
-
data.zoomin.off("mousedown");
|
113 |
-
data.zoomin.on("mousedown", function(e){plusDown(mocc, e)});
|
114 |
-
data.zoomin.off("mouseup");
|
115 |
-
data.zoomin.on("mouseup", function(e){buttonUp(mocc, e)});
|
116 |
-
data.zoomout.on("mousedown", function(e){minDown(mocc, e)});
|
117 |
-
data.zoomout.on("mouseup", function(e){buttonUp(mocc, e)});
|
118 |
-
|
119 |
|
120 |
// Common event handlers
|
121 |
if ( data.isLightbox ) {
|
@@ -457,7 +431,7 @@ function wppaDoZoomPan(mocc, xdata) {
|
|
457 |
update(mocc, {
|
458 |
deltaX :delta,
|
459 |
buttondown :true,
|
460 |
-
manual
|
461 |
});
|
462 |
render(mocc);
|
463 |
}
|
2 |
//
|
3 |
// contains wppa functions for simple zoomable photos
|
4 |
//
|
5 |
+
var wppaJsZoomVersion = '8.2.01.001';
|
6 |
|
7 |
// The main proccedure
|
8 |
function wppaDoZoomPan(mocc, xdata) {
|
9 |
|
10 |
+
// Handy shorthand
|
11 |
+
var $ = jQuery;
|
12 |
+
|
13 |
+
// Store the data
|
14 |
+
wppaZoomData[mocc] = xdata;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
15 |
|
16 |
+
// Update data with image
|
17 |
+
var data = update(mocc,{image:document.getElementById( "wppa-" + xdata.itemId )});
|
18 |
+
|
19 |
// Find additional data
|
20 |
data.manual = false;
|
21 |
data.deltaX = 0;
|
52 |
data.time = 0;
|
53 |
|
54 |
// Install event listeners
|
55 |
+
data.right.on("touchstart", function(e){rightDown(mocc, e)});
|
56 |
+
data.right.on("touchend", function(e){buttonUp(mocc, e)});
|
57 |
+
data.left.on("touchstart", function(e){leftDown(mocc, e)});
|
58 |
+
data.left.on("touchend", function(e){buttonUp(mocc, e)});
|
59 |
+
data.up.on("touchstart", function(e){upDown(mocc, e)});
|
60 |
+
data.up.on("touchend", function(e){buttonUp(mocc, e)});
|
61 |
+
data.down.on("touchstart", function(e){downDown(mocc, e)});
|
62 |
+
data.down.on("touchend", function(e){buttonUp(mocc, e)});
|
63 |
+
data.zoomin.on("touchstart", function(e){plusDown(mocc, e)});
|
64 |
+
data.zoomin.on("touchend", function(e){buttonUp(mocc, e)});
|
65 |
+
data.zoomout.on("touchstart", function(e){minDown(mocc, e)});
|
66 |
+
data.zoomout.on("touchend", function(e){buttonUp(mocc, e)});
|
67 |
+
|
68 |
+
data.canvas.addEventListener("touchstart", function(e){canvasDown(mocc, e)});
|
69 |
+
data.canvas.addEventListener("touchmove", function(e){canvasMove(mocc, e)});
|
70 |
+
data.canvas.addEventListener("touchend", function(e){canvasUp(mocc,e)});
|
71 |
+
data.canvas.addEventListener("mousedown", function(e){canvasDown(mocc, e)});
|
72 |
+
data.canvas.addEventListener("mousemove", function(e){canvasMove(mocc, e)});
|
73 |
+
data.canvas.addEventListener("mouseup", function(e){canvasUp(mocc, e)});
|
74 |
+
data.canvas.addEventListener("mouseleave", function(e){canvasLeave(mocc, e)});
|
75 |
+
data.canvas.addEventListener("mouseenter", function(e){canvasEnter(mocc, e)});
|
76 |
+
|
77 |
+
document.getElementById("wppa-pan-canvas-" + data.itemId ).addEventListener("wheel", function(e){onDivWheel(mocc, e)});
|
78 |
+
|
79 |
+
data.right.on("mousedown", function(e){rightDown(mocc, e)});
|
80 |
+
data.right.on("mouseup", function(e){buttonUp(mocc, e)});
|
81 |
+
data.left.on("mousedown", function(e){leftDown(mocc, e)});
|
82 |
+
data.left.on("mouseup", function(e){buttonUp(mocc, e)});
|
83 |
+
data.up.on("mousedown", function(e){upDown(mocc, e)});
|
84 |
+
data.up.on("mouseup", function(e){buttonUp(mocc, e)});
|
85 |
+
data.down.on("mousedown", function(e){downDown(mocc, e)});
|
86 |
+
data.down.on("mouseup", function(e){buttonUp(mocc, e)});
|
87 |
+
data.zoomin.off("mousedown");
|
88 |
+
data.zoomin.on("mousedown", function(e){plusDown(mocc, e)});
|
89 |
+
data.zoomin.off("mouseup");
|
90 |
+
data.zoomin.on("mouseup", function(e){buttonUp(mocc, e)});
|
91 |
+
data.zoomout.on("mousedown", function(e){minDown(mocc, e)});
|
92 |
+
data.zoomout.on("mouseup", function(e){buttonUp(mocc, e)});
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
93 |
|
94 |
// Common event handlers
|
95 |
if ( data.isLightbox ) {
|
431 |
update(mocc, {
|
432 |
deltaX :delta,
|
433 |
buttondown :true,
|
434 |
+
manual :false
|
435 |
});
|
436 |
render(mocc);
|
437 |
}
|
js/wppa-zoom.min.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
var wppaJsZoomVersion="8.
|
1 |
+
var wppaJsZoomVersion="8.2.01.001";function wppaDoZoomPan(n,t){var p=jQuery;wppaZoomData[n]=t;var o=l(n,{image:document.getElementById("wppa-"+t.itemId)});function h(t){var a,n,o,e,i,s=l(t);s.canvas&&(Y()<s.time+10||(l(t,{time:Y()}),(s.isLightbox&&!wppaOvlOpen||!s.isLightbox&&wppaOvlOpen)&&(s=l(0,{abort:!0})),s.abort?l(t,{manual:!1,buttondown:!1,pause:!1,ctx:null}):s.busy||(wppaDebugCounter++,e=(s=l(t,{busy:!0})).fromX,i=s.fromY,s.manual||(s.fromX+=s.deltaX,s.fromY+=s.deltaY,a=s.fromHeight/s.deltaFactor,n=s.fromWidth/s.deltaFactor,50<a&&(wppaIsFs()||a<=s.image.height)?(s.fromX-=(n-s.fromWidth)/2,s.fromY-=(a-s.fromHeight)/2,s.fromWidth=n,s.fromHeight=a):s.buttondown=!1),s.fromX=Math.max(0,Math.min(s.image.width-s.fromWidth,s.fromX)),s.fromY=Math.max(0,Math.min(s.image.height-s.fromHeight,s.fromY)),e==s.fromX&&i==s.fromY&&1==s.deltaFactor&&(s.buttondown=!1),o=screen.width/screen.height,e=(1-s.image.width/s.fromWidth)*s.canvas.width/2,i=(1-s.image.height/s.fromHeight)*s.canvas.height/2,s.ctx=s.canvas.getContext("2d"),o>s.imageRatio&&a>s.image.height&&wppaIsFs()||o<=s.imageRatio&&n>s.image.width&&wppaIsFs()?(s.enableManual=!1,s.ctx.clearRect(0,0,s.canvas.width,s.canvas.height),s.ctx.drawImage(s.image,s.fromX,s.fromY,s.fromWidth,s.fromHeight,e,i,s.canvas.width,s.canvas.height),jQuery(s.canvas).css({cursor:"default"})):(s.enableManual=!0,s.ctx.drawImage(s.image,s.fromX,s.fromY,s.fromWidth,s.fromHeight,0,0,s.canvas.width,s.canvas.height),jQuery(s.canvas).css({cursor:"grab"})),wppaIsFs()?(s.fsMaskTop=i-(s.canvas.height-screen.height)/2,s.fsMaskLeft=e-(s.canvas.width-screen.width)/2,s.fsMaskBottom=screen.height-s.fsMaskTop,s.fsMaskRight=screen.width-s.fsMaskLeft):(s.fsMaskTop=0,s.fsMaskLeft=0,s.fsMaskBottom=0,s.fsMaskRight=0),s.ctrlbarUpdate&&(wppaAdjustControlbar(),s.ctrlbarUpdate=!1),s.busy=!1,wppaIsElementInViewport(s.canvas)||(s.buttondown=!1),l(t,s),s.pause||!s.manual&&!s.buttondown||setTimeout(function(){h(t)},10),s.pause&&l(t,{pause:!1}))))}function a(t,a){var n,o=l(t);if(o){if(o.isLightbox){p("#wppa-overlay-zpc").css("display","");var e,i,s,r=!wppaIsFs(),c=r?(e=window.innerWidth||screen.width,window.innerHeight||screen.height):(e=screen.width,screen.height),d=0,u=8,m=8+(o.controls?o.icsize+10:0)+10;r?(u+=2*o.borderWidth,m+=2*o.borderWidth):u=40,n=r?c-m>(e-u)/o.imageRatio:(screenRatio=screen.width/screen.height,screenRatio<o.imageRatio),r&&n&&(d=(c-(s=(i=e-u)/o.imageRatio)-m)/2+20),r&&!n&&(s=(i=o.imageRatio*(c-(o.controls?o.icsize:0)-48))/o.imageRatio,d=20),!r&&n&&(i=(s=screen.height)*o.imageRatio,d=0),r||n||(s=(i=screen.width)/o.imageRatio,d=(screen.height-s)/2),p("#wppa-ovl-zoom-container").css({top:d}),p("#wppa-overlay-zpc").css({top:0,left:0}),o.canvasWidth=i,o.canvasHeight=s,o.canvas.width=o.canvasWidth,o.canvas.height=o.canvasHeight,r?(p("#wppa-ovl-zoom-container").css({backgroundColor:o.backgroundColor,padding:o.padding,borderRadius:o.borderRadius+"px",borderWidth:o.borderWidth+"px",width:i,marginLeft:0}),n?p("#wppa-overlay-zpc").css({left:4}):p("#wppa-overlay-zpc").css({left:(e-i)/2})):(p("#wppa-overlay-zpc").css({marginLeft:0}),p("#wppa-ovl-zoom-container").css({backgroundColor:"transparent",padding:0,borderRadius:"0px",borderWidth:"0px",width:i,left:(e-i)/2,position:"fixed"})),o.ctrlbarUpdate=!0}else{if("force"!=a&&o.canvasWidth==p(o.div).parent().width())return;o.canvasWidth=p(o.div).parent().width(),o.canvasHeight=o.canvasWidth/o.imageRatio,o.canvas.width=o.canvasWidth,o.canvas.height=o.canvasHeight,o.ctrlbarUpdate=!0}l(t,o),setTimeout(function(){h(t)},1),p("#wppa-ovl-zoom-container").show()}}function e(t){var a=l(t),a=a.image.naturalWidth/a.canvas.width;a<1.5&&(a=1.5),l(t,{deltaX:a*=1.5,buttondown:!0,manual:!1}),h(t)}function i(t){var a=l(t),a=a.image.naturalWidth/a.canvas.width;a<1.5&&(a=1.5),l(t,{deltaX:-(a*=1.5),buttondown:!0,manual:!1}),h(t)}function s(t){var a=l(t),a=a.image.naturalHeight/a.canvas.height;a<1.5&&(a=1.5),l(t,{deltaY:-(a*=1.5),buttondown:!0,manual:!1}),h(t)}function r(t){var a=l(t),a=a.image.naturalHeight/a.canvas.height;a<1.5&&(a=1.5),l(t,{deltaY:a*=1.5,buttondown:!0,manual:!1}),h(t)}function c(t){l(t,{deltaFactor:1.005,buttondown:!0,manual:!1}),h(t)}function u(t){l(t,{deltaFactor:.995,buttondown:!0,manual:!1}),h(t)}function m(t){l(t,{deltaX:0,deltaY:0,deltaFactor:1,buttondown:!1})}function f(t,a){var n=l(t),o=g(a).X,e=g(a).Y;if(wppaIsFs()&&n.isLightbox&&(o<n.fsMaskLeft||o>n.fsMaskRight||e<n.fsMaskTop||e>n.fsMaskBottom))return l(0,{abort:!0}),void jQuery("#wppa-overlay-bg").trigger("click");n.enableManual&&(l(t,{manual:!0,savedCanvasX:o=b(t,a).X,savedCanvasY:e=b(t,a).Y,buttondown:!1}),h(t))}function w(t,a){a.preventDefault(),a.stopPropagation();var n,o=l(t),e=b(t,a).X,i=b(t,a).Y;o.manual&&(n=o.canvas.width/o.fromWidth,a=(o.savedCanvasX-e)/n+o.fromX,n=(o.savedCanvasY-i)/n+o.fromY,0<a&&0<n&&a+o.fromWidth<o.image.width&&n+o.fromHeight<o.image.height&&l(t,{fromX:a,fromY:n,savedCanvasX:e,savedCanvasY:i}))}function v(t){l(t,{manual:!1})}function l(t,a){if(!wppaZoomData[t])return!1;if(a)for(var n in a)wppaZoomData[t][n]=a[n];return wppaZoomData[t]}function g(t){var a;return t=t.touches?(a=t.touches[0].screenX,t.touches[0].screenY):(a=t.screenX,t.screenY),{X:a,Y:t}}function b(t,a){var n;return a=a.touches?(t=l(t),n=a.touches[0].screenX-t.fsMaskLeft,a.touches[0].screenY-t.fsMaskTop):(n=a.offsetX,a.offsetY),{X:n,Y:a}}function Y(){return d=new Date,d.getTime()}o.manual=!1,o.deltaX=0,o.deltaY=0,o.deltaFactor=1,o.busy=!1,o.div=p("#wppa-pan-div-"+o.itemId),o.canvas=document.getElementById("wppa-pan-canvas-"+o.itemId),o.left=p("#wppa-pctl-left-"+o.itemId),o.right=p("#wppa-pctl-right-"+o.itemId),o.up=p("#wppa-pctl-up-"+o.itemId),o.down=p("#wppa-pctl-down-"+o.itemId),o.zoomin=p("#wppa-pctl-zoomin-"+o.itemId),o.zoomout=p("#wppa-pctl-zoomout-"+o.itemId),o.prev=p("#wppa-pctl-prev-"+o.itemId),o.next=p("#wppa-pctl-next-"+o.itemId),o.exit=p("#wppa-exit-btn-2"),o.canvasWidth=o.width,o.canvasHeight=o.height,o.savedCanvasX=0,o.savedCanvasY=0,o.fromHeight=o.image.height,o.fromWidth=o.image.width,o.imageRatio=o.image.width/o.image.height,o.fromX=0,o.fromY=0,o.centerX=o.fromX+o.fromWidth/2,o.centerY=o.fromY+o.fromHeight/2,o.ctx=null,o.buttondown=!1,o.enableManual=!0,o.ctrlbarUpdate=!0,o.pause=!1,o.time=0,o.right.on("touchstart",function(t){e(n)}),o.right.on("touchend",function(t){m(n)}),o.left.on("touchstart",function(t){i(n)}),o.left.on("touchend",function(t){m(n)}),o.up.on("touchstart",function(t){s(n)}),o.up.on("touchend",function(t){m(n)}),o.down.on("touchstart",function(t){r(n)}),o.down.on("touchend",function(t){m(n)}),o.zoomin.on("touchstart",function(t){c(n)}),o.zoomin.on("touchend",function(t){m(n)}),o.zoomout.on("touchstart",function(t){u(n)}),o.zoomout.on("touchend",function(t){m(n)}),o.canvas.addEventListener("touchstart",function(t){f(n,t)}),o.canvas.addEventListener("touchmove",function(t){w(n,t)}),o.canvas.addEventListener("touchend",function(t){v(n)}),o.canvas.addEventListener("mousedown",function(t){f(n,t)}),o.canvas.addEventListener("mousemove",function(t){w(n,t)}),o.canvas.addEventListener("mouseup",function(t){v(n)}),o.canvas.addEventListener("mouseleave",function(t){(o=l(n)).manual&&l(n,{pause:!0})}),o.canvas.addEventListener("mouseenter",function(t){var a;l(a=n,{pause:!1}).manual&&h(a)}),document.getElementById("wppa-pan-canvas-"+o.itemId).addEventListener("wheel",function(t){var a;a=n,(t=t).preventDefault(),t.stopPropagation(),o=l(a),l(a,{deltaFactor:1+t.deltaY*o.zoomsensitivity/1e4,manual:!1,burrondown:!1}),h(a),setTimeout(function(){l(a,{deltaFactor:1})},25)}),o.right.on("mousedown",function(t){e(n)}),o.right.on("mouseup",function(t){m(n)}),o.left.on("mousedown",function(t){i(n)}),o.left.on("mouseup",function(t){m(n)}),o.up.on("mousedown",function(t){s(n)}),o.up.on("mouseup",function(t){m(n)}),o.down.on("mousedown",function(t){r(n)}),o.down.on("mouseup",function(t){m(n)}),o.zoomin.off("mousedown"),o.zoomin.on("mousedown",function(t){c(n)}),o.zoomin.off("mouseup"),o.zoomin.on("mouseup",function(t){m(n)}),o.zoomout.on("mousedown",function(t){u(n)}),o.zoomout.on("mouseup",function(t){m(n)}),o.isLightbox&&(p("body").on("quitimage",function(t){o=l(n,{abort:!0}),p(o.canvas).hide(),p("#wppa-pctl-div-"+o.itemId).hide(),p("#wppa-ovl-zoom-container").hide()}),p("#wppa-pctl-div-"+o.itemId).on("click",function(t){wppaKillEvent(t)})),o.isLightbox?(p(window).off("resize",wppaOvlShowSame),p(window).on("resize",wppaOvlShowSame)):p(window).on("wpparesizeend",function(t){a(n,t)}),a(n,"force"),o.initialized=!0,l(n,o),p("#wppa-ovl-spin").hide(),wppaProtect()}
|
wppa-admins-choice-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the admins-choice widget
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -91,7 +91,7 @@ class AdminsChoice extends WP_Widget {
|
|
91 |
wppa_echo( wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) ) );
|
92 |
|
93 |
// Loggedin only
|
94 |
-
|
95 |
}
|
96 |
|
97 |
// Set defaults
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the admins-choice widget
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
91 |
wppa_echo( wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) ) );
|
92 |
|
93 |
// Loggedin only
|
94 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
95 |
}
|
96 |
|
97 |
// Set defaults
|
wppa-album-navigator-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display album names linking to content
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
class AlbumNavigatorWidget extends WP_Widget {
|
@@ -148,21 +148,17 @@ class AlbumNavigatorWidget extends WP_Widget {
|
|
148 |
$disabled[] = false;
|
149 |
}
|
150 |
|
151 |
-
|
152 |
-
wppa_widget_selection( $this, 'parent', $instance['parent'], __( 'Album selection or Parent album', 'wp-photo-album-plus' ), $options, $values, $disabled ) );
|
153 |
|
154 |
// Skip empty
|
155 |
-
|
156 |
-
wppa_widget_checkbox( $this, 'skip', $instance['skip'], __( 'Skip "empty" albums', 'wp-photo-album-plus' ) ) );
|
157 |
}
|
158 |
|
159 |
// Loggedin only
|
160 |
-
|
161 |
-
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) ) );
|
162 |
|
163 |
// Cache
|
164 |
-
|
165 |
-
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) ) );
|
166 |
}
|
167 |
|
168 |
function get_widget_id() {
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display album names linking to content
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
class AlbumNavigatorWidget extends WP_Widget {
|
148 |
$disabled[] = false;
|
149 |
}
|
150 |
|
151 |
+
wppa_widget_selection( $this, 'parent', $instance['parent'], __( 'Album selection or Parent album', 'wp-photo-album-plus' ), $options, $values, $disabled );
|
|
|
152 |
|
153 |
// Skip empty
|
154 |
+
wppa_widget_checkbox( $this, 'skip', $instance['skip'], __( 'Skip "empty" albums', 'wp-photo-album-plus' ) );
|
|
|
155 |
}
|
156 |
|
157 |
// Loggedin only
|
158 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
|
|
159 |
|
160 |
// Cache
|
161 |
+
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
|
|
162 |
}
|
163 |
|
164 |
function get_widget_id() {
|
wppa-album-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display thumbnail albums
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
@@ -440,30 +440,29 @@ class AlbumWidget extends WP_Widget {
|
|
440 |
}
|
441 |
}
|
442 |
|
443 |
-
|
444 |
-
wppa_widget_selection( $this, 'parent', $instance['parent'], __( 'Album selection or Parent album', 'wp-photo-album-plus' ), $options, $values, $disabled ) .
|
445 |
|
446 |
// Include subalbums
|
447 |
-
wppa_widget_checkbox( $this, 'subs', $instance['subs'], __( 'Include subalbums', 'wp-photo-album-plus' ) )
|
448 |
|
449 |
// Show album name?
|
450 |
-
wppa_widget_checkbox( $this, 'name', $instance['name'], __( 'Show album names', 'wp-photo-album-plus' ) )
|
451 |
|
452 |
// Skip empty albums?
|
453 |
-
wppa_widget_checkbox( $this, 'skip', $instance['skip'], __( 'Skip "empty" albums', 'wp-photo-album-plus' ) )
|
454 |
|
455 |
// Loggedin only
|
456 |
-
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) )
|
457 |
|
458 |
// Cache
|
459 |
-
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) )
|
460 |
|
461 |
// Explanation
|
462 |
if ( current_user_can( 'wppa_settings' ) ) {
|
463 |
wppa_echo(
|
464 |
'<p>' .
|
465 |
-
|
466 |
-
' ' .
|
467 |
wppa_see_also( 'widget', '1', '10.11' ) .
|
468 |
'</p>' );
|
469 |
};
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display thumbnail albums
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
440 |
}
|
441 |
}
|
442 |
|
443 |
+
wppa_widget_selection( $this, 'parent', $instance['parent'], __( 'Album selection or Parent album', 'wp-photo-album-plus' ), $options, $values, $disabled );
|
|
|
444 |
|
445 |
// Include subalbums
|
446 |
+
wppa_widget_checkbox( $this, 'subs', $instance['subs'], __( 'Include subalbums', 'wp-photo-album-plus' ) );
|
447 |
|
448 |
// Show album name?
|
449 |
+
wppa_widget_checkbox( $this, 'name', $instance['name'], __( 'Show album names', 'wp-photo-album-plus' ) );
|
450 |
|
451 |
// Skip empty albums?
|
452 |
+
wppa_widget_checkbox( $this, 'skip', $instance['skip'], __( 'Skip "empty" albums', 'wp-photo-album-plus' ) );
|
453 |
|
454 |
// Loggedin only
|
455 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
456 |
|
457 |
// Cache
|
458 |
+
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
459 |
|
460 |
// Explanation
|
461 |
if ( current_user_can( 'wppa_settings' ) ) {
|
462 |
wppa_echo(
|
463 |
'<p>' .
|
464 |
+
__( 'You can set the sizes in this widget in the <b>Photo Albums -> Settings</b> admin page.', 'wp-photo-album-plus' ) .
|
465 |
+
' ' . __( 'Basic settings -> Widgets -> I -> Items 10 and 11', 'wp-photo-album-plus' ) .
|
466 |
wppa_see_also( 'widget', '1', '10.11' ) .
|
467 |
'</p>' );
|
468 |
};
|
wppa-bestof-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the best rated photos
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -121,7 +121,7 @@ class BestOfWidget extends WP_Widget {
|
|
121 |
|
122 |
// Widget Title
|
123 |
wppa_echo(
|
124 |
-
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) ) )
|
125 |
|
126 |
// Max number to diaplsy
|
127 |
wppa_widget_number( $this, 'count', $instance['count'], __( 'Max number of thumbnails', 'wp-photo-album-plus' ), '1', '25' );
|
@@ -134,8 +134,7 @@ class BestOfWidget extends WP_Widget {
|
|
134 |
'owner',
|
135 |
);
|
136 |
|
137 |
-
|
138 |
-
wppa_widget_selection( $this, 'display', $instance['display'], __( 'Select photos or owners', 'wp-photo-album-plus' ), $options, $values, array(), '' ) );
|
139 |
|
140 |
// Period
|
141 |
$options = array( __( 'Last week', 'wp-photo-album-plus' ),
|
@@ -152,8 +151,8 @@ class BestOfWidget extends WP_Widget {
|
|
152 |
'lastyear',
|
153 |
'thisyear',
|
154 |
);
|
155 |
-
|
156 |
-
wppa_widget_selection( $this, 'period', $instance['period'], __( 'Limit to ratings given during', 'wp-photo-album-plus' ), $options, $values, array(), '' )
|
157 |
|
158 |
// Sort by
|
159 |
$options = array( __( 'Number of max ratings', 'wp-photo-album-plus' ),
|
@@ -166,20 +165,20 @@ class BestOfWidget extends WP_Widget {
|
|
166 |
'ratingcount',
|
167 |
'totvalue',
|
168 |
);
|
169 |
-
|
170 |
-
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values, array(), '' )
|
171 |
|
172 |
// Number of max ratings
|
173 |
-
wppa_widget_checkbox( $this, 'maxratings', $instance['maxratings'], __( 'Show number of max ratings', 'wp-photo-album-plus' ) )
|
174 |
|
175 |
// Mean rating
|
176 |
-
wppa_widget_checkbox( $this, 'meanrat', $instance['meanrat'], __( 'Show mean rating', 'wp-photo-album-plus' ) )
|
177 |
|
178 |
// Number of ratings
|
179 |
-
wppa_widget_checkbox( $this, 'ratcount', $instance['ratcount'], __( 'Show number of ratings', 'wp-photo-album-plus' ) )
|
180 |
|
181 |
// Total value
|
182 |
-
wppa_widget_checkbox( $this, 'totvalue', $instance['totvalue'], __( 'Show the sum of all ratings', 'wp-photo-album-plus' ) )
|
183 |
|
184 |
// Link to
|
185 |
$options = array( __( '--- none ---', 'wp-photo-album-plus' ),
|
@@ -198,16 +197,14 @@ class BestOfWidget extends WP_Widget {
|
|
198 |
'upldrphotosslide',
|
199 |
'lightboxsingle',
|
200 |
);
|
201 |
-
|
202 |
-
wppa_widget_selection( $this, 'linktype', $instance['linktype'], __( 'Link to', 'wp-photo-album-plus' ), $options, $values, array(), '' )
|
203 |
|
204 |
// Loggedin only
|
205 |
-
|
206 |
-
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) ) );
|
207 |
|
208 |
// Cache
|
209 |
-
|
210 |
-
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) ) );
|
211 |
|
212 |
}
|
213 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the best rated photos
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
121 |
|
122 |
// Widget Title
|
123 |
wppa_echo(
|
124 |
+
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) ) );
|
125 |
|
126 |
// Max number to diaplsy
|
127 |
wppa_widget_number( $this, 'count', $instance['count'], __( 'Max number of thumbnails', 'wp-photo-album-plus' ), '1', '25' );
|
134 |
'owner',
|
135 |
);
|
136 |
|
137 |
+
wppa_widget_selection( $this, 'display', $instance['display'], __( 'Select photos or owners', 'wp-photo-album-plus' ), $options, $values, array(), '' );
|
|
|
138 |
|
139 |
// Period
|
140 |
$options = array( __( 'Last week', 'wp-photo-album-plus' ),
|
151 |
'lastyear',
|
152 |
'thisyear',
|
153 |
);
|
154 |
+
|
155 |
+
wppa_widget_selection( $this, 'period', $instance['period'], __( 'Limit to ratings given during', 'wp-photo-album-plus' ), $options, $values, array(), '' );
|
156 |
|
157 |
// Sort by
|
158 |
$options = array( __( 'Number of max ratings', 'wp-photo-album-plus' ),
|
165 |
'ratingcount',
|
166 |
'totvalue',
|
167 |
);
|
168 |
+
|
169 |
+
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values, array(), '' );
|
170 |
|
171 |
// Number of max ratings
|
172 |
+
wppa_widget_checkbox( $this, 'maxratings', $instance['maxratings'], __( 'Show number of max ratings', 'wp-photo-album-plus' ) );
|
173 |
|
174 |
// Mean rating
|
175 |
+
wppa_widget_checkbox( $this, 'meanrat', $instance['meanrat'], __( 'Show mean rating', 'wp-photo-album-plus' ) );
|
176 |
|
177 |
// Number of ratings
|
178 |
+
wppa_widget_checkbox( $this, 'ratcount', $instance['ratcount'], __( 'Show number of ratings', 'wp-photo-album-plus' ) );
|
179 |
|
180 |
// Total value
|
181 |
+
wppa_widget_checkbox( $this, 'totvalue', $instance['totvalue'], __( 'Show the sum of all ratings', 'wp-photo-album-plus' ) );
|
182 |
|
183 |
// Link to
|
184 |
$options = array( __( '--- none ---', 'wp-photo-album-plus' ),
|
197 |
'upldrphotosslide',
|
198 |
'lightboxsingle',
|
199 |
);
|
200 |
+
|
201 |
+
wppa_widget_selection( $this, 'linktype', $instance['linktype'], __( 'Link to', 'wp-photo-album-plus' ), $options, $values, array(), '' );
|
202 |
|
203 |
// Loggedin only
|
204 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
|
|
205 |
|
206 |
// Cache
|
207 |
+
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
|
|
208 |
|
209 |
}
|
210 |
|
wppa-cache.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
/*
|
4 |
/* Contains all wppa smart cache functions
|
5 |
/*
|
6 |
-
/* Version 8.
|
7 |
*/
|
8 |
|
9 |
// Test for caching
|
@@ -30,7 +30,7 @@ global $wppa_lang;
|
|
30 |
if ( wppa( 'cache' ) ) {
|
31 |
|
32 |
// No querystring?
|
33 |
-
if ( ! wppa_in_widget() && ! $_SERVER['REQUEST_URI'] ) {
|
34 |
$caching = true;
|
35 |
}
|
36 |
|
3 |
/*
|
4 |
/* Contains all wppa smart cache functions
|
5 |
/*
|
6 |
+
/* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
// Test for caching
|
30 |
if ( wppa( 'cache' ) ) {
|
31 |
|
32 |
// No querystring?
|
33 |
+
if ( /* ! wppa_in_widget() && */ ! $_SERVER['REQUEST_URI'] ) {
|
34 |
$caching = true;
|
35 |
}
|
36 |
|
wppa-comment-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the recent commets on photos
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
@@ -161,26 +161,26 @@ class wppaCommentWidget extends WP_Widget {
|
|
161 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
162 |
|
163 |
// Title
|
164 |
-
|
165 |
-
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) ) );
|
166 |
|
167 |
// Loggedin only
|
168 |
-
|
169 |
-
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) ) );
|
170 |
|
171 |
// Cache
|
172 |
-
|
173 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
174 |
|
175 |
-
wppa_echo(
|
176 |
-
'<p>' .
|
177 |
-
esc_html__( 'You can set the sizes in this widget in the <b>Photo Albums -> Settings</b> admin page.', 'wp-photo-album-plus' ) .
|
178 |
-
' ' . esc_html__( 'Basic settings -> Widgets -> I -> Items 4 and 5', 'wp-photo-album-plus' ) ) . '.';
|
179 |
if ( current_user_can( 'wppa_settings' ) ) {
|
180 |
-
|
181 |
}
|
182 |
-
|
183 |
-
|
184 |
|
185 |
}
|
186 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the recent commets on photos
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
161 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
162 |
|
163 |
// Title
|
164 |
+
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
|
|
165 |
|
166 |
// Loggedin only
|
167 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
|
|
168 |
|
169 |
// Cache
|
170 |
+
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
171 |
+
|
172 |
+
$subtext = __( 'You can set the sizes in this widget in the <b>Photo Albums -> Settings</b> admin page.', 'wp-photo-album-plus' ) .
|
173 |
+
' ' . __( 'Basic settings -> Widgets -> I -> Items 4 and 5', 'wp-photo-album-plus' ) . '.';
|
174 |
+
|
175 |
+
$result = '
|
176 |
+
<p>' .
|
177 |
+
strip_tags( wp_check_invalid_utf8( $subtext ), ["<br>", "<a>", "<i>", "<b>"] );
|
178 |
|
|
|
|
|
|
|
|
|
179 |
if ( current_user_can( 'wppa_settings' ) ) {
|
180 |
+
$result .= wppa_see_also( 'widget', 1, '4.5' );
|
181 |
}
|
182 |
+
$result .='</p>';
|
183 |
+
wppa_echo( $result );
|
184 |
|
185 |
}
|
186 |
|
wppa-common-functions.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/* wppa-common-functions.php
|
3 |
*
|
4 |
* Functions used in admin and in themes
|
5 |
-
* Version 8.
|
6 |
*
|
7 |
*/
|
8 |
|
@@ -1109,31 +1109,33 @@ global $wppa;
|
|
1109 |
|
1110 |
// Reload home?
|
1111 |
if ( $reload == 'home' ) {
|
1112 |
-
|
1113 |
-
<
|
1114 |
-
|
1115 |
-
|
1116 |
-
|
1117 |
-
</
|
1118 |
}
|
1119 |
|
1120 |
// Just reload after?
|
1121 |
elseif ( $reload ) {
|
1122 |
-
|
1123 |
-
<
|
1124 |
-
|
1125 |
-
|
1126 |
-
|
1127 |
-
</
|
1128 |
}
|
1129 |
|
1130 |
// Just alert (once)
|
1131 |
else {
|
1132 |
-
|
1133 |
-
<
|
1134 |
-
|
1135 |
-
|
1136 |
-
|
|
|
|
|
1137 |
}
|
1138 |
}
|
1139 |
|
2 |
/* wppa-common-functions.php
|
3 |
*
|
4 |
* Functions used in admin and in themes
|
5 |
+
* Version 8.2.01.001
|
6 |
*
|
7 |
*/
|
8 |
|
1109 |
|
1110 |
// Reload home?
|
1111 |
if ( $reload == 'home' ) {
|
1112 |
+
wppa_echo( '
|
1113 |
+
<div class="wppa-kamikaze">
|
1114 |
+
<img
|
1115 |
+
src="dummy"
|
1116 |
+
onerror="alert( \'' . $msg . '\' );document.location.href=\'' . home_url() . '\';" >
|
1117 |
+
</div>' );
|
1118 |
}
|
1119 |
|
1120 |
// Just reload after?
|
1121 |
elseif ( $reload ) {
|
1122 |
+
wppa_echo( '
|
1123 |
+
<div class="wppa-kamikaze">
|
1124 |
+
<img
|
1125 |
+
src="dummy"
|
1126 |
+
onerror="alert( \'' . $msg . '\' );document.location.reload( true );" >
|
1127 |
+
</div>' );
|
1128 |
}
|
1129 |
|
1130 |
// Just alert (once)
|
1131 |
else {
|
1132 |
+
wppa_echo( '
|
1133 |
+
<div class="wppa-kamikaze">
|
1134 |
+
<img
|
1135 |
+
src="dummy"
|
1136 |
+
style="display:none"
|
1137 |
+
onerror="alert( \'' . $msg . '\' );jQuery( \'.wppa-kamikaze\' ).html( \'\' )" >
|
1138 |
+
</div>' );
|
1139 |
}
|
1140 |
}
|
1141 |
|
wppa-featen-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the featured photos
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
@@ -230,7 +230,7 @@ class FeaTenWidget extends WP_Widget {
|
|
230 |
$album = $instance['album'];
|
231 |
|
232 |
// Widget title
|
233 |
-
|
234 |
|
235 |
// Album selection
|
236 |
$body = wppa_album_select_a( array( 'selected' => $album,
|
@@ -239,21 +239,21 @@ class FeaTenWidget extends WP_Widget {
|
|
239 |
'path' => true,
|
240 |
'sort' => true,
|
241 |
) );
|
242 |
-
|
243 |
|
244 |
// Loggedin only
|
245 |
-
|
246 |
|
247 |
// Cache
|
248 |
-
|
249 |
|
250 |
// Explanation
|
251 |
-
|
252 |
-
|
253 |
-
|
254 |
-
|
255 |
-
|
256 |
-
);
|
257 |
|
258 |
}
|
259 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the featured photos
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
230 |
$album = $instance['album'];
|
231 |
|
232 |
// Widget title
|
233 |
+
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
234 |
|
235 |
// Album selection
|
236 |
$body = wppa_album_select_a( array( 'selected' => $album,
|
239 |
'path' => true,
|
240 |
'sort' => true,
|
241 |
) );
|
242 |
+
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
243 |
|
244 |
// Loggedin only
|
245 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
246 |
|
247 |
// Cache
|
248 |
+
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
249 |
|
250 |
// Explanation
|
251 |
+
$result = '
|
252 |
+
<p>' .
|
253 |
+
__( 'You can set the sizes in this widget in the <b>Photo Albums -> Settings</b> admin page.', 'wp-photo-album-plus' ) .
|
254 |
+
' ' . __( 'Basic settings -> Widgets -> I -> Items 12 and 13', 'wp-photo-album-plus' ) . '
|
255 |
+
</p>';
|
256 |
+
wppa_echo( strip_tags( wp_check_invalid_utf8( $result), ["<br>", "<a>", "<i>", "<b>", "<p>"] ) );
|
257 |
|
258 |
}
|
259 |
|
wppa-functions.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Various functions
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -5260,7 +5260,7 @@ global $wppa_upload_succes_id;
|
|
5260 |
}
|
5261 |
|
5262 |
// Description
|
5263 |
-
$description = wppa_get( 'albumeditdesc' );
|
5264 |
|
5265 |
|
5266 |
// Custom data
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Various functions
|
6 |
+
* Version 8.2.01.002
|
7 |
*
|
8 |
*/
|
9 |
|
5260 |
}
|
5261 |
|
5262 |
// Description
|
5263 |
+
$description = wppa_get( 'albumeditdesc', '', 'html' );
|
5264 |
|
5265 |
|
5266 |
// Custom data
|
wppa-gp-widget.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
*
|
5 |
* A text widget that interpretes wppa shortcodes
|
6 |
*
|
7 |
-
* Version 8.
|
8 |
*/
|
9 |
|
10 |
class WppaGpWidget extends WP_Widget {
|
@@ -108,22 +108,20 @@ class WppaGpWidget extends WP_Widget {
|
|
108 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
109 |
|
110 |
// Widget title
|
111 |
-
$
|
112 |
-
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) ) .
|
113 |
|
114 |
// Text area
|
115 |
-
wppa_widget_textarea( $this, 'text', $instance['text'], __( 'Enter the content just like a normal text widget. This widget will interpret [wppa] shortcodes', 'wp-photo-album-plus' ) )
|
116 |
|
117 |
// Run wpautop?
|
118 |
-
wppa_widget_checkbox( $this, 'filter', $instance['filter'], __( 'Automatically add paragraphs', 'wp-photo-album-plus' ) )
|
119 |
|
120 |
// Logged in only?
|
121 |
-
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) )
|
122 |
|
123 |
// Cache
|
124 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
125 |
|
126 |
-
wppa_echo( $result );
|
127 |
}
|
128 |
|
129 |
// Set defaults
|
4 |
*
|
5 |
* A text widget that interpretes wppa shortcodes
|
6 |
*
|
7 |
+
* Version 8.2.01.001
|
8 |
*/
|
9 |
|
10 |
class WppaGpWidget extends WP_Widget {
|
108 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
109 |
|
110 |
// Widget title
|
111 |
+
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
|
|
112 |
|
113 |
// Text area
|
114 |
+
wppa_widget_textarea( $this, 'text', $instance['text'], __( 'Enter the content just like a normal text widget. This widget will interpret [wppa] shortcodes', 'wp-photo-album-plus' ) );
|
115 |
|
116 |
// Run wpautop?
|
117 |
+
wppa_widget_checkbox( $this, 'filter', $instance['filter'], __( 'Automatically add paragraphs', 'wp-photo-album-plus' ) );
|
118 |
|
119 |
// Logged in only?
|
120 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
121 |
|
122 |
// Cache
|
123 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
124 |
|
|
|
125 |
}
|
126 |
|
127 |
// Set defaults
|
wppa-input.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains functions for sanitizing and formatting user input
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -151,6 +151,8 @@ function wppa_get_get_filter( $name ) {
|
|
151 |
case 'comment':
|
152 |
case 'commenttext':
|
153 |
case 'upn-description':
|
|
|
|
|
154 |
$result = 'html';
|
155 |
break;
|
156 |
|
@@ -184,7 +186,6 @@ function wppa_get_get_filter( $name ) {
|
|
184 |
case 'owner':
|
185 |
case 'nonce':
|
186 |
case 'user-name': // Photo/video name supplied by user
|
187 |
-
case 'user-desc': // Desc by user
|
188 |
case 'ntfy-nonce':
|
189 |
case 'qr-nonce':
|
190 |
case 'crypt':
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains functions for sanitizing and formatting user input
|
6 |
+
* Version 8.2.01.002
|
7 |
*
|
8 |
*/
|
9 |
|
151 |
case 'comment':
|
152 |
case 'commenttext':
|
153 |
case 'upn-description':
|
154 |
+
case 'user-desc': // Desc by user during fe upload
|
155 |
+
case 'albumeditdesc': // Fe album desc
|
156 |
$result = 'html';
|
157 |
break;
|
158 |
|
186 |
case 'owner':
|
187 |
case 'nonce':
|
188 |
case 'user-name': // Photo/video name supplied by user
|
|
|
189 |
case 'ntfy-nonce':
|
190 |
case 'qr-nonce':
|
191 |
case 'crypt':
|
wppa-lasten-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the last uploaded photos
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
class LasTenWidget extends WP_Widget {
|
@@ -240,7 +240,6 @@ class LasTenWidget extends WP_Widget {
|
|
240 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
241 |
|
242 |
// Title
|
243 |
-
$result =
|
244 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
245 |
|
246 |
// Album
|
@@ -250,16 +249,11 @@ class LasTenWidget extends WP_Widget {
|
|
250 |
'addnumbers' => true,
|
251 |
'path' => true,
|
252 |
) );
|
253 |
-
|
254 |
-
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) )
|
255 |
|
256 |
// Album enumeration
|
257 |
-
wppa_widget_input( $this,
|
258 |
-
'albumenum',
|
259 |
-
$instance['albumenum'],
|
260 |
-
__( 'Albums', 'wp-photo-album-plus' ),
|
261 |
-
__( 'Select --- multiple see below --- in the Album selection box. Then enter album numbers seperated by commas', 'wp-photo-album-plus' )
|
262 |
-
) .
|
263 |
|
264 |
// Include subalbums
|
265 |
wppa_widget_checkbox( $this, 'includesubs', $instance['includesubs'], __( 'Include subalbums', 'wp-photo-album-plus' ) );
|
@@ -271,23 +265,24 @@ class LasTenWidget extends WP_Widget {
|
|
271 |
$values = array( 'thumbs',
|
272 |
'names',
|
273 |
);
|
274 |
-
|
275 |
-
wppa_widget_selection( $this, 'display', $instance['display'], __( 'Display type', 'wp-photo-album-plus' ), $options, $values )
|
276 |
|
277 |
// Time since
|
278 |
-
wppa_widget_checkbox( $this, 'timesince', $instance['timesince'], __( 'Show time since', 'wp-photo-album-plus' ) )
|
279 |
|
280 |
// Loggedin only
|
281 |
-
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) )
|
282 |
|
283 |
// Cache
|
284 |
-
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) )
|
285 |
-
|
286 |
-
'
|
287 |
-
|
288 |
-
|
289 |
-
|
290 |
-
|
|
|
291 |
}
|
292 |
|
293 |
// Set defaults
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the last uploaded photos
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
class LasTenWidget extends WP_Widget {
|
240 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
241 |
|
242 |
// Title
|
|
|
243 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
244 |
|
245 |
// Album
|
249 |
'addnumbers' => true,
|
250 |
'path' => true,
|
251 |
) );
|
252 |
+
|
253 |
+
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
254 |
|
255 |
// Album enumeration
|
256 |
+
wppa_widget_input( $this, 'albumenum', $instance['albumenum'], __( 'Albums', 'wp-photo-album-plus' ), __( 'Select --- multiple see below --- in the Album selection box. Then enter album numbers seperated by commas', 'wp-photo-album-plus' ) );
|
|
|
|
|
|
|
|
|
|
|
257 |
|
258 |
// Include subalbums
|
259 |
wppa_widget_checkbox( $this, 'includesubs', $instance['includesubs'], __( 'Include subalbums', 'wp-photo-album-plus' ) );
|
265 |
$values = array( 'thumbs',
|
266 |
'names',
|
267 |
);
|
268 |
+
|
269 |
+
wppa_widget_selection( $this, 'display', $instance['display'], __( 'Display type', 'wp-photo-album-plus' ), $options, $values );
|
270 |
|
271 |
// Time since
|
272 |
+
wppa_widget_checkbox( $this, 'timesince', $instance['timesince'], __( 'Show time since', 'wp-photo-album-plus' ) );
|
273 |
|
274 |
// Loggedin only
|
275 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
276 |
|
277 |
// Cache
|
278 |
+
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
279 |
+
|
280 |
+
$result = '
|
281 |
+
<p>' .
|
282 |
+
__( 'You can set the sizes in this widget in the <b>Photo Albums -> Settings</b> admin page.', 'wp-photo-album-plus' ) .
|
283 |
+
' ' . __( 'Basic settings -> Widgets -> I -> Items 8 and 9', 'wp-photo-album-plus' ) . '
|
284 |
+
</p>';
|
285 |
+
wppa_echo( strip_tags( wp_check_invalid_utf8( $result), ["<br>", "<a>", "<i>", "<b>", "<p>"] ) );
|
286 |
}
|
287 |
|
288 |
// Set defaults
|
wppa-multitag-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the multitag widget
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -37,9 +37,9 @@ class MultitagPhotos extends WP_Widget {
|
|
37 |
|
38 |
// Cache?
|
39 |
if ( $cache && wppa_is_file( $cachefile ) ) {
|
40 |
-
|
41 |
update_option( 'wppa_cache_hits', get_option( 'wppa_cache_hits', 0 ) +1 );
|
42 |
-
|
43 |
wppa( 'in_widget', false );
|
44 |
return;
|
45 |
}
|
@@ -61,8 +61,8 @@ class MultitagPhotos extends WP_Widget {
|
|
61 |
}
|
62 |
$result .= $widget_content . $after_widget;
|
63 |
|
64 |
-
|
65 |
-
|
66 |
|
67 |
// Cache?
|
68 |
if ( $cache ) {
|
@@ -101,12 +101,10 @@ class MultitagPhotos extends WP_Widget {
|
|
101 |
if ( empty( $stags ) ) $stags = array();
|
102 |
|
103 |
// Title
|
104 |
-
echo
|
105 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
106 |
|
107 |
// Columns
|
108 |
-
|
109 |
-
wppa_widget_number( $this, 'cols', $instance['cols'], __( 'Number of columns', 'wp-photo-album-plus' ), '1', '6' );
|
110 |
|
111 |
// Tags selection
|
112 |
$tags = wppa_get_taglist();
|
@@ -115,27 +113,25 @@ class MultitagPhotos extends WP_Widget {
|
|
115 |
if ( in_array( $tag, $stags ) ) $sel = ' selected'; else $sel = '';
|
116 |
$body .= '<option value="' . esc_attr( $tag ) . '"' . $sel . ' >' . htmlspecialchars( $tag ) . '</option>';
|
117 |
}
|
118 |
-
|
119 |
-
wppa_widget_selection_frame( $this, 'tags', $body, __( 'Select multiple tags or --- all ---', 'wp-photo-album-plus' ), 'multi' );
|
120 |
|
121 |
// Currently selected
|
122 |
if ( isset( $instance['tags']['0'] ) && $instance['tags']['0'] ) $s = implode( ',', $instance['tags'] ); else $s = __( '--- all ---', 'wp-photo-album-plus' );
|
123 |
-
|
124 |
-
|
125 |
-
__( 'Currently selected tags', 'wp-photo-album-plus' ) . ':
|
126 |
-
|
127 |
-
|
128 |
-
$s .
|
129 |
-
|
130 |
-
|
|
|
131 |
|
132 |
// Loggedin only
|
133 |
-
|
134 |
-
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
135 |
|
136 |
// Cache
|
137 |
-
|
138 |
-
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
139 |
|
140 |
}
|
141 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the multitag widget
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
37 |
|
38 |
// Cache?
|
39 |
if ( $cache && wppa_is_file( $cachefile ) ) {
|
40 |
+
wppa_echo( wppa_get_contents( $cachefile ) );
|
41 |
update_option( 'wppa_cache_hits', get_option( 'wppa_cache_hits', 0 ) +1 );
|
42 |
+
wppa_echo( wppa_widget_timer( 'show', $widget_title, true ) );
|
43 |
wppa( 'in_widget', false );
|
44 |
return;
|
45 |
}
|
61 |
}
|
62 |
$result .= $widget_content . $after_widget;
|
63 |
|
64 |
+
wppa_echo( $result );
|
65 |
+
wppa_echo( wppa_widget_timer( 'show', $widget_title ) );
|
66 |
|
67 |
// Cache?
|
68 |
if ( $cache ) {
|
101 |
if ( empty( $stags ) ) $stags = array();
|
102 |
|
103 |
// Title
|
|
|
104 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
105 |
|
106 |
// Columns
|
107 |
+
wppa_widget_number( $this, 'cols', $instance['cols'], __( 'Number of columns', 'wp-photo-album-plus' ), '1', '6', '', 'true' );
|
|
|
108 |
|
109 |
// Tags selection
|
110 |
$tags = wppa_get_taglist();
|
113 |
if ( in_array( $tag, $stags ) ) $sel = ' selected'; else $sel = '';
|
114 |
$body .= '<option value="' . esc_attr( $tag ) . '"' . $sel . ' >' . htmlspecialchars( $tag ) . '</option>';
|
115 |
}
|
116 |
+
wppa_widget_selection_frame( $this, 'tags', $body, '<div style="clear:both"></div>' . __( 'Select multiple tags or --- all ---', 'wp-photo-album-plus' ), 'multi' );
|
|
|
117 |
|
118 |
// Currently selected
|
119 |
if ( isset( $instance['tags']['0'] ) && $instance['tags']['0'] ) $s = implode( ',', $instance['tags'] ); else $s = __( '--- all ---', 'wp-photo-album-plus' );
|
120 |
+
$result = '
|
121 |
+
<p style="word-break:break-all">' .
|
122 |
+
__( 'Currently selected tags', 'wp-photo-album-plus' ) . ':
|
123 |
+
<br>
|
124 |
+
<b>' .
|
125 |
+
$s . '
|
126 |
+
</b>
|
127 |
+
</p>';
|
128 |
+
wppa_echo( strip_tags( wp_check_invalid_utf8( $result), ["<br>", "<a>", "<i>", "<b>"] ) );
|
129 |
|
130 |
// Loggedin only
|
131 |
+
wppa_echo( wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) ) );
|
|
|
132 |
|
133 |
// Cache
|
134 |
+
wppa_echo( wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) ) );
|
|
|
135 |
|
136 |
}
|
137 |
|
wppa-non-admin.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains all the non admin stuff
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -351,7 +351,7 @@ global $wppa_session;
|
|
351 |
}
|
352 |
|
353 |
/* FACEBOOK COMMENTS */
|
354 |
-
add_action( 'wp_footer', 'wppa_fbc_setup',
|
355 |
|
356 |
function wppa_fbc_setup() {
|
357 |
global $wppa_locale;
|
@@ -366,18 +366,22 @@ global $wppa_locale;
|
|
366 |
wppa_switch( 'facebook_like' ) ||
|
367 |
wppa_switch( 'facebook_comments' ) ) // But is it used by wppa?
|
368 |
) {
|
369 |
-
|
|
|
370 |
<!-- Facebook Comments for WPPA+ -->
|
371 |
-
<div id="fb-root"></div>
|
372 |
-
|
|
|
|
|
373 |
var js, fjs = d.getElementsByTagName(s)[0];
|
374 |
if (d.getElementById(id)) return;
|
375 |
js = d.createElement(s); js.id = id;
|
376 |
-
js.src = "//connect.facebook.net
|
377 |
fjs.parentNode.insertBefore(js, fjs);
|
378 |
-
}(document, 'script', 'facebook-jssdk'));
|
379 |
-
|
380 |
-
|
|
|
381 |
}
|
382 |
}
|
383 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains all the non admin stuff
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
351 |
}
|
352 |
|
353 |
/* FACEBOOK COMMENTS */
|
354 |
+
add_action( 'wp_footer', 'wppa_fbc_setup', 1 );
|
355 |
|
356 |
function wppa_fbc_setup() {
|
357 |
global $wppa_locale;
|
366 |
wppa_switch( 'facebook_like' ) ||
|
367 |
wppa_switch( 'facebook_comments' ) ) // But is it used by wppa?
|
368 |
) {
|
369 |
+
|
370 |
+
$the_html = '
|
371 |
<!-- Facebook Comments for WPPA+ -->
|
372 |
+
<div id="fb-root"></div>';
|
373 |
+
|
374 |
+
$the_js = '
|
375 |
+
(function(d, s, id) {
|
376 |
var js, fjs = d.getElementsByTagName(s)[0];
|
377 |
if (d.getElementById(id)) return;
|
378 |
js = d.createElement(s); js.id = id;
|
379 |
+
js.src = "//connect.facebook.net/' . $wppa_locale . '/all.js#xfbml=1";
|
380 |
fjs.parentNode.insertBefore(js, fjs);
|
381 |
+
}(document, \'script\', \'facebook-jssdk\'));';
|
382 |
+
|
383 |
+
wppa_echo( $the_html );
|
384 |
+
wppa_add_inline_script( 'wppa', $the_js );
|
385 |
}
|
386 |
}
|
387 |
|
wppa-picture.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Make the picture html
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -635,9 +635,8 @@ function wppa_get_spheric_pan_html( $args ) {
|
|
635 |
$run = 'false';
|
636 |
}
|
637 |
|
638 |
-
$
|
639 |
-
|
640 |
-
'<script>
|
641 |
var data' . $mocc . ' =
|
642 |
{ mocc :' . $mocc . ',
|
643 |
id :' . $id . ',
|
@@ -645,7 +644,7 @@ function wppa_get_spheric_pan_html( $args ) {
|
|
645 |
isLightbox :' . ( $lightbox ? 'true' : 'false' ) . ',
|
646 |
height :' . $height . ',
|
647 |
width :' . $width . ',
|
648 |
-
url
|
649 |
abort :false,
|
650 |
autorun :' . $run . ',
|
651 |
dX :' . $dX . ',
|
@@ -656,17 +655,25 @@ function wppa_get_spheric_pan_html( $args ) {
|
|
656 |
controls :' . ( $controls ? 'true' : 'false' ) . ',
|
657 |
initialized :false,
|
658 |
icsize :' . ( $lightbox ? wppa_opt( 'nav_icon_size_lightbox' ) : wppa_opt( 'nav_icon_size_panorama' ) ) . ',
|
659 |
-
backgroundColor
|
660 |
borderRadius :' . wppa_opt( 'ovl_border_radius' ) . ',
|
661 |
padding :' . wppa_opt( 'ovl_border_width' ) . ',
|
662 |
enableManual :' . ( $manual ? 'true' : 'false' ) . ',
|
663 |
-
vtime :0
|
664 |
};
|
665 |
-
|
|
|
666 |
|
667 |
-
'
|
|
|
|
|
|
|
|
|
|
|
668 |
|
669 |
-
( $haslink
|
|
|
|
|
670 |
|
671 |
$result = wppa_pan_min( $result );
|
672 |
|
@@ -694,6 +701,7 @@ function wppa_get_flat_pan_html( $args ) {
|
|
694 |
|
695 |
$id = strval( intval ( $args['id'] ) );
|
696 |
$mocc = $args['mocc'] ? $args['mocc'] : wppa( 'mocc' );
|
|
|
697 |
$width = $args['width'] ? $args['width'] : wppa_get_container_width();
|
698 |
$height = $args['height'] ? $args['height'] : round( $width * wppa_get_photoy( $id ) / wppa_get_photox( $id ) );
|
699 |
$haslink = $args['haslink'];
|
@@ -890,529 +898,55 @@ function wppa_get_flat_pan_html( $args ) {
|
|
890 |
'</span>';
|
891 |
}
|
892 |
}
|
893 |
-
|
894 |
-
$result .=
|
895 |
-
'</div>';
|
896 |
}
|
897 |
|
898 |
-
//
|
899 |
-
( $lightbox ? '</div>' : '' );
|
900 |
-
|
901 |
-
// The js part
|
902 |
$result .=
|
903 |
-
|
904 |
-
|
905 |
-
// Create image object and add the image url to it
|
906 |
-
'var image' . $mocc . ' = new Image();
|
907 |
-
image' . $mocc . '.src = "' . $url . '";' .
|
908 |
-
'var wppaFlatLastRenderTime = [];
|
909 |
-
var wppaFlatId = [];' .
|
910 |
-
|
911 |
-
// When document complete, run the main proc
|
912 |
-
'jQuery(document).ready(function(){wppaDoFlatPanorama' . $mocc . '("' . $id . '");});' .
|
913 |
-
|
914 |
-
// The main proccedure
|
915 |
-
'function wppaDoFlatPanorama' . $mocc . '(id){' .
|
916 |
-
|
917 |
-
// Wait until the image file has been completely loaded
|
918 |
-
'if (!image' . $mocc . '.complete){setTimeout( wppaDoFlatPanorama' . $mocc . ', 200 );return;}' .
|
919 |
-
|
920 |
-
'wppaFlatId['.$mocc.'] = id;' .
|
921 |
-
|
922 |
-
// Var declarations
|
923 |
-
'var
|
924 |
-
$ = jQuery,
|
925 |
-
mocc = ' . $mocc . ',
|
926 |
-
manualControl = false,
|
927 |
-
zoomsensitivity = ' . $zoomsensitivity . ',
|
928 |
-
deltaX = ' . $deltaX . ',
|
929 |
-
deltaY = 0,
|
930 |
-
deltaFactor = 1.0,
|
931 |
-
autorun = ' . ( $autorun ? 'true' : 'false' ) . ',
|
932 |
-
run = deltaX ? 5 : 4,
|
933 |
-
abort = false,
|
934 |
-
div = $("#wppa-pan-div-' . $mocc . '"),
|
935 |
-
canvas = document.getElementById("wppa-pan-canvas-' . $mocc . '"),
|
936 |
-
prevCanvas = document.getElementById("wppa-pan-prev-canvas-' . $mocc . '"),
|
937 |
-
left = $("#wppa-pctl-left-' . $mocc . '"),
|
938 |
-
right = $("#wppa-pctl-right-' . $mocc . '"),
|
939 |
-
up = $("#wppa-pctl-up-' . $mocc . '"),
|
940 |
-
down = $("#wppa-pctl-down-' . $mocc . '"),
|
941 |
-
zoomin = $("#wppa-pctl-zoomin-' . $mocc . '"),
|
942 |
-
zoomout = $("#wppa-pctl-zoomout-' . $mocc . '"),
|
943 |
-
prev = $("#wppa-pctl-prev-' . $mocc . '"),
|
944 |
-
next = $("#wppa-pctl-next-' . $mocc . '"),
|
945 |
-
canvasWidth = $(div).parent().width(),
|
946 |
-
canvasHeight = canvasWidth / 2,
|
947 |
-
savedCanvasX = 0,
|
948 |
-
savedCanvasY = 0,
|
949 |
-
fromHeight = image' . $mocc . '.height / 2,
|
950 |
-
fromWidth = fromHeight * 2,
|
951 |
-
fromX = ( image' . $mocc . '.width - fromWidth ) / 2,
|
952 |
-
fromY = ( image' . $mocc . '.height - fromHeight ) / 2,
|
953 |
-
centerX = fromX + fromWidth / 2,
|
954 |
-
centerY = fromY + fromHeight / 2;' .
|
955 |
-
|
956 |
-
'wppaFlatLastRenderTime[mocc] = 0;' .
|
957 |
-
|
958 |
-
// Install listeners
|
959 |
-
|
960 |
-
'right.off("touchstart");
|
961 |
-
right.on("touchstart", onRightMouseDown);
|
962 |
-
right.off("touchend");
|
963 |
-
right.on("touchend", onButtonUp);
|
964 |
-
left.off("touchstart");
|
965 |
-
left.on("touchstart", onLeftMouseDown);
|
966 |
-
left.off("touchend");
|
967 |
-
left.on("touchend", onButtonUp);
|
968 |
-
up.off("touchstart");
|
969 |
-
up.on("touchstart", onUpMouseDown);
|
970 |
-
up.off("touchend");
|
971 |
-
up.on("touchend", onButtonUp);
|
972 |
-
down.off("touchstart");
|
973 |
-
down.on("touchstart", onDownMouseDown);
|
974 |
-
down.off("touchend");
|
975 |
-
down.on("touchend", onButtonUp);
|
976 |
-
zoomin.off("touchstart");
|
977 |
-
zoomin.on("touchstart", onZoomInMouseDown);
|
978 |
-
zoomin.off("touchend");
|
979 |
-
zoomin.on("touchend", onButtonUp);
|
980 |
-
zoomout.off("touchstart");
|
981 |
-
zoomout.on("touchstart", onZoomOutMouseDown);
|
982 |
-
zoomout.off("touchend");
|
983 |
-
zoomout.on("touchend", onButtonUp);'
|
984 |
-
.
|
985 |
-
( $manual ?
|
986 |
-
'canvas.removeEventListener("mousedown", onCanvasMouseDown);
|
987 |
-
canvas.addEventListener("mousedown", onCanvasMouseDown);
|
988 |
-
canvas.removeEventListener("mousemove", onCanvasMouseMove);
|
989 |
-
canvas.addEventListener("mousemove", onCanvasMouseMove);
|
990 |
-
canvas.removeEventListener("mouseup", onCanvasMouseUp);
|
991 |
-
canvas.addEventListener("mouseup", onCanvasMouseUp);
|
992 |
-
canvas.addEventListener("mouseout", onCanvasMouseUp);
|
993 |
-
canvas.removeEventListener("mouseout", onCanvasMouseUp);
|
994 |
-
document.getElementById("wppa-pan-canvas-' . $mocc . '").removeEventListener("wheel", onDivWheel);
|
995 |
-
document.getElementById("wppa-pan-canvas-' . $mocc . '").addEventListener("wheel", onDivWheel);
|
996 |
-
prevCanvas.removeEventListener("mousedown", onCanvasMouseDown);
|
997 |
-
prevCanvas.addEventListener("mousedown", onCanvasMouseDown);
|
998 |
-
prevCanvas.removeEventListener("mousemove", onPrevCanvasMouseMove);
|
999 |
-
prevCanvas.addEventListener("mousemove", onPrevCanvasMouseMove);
|
1000 |
-
prevCanvas.removeEventListener("mouseup", onCanvasMouseUp);
|
1001 |
-
prevCanvas.addEventListener("mouseup", onCanvasMouseUp);
|
1002 |
-
prevCanvas.removeEventListener("mouseout", onCanvasMouseUp);
|
1003 |
-
prevCanvas.addEventListener("mouseout", onCanvasMouseUp);'
|
1004 |
-
: '' ) .
|
1005 |
-
|
1006 |
-
'right.off("mousedown");
|
1007 |
-
right.on("mousedown", onRightMouseDown);
|
1008 |
-
right.off("mouseup");
|
1009 |
-
right.on("mouseup", onButtonUp);
|
1010 |
-
left.off("mousedown");
|
1011 |
-
left.on("mousedown", onLeftMouseDown);
|
1012 |
-
left.off("mouseup");
|
1013 |
-
left.on("mouseup", onButtonUp);
|
1014 |
-
up.off("mousedown");
|
1015 |
-
up.on("mousedown", onUpMouseDown);
|
1016 |
-
up.off("mouseup");
|
1017 |
-
up.on("mouseup", onButtonUp);
|
1018 |
-
down.off("mousedown");
|
1019 |
-
down.on("mousedown", onDownMouseDown);
|
1020 |
-
down.off("mouseup");
|
1021 |
-
down.on("mouseup", onButtonUp);
|
1022 |
-
zoomin.off("mousedown");
|
1023 |
-
zoomin.on("mousedown", onZoomInMouseDown);
|
1024 |
-
zoomin.off("mouseup");
|
1025 |
-
zoomin.on("mouseup", onButtonUp);
|
1026 |
-
zoomout.off("mousedown");
|
1027 |
-
zoomout.on("mousedown", onZoomOutMouseDown);
|
1028 |
-
zoomout.off("mouseup");
|
1029 |
-
zoomout.on("mouseup", onButtonUp);'
|
1030 |
-
.
|
1031 |
-
|
1032 |
-
// Install Resize handler
|
1033 |
-
'$(window).off("DOMContentLoaded load resize orientationchange",onResize' . $mocc . ');' .
|
1034 |
-
'$(window).on("DOMContentLoaded load resize orientationchange",onResize' . $mocc . ');' .
|
1035 |
-
|
1036 |
-
// Lightbox exit handler
|
1037 |
-
( $lightbox ?
|
1038 |
-
'$("body").off("quitimage",quitImage);' .
|
1039 |
-
'$("body").on("quitimage",quitImage);' .
|
1040 |
-
'$("#wppa-pctl-div-'.$mocc.'").on("click", function(e){wppaKillEvent(e)});' :
|
1041 |
-
'' ) .
|
1042 |
-
|
1043 |
-
// Remove spinner
|
1044 |
-
'$("#wppa-ovl-spin").hide();' .
|
1045 |
-
|
1046 |
-
// Disable right click
|
1047 |
-
'wppaProtect();' .
|
1048 |
-
|
1049 |
-
// Do the rendering
|
1050 |
-
'render();' .
|
1051 |
-
|
1052 |
-
// Resize
|
1053 |
-
'onResize' . $mocc . '();' .
|
1054 |
-
|
1055 |
-
// The render function
|
1056 |
-
'function render(){' .
|
1057 |
-
|
1058 |
-
( $lightbox ? 'if (!wppaOvlOpen) abort=true;' : 'if (!wppaIsElementInViewport(canvas)) {setTimeout(render,200);return;}' ) .
|
1059 |
-
|
1060 |
-
'if (abort) {
|
1061 |
-
ctx = null;
|
1062 |
-
prevctx = null;
|
1063 |
-
return;
|
1064 |
-
}
|
1065 |
-
if (run==0) {
|
1066 |
-
return;
|
1067 |
-
}' .
|
1068 |
-
|
1069 |
-
// Duplicate loops?
|
1070 |
-
'var curTime = timnow();
|
1071 |
-
if ( autorun && curTime < wppaFlatLastRenderTime[mocc] + 25 ) {
|
1072 |
-
return;
|
1073 |
-
}
|
1074 |
-
wppaFlatLastRenderTime[mocc] = curTime;' .
|
1075 |
-
|
1076 |
-
// manualControl is true when a drag on the canvas is being performed
|
1077 |
-
'if(!manualControl){' .
|
1078 |
-
|
1079 |
-
// Panning
|
1080 |
-
'fromX += deltaX;
|
1081 |
-
fromY += deltaY;' .
|
1082 |
-
|
1083 |
-
// Zooming
|
1084 |
-
'var newHeight = fromHeight / deltaFactor;
|
1085 |
-
var newWidth = fromWidth / deltaFactor;' .
|
1086 |
-
|
1087 |
-
// Keep zooming in range
|
1088 |
-
'if ( deltaFactor != 1 && newHeight <= image' . $mocc . '.height && newHeight > 50 ) {
|
1089 |
-
fromX -= ( newWidth - fromWidth ) / 2;
|
1090 |
-
fromY -= ( newHeight - fromHeight ) / 2;
|
1091 |
-
fromWidth = newWidth;
|
1092 |
-
fromHeight = newHeight;
|
1093 |
-
}
|
1094 |
-
}' .
|
1095 |
-
|
1096 |
-
// Keep viewport within image boundaries
|
1097 |
-
'fromX = Math.max(0, Math.min(image' . $mocc . '.width-fromWidth, fromX));' .
|
1098 |
-
'fromY = Math.max(0, Math.min(image' . $mocc . '.height-fromHeight, fromY));' .
|
1099 |
-
|
1100 |
-
// Check for turningpoint in case autrun
|
1101 |
-
'if ( autorun ) {
|
1102 |
-
if ( fromX == 0 || fromX == ( image' . $mocc . '.width-fromWidth ) ) {
|
1103 |
-
deltaX *= -1;
|
1104 |
-
}
|
1105 |
-
}' .
|
1106 |
-
|
1107 |
-
// Draw the image
|
1108 |
-
'var ctx = canvas.getContext("2d");
|
1109 |
-
ctx.drawImage(image' . $mocc . ',fromX,fromY,fromWidth,fromHeight,0,0,canvas.width,canvas.height);' .
|
1110 |
-
|
1111 |
-
// Draw the preview image
|
1112 |
-
'var prevctx = prevCanvas.getContext("2d");
|
1113 |
-
prevctx.clearRect(0, 0, prevCanvas.width, prevCanvas.height);
|
1114 |
-
prevctx.drawImage(image' . $mocc . ',0,0,image' . $mocc . '.width,image' . $mocc . '.height,0,0,prevCanvas.width,prevCanvas.height);' .
|
1115 |
-
|
1116 |
-
// Draw viewport rect on preview image
|
1117 |
-
'var factor = prevCanvas.width / image' . $mocc . '.width;
|
1118 |
-
prevctx.strokeRect(factor*fromX,factor*fromY,factor*fromWidth,factor*fromHeight);' .
|
1119 |
-
|
1120 |
-
// Re-render if needed
|
1121 |
-
'if (run>0) {
|
1122 |
-
if (autorun){timer=setTimeout(function(){render()},25);}
|
1123 |
-
else {timer=setTimeout(function(){render()},25);}
|
1124 |
-
}
|
1125 |
-
if(run<5)run--;' .
|
1126 |
-
|
1127 |
-
// Make controlbar visible
|
1128 |
-
'setTimeout(function(){jQuery("#wppa-pctl-div-"+' . $mocc . ').css({visibility:"visible"});}, 100);
|
1129 |
-
|
1130 |
-
}' .
|
1131 |
-
|
1132 |
-
// Horizontal movement by button
|
1133 |
-
'function onRightMouseDown(e){
|
1134 |
-
e.preventDefault();
|
1135 |
-
autorun=false;
|
1136 |
-
run=5;
|
1137 |
-
deltaX=3;
|
1138 |
-
deltaY=0;
|
1139 |
-
render();
|
1140 |
-
}' .
|
1141 |
-
|
1142 |
-
'function onLeftMouseDown(e){
|
1143 |
-
e.preventDefault();
|
1144 |
-
autorun=false;
|
1145 |
-
run=5;
|
1146 |
-
deltaX=-3;
|
1147 |
-
deltaY=0;
|
1148 |
-
render();
|
1149 |
-
}' .
|
1150 |
-
|
1151 |
-
// Vertical movement by button
|
1152 |
-
'function onUpMouseDown(e){
|
1153 |
-
e.preventDefault();
|
1154 |
-
autorun=false;
|
1155 |
-
run=5;
|
1156 |
-
deltaX=0;
|
1157 |
-
deltaY=-3;
|
1158 |
-
render();
|
1159 |
-
}' .
|
1160 |
-
|
1161 |
-
'function onDownMouseDown(e){
|
1162 |
-
e.preventDefault();
|
1163 |
-
autorun=false;
|
1164 |
-
run=5;
|
1165 |
-
deltaX=0;
|
1166 |
-
deltaY=3;
|
1167 |
-
render();
|
1168 |
-
}' .
|
1169 |
-
|
1170 |
-
// Zooming
|
1171 |
-
'function onZoomInMouseDown(e){
|
1172 |
-
e.preventDefault();
|
1173 |
-
deltaX=0;
|
1174 |
-
deltaY=0;
|
1175 |
-
autorun=false;
|
1176 |
-
run=5;
|
1177 |
-
deltaFactor=1.005;
|
1178 |
-
render();
|
1179 |
-
}' .
|
1180 |
-
|
1181 |
-
'function onZoomOutMouseDown(e){
|
1182 |
-
e.preventDefault();
|
1183 |
-
deltaX=0;
|
1184 |
-
deltaY=0;
|
1185 |
-
autorun=false;
|
1186 |
-
run=5;
|
1187 |
-
deltaFactor=0.995;
|
1188 |
-
render();
|
1189 |
-
}' .
|
1190 |
-
|
1191 |
-
// Mouse wheel
|
1192 |
-
'function onDivWheel(e) {
|
1193 |
-
e.preventDefault();
|
1194 |
-
deltaX=0;
|
1195 |
-
deltaY=0;
|
1196 |
-
autorun=false;
|
1197 |
-
run=4;
|
1198 |
-
deltaFactor = 1 + e.deltaY * zoomsensitivity / 10000;
|
1199 |
-
render();
|
1200 |
-
setTimeout(function(){deltaFactor = 1}, 25);
|
1201 |
-
e.stopPropagation();
|
1202 |
-
}' .
|
1203 |
-
|
1204 |
-
// When a navigation button is released, stop and reset all deltas
|
1205 |
-
'function onButtonUp(e) {
|
1206 |
-
e.preventDefault();
|
1207 |
-
autorun=false;deltaX=0;deltaY=0;deltaFactor=1;
|
1208 |
-
run=4;
|
1209 |
-
}' .
|
1210 |
-
|
1211 |
-
// When a (responsive) resize is required, we resize the wppaScene
|
1212 |
-
'function onResize' . $mocc . '(e){
|
1213 |
-
|
1214 |
-
if (abort) return;' .
|
1215 |
-
|
1216 |
-
( $lightbox ?
|
1217 |
-
|
1218 |
-
// Show image container
|
1219 |
-
'$("#wppa-overlay-fpc").css("display", "");' .
|
1220 |
-
|
1221 |
-
// There are 4 possiblilities: all combi of 'Width is the limit or not' and 'Mode is normal or fullscreen'
|
1222 |
-
'var widthIsLim,
|
1223 |
-
modeIsNormal = ! wppaIsFs();' .
|
1224 |
-
|
1225 |
-
// First find container dimensions dependant of mode
|
1226 |
-
'var contWidth, contHeight;
|
1227 |
-
|
1228 |
-
if ( modeIsNormal ) {
|
1229 |
-
contWidth = window.innerWidth ? window.innerWidth : screen.width;
|
1230 |
-
contHeight = window.innerHeight ? window.innerHeight : screen.height;
|
1231 |
-
}
|
1232 |
-
else {
|
1233 |
-
contWidth = screen.width;
|
1234 |
-
contHeight = screen.height;
|
1235 |
-
}
|
1236 |
-
newWidth = parseInt(newWidth);
|
1237 |
-
newHeight = parseInt(newHeight);
|
1238 |
-
' .
|
1239 |
-
|
1240 |
-
// Initialize new display sizes
|
1241 |
-
'var newWidth,
|
1242 |
-
newHeight,
|
1243 |
-
topMarg,
|
1244 |
-
leftMarg,
|
1245 |
-
extraX = 8,
|
1246 |
-
extraY = 24 + ' . ( $controls ? $icsiz : 0 ) . ' + contWidth * ' . $height . ' / ' . $width . ' + 40;' .
|
1247 |
-
|
1248 |
-
// Add borderwidth in case of mode == normal
|
1249 |
-
'if ( modeIsNormal ) {
|
1250 |
-
extraX += 2 * ' . wppa_opt( 'ovl_border_width' ) . ';
|
1251 |
-
extraY += 2 * ' . wppa_opt( 'ovl_border_width' ) . ';
|
1252 |
-
}
|
1253 |
-
' .
|
1254 |
-
|
1255 |
-
// Find out if the width is the limitng dimension
|
1256 |
-
'widthIsLim = ( contHeight > ( ( contWidth / 2 ) + extraY ) );' .
|
1257 |
|
1258 |
-
|
1259 |
-
|
1260 |
-
|
1261 |
-
|
1262 |
-
|
1263 |
-
|
1264 |
-
|
1265 |
-
|
1266 |
-
|
1267 |
-
|
1268 |
-
|
1269 |
-
|
1270 |
-
|
1271 |
-
|
1272 |
-
|
1273 |
-
|
1274 |
-
|
1275 |
-
|
1276 |
-
|
1277 |
-
|
1278 |
-
|
1279 |
-
|
1280 |
-
|
1281 |
-
|
1282 |
-
|
1283 |
-
|
1284 |
-
|
1285 |
-
|
1286 |
-
|
1287 |
-
|
1288 |
-
|
1289 |
-
|
1290 |
-
|
1291 |
-
'if ( widthIsLim ) {
|
1292 |
-
$("#wppa-overlay-fpc").css({left:4});
|
1293 |
-
}
|
1294 |
-
else {
|
1295 |
-
$("#wppa-overlay-fpc").css({left:(contWidth-newWidth)/2});
|
1296 |
-
}
|
1297 |
-
wppaAdjustControlbar();
|
1298 |
-
}' .
|
1299 |
-
|
1300 |
-
// Mode is fullscreen
|
1301 |
-
'else {' .
|
1302 |
-
|
1303 |
-
// Common for mode fullscreen
|
1304 |
-
'$("#wppa-overlay-fpc").css({marginLeft:0});
|
1305 |
-
$("#wppa-ovl-flatpan-container").css({
|
1306 |
-
backgroundColor:"transparent",
|
1307 |
-
padding:0,
|
1308 |
-
borderRadius:"0px",
|
1309 |
-
width:newWidth,
|
1310 |
-
left:(contWidth-newWidth)/2
|
1311 |
-
});' .
|
1312 |
-
'wppaAdjustControlbar();' .
|
1313 |
-
|
1314 |
-
'}' .
|
1315 |
-
|
1316 |
-
'run=(autorun?5:4);
|
1317 |
-
render();
|
1318 |
-
' :
|
1319 |
-
|
1320 |
-
// Not lightbox
|
1321 |
-
'canvasWidth = $(div).parent().width();
|
1322 |
-
canvasHeight = canvasWidth / 2;
|
1323 |
-
canvas.width = canvasWidth;
|
1324 |
-
canvas.height = canvasHeight;
|
1325 |
-
prevCanvas.width = canvasWidth;
|
1326 |
-
prevCanvas.height = canvasWidth * ' . $height . ' / ' . $width . ';
|
1327 |
-
run=(autorun?5:4);
|
1328 |
-
render();'
|
1329 |
-
) .
|
1330 |
-
|
1331 |
-
'}' .
|
1332 |
-
|
1333 |
-
// when the mouse is pressed on the canvas, we switch to manual control and save current coordinates
|
1334 |
-
'function onCanvasMouseDown(e){
|
1335 |
-
e.preventDefault();
|
1336 |
-
manualControl = true;
|
1337 |
-
autorun=false;
|
1338 |
-
deltaX=0;
|
1339 |
-
savedCanvasX = e.offsetX;
|
1340 |
-
savedCanvasY = e.offsetY;
|
1341 |
-
run=5;
|
1342 |
-
render();
|
1343 |
-
}' .
|
1344 |
-
|
1345 |
-
'function onCanvasMouseMove(e){
|
1346 |
-
if ( manualControl ){
|
1347 |
-
autorun=false;
|
1348 |
-
deltaX=0;
|
1349 |
-
var factor = canvas.width / fromWidth;
|
1350 |
-
var x = ( savedCanvasX - e.offsetX ) / factor + fromX;
|
1351 |
-
var y = ( savedCanvasY - e.offsetY ) / factor + fromY;
|
1352 |
-
|
1353 |
-
if ( x > 0 && y > 0 && ( x + fromWidth ) < image' . $mocc . '.width && ( y + fromHeight ) < image' . $mocc . '.height ) {
|
1354 |
-
fromX = x;
|
1355 |
-
fromY = y;
|
1356 |
-
savedCanvasX = e.offsetX;
|
1357 |
-
savedCanvasY = e.offsetY;
|
1358 |
-
}
|
1359 |
-
}
|
1360 |
-
}' .
|
1361 |
-
|
1362 |
-
'function onPrevCanvasMouseMove(e){
|
1363 |
-
var factor = prevCanvas.width / image' . $mocc . '.width;
|
1364 |
-
|
1365 |
-
if (e.offsetX > factor * fromX &&
|
1366 |
-
e.offsetX < factor * ( fromX + fromWidth ) &&
|
1367 |
-
e.offsetY > factor * fromY &&
|
1368 |
-
e.offsetY < factor * ( fromY + fromHeight ) ) {
|
1369 |
-
$(prevCanvas).css("cursor","grab");
|
1370 |
-
}
|
1371 |
-
else {
|
1372 |
-
$(prevCanvas).css("cursor","default");
|
1373 |
-
}
|
1374 |
|
1375 |
-
|
1376 |
-
|
1377 |
-
|
1378 |
-
|
1379 |
-
|
1380 |
-
e.offsetY > factor * fromY &&
|
1381 |
-
e.offsetY < factor * ( fromY + fromHeight ) ) {
|
1382 |
-
fromX = ( e.offsetX - savedCanvasX ) / factor + fromX;
|
1383 |
-
fromY = ( e.offsetY - savedCanvasY ) / factor + fromY;
|
1384 |
-
savedCanvasX = e.offsetX;
|
1385 |
-
savedCanvasY = e.offsetY;
|
1386 |
-
}
|
1387 |
-
}
|
1388 |
-
}' .
|
1389 |
|
1390 |
-
|
1391 |
-
|
1392 |
-
|
1393 |
-
manualControl = false;
|
1394 |
-
}
|
1395 |
-
}' .
|
1396 |
-
|
1397 |
-
'function timnow() {
|
1398 |
-
d = new Date();
|
1399 |
-
return d.getTime();
|
1400 |
-
}' .
|
1401 |
-
|
1402 |
-
// Clean up
|
1403 |
-
'function quitImage(e) {
|
1404 |
-
abort = true;
|
1405 |
-
run = 0;
|
1406 |
-
autorun = false;
|
1407 |
-
clearTimeout(timer);
|
1408 |
-
$(canvas).hide();
|
1409 |
-
$(prevCanvas).hide();
|
1410 |
-
$("#wppa-pctl-div-0").hide();
|
1411 |
-
}' .
|
1412 |
-
'}
|
1413 |
-
|
1414 |
-
</script>
|
1415 |
-
' . ( $haslink ? '<a>' : '' ) . '';
|
1416 |
|
1417 |
return wppa_pan_min( $result );
|
1418 |
}
|
@@ -1485,9 +1019,17 @@ function wppa_get_zoom_pan_html( $args ) {
|
|
1485 |
id="wppa-pan-div-' . $itemid . '"
|
1486 |
class="wppa-pan-div wppa-pan-div-' . $mocc . '"
|
1487 |
style="' . ( $controls ? 'margin-bottom:4px;' : '' ) . 'line-height:0;"
|
1488 |
-
>'
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1489 |
|
1490 |
// The actual drawing area
|
|
|
1491 |
'<canvas
|
1492 |
id="wppa-pan-canvas-' . $itemid . '"
|
1493 |
style="' . ( $manual ? 'cursor:grab;' : '' ) . ';"
|
@@ -1639,51 +1181,52 @@ function wppa_get_zoom_pan_html( $args ) {
|
|
1639 |
'</div>';
|
1640 |
}
|
1641 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1642 |
// wppa-ovl-zoom-container
|
1643 |
if ( $lightbox ) {
|
1644 |
$result .=
|
1645 |
'</div>';
|
1646 |
}
|
1647 |
|
1648 |
-
|
1649 |
-
|
1650 |
-
|
1651 |
-
|
1652 |
-
// Create image object and add the image url to it
|
1653 |
-
( $lightbox ?
|
1654 |
-
'var image = document.getElementById(\'wppa-pre-curr\');' :
|
1655 |
-
'var image = new Image();'
|
1656 |
-
) .
|
1657 |
-
'image.src = "' . $url . '";' .
|
1658 |
-
|
1659 |
-
'var data' . $mocc . ' =
|
1660 |
-
{ mocc :' . $mocc . ',
|
1661 |
-
id :' . $id . ',
|
1662 |
-
itemId :"' . $itemid . '",
|
1663 |
-
isLightbox :' . ( $lightbox ? 'true' : 'false' ) . ',
|
1664 |
-
image :image,
|
1665 |
-
abort :false,
|
1666 |
-
zoomsensitivity :' . $zoomsensitivity . ',
|
1667 |
-
borderWidth :' . wppa_opt( 'ovl_border_width' ) . ',
|
1668 |
-
controls :' . ( $controls ? 'true' : 'false' ) . ',
|
1669 |
-
height :' . $height . ',
|
1670 |
-
width :' . $width . ',
|
1671 |
-
initialized :false,
|
1672 |
-
icsize :' . ( $lightbox ? wppa_opt( 'nav_icon_size_lightbox' ) : wppa_opt( 'nav_icon_size_panorama' ) ) . ',
|
1673 |
-
backgroundColor :\'' . wppa_opt( 'ovl_theme' ) . '\',
|
1674 |
-
borderRadius :' . wppa_opt( 'ovl_border_radius' ) . ',
|
1675 |
-
padding :' . wppa_opt( 'ovl_border_width' ) . '
|
1676 |
-
};
|
1677 |
-
|
1678 |
-
jQuery(document).ready(function(){wppaDoZoomPan(' . $mocc . ', data' . $mocc . ');});
|
1679 |
-
|
1680 |
-
</script>
|
1681 |
-
' . ( $haslink ? '<a>' : '' ) . '';
|
1682 |
|
1683 |
return wppa_pan_min( $result );
|
1684 |
}
|
1685 |
|
1686 |
-
// Minimize
|
1687 |
function wppa_pan_min( $result ) {
|
1688 |
|
1689 |
// Remove tabs
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Make the picture html
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
635 |
$run = 'false';
|
636 |
}
|
637 |
|
638 |
+
$onload = '
|
639 |
+
jQuery(document).ready(function(){
|
|
|
640 |
var data' . $mocc . ' =
|
641 |
{ mocc :' . $mocc . ',
|
642 |
id :' . $id . ',
|
644 |
isLightbox :' . ( $lightbox ? 'true' : 'false' ) . ',
|
645 |
height :' . $height . ',
|
646 |
width :' . $width . ',
|
647 |
+
url :\'' . $url . '\',
|
648 |
abort :false,
|
649 |
autorun :' . $run . ',
|
650 |
dX :' . $dX . ',
|
655 |
controls :' . ( $controls ? 'true' : 'false' ) . ',
|
656 |
initialized :false,
|
657 |
icsize :' . ( $lightbox ? wppa_opt( 'nav_icon_size_lightbox' ) : wppa_opt( 'nav_icon_size_panorama' ) ) . ',
|
658 |
+
backgroundColor :\'' . wppa_opt( 'ovl_theme' ) . '\',
|
659 |
borderRadius :' . wppa_opt( 'ovl_border_radius' ) . ',
|
660 |
padding :' . wppa_opt( 'ovl_border_width' ) . ',
|
661 |
enableManual :' . ( $manual ? 'true' : 'false' ) . ',
|
662 |
+
vtime :0
|
663 |
};
|
664 |
+
wppaDoSphericPan(' . $mocc . ', data' . $mocc . ');
|
665 |
+
});';
|
666 |
|
667 |
+
$result .= '
|
668 |
+
<img
|
669 |
+
id="wppa-' . $mocc . '-' . $id . '"
|
670 |
+
src="' . esc_url( $url ) . '"
|
671 |
+
style="display:none"
|
672 |
+
onload="' . esc_attr( $onload ) . '" />';
|
673 |
|
674 |
+
if ( $haslink ) {
|
675 |
+
$result .= '<a>';
|
676 |
+
}
|
677 |
|
678 |
$result = wppa_pan_min( $result );
|
679 |
|
701 |
|
702 |
$id = strval( intval ( $args['id'] ) );
|
703 |
$mocc = $args['mocc'] ? $args['mocc'] : wppa( 'mocc' );
|
704 |
+
$itemid = $mocc . '-' . $id;
|
705 |
$width = $args['width'] ? $args['width'] : wppa_get_container_width();
|
706 |
$height = $args['height'] ? $args['height'] : round( $width * wppa_get_photoy( $id ) / wppa_get_photox( $id ) );
|
707 |
$haslink = $args['haslink'];
|
898 |
'</span>';
|
899 |
}
|
900 |
}
|
|
|
|
|
|
|
901 |
}
|
902 |
|
903 |
+
// End controlbar
|
|
|
|
|
|
|
904 |
$result .=
|
905 |
+
'</div>';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
906 |
|
907 |
+
// Add placeholder for image
|
908 |
+
$onload =
|
909 |
+
'jQuery(document).ready(function(){
|
910 |
+
var data' . $mocc . ' =
|
911 |
+
{ mocc :' . $mocc . ',
|
912 |
+
id :' . $id . ',
|
913 |
+
itemId :\'' . $itemid . '\',
|
914 |
+
isLightbox :' . ( $lightbox ? 'true' : 'false' ) . ',
|
915 |
+
url :\'' . $url . '\',
|
916 |
+
abort :false,
|
917 |
+
zoomsensitivity :' . $zoomsensitivity . ',
|
918 |
+
borderWidth :' . wppa_opt( 'ovl_border_width' ) . ',
|
919 |
+
controls :' . ( $controls ? 'true' : 'false' ) . ',
|
920 |
+
height :' . $height . ',
|
921 |
+
width :' . $width . ',
|
922 |
+
icsize :' . ( $lightbox ? wppa_opt( 'nav_icon_size_lightbox' ) : wppa_opt( 'nav_icon_size_panorama' ) ) . ',
|
923 |
+
backgroundColor :\'' . wppa_opt( 'ovl_theme' ) . '\',
|
924 |
+
borderRadius :' . wppa_opt( 'ovl_border_radius' ) . ',
|
925 |
+
padding :' . wppa_opt( 'ovl_border_width' ) . ',
|
926 |
+
deltaX :' . $deltaX . ',
|
927 |
+
autorun :' . ( $autorun ? 'true' : 'false' ) . ',
|
928 |
+
manual :' . ( $manual ? 'true' : 'false' ) . ',
|
929 |
+
};
|
930 |
+
jQuery( \'#wppa-spinner-'.$mocc.'\' ).hide();
|
931 |
+
wppaDoFlatPanorama(' . $mocc . ', data' . $mocc . ');
|
932 |
+
});';
|
933 |
+
|
934 |
+
$result .= '
|
935 |
+
<img
|
936 |
+
id="wppa-' . $itemid . '"
|
937 |
+
src="' . esc_url( $url ) . '"
|
938 |
+
style="display:none"
|
939 |
+
onload="' . esc_attr( $onload ) . '" />';
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
940 |
|
941 |
+
// wppa-ovl-flatpan-container
|
942 |
+
if ( $lightbox ) {
|
943 |
+
$result .=
|
944 |
+
'</div>';
|
945 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
946 |
|
947 |
+
if ( $haslink ) {
|
948 |
+
$result .= '<a>';
|
949 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
950 |
|
951 |
return wppa_pan_min( $result );
|
952 |
}
|
1019 |
id="wppa-pan-div-' . $itemid . '"
|
1020 |
class="wppa-pan-div wppa-pan-div-' . $mocc . '"
|
1021 |
style="' . ( $controls ? 'margin-bottom:4px;' : '' ) . 'line-height:0;"
|
1022 |
+
>';
|
1023 |
+
|
1024 |
+
// The spinner image
|
1025 |
+
if ( $lightbox ) {
|
1026 |
+
}
|
1027 |
+
else {
|
1028 |
+
$result .= wppa_get_spinner_svg_html( ['id' => 'wppa-spinner-'.$mocc, 'display' => ''] );
|
1029 |
+
}
|
1030 |
|
1031 |
// The actual drawing area
|
1032 |
+
$result .=
|
1033 |
'<canvas
|
1034 |
id="wppa-pan-canvas-' . $itemid . '"
|
1035 |
style="' . ( $manual ? 'cursor:grab;' : '' ) . ';"
|
1181 |
'</div>';
|
1182 |
}
|
1183 |
|
1184 |
+
// Add placeholder for image
|
1185 |
+
$onload =
|
1186 |
+
'jQuery(document).ready(function(){
|
1187 |
+
var data' . $mocc . ' =
|
1188 |
+
{ mocc :' . $mocc . ',
|
1189 |
+
id :' . $id . ',
|
1190 |
+
itemId :\'' . $itemid . '\',
|
1191 |
+
isLightbox :' . ( $lightbox ? 'true' : 'false' ) . ',
|
1192 |
+
url :\'' . $url . '\',
|
1193 |
+
abort :false,
|
1194 |
+
zoomsensitivity :' . $zoomsensitivity . ',
|
1195 |
+
borderWidth :' . wppa_opt( 'ovl_border_width' ) . ',
|
1196 |
+
controls :' . ( $controls ? 'true' : 'false' ) . ',
|
1197 |
+
height :' . $height . ',
|
1198 |
+
width :' . $width . ',
|
1199 |
+
initialized :false,
|
1200 |
+
icsize :' . ( $lightbox ? wppa_opt( 'nav_icon_size_lightbox' ) : wppa_opt( 'nav_icon_size_panorama' ) ) . ',
|
1201 |
+
backgroundColor :\'' . wppa_opt( 'ovl_theme' ) . '\',
|
1202 |
+
borderRadius :' . wppa_opt( 'ovl_border_radius' ) . ',
|
1203 |
+
padding :' . wppa_opt( 'ovl_border_width' ) . '
|
1204 |
+
};
|
1205 |
+
jQuery( \'#wppa-spinner-'.$mocc.'\' ).hide();
|
1206 |
+
wppaDoZoomPan(' . $mocc . ', data' . $mocc . ');
|
1207 |
+
});';
|
1208 |
+
|
1209 |
+
$result .= '
|
1210 |
+
<img
|
1211 |
+
id="wppa-' . $itemid . '"
|
1212 |
+
src="' . esc_url( $url ) . '"
|
1213 |
+
style="display:none"
|
1214 |
+
onload="' . esc_attr( $onload ) . '" />';
|
1215 |
+
|
1216 |
// wppa-ovl-zoom-container
|
1217 |
if ( $lightbox ) {
|
1218 |
$result .=
|
1219 |
'</div>';
|
1220 |
}
|
1221 |
|
1222 |
+
if ( $haslink ) {
|
1223 |
+
$result .= '<a>';
|
1224 |
+
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1225 |
|
1226 |
return wppa_pan_min( $result );
|
1227 |
}
|
1228 |
|
1229 |
+
// Minimize inline mixed html / js code
|
1230 |
function wppa_pan_min( $result ) {
|
1231 |
|
1232 |
// Remove tabs
|
wppa-potd-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the photo of the day widget
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
@@ -248,18 +248,16 @@ class PhotoOfTheDay extends WP_Widget {
|
|
248 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
249 |
|
250 |
// Title
|
251 |
-
$result =
|
252 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
253 |
|
254 |
// Loggedin only
|
255 |
-
$result .=
|
256 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
257 |
|
258 |
// Explanation
|
259 |
if ( current_user_can( 'wppa_settings' ) ) {
|
260 |
-
$result
|
261 |
'<p>' .
|
262 |
-
|
263 |
wppa_see_also( 'photos', 3 ); // .
|
264 |
'</p>';
|
265 |
}
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the photo of the day widget
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
248 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
249 |
|
250 |
// Title
|
|
|
251 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
252 |
|
253 |
// Loggedin only
|
|
|
254 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
255 |
|
256 |
// Explanation
|
257 |
if ( current_user_can( 'wppa_settings' ) ) {
|
258 |
+
$result =
|
259 |
'<p>' .
|
260 |
+
__( 'You can set the content and the sizes in this widget in the <b>Photo Albums -> Photo of the day</b> admin page.', 'wp-photo-album-plus' ) .
|
261 |
wppa_see_also( 'photos', 3 ); // .
|
262 |
'</p>';
|
263 |
}
|
wppa-qr-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display qr code
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -84,20 +84,20 @@ class wppaQRWidget extends WP_Widget {
|
|
84 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
85 |
|
86 |
// Title
|
87 |
-
|
88 |
-
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) ) );
|
89 |
|
90 |
// Loggedin only
|
91 |
-
|
92 |
-
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) ) );
|
93 |
|
94 |
// Explanation
|
95 |
if ( current_user_can( 'wppa_settings' ) ) {
|
96 |
-
|
97 |
-
'
|
98 |
-
|
|
|
99 |
wppa_see_also( 'widget', '3' ) .
|
100 |
-
'</p>'
|
|
|
101 |
};
|
102 |
}
|
103 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display qr code
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
84 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
85 |
|
86 |
// Title
|
87 |
+
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
|
|
88 |
|
89 |
// Loggedin only
|
90 |
+
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
|
|
91 |
|
92 |
// Explanation
|
93 |
if ( current_user_can( 'wppa_settings' ) ) {
|
94 |
+
|
95 |
+
$result = '
|
96 |
+
<p>' .
|
97 |
+
__( 'You can set the sizes and colors in this widget in the <b>Photo Albums -> Settings</b> admin page Tab Widgets -> III', 'wp-photo-album-plus' ) .
|
98 |
wppa_see_also( 'widget', '3' ) .
|
99 |
+
'</p>';
|
100 |
+
wppa_echo( strip_tags( wp_check_invalid_utf8( $result), ["<br>", "<a>", "<i>", "<b>", "<p>"] ) );
|
101 |
};
|
102 |
}
|
103 |
|
wppa-scripts.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
*
|
5 |
* This file contains all functions for activating javascript
|
6 |
*
|
7 |
-
* Version 8.
|
8 |
*/
|
9 |
|
10 |
// Place all wppa related js declarations in the header, both admin and frontend
|
@@ -184,6 +184,7 @@ global $wpdb;
|
|
184 |
wppaPhotoId = 0,
|
185 |
wppaOvlVideoStart = false,
|
186 |
wppaOvlAudioStart = false,
|
|
|
187 |
wppaLastIptc = "",
|
188 |
wppaLastExif = "",
|
189 |
wppaIsIpad = false,
|
@@ -563,6 +564,7 @@ global $wppa_opt;
|
|
563 |
'wppa-touch',
|
564 |
'wppa-zoom',
|
565 |
'wppa-spheric',
|
|
|
566 |
);
|
567 |
|
568 |
foreach ( array_keys( $js_files ) as $idx ) {
|
@@ -670,7 +672,7 @@ global $wppa_gutenberg_preview;
|
|
670 |
}
|
671 |
|
672 |
// Do it
|
673 |
-
if ( wppa_is_caching() || wppa_in_widget() || $now || $wppa_gutenberg_preview ) {
|
674 |
wppa_out( '<script>' . $txt . '</script>' );
|
675 |
return;
|
676 |
}
|
4 |
*
|
5 |
* This file contains all functions for activating javascript
|
6 |
*
|
7 |
+
* Version 8.2.01.001
|
8 |
*/
|
9 |
|
10 |
// Place all wppa related js declarations in the header, both admin and frontend
|
184 |
wppaPhotoId = 0,
|
185 |
wppaOvlVideoStart = false,
|
186 |
wppaOvlAudioStart = false,
|
187 |
+
wppaOvlIsSingle = false,
|
188 |
wppaLastIptc = "",
|
189 |
wppaLastExif = "",
|
190 |
wppaIsIpad = false,
|
564 |
'wppa-touch',
|
565 |
'wppa-zoom',
|
566 |
'wppa-spheric',
|
567 |
+
'wppa-flatpan',
|
568 |
);
|
569 |
|
570 |
foreach ( array_keys( $js_files ) as $idx ) {
|
672 |
}
|
673 |
|
674 |
// Do it
|
675 |
+
if ( wppa_is_caching() || /* wppa_in_widget() || */ $now || $wppa_gutenberg_preview ) {
|
676 |
wppa_out( '<script>' . $txt . '</script>' );
|
677 |
return;
|
678 |
}
|
wppa-search-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the search widget
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -83,11 +83,9 @@ class SearchPhotos extends WP_Widget {
|
|
83 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
84 |
|
85 |
// Title
|
86 |
-
echo
|
87 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
88 |
|
89 |
// Pre input text
|
90 |
-
echo
|
91 |
wppa_widget_input( $this,
|
92 |
'label',
|
93 |
$instance['label'],
|
@@ -96,7 +94,6 @@ class SearchPhotos extends WP_Widget {
|
|
96 |
);
|
97 |
|
98 |
// Enable rootsearch
|
99 |
-
echo
|
100 |
wppa_widget_checkbox( $this,
|
101 |
'root',
|
102 |
$instance['root'],
|
@@ -110,7 +107,7 @@ class SearchPhotos extends WP_Widget {
|
|
110 |
'sort' => true,
|
111 |
'path' => true,
|
112 |
) );
|
113 |
-
|
114 |
wppa_widget_selection_frame( $this,
|
115 |
'album',
|
116 |
$body,
|
@@ -122,7 +119,6 @@ class SearchPhotos extends WP_Widget {
|
|
122 |
);
|
123 |
|
124 |
// Subsearch?
|
125 |
-
echo
|
126 |
wppa_widget_checkbox( $this,
|
127 |
'sub',
|
128 |
$instance['sub'],
|
@@ -131,7 +127,6 @@ class SearchPhotos extends WP_Widget {
|
|
131 |
);
|
132 |
|
133 |
// Category selection
|
134 |
-
echo
|
135 |
wppa_widget_checkbox( $this,
|
136 |
'catbox',
|
137 |
$instance['catbox'],
|
@@ -140,7 +135,6 @@ class SearchPhotos extends WP_Widget {
|
|
140 |
);
|
141 |
|
142 |
// Selection boxes
|
143 |
-
echo
|
144 |
wppa_widget_checkbox( $this,
|
145 |
'selboxes',
|
146 |
$instance['selboxes'],
|
@@ -179,7 +173,6 @@ class SearchPhotos extends WP_Widget {
|
|
179 |
}
|
180 |
}
|
181 |
|
182 |
-
echo
|
183 |
wppa_widget_selection( $this,
|
184 |
'landingpage',
|
185 |
$instance['landingpage'],
|
@@ -192,7 +185,6 @@ class SearchPhotos extends WP_Widget {
|
|
192 |
);
|
193 |
|
194 |
// Loggedin only
|
195 |
-
echo
|
196 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
197 |
}
|
198 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the search widget
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
83 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
84 |
|
85 |
// Title
|
|
|
86 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
87 |
|
88 |
// Pre input text
|
|
|
89 |
wppa_widget_input( $this,
|
90 |
'label',
|
91 |
$instance['label'],
|
94 |
);
|
95 |
|
96 |
// Enable rootsearch
|
|
|
97 |
wppa_widget_checkbox( $this,
|
98 |
'root',
|
99 |
$instance['root'],
|
107 |
'sort' => true,
|
108 |
'path' => true,
|
109 |
) );
|
110 |
+
|
111 |
wppa_widget_selection_frame( $this,
|
112 |
'album',
|
113 |
$body,
|
119 |
);
|
120 |
|
121 |
// Subsearch?
|
|
|
122 |
wppa_widget_checkbox( $this,
|
123 |
'sub',
|
124 |
$instance['sub'],
|
127 |
);
|
128 |
|
129 |
// Category selection
|
|
|
130 |
wppa_widget_checkbox( $this,
|
131 |
'catbox',
|
132 |
$instance['catbox'],
|
135 |
);
|
136 |
|
137 |
// Selection boxes
|
|
|
138 |
wppa_widget_checkbox( $this,
|
139 |
'selboxes',
|
140 |
$instance['selboxes'],
|
173 |
}
|
174 |
}
|
175 |
|
|
|
176 |
wppa_widget_selection( $this,
|
177 |
'landingpage',
|
178 |
$instance['landingpage'],
|
185 |
);
|
186 |
|
187 |
// Loggedin only
|
|
|
188 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
189 |
}
|
190 |
|
wppa-setting-functions.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* manage all options
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -331,8 +331,8 @@ global $no_default;
|
|
331 |
|
332 |
$dft = $dflt;
|
333 |
switch ($dflt) {
|
334 |
-
case 'yes': $dft
|
335 |
-
case 'no': $dft
|
336 |
/* case 'none': $dft .= ': '.__('no link at all.', 'wp-photo-album-plus' ); break;
|
337 |
case 'file': $dft .= ': '.__('the plain photo (file).', 'wp-photo-album-plus' ); break;
|
338 |
case 'photo': $dft .= ': '.__('the full size photo in a slideshow.', 'wp-photo-album-plus' ); break;
|
@@ -753,12 +753,12 @@ global $wppa_setting_error;
|
|
753 |
if ( $help ) {
|
754 |
$is_dflt = true;
|
755 |
|
756 |
-
$helptext =
|
757 |
|
758 |
if ( ! $no_default ) {
|
759 |
if ( $slugs && wppa_dflt($slugs[0]) ) {
|
760 |
-
$helptext .= '<br>' . esc_html__( 'The default for this setting is:', 'wp-photo-album-plus' );
|
761 |
if ( count($slugs) == 1) {
|
|
|
762 |
if ( $slugs[0] != '' ) {
|
763 |
$helptext .= ' '.htmlspecialchars(wppa_dflt($slugs[0]));
|
764 |
if ( $wppa_opt[$slugs[0]] != $wppa_defaults[$slugs[0]] ) {
|
@@ -766,10 +766,15 @@ global $wppa_setting_error;
|
|
766 |
}
|
767 |
}
|
768 |
}
|
769 |
-
else
|
770 |
-
|
771 |
-
|
772 |
-
|
|
|
|
|
|
|
|
|
|
|
773 |
}
|
774 |
}
|
775 |
}
|
@@ -792,10 +797,10 @@ global $wppa_setting_error;
|
|
792 |
'<td>' . esc_html( $xnum ) . '</td>' .
|
793 |
|
794 |
// The Item name
|
795 |
-
'<td>' .
|
796 |
|
797 |
// The item description
|
798 |
-
'<td><small>' . $desc . '</small></td>';
|
799 |
|
800 |
// The html
|
801 |
if ( $htmls ) foreach ( $htmls as $html ) {
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* manage all options
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
331 |
|
332 |
$dft = $dflt;
|
333 |
switch ($dflt) {
|
334 |
+
case 'yes': $dft = __('Checked', 'wp-photo-album-plus' ); break;
|
335 |
+
case 'no': $dft = __('Unchecked', 'wp-photo-album-plus' ); break;
|
336 |
/* case 'none': $dft .= ': '.__('no link at all.', 'wp-photo-album-plus' ); break;
|
337 |
case 'file': $dft .= ': '.__('the plain photo (file).', 'wp-photo-album-plus' ); break;
|
338 |
case 'photo': $dft .= ': '.__('the full size photo in a slideshow.', 'wp-photo-album-plus' ); break;
|
753 |
if ( $help ) {
|
754 |
$is_dflt = true;
|
755 |
|
756 |
+
$helptext = strip_tags( wp_check_invalid_utf8( $help ), ["<br>", "<a>", "<b>", "<i>"] );
|
757 |
|
758 |
if ( ! $no_default ) {
|
759 |
if ( $slugs && wppa_dflt($slugs[0]) ) {
|
|
|
760 |
if ( count($slugs) == 1) {
|
761 |
+
$helptext .= '<br>' . esc_html__( 'The default for this setting is:', 'wp-photo-album-plus' );
|
762 |
if ( $slugs[0] != '' ) {
|
763 |
$helptext .= ' '.htmlspecialchars(wppa_dflt($slugs[0]));
|
764 |
if ( $wppa_opt[$slugs[0]] != $wppa_defaults[$slugs[0]] ) {
|
766 |
}
|
767 |
}
|
768 |
}
|
769 |
+
else {
|
770 |
+
$helptext .= '<br>' . esc_html__( 'The defaults for this setting are', 'wp-photo-album-plus' );
|
771 |
+
$first = true;
|
772 |
+
foreach ( array_keys($slugs) as $slugidx ) {
|
773 |
+
if ( $slugs[$slugidx] ) $helptext .= ( $first ? ': ' : ', ' ).wppa_dflt($slugs[$slugidx]);
|
774 |
+
$first = false;
|
775 |
+
if ( $slugs[$slugidx] && isset($wppa_opt[$slugs[$slugidx]]) && $wppa_opt[$slugs[$slugidx]] != $wppa_defaults[$slugs[$slugidx]] ) {
|
776 |
+
$is_dflt = false;
|
777 |
+
}
|
778 |
}
|
779 |
}
|
780 |
}
|
797 |
'<td>' . esc_html( $xnum ) . '</td>' .
|
798 |
|
799 |
// The Item name
|
800 |
+
'<td>' . strip_tags( wp_check_invalid_utf8( $name ), ["<br>", "<a>", "<b>", "<i>"] ) . '</td>' .
|
801 |
|
802 |
// The item description
|
803 |
+
'<td><small>' . strip_tags( wp_check_invalid_utf8( $desc ), ["<br>", "<a>", "<b>", "<i>"] ) . '</small></td>';
|
804 |
|
805 |
// The html
|
806 |
if ( $htmls ) foreach ( $htmls as $html ) {
|
wppa-settings-autosave.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* manage all options
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -5394,7 +5394,7 @@ global $wppa_subtab_names;
|
|
5394 |
$slug4 = 'wppa_tagcloud_linkpage_oc';
|
5395 |
$slug = array($slug1, $slug2, $slug3, $slug4);
|
5396 |
$opts1 = array(
|
5397 |
-
__('thumbnails', 'wp-photo-album-plus' ),
|
5398 |
__('slideshow', 'wp-photo-album-plus' )
|
5399 |
);
|
5400 |
$vals1 = array(
|
@@ -5425,7 +5425,7 @@ global $wppa_subtab_names;
|
|
5425 |
$slug4 = 'wppa_multitag_linkpage_oc';
|
5426 |
$slug = array($slug1, $slug2, $slug3, $slug4);
|
5427 |
$opts1 = array(
|
5428 |
-
__('thumbnails', 'wp-photo-album-plus' ),
|
5429 |
__('slideshow', 'wp-photo-album-plus' )
|
5430 |
);
|
5431 |
$vals1 = array(
|
@@ -5703,7 +5703,7 @@ global $wppa_subtab_names;
|
|
5703 |
|
5704 |
$name = __('Album id on cover is link', 'wp-photo-album-plus' );
|
5705 |
$desc = __('The album number on the cover links to the album admin page of the album', 'wp-photo-album-plus' );
|
5706 |
-
$help = __('Album id on cover must be enabled. The ids are only links when the user has edit album
|
5707 |
$slug1 = 'wppa_fe_albid_edit';
|
5708 |
$slug2 = '';
|
5709 |
$slug3 = '';
|
@@ -9754,22 +9754,6 @@ global $wppa_subtab_names;
|
|
9754 |
$html = wppa_select($slug, $opts, $vals);
|
9755 |
wppa_setting_new($slug, '2', $name, $desc, $html, $help);
|
9756 |
|
9757 |
-
$name = __('Default coverphoto selection', 'wp-photo-album-plus' );
|
9758 |
-
$desc = __('Default select cover photo method.', 'wp-photo-album-plus' );
|
9759 |
-
$help = __('The coverphoto slection method can be overruled on the edit album page.', 'wp-photo-album-plus' );
|
9760 |
-
$help .= '<br>' . __('Alternatively an individual photo can be selected on the edit album page.', 'wp-photo-album-plus' );
|
9761 |
-
$opts = array( __('--- random ---', 'wp-photo-album-plus' ),
|
9762 |
-
__('--- random featured ---', 'wp-photo-album-plus' ),
|
9763 |
-
__('--- most recent added ---', 'wp-photo-album-plus' ),
|
9764 |
-
__('--- random from (grand)children ---', 'wp-photo-album-plus' ),
|
9765 |
-
__('--- most recent from (grand)children ---', 'wp-photo-album-plus' ),
|
9766 |
-
__('--- according to albums photo sequence ---', 'wp-photo-album-plus' ),
|
9767 |
-
);
|
9768 |
-
$vals = array('-9', '-1', '-2', '-3', '-4', '-5');
|
9769 |
-
$slug = 'wppa_main_photo';
|
9770 |
-
$html = wppa_select($slug, $opts, $vals, 'wppaRefreshAfter()');
|
9771 |
-
wppa_setting_new($slug, '3', $name, $desc, $html, $help, wppa_opt('main_photo') != '-3' && wppa_opt('main_photo') != '-9');
|
9772 |
-
|
9773 |
$name = __('Default coverphoto selection', 'wp-photo-album-plus' );
|
9774 |
$desc = __('Default select cover photo method.', 'wp-photo-album-plus' );
|
9775 |
$help = __('The coverphoto slection method can be overruled on the edit album page.', 'wp-photo-album-plus' );
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* manage all options
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
5394 |
$slug4 = 'wppa_tagcloud_linkpage_oc';
|
5395 |
$slug = array($slug1, $slug2, $slug3, $slug4);
|
5396 |
$opts1 = array(
|
5397 |
+
__('album (thumbnails only)', 'wp-photo-album-plus' ),
|
5398 |
__('slideshow', 'wp-photo-album-plus' )
|
5399 |
);
|
5400 |
$vals1 = array(
|
5425 |
$slug4 = 'wppa_multitag_linkpage_oc';
|
5426 |
$slug = array($slug1, $slug2, $slug3, $slug4);
|
5427 |
$opts1 = array(
|
5428 |
+
__('album (thumbnails only)', 'wp-photo-album-plus' ),
|
5429 |
__('slideshow', 'wp-photo-album-plus' )
|
5430 |
);
|
5431 |
$vals1 = array(
|
5703 |
|
5704 |
$name = __('Album id on cover is link', 'wp-photo-album-plus' );
|
5705 |
$desc = __('The album number on the cover links to the album admin page of the album', 'wp-photo-album-plus' );
|
5706 |
+
$help = __('Album id on cover must be enabled. The ids are only links when the user has edit album access to the album', 'wp-photo-album-plus' );
|
5707 |
$slug1 = 'wppa_fe_albid_edit';
|
5708 |
$slug2 = '';
|
5709 |
$slug3 = '';
|
9754 |
$html = wppa_select($slug, $opts, $vals);
|
9755 |
wppa_setting_new($slug, '2', $name, $desc, $html, $help);
|
9756 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
9757 |
$name = __('Default coverphoto selection', 'wp-photo-album-plus' );
|
9758 |
$desc = __('Default select cover photo method.', 'wp-photo-album-plus' );
|
9759 |
$help = __('The coverphoto slection method can be overruled on the edit album page.', 'wp-photo-album-plus' );
|
wppa-slideshow-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display a slideshow in the sidebar
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
@@ -69,7 +69,6 @@ class SlideshowWidget extends WP_Widget {
|
|
69 |
}
|
70 |
|
71 |
// Fill in runtime parameters to tune the slideshow
|
72 |
-
wppa_reset_occurrance();
|
73 |
if ( $instance['linkurl'] && wppa_opt( 'slideonly_widget_linktype' ) == 'widget' ) {
|
74 |
wppa( 'in_widget_linkurl', $instance['linkurl'] );
|
75 |
wppa( 'in_widget_linktitle', __( $instance['linktitle'] ) );
|
@@ -116,7 +115,6 @@ class SlideshowWidget extends WP_Widget {
|
|
116 |
else {
|
117 |
|
118 |
// Nothing left after stripping. quit
|
119 |
-
wppa_reset_occurrance();
|
120 |
wppa( 'in_widget', false );
|
121 |
return;
|
122 |
}
|
@@ -142,8 +140,8 @@ class SlideshowWidget extends WP_Widget {
|
|
142 |
}
|
143 |
$result .= $widget_content . $after_widget;
|
144 |
|
145 |
-
echo $result;
|
146 |
-
|
147 |
|
148 |
// Cache?
|
149 |
if ( $cache ) {
|
@@ -151,9 +149,6 @@ class SlideshowWidget extends WP_Widget {
|
|
151 |
wppa_save_cache_file( ['file' => $cachefile, 'data' => $result] );
|
152 |
}
|
153 |
|
154 |
-
// Reset runtime parameters
|
155 |
-
wppa_reset_occurrance();
|
156 |
-
|
157 |
wppa( 'in_widget', false );
|
158 |
}
|
159 |
|
@@ -183,7 +178,6 @@ class SlideshowWidget extends WP_Widget {
|
|
183 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
184 |
|
185 |
// Title
|
186 |
-
echo
|
187 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
188 |
|
189 |
// Album
|
@@ -196,21 +190,14 @@ class SlideshowWidget extends WP_Widget {
|
|
196 |
'sort' => true,
|
197 |
) );
|
198 |
|
199 |
-
echo
|
200 |
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
201 |
}
|
202 |
else {
|
203 |
-
echo
|
204 |
wppa_widget_input( $this, 'album', $instance['album'], __( 'Album', 'wp-photo-album-plus' ) );
|
205 |
}
|
206 |
|
207 |
// Including sub albums?
|
208 |
-
|
209 |
-
wppa_widget_checkbox( $this,
|
210 |
-
'incsubs',
|
211 |
-
$instance['incsubs'],
|
212 |
-
__( 'Including subalbums', 'wp-photo-album-plus' )
|
213 |
-
);
|
214 |
|
215 |
// Max
|
216 |
$body =
|
@@ -224,50 +211,26 @@ class SlideshowWidget extends WP_Widget {
|
|
224 |
'<option value="250" ' . ( $instance['maxslides'] == '250' ? 'selected' : '' ) . ' >250</option>' .
|
225 |
'<option value="350" ' . ( $instance['maxslides'] == '350' ? 'selected' : '' ) . ' >350</option>' .
|
226 |
'<option value="500" ' . ( $instance['maxslides'] == '500' ? 'selected' : '' ) . ' >500</option>';
|
227 |
-
echo
|
228 |
wppa_widget_selection_frame( $this, 'maxslides', $body, __( 'Max slides', 'wp-photo-album-plus' ), false, __( 'High numbers may cause slow pageloads!', 'wp-photo-album-plus' ) );
|
229 |
|
230 |
// Random
|
231 |
-
|
232 |
-
wppa_widget_checkbox( $this,
|
233 |
-
'random',
|
234 |
-
$instance['random'],
|
235 |
-
__( 'Random sequence', 'wp-photo-album-plus' )
|
236 |
-
);
|
237 |
|
238 |
// Sizes and alignment
|
239 |
-
|
240 |
__( 'Sizes and alignment', 'wp-photo-album-plus' ) . ':' .
|
241 |
'<div style="padding:6px;border:1px solid lightgray;margin-top:2px">' .
|
242 |
__( 'Enter the width and optionally the height of the area wherein the slides will appear. If you specify a 0 for the height, it will be calculated. The value for the height will be ignored if you set the vertical alignment to \'fit\'.', 'wp-photo-album-plus' ) .
|
243 |
' ' .
|
244 |
__( 'Tick the portrait only checkbox if there are only portrait images in the album and you want the photos to fill the full width of the widget.', 'wp-photo-album-plus' ) .
|
245 |
' ' .
|
246 |
-
__ ( 'If portrait only is checked, the vertical alignment will be forced to \'fit\'.', 'wp-photo-album-plus' );
|
247 |
|
248 |
// Width
|
249 |
-
|
250 |
-
wppa_widget_number( $this,
|
251 |
-
'width',
|
252 |
-
$instance['width'],
|
253 |
-
__( 'Width in pixels', 'wp-photo-album-plus' ),
|
254 |
-
'50',
|
255 |
-
'500',
|
256 |
-
'',
|
257 |
-
'float'
|
258 |
-
);
|
259 |
|
260 |
// Height
|
261 |
-
|
262 |
-
wppa_widget_number( $this,
|
263 |
-
'height',
|
264 |
-
$instance['height'],
|
265 |
-
__( 'Height in pixels', 'wp-photo-album-plus' ),
|
266 |
-
'0',
|
267 |
-
'500',
|
268 |
-
'',
|
269 |
-
'float'
|
270 |
-
);
|
271 |
|
272 |
// Portrait only
|
273 |
echo
|
@@ -288,7 +251,7 @@ class SlideshowWidget extends WP_Widget {
|
|
288 |
'bottom',
|
289 |
'fit',
|
290 |
);
|
291 |
-
|
292 |
wppa_widget_selection( $this,
|
293 |
'valign',
|
294 |
$instance['valign'],
|
@@ -301,16 +264,13 @@ class SlideshowWidget extends WP_Widget {
|
|
301 |
);
|
302 |
|
303 |
|
304 |
-
|
305 |
-
'</div>';
|
306 |
|
307 |
-
echo
|
308 |
// Timeout
|
309 |
-
wppa_widget_number( $this, 'timeout', $instance['timeout'], __( 'Slideshow timeout in seconds', 'wp-photo-album-plus' ), '1', '60' )
|
310 |
|
311 |
// Linkurl
|
312 |
if ( wppa_opt( 'slideonly_widget_linktype' ) == 'widget' ) {
|
313 |
-
echo
|
314 |
wppa_widget_input( $this,
|
315 |
'linkurl',
|
316 |
$instance['linkurl'],
|
@@ -320,48 +280,47 @@ class SlideshowWidget extends WP_Widget {
|
|
320 |
}
|
321 |
|
322 |
// Additional boxes
|
323 |
-
|
324 |
__( 'Slideshow options to display', 'wp-photo-album-plus' ) .
|
325 |
-
'<div style="padding:6px;border:1px solid lightgray;margin-top:2px;margin-bottom:1em">'
|
326 |
|
327 |
// Name
|
328 |
-
wppa_widget_checkbox( $this, 'name', $instance['name'], __( 'Show name', 'wp-photo-album-plus' ) )
|
329 |
|
330 |
// Description
|
331 |
-
wppa_widget_checkbox( $this, 'desc', $instance['desc'], __( 'Show description', 'wp-photo-album-plus' ) )
|
332 |
|
333 |
// Filmstrip
|
334 |
-
wppa_widget_checkbox( $this, 'film', $instance['film'], __( 'Show filmstrip', 'wp-photo-album-plus' ) )
|
335 |
|
336 |
// Browsebar
|
337 |
-
wppa_widget_checkbox( $this, 'browse', $instance['browse'], __( 'Show browsebar', 'wp-photo-album-plus' ) )
|
338 |
|
339 |
// Numbar
|
340 |
-
wppa_widget_checkbox( $this, 'numbar', $instance['numbar'], __( 'Show number bar', 'wp-photo-album-plus' ) )
|
341 |
-
|
|
|
342 |
|
343 |
// qTranslate supported textfields
|
344 |
-
|
345 |
__( 'The following text fields support qTranslate', 'wp-photo-album-plus' ) .
|
346 |
-
'<div style="padding:6px;border:1px solid lightgray;margin-top:2px">'
|
347 |
|
348 |
// Link title
|
349 |
-
wppa_widget_input( $this, 'linktitle', $instance['linktitle'], __( 'Tooltip text', 'wp-photo-album-plus' ) )
|
350 |
|
351 |
// Supertext
|
352 |
-
wppa_widget_input( $this, 'supertext', $instance['supertext'], __( 'Text above photos', 'wp-photo-album-plus' ) )
|
353 |
|
354 |
// Sutext
|
355 |
-
wppa_widget_input( $this, 'subtext', $instance['subtext'], __( 'Text below photos', 'wp-photo-album-plus' ) )
|
356 |
|
357 |
-
'</div>';
|
358 |
|
359 |
// Loggedin only
|
360 |
-
echo
|
361 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
362 |
|
363 |
// Cache
|
364 |
-
echo
|
365 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
366 |
|
367 |
}
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display a slideshow in the sidebar
|
6 |
+
* Version 8.2.01.002
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
69 |
}
|
70 |
|
71 |
// Fill in runtime parameters to tune the slideshow
|
|
|
72 |
if ( $instance['linkurl'] && wppa_opt( 'slideonly_widget_linktype' ) == 'widget' ) {
|
73 |
wppa( 'in_widget_linkurl', $instance['linkurl'] );
|
74 |
wppa( 'in_widget_linktitle', __( $instance['linktitle'] ) );
|
115 |
else {
|
116 |
|
117 |
// Nothing left after stripping. quit
|
|
|
118 |
wppa( 'in_widget', false );
|
119 |
return;
|
120 |
}
|
140 |
}
|
141 |
$result .= $widget_content . $after_widget;
|
142 |
|
143 |
+
echo wppa_compress_html( $result );
|
144 |
+
wppa_echo( wppa_widget_timer( 'show', $widget_title ) );
|
145 |
|
146 |
// Cache?
|
147 |
if ( $cache ) {
|
149 |
wppa_save_cache_file( ['file' => $cachefile, 'data' => $result] );
|
150 |
}
|
151 |
|
|
|
|
|
|
|
152 |
wppa( 'in_widget', false );
|
153 |
}
|
154 |
|
178 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
179 |
|
180 |
// Title
|
|
|
181 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
182 |
|
183 |
// Album
|
190 |
'sort' => true,
|
191 |
) );
|
192 |
|
|
|
193 |
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
194 |
}
|
195 |
else {
|
|
|
196 |
wppa_widget_input( $this, 'album', $instance['album'], __( 'Album', 'wp-photo-album-plus' ) );
|
197 |
}
|
198 |
|
199 |
// Including sub albums?
|
200 |
+
wppa_widget_checkbox( $this, 'incsubs', $instance['incsubs'], __( 'Including subalbums', 'wp-photo-album-plus' ) );
|
|
|
|
|
|
|
|
|
|
|
201 |
|
202 |
// Max
|
203 |
$body =
|
211 |
'<option value="250" ' . ( $instance['maxslides'] == '250' ? 'selected' : '' ) . ' >250</option>' .
|
212 |
'<option value="350" ' . ( $instance['maxslides'] == '350' ? 'selected' : '' ) . ' >350</option>' .
|
213 |
'<option value="500" ' . ( $instance['maxslides'] == '500' ? 'selected' : '' ) . ' >500</option>';
|
|
|
214 |
wppa_widget_selection_frame( $this, 'maxslides', $body, __( 'Max slides', 'wp-photo-album-plus' ), false, __( 'High numbers may cause slow pageloads!', 'wp-photo-album-plus' ) );
|
215 |
|
216 |
// Random
|
217 |
+
wppa_widget_checkbox( $this, 'random', $instance['random'], __( 'Random sequence', 'wp-photo-album-plus' ) );
|
|
|
|
|
|
|
|
|
|
|
218 |
|
219 |
// Sizes and alignment
|
220 |
+
wppa_echo(
|
221 |
__( 'Sizes and alignment', 'wp-photo-album-plus' ) . ':' .
|
222 |
'<div style="padding:6px;border:1px solid lightgray;margin-top:2px">' .
|
223 |
__( 'Enter the width and optionally the height of the area wherein the slides will appear. If you specify a 0 for the height, it will be calculated. The value for the height will be ignored if you set the vertical alignment to \'fit\'.', 'wp-photo-album-plus' ) .
|
224 |
' ' .
|
225 |
__( 'Tick the portrait only checkbox if there are only portrait images in the album and you want the photos to fill the full width of the widget.', 'wp-photo-album-plus' ) .
|
226 |
' ' .
|
227 |
+
__ ( 'If portrait only is checked, the vertical alignment will be forced to \'fit\'.', 'wp-photo-album-plus' ) );
|
228 |
|
229 |
// Width
|
230 |
+
wppa_widget_number( $this, 'width', $instance['width'], __( 'Width in pixels', 'wp-photo-album-plus' ), '50', '500', '', 'float' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
231 |
|
232 |
// Height
|
233 |
+
wppa_widget_number( $this, 'height', $instance['height'], __( 'Height in pixels', 'wp-photo-album-plus' ), '0', '500', '', 'float' );
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
234 |
|
235 |
// Portrait only
|
236 |
echo
|
251 |
'bottom',
|
252 |
'fit',
|
253 |
);
|
254 |
+
|
255 |
wppa_widget_selection( $this,
|
256 |
'valign',
|
257 |
$instance['valign'],
|
264 |
);
|
265 |
|
266 |
|
267 |
+
wppa_echo( '</div>' );
|
|
|
268 |
|
|
|
269 |
// Timeout
|
270 |
+
wppa_widget_number( $this, 'timeout', $instance['timeout'], __( 'Slideshow timeout in seconds', 'wp-photo-album-plus' ), '1', '60' );
|
271 |
|
272 |
// Linkurl
|
273 |
if ( wppa_opt( 'slideonly_widget_linktype' ) == 'widget' ) {
|
|
|
274 |
wppa_widget_input( $this,
|
275 |
'linkurl',
|
276 |
$instance['linkurl'],
|
280 |
}
|
281 |
|
282 |
// Additional boxes
|
283 |
+
wppa_echo(
|
284 |
__( 'Slideshow options to display', 'wp-photo-album-plus' ) .
|
285 |
+
'<div style="padding:6px;border:1px solid lightgray;margin-top:2px;margin-bottom:1em">' );
|
286 |
|
287 |
// Name
|
288 |
+
wppa_widget_checkbox( $this, 'name', $instance['name'], __( 'Show name', 'wp-photo-album-plus' ) );
|
289 |
|
290 |
// Description
|
291 |
+
wppa_widget_checkbox( $this, 'desc', $instance['desc'], __( 'Show description', 'wp-photo-album-plus' ) );
|
292 |
|
293 |
// Filmstrip
|
294 |
+
wppa_widget_checkbox( $this, 'film', $instance['film'], __( 'Show filmstrip', 'wp-photo-album-plus' ) );
|
295 |
|
296 |
// Browsebar
|
297 |
+
wppa_widget_checkbox( $this, 'browse', $instance['browse'], __( 'Show browsebar', 'wp-photo-album-plus' ) );
|
298 |
|
299 |
// Numbar
|
300 |
+
wppa_widget_checkbox( $this, 'numbar', $instance['numbar'], __( 'Show number bar', 'wp-photo-album-plus' ) );
|
301 |
+
|
302 |
+
wppa_echo( '</div>' );
|
303 |
|
304 |
// qTranslate supported textfields
|
305 |
+
wppa_echo(
|
306 |
__( 'The following text fields support qTranslate', 'wp-photo-album-plus' ) .
|
307 |
+
'<div style="padding:6px;border:1px solid lightgray;margin-top:2px">' );
|
308 |
|
309 |
// Link title
|
310 |
+
wppa_widget_input( $this, 'linktitle', $instance['linktitle'], __( 'Tooltip text', 'wp-photo-album-plus' ) );
|
311 |
|
312 |
// Supertext
|
313 |
+
wppa_widget_input( $this, 'supertext', $instance['supertext'], __( 'Text above photos', 'wp-photo-album-plus' ) );
|
314 |
|
315 |
// Sutext
|
316 |
+
wppa_widget_input( $this, 'subtext', $instance['subtext'], __( 'Text below photos', 'wp-photo-album-plus' ) );
|
317 |
|
318 |
+
wppa_echo( '</div>' );
|
319 |
|
320 |
// Loggedin only
|
|
|
321 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
322 |
|
323 |
// Cache
|
|
|
324 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
325 |
|
326 |
}
|
wppa-stats-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the stats widget
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
class WppaStatsWidget extends WP_Widget {
|
@@ -157,11 +157,9 @@ class WppaStatsWidget extends WP_Widget {
|
|
157 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
158 |
|
159 |
// Title
|
160 |
-
echo
|
161 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
162 |
|
163 |
// Ip
|
164 |
-
echo
|
165 |
wppa_widget_checkbox( $this,
|
166 |
'ip',
|
167 |
$instance['ip'],
|
@@ -170,7 +168,6 @@ class WppaStatsWidget extends WP_Widget {
|
|
170 |
);
|
171 |
|
172 |
// Ip
|
173 |
-
echo
|
174 |
wppa_widget_checkbox( $this,
|
175 |
'browser',
|
176 |
$instance['browser'],
|
@@ -179,7 +176,6 @@ class WppaStatsWidget extends WP_Widget {
|
|
179 |
);
|
180 |
|
181 |
// Dayno
|
182 |
-
echo
|
183 |
wppa_widget_checkbox( $this,
|
184 |
'dayno',
|
185 |
$instance['dayno'],
|
@@ -187,7 +183,6 @@ class WppaStatsWidget extends WP_Widget {
|
|
187 |
);
|
188 |
|
189 |
// Active sessions
|
190 |
-
echo
|
191 |
wppa_widget_checkbox( $this,
|
192 |
'sessions-active',
|
193 |
$instance['sessions-active'],
|
@@ -195,35 +190,30 @@ class WppaStatsWidget extends WP_Widget {
|
|
195 |
);
|
196 |
|
197 |
// 24 hrs sessions
|
198 |
-
echo
|
199 |
wppa_widget_checkbox( $this,
|
200 |
'sessions-day',
|
201 |
$instance['sessions-day'],
|
202 |
__( 'Show 24hr sessions', 'wp-photo-album-plus' )
|
203 |
);
|
204 |
|
205 |
-
echo
|
206 |
wppa_widget_checkbox( $this,
|
207 |
'reg-users',
|
208 |
$instance['reg-users'],
|
209 |
__( 'Show number of registered users', 'wp-photo-album-plus' )
|
210 |
);
|
211 |
|
212 |
-
echo
|
213 |
wppa_widget_checkbox( $this,
|
214 |
'albums',
|
215 |
$instance['albums'],
|
216 |
__( 'Show number of albums', 'wp-photo-album-plus' )
|
217 |
);
|
218 |
|
219 |
-
echo
|
220 |
wppa_widget_checkbox( $this,
|
221 |
'mediaitems',
|
222 |
$instance['mediaitems'],
|
223 |
__( 'Show number of media items', 'wp-photo-album-plus' )
|
224 |
);
|
225 |
|
226 |
-
echo
|
227 |
wppa_widget_checkbox( $this,
|
228 |
'photos',
|
229 |
$instance['photos'],
|
@@ -231,7 +221,6 @@ class WppaStatsWidget extends WP_Widget {
|
|
231 |
);
|
232 |
|
233 |
if ( wppa_switch( 'enable_video' ) ) {
|
234 |
-
echo
|
235 |
wppa_widget_checkbox( $this,
|
236 |
'videos',
|
237 |
$instance['videos'],
|
@@ -240,7 +229,6 @@ class WppaStatsWidget extends WP_Widget {
|
|
240 |
}
|
241 |
|
242 |
if ( wppa_switch( 'enable_audio' ) ) {
|
243 |
-
echo
|
244 |
wppa_widget_checkbox( $this,
|
245 |
'audios',
|
246 |
$instance['videos'],
|
@@ -249,7 +237,6 @@ class WppaStatsWidget extends WP_Widget {
|
|
249 |
}
|
250 |
|
251 |
if ( wppa_switch( 'enable_pdf' ) ) {
|
252 |
-
echo
|
253 |
wppa_widget_checkbox( $this,
|
254 |
'pdfs',
|
255 |
$instance['pdfs'],
|
@@ -258,27 +245,22 @@ class WppaStatsWidget extends WP_Widget {
|
|
258 |
}
|
259 |
|
260 |
if ( wppa_switch( 'show_comments' ) ) {
|
261 |
-
echo
|
262 |
wppa_widget_checkbox( $this,
|
263 |
'comments',
|
264 |
$instance['comments'],
|
265 |
__( 'Show number of comments', 'wp-photo-album-plus' )
|
266 |
);
|
267 |
-
|
268 |
}
|
269 |
|
270 |
if ( wppa_switch( 'rating_on' ) ) {
|
271 |
-
echo
|
272 |
wppa_widget_checkbox( $this,
|
273 |
'rating',
|
274 |
$instance['rating'],
|
275 |
__( 'Show number of ratings', 'wp-photo-album-plus' )
|
276 |
);
|
277 |
-
|
278 |
}
|
279 |
|
280 |
// Loggedin only
|
281 |
-
echo
|
282 |
wppa_widget_checkbox( $this,
|
283 |
'logonly',
|
284 |
$instance['logonly'],
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the stats widget
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
class WppaStatsWidget extends WP_Widget {
|
157 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
158 |
|
159 |
// Title
|
|
|
160 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
161 |
|
162 |
// Ip
|
|
|
163 |
wppa_widget_checkbox( $this,
|
164 |
'ip',
|
165 |
$instance['ip'],
|
168 |
);
|
169 |
|
170 |
// Ip
|
|
|
171 |
wppa_widget_checkbox( $this,
|
172 |
'browser',
|
173 |
$instance['browser'],
|
176 |
);
|
177 |
|
178 |
// Dayno
|
|
|
179 |
wppa_widget_checkbox( $this,
|
180 |
'dayno',
|
181 |
$instance['dayno'],
|
183 |
);
|
184 |
|
185 |
// Active sessions
|
|
|
186 |
wppa_widget_checkbox( $this,
|
187 |
'sessions-active',
|
188 |
$instance['sessions-active'],
|
190 |
);
|
191 |
|
192 |
// 24 hrs sessions
|
|
|
193 |
wppa_widget_checkbox( $this,
|
194 |
'sessions-day',
|
195 |
$instance['sessions-day'],
|
196 |
__( 'Show 24hr sessions', 'wp-photo-album-plus' )
|
197 |
);
|
198 |
|
|
|
199 |
wppa_widget_checkbox( $this,
|
200 |
'reg-users',
|
201 |
$instance['reg-users'],
|
202 |
__( 'Show number of registered users', 'wp-photo-album-plus' )
|
203 |
);
|
204 |
|
|
|
205 |
wppa_widget_checkbox( $this,
|
206 |
'albums',
|
207 |
$instance['albums'],
|
208 |
__( 'Show number of albums', 'wp-photo-album-plus' )
|
209 |
);
|
210 |
|
|
|
211 |
wppa_widget_checkbox( $this,
|
212 |
'mediaitems',
|
213 |
$instance['mediaitems'],
|
214 |
__( 'Show number of media items', 'wp-photo-album-plus' )
|
215 |
);
|
216 |
|
|
|
217 |
wppa_widget_checkbox( $this,
|
218 |
'photos',
|
219 |
$instance['photos'],
|
221 |
);
|
222 |
|
223 |
if ( wppa_switch( 'enable_video' ) ) {
|
|
|
224 |
wppa_widget_checkbox( $this,
|
225 |
'videos',
|
226 |
$instance['videos'],
|
229 |
}
|
230 |
|
231 |
if ( wppa_switch( 'enable_audio' ) ) {
|
|
|
232 |
wppa_widget_checkbox( $this,
|
233 |
'audios',
|
234 |
$instance['videos'],
|
237 |
}
|
238 |
|
239 |
if ( wppa_switch( 'enable_pdf' ) ) {
|
|
|
240 |
wppa_widget_checkbox( $this,
|
241 |
'pdfs',
|
242 |
$instance['pdfs'],
|
245 |
}
|
246 |
|
247 |
if ( wppa_switch( 'show_comments' ) ) {
|
|
|
248 |
wppa_widget_checkbox( $this,
|
249 |
'comments',
|
250 |
$instance['comments'],
|
251 |
__( 'Show number of comments', 'wp-photo-album-plus' )
|
252 |
);
|
|
|
253 |
}
|
254 |
|
255 |
if ( wppa_switch( 'rating_on' ) ) {
|
|
|
256 |
wppa_widget_checkbox( $this,
|
257 |
'rating',
|
258 |
$instance['rating'],
|
259 |
__( 'Show number of ratings', 'wp-photo-album-plus' )
|
260 |
);
|
|
|
261 |
}
|
262 |
|
263 |
// Loggedin only
|
|
|
264 |
wppa_widget_checkbox( $this,
|
265 |
'logonly',
|
266 |
$instance['logonly'],
|
wppa-stereo-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the top rated photos
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
class wppaStereoWidget extends WP_Widget {
|
@@ -70,11 +70,9 @@ class wppaStereoWidget extends WP_Widget {
|
|
70 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
71 |
|
72 |
// Title
|
73 |
-
echo
|
74 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
75 |
|
76 |
// Loggedin only
|
77 |
-
echo
|
78 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
79 |
}
|
80 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the top rated photos
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
class wppaStereoWidget extends WP_Widget {
|
70 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
71 |
|
72 |
// Title
|
|
|
73 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
74 |
|
75 |
// Loggedin only
|
|
|
76 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
77 |
}
|
78 |
|
wppa-super-view-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* ask the album / display you want
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
|
@@ -91,16 +91,13 @@ class WppaSuperView extends WP_Widget {
|
|
91 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
92 |
|
93 |
// Title
|
94 |
-
echo
|
95 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
96 |
|
97 |
// Root
|
98 |
$body = wppa_album_select_a( array( 'selected' => $instance['root'], 'addall' => true, 'addseparate' => true, 'addgeneric' => true, 'path' => true ) );
|
99 |
-
echo
|
100 |
wppa_widget_selection_frame( $this, 'root', $body, __( 'Enable (sub)albums of', 'wp-photo-album-plus' ) );
|
101 |
|
102 |
// Sort
|
103 |
-
echo
|
104 |
wppa_widget_checkbox( $this,
|
105 |
'sort',
|
106 |
$instance['sort'],
|
@@ -109,11 +106,9 @@ class WppaSuperView extends WP_Widget {
|
|
109 |
);
|
110 |
|
111 |
// Loggedin only
|
112 |
-
echo
|
113 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
114 |
|
115 |
// Cache
|
116 |
-
echo
|
117 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
118 |
|
119 |
}
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* ask the album / display you want
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
|
91 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
92 |
|
93 |
// Title
|
|
|
94 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
95 |
|
96 |
// Root
|
97 |
$body = wppa_album_select_a( array( 'selected' => $instance['root'], 'addall' => true, 'addseparate' => true, 'addgeneric' => true, 'path' => true ) );
|
|
|
98 |
wppa_widget_selection_frame( $this, 'root', $body, __( 'Enable (sub)albums of', 'wp-photo-album-plus' ) );
|
99 |
|
100 |
// Sort
|
|
|
101 |
wppa_widget_checkbox( $this,
|
102 |
'sort',
|
103 |
$instance['sort'],
|
106 |
);
|
107 |
|
108 |
// Loggedin only
|
|
|
109 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
110 |
|
111 |
// Cache
|
|
|
112 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
113 |
|
114 |
}
|
wppa-tagcloud-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the tagcloud widget
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -100,7 +100,6 @@ class TagcloudPhotos extends WP_Widget {
|
|
100 |
if ( ! $stags ) $stags = array();
|
101 |
|
102 |
// Title
|
103 |
-
echo
|
104 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
105 |
|
106 |
// Tags selection
|
@@ -111,7 +110,6 @@ class TagcloudPhotos extends WP_Widget {
|
|
111 |
if ( in_array( $tag, $stags ) ) $sel = ' selected'; else $sel = '';
|
112 |
$body .= '<option value="' . esc_attr( $tag ) . '"' . $sel . ' >' . htmlspecialchars( $tag ) . '</option>';
|
113 |
}
|
114 |
-
echo
|
115 |
wppa_widget_selection_frame( $this, 'tags', $body, __( 'Select multiple tags or --- all ---', 'wp-photo-album-plus' ), 'multi' );
|
116 |
|
117 |
// Show current selection
|
@@ -121,14 +119,12 @@ class TagcloudPhotos extends WP_Widget {
|
|
121 |
else {
|
122 |
$s = __( '--- all ---', 'wp-photo-album-plus' );
|
123 |
}
|
124 |
-
|
125 |
|
126 |
// Loggedin only
|
127 |
-
echo
|
128 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
129 |
|
130 |
// Cache
|
131 |
-
echo
|
132 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
133 |
}
|
134 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the tagcloud widget
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
100 |
if ( ! $stags ) $stags = array();
|
101 |
|
102 |
// Title
|
|
|
103 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
104 |
|
105 |
// Tags selection
|
110 |
if ( in_array( $tag, $stags ) ) $sel = ' selected'; else $sel = '';
|
111 |
$body .= '<option value="' . esc_attr( $tag ) . '"' . $sel . ' >' . htmlspecialchars( $tag ) . '</option>';
|
112 |
}
|
|
|
113 |
wppa_widget_selection_frame( $this, 'tags', $body, __( 'Select multiple tags or --- all ---', 'wp-photo-album-plus' ), 'multi' );
|
114 |
|
115 |
// Show current selection
|
119 |
else {
|
120 |
$s = __( '--- all ---', 'wp-photo-album-plus' );
|
121 |
}
|
122 |
+
wppa_echo( '<p style="word-break:break-all">' . esc_html__( 'Currently selected tags', 'wp-photo-album-plus' ) . ': <br><b>' . $s . '</b></p>' );
|
123 |
|
124 |
// Loggedin only
|
|
|
125 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
126 |
|
127 |
// Cache
|
|
|
128 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
129 |
}
|
130 |
|
wppa-thumbnail-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display thumbnail photos
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
class ThumbnailWidget extends WP_Widget {
|
@@ -188,18 +188,16 @@ class ThumbnailWidget extends WP_Widget {
|
|
188 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
189 |
|
190 |
// Title
|
191 |
-
|
192 |
-
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) ) .
|
193 |
|
194 |
// Link from the widget title
|
195 |
-
wppa_widget_input( $this, 'link', $instance['link'], __( 'Link from the title', 'wp-photo-album-plus' ) )
|
196 |
|
197 |
// Tooltip on the link from the title
|
198 |
wppa_widget_input( $this, 'linktitle', $instance['linktitle'], __( 'Link Title ( tooltip )', 'wp-photo-album-plus' ) );
|
199 |
|
200 |
// Album
|
201 |
$body = wppa_album_select_a( array( 'selected' => $instance['album'], 'addseparate' => true, 'addall' => true, 'path' => true ) );
|
202 |
-
echo
|
203 |
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
204 |
|
205 |
// Sort by
|
@@ -219,11 +217,10 @@ class ThumbnailWidget extends WP_Widget {
|
|
219 |
'ORDER BY rating_count DESC',
|
220 |
'ORDER BY timestamp DESC',
|
221 |
);
|
222 |
-
|
223 |
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values );
|
224 |
|
225 |
// Max number
|
226 |
-
echo
|
227 |
wppa_widget_number( $this, 'limit', $instance['limit'], __( 'Max number', 'wp-photo-album-plus' ), '1', '100' );
|
228 |
|
229 |
// Display type
|
@@ -233,26 +230,24 @@ class ThumbnailWidget extends WP_Widget {
|
|
233 |
$values = array( 'thumbs',
|
234 |
'names',
|
235 |
);
|
236 |
-
|
237 |
wppa_widget_selection( $this, 'display', $instance['display'], __( 'Display', 'wp-photo-album-plus' ), $options, $values );
|
238 |
|
239 |
// Names under thumbs
|
240 |
-
echo
|
241 |
wppa_widget_checkbox( $this, 'name', $instance['name'], __( 'Show photo names under thumbnails', 'wp-photo-album-plus' ) );
|
242 |
|
243 |
// Loggedin only
|
244 |
-
echo
|
245 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
246 |
|
247 |
// Cache
|
248 |
-
echo
|
249 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
250 |
|
251 |
-
|
252 |
-
|
253 |
-
|
254 |
-
' ' .
|
255 |
'</p>';
|
|
|
256 |
|
257 |
}
|
258 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display thumbnail photos
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
class ThumbnailWidget extends WP_Widget {
|
188 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
189 |
|
190 |
// Title
|
191 |
+
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
|
|
192 |
|
193 |
// Link from the widget title
|
194 |
+
wppa_widget_input( $this, 'link', $instance['link'], __( 'Link from the title', 'wp-photo-album-plus' ) );
|
195 |
|
196 |
// Tooltip on the link from the title
|
197 |
wppa_widget_input( $this, 'linktitle', $instance['linktitle'], __( 'Link Title ( tooltip )', 'wp-photo-album-plus' ) );
|
198 |
|
199 |
// Album
|
200 |
$body = wppa_album_select_a( array( 'selected' => $instance['album'], 'addseparate' => true, 'addall' => true, 'path' => true ) );
|
|
|
201 |
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
202 |
|
203 |
// Sort by
|
217 |
'ORDER BY rating_count DESC',
|
218 |
'ORDER BY timestamp DESC',
|
219 |
);
|
220 |
+
|
221 |
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values );
|
222 |
|
223 |
// Max number
|
|
|
224 |
wppa_widget_number( $this, 'limit', $instance['limit'], __( 'Max number', 'wp-photo-album-plus' ), '1', '100' );
|
225 |
|
226 |
// Display type
|
230 |
$values = array( 'thumbs',
|
231 |
'names',
|
232 |
);
|
233 |
+
|
234 |
wppa_widget_selection( $this, 'display', $instance['display'], __( 'Display', 'wp-photo-album-plus' ), $options, $values );
|
235 |
|
236 |
// Names under thumbs
|
|
|
237 |
wppa_widget_checkbox( $this, 'name', $instance['name'], __( 'Show photo names under thumbnails', 'wp-photo-album-plus' ) );
|
238 |
|
239 |
// Loggedin only
|
|
|
240 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
241 |
|
242 |
// Cache
|
|
|
243 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
244 |
|
245 |
+
$result = '
|
246 |
+
<p>' .
|
247 |
+
__( 'You can set the sizes in this widget in the <b>Photo Albums -> Settings</b> admin page.', 'wp-photo-album-plus' ) .
|
248 |
+
' ' . __( 'Tab Widget I items 6 and 7', 'wp-photo-album-plus' ) .
|
249 |
'</p>';
|
250 |
+
wppa_echo( strip_tags( wp_check_invalid_utf8( $result), ["<br>", "<a>", "<i>", "<b>"] ) );
|
251 |
|
252 |
}
|
253 |
|
wppa-topten-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the top rated photos
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
class TopTenWidget extends WP_Widget {
|
@@ -559,7 +559,6 @@ class TopTenWidget extends WP_Widget {
|
|
559 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
560 |
|
561 |
// Title
|
562 |
-
echo
|
563 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
564 |
|
565 |
// Album
|
@@ -569,7 +568,7 @@ class TopTenWidget extends WP_Widget {
|
|
569 |
'path' => true,
|
570 |
'sort' => true,
|
571 |
) );
|
572 |
-
|
573 |
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
574 |
|
575 |
// Display type
|
@@ -579,7 +578,7 @@ class TopTenWidget extends WP_Widget {
|
|
579 |
$values = array( 'thumbs',
|
580 |
'names',
|
581 |
);
|
582 |
-
|
583 |
wppa_widget_selection( $this, 'display', $instance['display'], __( 'Display', 'wp-photo-album-plus' ), $options, $values );
|
584 |
|
585 |
// Sortby
|
@@ -593,56 +592,52 @@ class TopTenWidget extends WP_Widget {
|
|
593 |
'views',
|
594 |
'dlcount',
|
595 |
);
|
596 |
-
|
597 |
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values );
|
598 |
|
599 |
// Include sub albums
|
600 |
-
echo
|
601 |
wppa_widget_checkbox( $this, 'includesubs', $instance['includesubs'], __( 'Include sub albums', 'wp-photo-album-plus' ) );
|
602 |
|
603 |
// Medals only
|
604 |
-
echo
|
605 |
wppa_widget_checkbox( $this, 'medalsonly', $instance['medalsonly'], __( 'Only with medals', 'wp-photo-album-plus' ) );
|
606 |
|
607 |
// Subtitles
|
608 |
-
|
609 |
-
|
610 |
-
|
611 |
|
612 |
// Owner
|
613 |
-
wppa_widget_checkbox( $this, 'showowner', $instance['showowner'], __( 'Owner', 'wp-photo-album-plus' ) )
|
614 |
|
615 |
// Album
|
616 |
-
wppa_widget_checkbox( $this, 'showalbum', $instance['showalbum'], __( 'Album', 'wp-photo-album-plus' ) )
|
617 |
|
618 |
// Mean rating
|
619 |
-
wppa_widget_checkbox( $this, 'meanrat', $instance['meanrat'], __( 'Mean rating', 'wp-photo-album-plus' ) )
|
620 |
|
621 |
// Rating count
|
622 |
-
wppa_widget_checkbox( $this, 'ratcount', $instance['ratcount'], __( 'Rating count', 'wp-photo-album-plus' ) )
|
623 |
|
624 |
// View count
|
625 |
-
wppa_widget_checkbox( $this, 'viewcount', $instance['viewcount'], __( 'View count', 'wp-photo-album-plus' ) )
|
626 |
|
627 |
// Download count
|
628 |
wppa_widget_checkbox( $this, 'dlcount', $instance['dlcount'], __( 'Download count', 'wp-photo-album-plus' ) );
|
629 |
|
630 |
-
|
631 |
-
'</div>';
|
632 |
|
633 |
// Loggedin only
|
634 |
-
echo
|
635 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
636 |
|
637 |
// Cache
|
638 |
-
echo
|
639 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
640 |
|
641 |
-
|
642 |
'<p>' .
|
643 |
-
|
644 |
-
' ' .
|
645 |
'</p>';
|
|
|
646 |
|
647 |
}
|
648 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display the top rated photos
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
class TopTenWidget extends WP_Widget {
|
559 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
560 |
|
561 |
// Title
|
|
|
562 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
563 |
|
564 |
// Album
|
568 |
'path' => true,
|
569 |
'sort' => true,
|
570 |
) );
|
571 |
+
|
572 |
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
573 |
|
574 |
// Display type
|
578 |
$values = array( 'thumbs',
|
579 |
'names',
|
580 |
);
|
581 |
+
|
582 |
wppa_widget_selection( $this, 'display', $instance['display'], __( 'Display', 'wp-photo-album-plus' ), $options, $values );
|
583 |
|
584 |
// Sortby
|
592 |
'views',
|
593 |
'dlcount',
|
594 |
);
|
595 |
+
|
596 |
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values );
|
597 |
|
598 |
// Include sub albums
|
|
|
599 |
wppa_widget_checkbox( $this, 'includesubs', $instance['includesubs'], __( 'Include sub albums', 'wp-photo-album-plus' ) );
|
600 |
|
601 |
// Medals only
|
|
|
602 |
wppa_widget_checkbox( $this, 'medalsonly', $instance['medalsonly'], __( 'Only with medals', 'wp-photo-album-plus' ) );
|
603 |
|
604 |
// Subtitles
|
605 |
+
wppa_echo(
|
606 |
+
__( 'Subtitles', 'wp-photo-album-plus' ) . ':' .
|
607 |
+
'<div style="padding:6px;border:1px solid lightgray;margin-top:2px">' );
|
608 |
|
609 |
// Owner
|
610 |
+
wppa_widget_checkbox( $this, 'showowner', $instance['showowner'], __( 'Owner', 'wp-photo-album-plus' ) );
|
611 |
|
612 |
// Album
|
613 |
+
wppa_widget_checkbox( $this, 'showalbum', $instance['showalbum'], __( 'Album', 'wp-photo-album-plus' ) );
|
614 |
|
615 |
// Mean rating
|
616 |
+
wppa_widget_checkbox( $this, 'meanrat', $instance['meanrat'], __( 'Mean rating', 'wp-photo-album-plus' ) );
|
617 |
|
618 |
// Rating count
|
619 |
+
wppa_widget_checkbox( $this, 'ratcount', $instance['ratcount'], __( 'Rating count', 'wp-photo-album-plus' ) );
|
620 |
|
621 |
// View count
|
622 |
+
wppa_widget_checkbox( $this, 'viewcount', $instance['viewcount'], __( 'View count', 'wp-photo-album-plus' ) );
|
623 |
|
624 |
// Download count
|
625 |
wppa_widget_checkbox( $this, 'dlcount', $instance['dlcount'], __( 'Download count', 'wp-photo-album-plus' ) );
|
626 |
|
627 |
+
wppa_echo( '</div>' );
|
|
|
628 |
|
629 |
// Loggedin only
|
|
|
630 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
631 |
|
632 |
// Cache
|
|
|
633 |
wppa_widget_checkbox( $this, 'cache', $instance['cache'], __( 'Cache this widget', 'wp-photo-album-plus' ) );
|
634 |
|
635 |
+
$result =
|
636 |
'<p>' .
|
637 |
+
__( 'You can set the sizes in this widget in the <b>Photo Albums -> Settings</b> admin page.', 'wp-photo-album-plus' ) .
|
638 |
+
' ' . __( 'Tab Widget I Items 2 and 3', 'wp-photo-album-plus' ) .
|
639 |
'</p>';
|
640 |
+
wppa_echo( strip_tags( wp_check_invalid_utf8( $result), ["<br>", "<a>", "<i>", "<b>"] ) );
|
641 |
|
642 |
}
|
643 |
|
wppa-upldr-widget.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display a list of users linking to their photos
|
6 |
-
* Version 8.
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
@@ -204,7 +204,6 @@ class UpldrWidget extends WP_Widget {
|
|
204 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
205 |
|
206 |
// Title
|
207 |
-
echo
|
208 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
209 |
|
210 |
// Sortby
|
@@ -216,11 +215,10 @@ class UpldrWidget extends WP_Widget {
|
|
216 |
'count',
|
217 |
'date',
|
218 |
);
|
219 |
-
|
220 |
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values );
|
221 |
|
222 |
// Ignore these users
|
223 |
-
echo
|
224 |
wppa_widget_input( $this,
|
225 |
'ignore',
|
226 |
$instance['ignore'],
|
@@ -265,15 +263,12 @@ class UpldrWidget extends WP_Widget {
|
|
265 |
</p>
|
266 |
<?php
|
267 |
// Ownercount
|
268 |
-
echo
|
269 |
wppa_widget_checkbox( $this, 'showownercount', $instance['showownercount'], __( 'Show count of owners', 'wp-photo-album-plus' ) );
|
270 |
|
271 |
// Photocount
|
272 |
-
echo
|
273 |
wppa_widget_checkbox( $this, 'showphotocount', $instance['showphotocount'], __( 'Show count of photos', 'wp-photo-album-plus' ) );
|
274 |
|
275 |
// Loggedin only
|
276 |
-
echo
|
277 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
278 |
}
|
279 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* display a list of users linking to their photos
|
6 |
+
* Version 8.2.01.001
|
7 |
*/
|
8 |
|
9 |
if ( ! defined( 'ABSPATH' ) ) die( "Can't load this file directly" );
|
204 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
205 |
|
206 |
// Title
|
|
|
207 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
208 |
|
209 |
// Sortby
|
215 |
'count',
|
216 |
'date',
|
217 |
);
|
218 |
+
|
219 |
wppa_widget_selection( $this, 'sortby', $instance['sortby'], __( 'Sort by', 'wp-photo-album-plus' ), $options, $values );
|
220 |
|
221 |
// Ignore these users
|
|
|
222 |
wppa_widget_input( $this,
|
223 |
'ignore',
|
224 |
$instance['ignore'],
|
263 |
</p>
|
264 |
<?php
|
265 |
// Ownercount
|
|
|
266 |
wppa_widget_checkbox( $this, 'showownercount', $instance['showownercount'], __( 'Show count of owners', 'wp-photo-album-plus' ) );
|
267 |
|
268 |
// Photocount
|
|
|
269 |
wppa_widget_checkbox( $this, 'showphotocount', $instance['showphotocount'], __( 'Show count of photos', 'wp-photo-album-plus' ) );
|
270 |
|
271 |
// Loggedin only
|
|
|
272 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
273 |
}
|
274 |
|
wppa-upload-widget.php
CHANGED
@@ -4,7 +4,7 @@
|
|
4 |
*
|
5 |
* A wppa widget to upload photos
|
6 |
*
|
7 |
-
* Version 8.
|
8 |
*/
|
9 |
|
10 |
class WppaUploadWidget extends WP_Widget {
|
@@ -102,16 +102,13 @@ class WppaUploadWidget extends WP_Widget {
|
|
102 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
103 |
|
104 |
// Widget title
|
105 |
-
echo
|
106 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
107 |
|
108 |
// Album selection
|
109 |
$body = wppa_album_select_a( array( 'path' => true, 'selected' => $instance['album'], 'addselbox' => true ) );
|
110 |
-
echo
|
111 |
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
112 |
|
113 |
// Loggedin only
|
114 |
-
echo
|
115 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
116 |
}
|
117 |
|
4 |
*
|
5 |
* A wppa widget to upload photos
|
6 |
*
|
7 |
+
* Version 8.2.01.001
|
8 |
*/
|
9 |
|
10 |
class WppaUploadWidget extends WP_Widget {
|
102 |
$instance = wppa_parse_args( (array) $instance, $this->get_defaults() );
|
103 |
|
104 |
// Widget title
|
|
|
105 |
wppa_widget_input( $this, 'title', $instance['title'], __( 'Title', 'wp-photo-album-plus' ) );
|
106 |
|
107 |
// Album selection
|
108 |
$body = wppa_album_select_a( array( 'path' => true, 'selected' => $instance['album'], 'addselbox' => true ) );
|
|
|
109 |
wppa_widget_selection_frame( $this, 'album', $body, __( 'Album', 'wp-photo-album-plus' ) );
|
110 |
|
111 |
// Loggedin only
|
|
|
112 |
wppa_widget_checkbox( $this, 'logonly', $instance['logonly'], __( 'Show to logged in visitors only', 'wp-photo-album-plus' ) );
|
113 |
}
|
114 |
|
wppa-upload.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains all the upload pages and functions
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -72,15 +72,23 @@ global $upload_album;
|
|
72 |
wppa_upload_multiple();
|
73 |
if ( wppa_get( 'go-edit-multiple', false, 'bool' ) ) {
|
74 |
if ( current_user_can( 'wppa_admin' ) ) {
|
75 |
-
wppa_ok_message( __( 'Connecting to edit album...' , 'wp-photo-album-plus' ) );
|
76 |
-
|
77 |
-
|
78 |
-
|
79 |
-
|
|
|
|
|
|
|
|
|
80 |
elseif ( wppa_opt( 'upload_edit' ) != '-none-' ) {
|
81 |
-
wppa_ok_message( __( 'Connecting to edit photos...' , 'wp-photo-album-plus' ) );
|
82 |
-
|
83 |
-
|
|
|
|
|
|
|
|
|
84 |
}
|
85 |
}
|
86 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains all the upload pages and functions
|
6 |
+
* Version 8.2.01.001
|
7 |
*
|
8 |
*/
|
9 |
|
72 |
wppa_upload_multiple();
|
73 |
if ( wppa_get( 'go-edit-multiple', false, 'bool' ) ) {
|
74 |
if ( current_user_can( 'wppa_admin' ) ) {
|
75 |
+
wppa_ok_message( __( 'Connecting to edit album...' , 'wp-photo-album-plus' ) );
|
76 |
+
wppa_echo( '
|
77 |
+
<img
|
78 |
+
src="dummy"
|
79 |
+
style="display:none"
|
80 |
+
onerror="document.location=\'' . get_admin_url() .
|
81 |
+
'admin.php?page=wppa_admin_menu&tab=edit&edit-id=' . $upload_album .
|
82 |
+
'&wppa-nonce=' . wp_create_nonce( 'wppa-nonce', 'wppa-nonce' ) . '\'" >' );
|
83 |
+
}
|
84 |
elseif ( wppa_opt( 'upload_edit' ) != '-none-' ) {
|
85 |
+
wppa_ok_message( __( 'Connecting to edit photos...' , 'wp-photo-album-plus' ) );
|
86 |
+
wppa_echo( '
|
87 |
+
<img
|
88 |
+
src="dummy"
|
89 |
+
style="display:none"
|
90 |
+
onerror="document.location=\'' . get_admin_url().'admin.php?page=wppa_edit_photo\'" >' );
|
91 |
+
}
|
92 |
}
|
93 |
}
|
94 |
|
wppa-utils.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains low-level utility routines
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -5010,32 +5010,15 @@ global $wppa_defaults;
|
|
5010 |
// Compress html
|
5011 |
function wppa_compress_html( $txt, $keeplinebreaks = false ) {
|
5012 |
|
5013 |
-
|
5014 |
-
if ( $keeplinebreaks ) { // yes
|
5015 |
|
5016 |
-
|
5017 |
-
|
5018 |
-
|
5019 |
-
// Examine all chunks
|
5020 |
-
foreach( array_keys( $arr ) as $key ) {
|
5021 |
-
|
5022 |
-
// Does this chunk contain textarea content?
|
5023 |
-
if ( strpos( $arr[$key], '</textarea>' ) === false ) { // no
|
5024 |
-
$arr[$key] = str_replace( ["\r\n", "\n"], [" ", " "], $arr[$key] );
|
5025 |
-
}
|
5026 |
-
else { // yes. only remove linebreaks in the part after </textarea>
|
5027 |
-
$arr2 = explode( '</textarea>', $arr[$key] );
|
5028 |
-
$arr2[1] = str_replace( ["\r\n", "\n"], [" ", " "], $arr2[1] );
|
5029 |
-
|
5030 |
-
// Recombide chunk parts
|
5031 |
-
$arr[$key] = implode( '</textarea>', $arr2 );
|
5032 |
-
}
|
5033 |
-
}
|
5034 |
-
|
5035 |
-
// Recombine chunks
|
5036 |
-
$result = implode( '<textarea', $arr );
|
5037 |
}
|
5038 |
-
|
|
|
|
|
5039 |
$result = str_replace( ["\r\n", "\n"], [" ", " "], $txt );
|
5040 |
}
|
5041 |
|
@@ -5056,7 +5039,7 @@ function wppa_compress_html( $txt, $keeplinebreaks = false ) {
|
|
5056 |
$from = array( "> <", "<ul></ul>", "<!--", '" >', '; ', '&', 'style=" ', '"/>', ' style=""', 'px;;' );
|
5057 |
$to = array( "><", "", "\n<!--", '">', ';', '&', 'style="', '" />', ' ', 'px;' );
|
5058 |
|
5059 |
-
|
5060 |
return $result;
|
5061 |
}
|
5062 |
|
@@ -5154,6 +5137,10 @@ function wppa_lazy() {
|
|
5154 |
// Are we building a cache file?
|
5155 |
function wppa_is_caching() {
|
5156 |
|
|
|
|
|
|
|
|
|
5157 |
$temp = wppa_test_for_caching();
|
5158 |
$caching = $temp['caching'];
|
5159 |
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains low-level utility routines
|
6 |
+
* Version 8.2.01.002
|
7 |
*
|
8 |
*/
|
9 |
|
5010 |
// Compress html
|
5011 |
function wppa_compress_html( $txt, $keeplinebreaks = false ) {
|
5012 |
|
5013 |
+
$result = $txt;
|
|
|
5014 |
|
5015 |
+
// Keep linebreaks when a textarea tag is seen
|
5016 |
+
if ( strpos( $txt, '<textarea' ) !== false ) {
|
5017 |
+
$keeplinebreaks = true;
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
5018 |
}
|
5019 |
+
|
5020 |
+
// Remove linebreaks
|
5021 |
+
if ( ! $keeplinebreaks ) {
|
5022 |
$result = str_replace( ["\r\n", "\n"], [" ", " "], $txt );
|
5023 |
}
|
5024 |
|
5039 |
$from = array( "> <", "<ul></ul>", "<!--", '" >', '; ', '&', 'style=" ', '"/>', ' style=""', 'px;;' );
|
5040 |
$to = array( "><", "", "\n<!--", '">', ';', '&', 'style="', '" />', ' ', 'px;' );
|
5041 |
|
5042 |
+
$result = str_replace( $from, $to, $result );
|
5043 |
return $result;
|
5044 |
}
|
5045 |
|
5137 |
// Are we building a cache file?
|
5138 |
function wppa_is_caching() {
|
5139 |
|
5140 |
+
if ( wppa_in_widget() ) {
|
5141 |
+
return wppa( 'cache' );
|
5142 |
+
}
|
5143 |
+
|
5144 |
$temp = wppa_test_for_caching();
|
5145 |
$caching = $temp['caching'];
|
5146 |
|
wppa-widget-functions.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/* wppa-widget-functions.php
|
3 |
/* Package: wp-photo-album-plus
|
4 |
/*
|
5 |
-
/* Version 8.
|
6 |
/*
|
7 |
*/
|
8 |
|
@@ -359,25 +359,28 @@ static $potd;
|
|
359 |
// Get widget checkbox html
|
360 |
function wppa_widget_checkbox( $class, $item, $value, $label, $subtext = '', $disabled = false, $onchange = '' ) {
|
361 |
|
362 |
-
$result =
|
363 |
-
|
364 |
-
|
365 |
-
|
366 |
-
|
367 |
-
|
368 |
wppa_checked( $value ) .
|
369 |
( $disabled ? ' disabled' : '' ) .
|
370 |
( $onchange ? ' onchange="' . esc_attr( $onchange ) . '"' : '' ) .
|
371 |
-
' />
|
372 |
-
|
373 |
-
|
374 |
-
|
375 |
-
$label .
|
376 |
-
|
377 |
-
( $subtext
|
378 |
-
|
|
|
|
|
|
|
379 |
|
380 |
-
|
381 |
}
|
382 |
|
383 |
// Widget input html
|
@@ -401,11 +404,14 @@ function wppa_widget_input( $class, $item, $value, $label, $subtext = '' ) {
|
|
401 |
' name="' . $class->get_field_name( $item ) . '"' .
|
402 |
' type="text"' .
|
403 |
' value="' . esc_attr( $value ) . '"' .
|
404 |
-
'/>'
|
405 |
-
( $subtext
|
406 |
-
|
|
|
|
|
|
|
407 |
|
408 |
-
|
409 |
}
|
410 |
|
411 |
// Widget input text area
|
@@ -436,64 +442,69 @@ function wppa_widget_number( $class, $item, $value, $label, $min, $max, $subtext
|
|
436 |
|
437 |
$_50 = wppa_is_ie() ? '60px;': '60%';
|
438 |
|
439 |
-
$result =
|
440 |
-
|
441 |
-
|
442 |
-
|
443 |
-
|
444 |
-
|
445 |
-
|
446 |
-
|
447 |
-
|
448 |
-
|
449 |
-
|
450 |
-
|
451 |
-
|
452 |
-
|
453 |
-
|
454 |
-
|
455 |
-
|
456 |
-
|
457 |
-
|
458 |
-
|
|
|
|
|
|
|
|
|
|
|
459 |
|
460 |
-
|
461 |
}
|
462 |
|
463 |
// Widget selection box
|
464 |
function wppa_widget_selection( $class, $item, $value, $label, $options, $values, $disabled = array(), $cls = 'widefat', $subtext = '' ) {
|
465 |
|
466 |
-
$result =
|
467 |
-
|
468 |
-
|
469 |
-
|
470 |
-
|
471 |
-
|
472 |
-
'
|
473 |
-
|
474 |
-
|
475 |
-
|
476 |
-
|
477 |
-
' name="' . $class->get_field_name( $item ) . '"' .
|
478 |
-
' >';
|
479 |
|
480 |
foreach( array_keys( $options ) as $key ) {
|
481 |
-
$result .=
|
482 |
-
|
483 |
-
|
484 |
( $value == $values[$key] ? ' selected' : '' ) .
|
485 |
( isset( $disabled[$key] ) && $disabled[$key] ? ' disabled' : '' ) .
|
486 |
'>' .
|
487 |
-
__( $options[$key] ) .
|
488 |
-
|
489 |
}
|
490 |
|
491 |
-
$result .=
|
492 |
-
|
493 |
-
|
494 |
-
|
|
|
|
|
495 |
|
496 |
-
|
497 |
}
|
498 |
|
499 |
// Widget selection box frame
|
@@ -513,11 +524,14 @@ function wppa_widget_selection_frame( $class, $item, $body, $label, $multi = fal
|
|
513 |
( $multi ? ' multiple' : '' ) .
|
514 |
' >' .
|
515 |
$body .
|
516 |
-
'</select>'
|
517 |
-
( $subtext
|
518 |
-
|
|
|
|
|
|
|
519 |
|
520 |
-
|
521 |
}
|
522 |
|
523 |
// Get checked html
|
@@ -613,17 +627,20 @@ static $time;
|
|
613 |
|
614 |
// Cache this widget?
|
615 |
function wppa_cache_widget( $instance_cache ) {
|
|
|
616 |
|
617 |
if ( is_admin() ) return false;
|
618 |
|
619 |
switch( wppa_opt( 'cache_overrule' ) ) {
|
620 |
case 'always':
|
|
|
621 |
return true;
|
622 |
break;
|
623 |
case 'never':
|
624 |
return false;
|
625 |
break;
|
626 |
default:
|
|
|
627 |
return $instance_cache;
|
628 |
}
|
629 |
}
|
2 |
/* wppa-widget-functions.php
|
3 |
/* Package: wp-photo-album-plus
|
4 |
/*
|
5 |
+
/* Version 8.2.01.001
|
6 |
/*
|
7 |
*/
|
8 |
|
359 |
// Get widget checkbox html
|
360 |
function wppa_widget_checkbox( $class, $item, $value, $label, $subtext = '', $disabled = false, $onchange = '' ) {
|
361 |
|
362 |
+
$result = '
|
363 |
+
<p style="clear:both">
|
364 |
+
<input
|
365 |
+
id="' . $class->get_field_id( $item ) . '"
|
366 |
+
name="' . $class->get_field_name( $item ) . '"
|
367 |
+
type="checkbox"' .
|
368 |
wppa_checked( $value ) .
|
369 |
( $disabled ? ' disabled' : '' ) .
|
370 |
( $onchange ? ' onchange="' . esc_attr( $onchange ) . '"' : '' ) .
|
371 |
+
' />
|
372 |
+
<label
|
373 |
+
for="' . $class->get_field_id( $item ) . '"
|
374 |
+
>' .
|
375 |
+
$label . '
|
376 |
+
</label>';
|
377 |
+
if ( $subtext ) {
|
378 |
+
$result .= '<small>' . strip_tags( wp_check_invalid_utf8( $subtext ), ["<br>", "<a>", "<i>", "<b>"] ) . '</small>';
|
379 |
+
}
|
380 |
+
$result .= '
|
381 |
+
</p>';
|
382 |
|
383 |
+
wppa_echo( $result );
|
384 |
}
|
385 |
|
386 |
// Widget input html
|
404 |
' name="' . $class->get_field_name( $item ) . '"' .
|
405 |
' type="text"' .
|
406 |
' value="' . esc_attr( $value ) . '"' .
|
407 |
+
'/>';
|
408 |
+
if ( $subtext ) {
|
409 |
+
$result .= '<small>' . strip_tags( wp_check_invalid_utf8( $subtext ), ["<br>", "<a>", "<i>", "<b>"] ) . '</small>';
|
410 |
+
}
|
411 |
+
$result .= '
|
412 |
+
</p>';
|
413 |
|
414 |
+
wppa_echo( $result );
|
415 |
}
|
416 |
|
417 |
// Widget input text area
|
442 |
|
443 |
$_50 = wppa_is_ie() ? '60px;': '60%';
|
444 |
|
445 |
+
$result = '
|
446 |
+
<p' . ( $float ? ' style="width:50%;float:left"' : '' ) . '>
|
447 |
+
<label
|
448 |
+
for="' . $class->get_field_id( $item ) . '">' .
|
449 |
+
$label . ':
|
450 |
+
</label>
|
451 |
+
<br>
|
452 |
+
<input
|
453 |
+
id="' . $class->get_field_id( $item ) . '"
|
454 |
+
name="' . $class->get_field_name( $item ) . '"
|
455 |
+
style="' . ( $float ? 'width:' . $_50 . ';' : '' ) . '"
|
456 |
+
type="number"
|
457 |
+
min="' . $min . '"
|
458 |
+
max="' . $max . '"
|
459 |
+
value="' . esc_attr( $value ) . '"
|
460 |
+
onchange="' . esc_attr(
|
461 |
+
'if(jQuery(this).val()<' . $min . '||jQuery(this).val()>' . $max . '){
|
462 |
+
alert(\'' . esc_js( sprintf( __( 'Please enter a number >= %1s and <= %2s', 'wp-photo-album-plus' ),$min, $max ) ) . '\');
|
463 |
+
jQuery(this).val(\'' . $max . '\');return false;}').'"
|
464 |
+
/>';
|
465 |
+
if ( $subtext ) {
|
466 |
+
$result .= '<small>' . ( $cls ? '' : '<br>' ) . strip_tags( wp_check_invalid_utf8( $subtext ), ["<br>", "<a>", "<i>", "<b>"] ) . '</small>';
|
467 |
+
}
|
468 |
+
$result .= '
|
469 |
+
</p>';
|
470 |
|
471 |
+
wppa_echo( $result );
|
472 |
}
|
473 |
|
474 |
// Widget selection box
|
475 |
function wppa_widget_selection( $class, $item, $value, $label, $options, $values, $disabled = array(), $cls = 'widefat', $subtext = '' ) {
|
476 |
|
477 |
+
$result = '
|
478 |
+
<p>
|
479 |
+
<label
|
480 |
+
for="' . $class->get_field_id( $item ) . '">' .
|
481 |
+
$label . ':
|
482 |
+
</label>' .
|
483 |
+
( $cls ? '' : '<br>' ) . '
|
484 |
+
<select
|
485 |
+
class="' . $cls . '"
|
486 |
+
id="' . $class->get_field_id( $item ) . '"
|
487 |
+
name="' . $class->get_field_name( $item ) . '">';
|
|
|
|
|
488 |
|
489 |
foreach( array_keys( $options ) as $key ) {
|
490 |
+
$result .= '
|
491 |
+
<option
|
492 |
+
value="' . $values[$key] . '"' .
|
493 |
( $value == $values[$key] ? ' selected' : '' ) .
|
494 |
( isset( $disabled[$key] ) && $disabled[$key] ? ' disabled' : '' ) .
|
495 |
'>' .
|
496 |
+
__( $options[$key] ) . '
|
497 |
+
</option>';
|
498 |
}
|
499 |
|
500 |
+
$result .= '</select>';
|
501 |
+
if ( $subtext ) {
|
502 |
+
$result .= '<small>' . ( $cls ? '' : '<br>' ) . strip_tags( wp_check_invalid_utf8( $subtext ), ["<br>", "<a>", "<i>", "<b>"] ) . '</small>';
|
503 |
+
}
|
504 |
+
$result .= '
|
505 |
+
</p>';
|
506 |
|
507 |
+
wppa_echo( $result );
|
508 |
}
|
509 |
|
510 |
// Widget selection box frame
|
524 |
( $multi ? ' multiple' : '' ) .
|
525 |
' >' .
|
526 |
$body .
|
527 |
+
'</select>';
|
528 |
+
if ( $subtext ) {
|
529 |
+
$result .= '<small>' . strip_tags( wp_check_invalid_utf8( $subtext ), ["<br>", "<a>", "<i>", "<b>"] ) . '</small>';
|
530 |
+
}
|
531 |
+
$result .= '
|
532 |
+
</p>';
|
533 |
|
534 |
+
wppa_echo( $result );
|
535 |
}
|
536 |
|
537 |
// Get checked html
|
627 |
|
628 |
// Cache this widget?
|
629 |
function wppa_cache_widget( $instance_cache ) {
|
630 |
+
global $wppa;
|
631 |
|
632 |
if ( is_admin() ) return false;
|
633 |
|
634 |
switch( wppa_opt( 'cache_overrule' ) ) {
|
635 |
case 'always':
|
636 |
+
$wppa['cache'] = true;
|
637 |
return true;
|
638 |
break;
|
639 |
case 'never':
|
640 |
return false;
|
641 |
break;
|
642 |
default:
|
643 |
+
$wppa['cache'] = $instance_cache;
|
644 |
return $instance_cache;
|
645 |
}
|
646 |
}
|
wppa-wpdb-update.php
CHANGED
@@ -3,7 +3,7 @@
|
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains low-level wpdb routines that update records
|
6 |
-
* Version 8.
|
7 |
*
|
8 |
*/
|
9 |
|
@@ -45,8 +45,8 @@ global $wpdb;
|
|
45 |
$need_re_index = true;
|
46 |
break;
|
47 |
case 'description':
|
48 |
-
$itemvalue = balanceTags( $itemvalue, true );
|
49 |
-
$itemvalue = wppa_strip_tags( $itemvalue, 'script&style' );
|
50 |
$doit = true;
|
51 |
$need_re_index = true;
|
52 |
break;
|
@@ -213,8 +213,8 @@ global $wpdb;
|
|
213 |
$set_modified = true;
|
214 |
break;
|
215 |
case 'description':
|
216 |
-
$itemvalue = balanceTags( $itemvalue, true );
|
217 |
-
$itemvalue = wppa_strip_tags( $itemvalue, 'script&style' );
|
218 |
$doit = true;
|
219 |
$need_re_index = true;
|
220 |
$set_modified = true;
|
3 |
* Package: wp-photo-album-plus
|
4 |
*
|
5 |
* Contains low-level wpdb routines that update records
|
6 |
+
* Version 8.2.01.002
|
7 |
*
|
8 |
*/
|
9 |
|
45 |
$need_re_index = true;
|
46 |
break;
|
47 |
case 'description':
|
48 |
+
// $itemvalue = balanceTags( $itemvalue, true );
|
49 |
+
// $itemvalue = wppa_strip_tags( $itemvalue, 'script&style' );
|
50 |
$doit = true;
|
51 |
$need_re_index = true;
|
52 |
break;
|
213 |
$set_modified = true;
|
214 |
break;
|
215 |
case 'description':
|
216 |
+
// $itemvalue = balanceTags( $itemvalue, true );
|
217 |
+
// $itemvalue = wppa_strip_tags( $itemvalue, 'script&style' );
|
218 |
$doit = true;
|
219 |
$need_re_index = true;
|
220 |
$set_modified = true;
|
wppa-wrappers.php
CHANGED
@@ -5,7 +5,7 @@
|
|
5 |
* Contains wrappers for standard php functions
|
6 |
* For security and bug reasons
|
7 |
*
|
8 |
-
* Version 8.
|
9 |
*
|
10 |
*/
|
11 |
|
@@ -789,6 +789,7 @@ static $allowed_tags;
|
|
789 |
'placeholder' => true,
|
790 |
'srcset' => true,
|
791 |
'onload' => true,
|
|
|
792 |
) ),
|
793 |
'input' => array_merge( $sa, array(
|
794 |
'type' => true,
|
5 |
* Contains wrappers for standard php functions
|
6 |
* For security and bug reasons
|
7 |
*
|
8 |
+
* Version 8.2.01.002
|
9 |
*
|
10 |
*/
|
11 |
|
789 |
'placeholder' => true,
|
790 |
'srcset' => true,
|
791 |
'onload' => true,
|
792 |
+
'onerror' => true,
|
793 |
) ),
|
794 |
'input' => array_merge( $sa, array(
|
795 |
'type' => true,
|
wppa.php
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
/*
|
3 |
* Plugin Name: WP Photo Album Plus
|
4 |
* Description: Easily manage and display your photo albums and slideshows within your WordPress site.
|
5 |
-
* Version: 8.
|
6 |
* Author: J.N. Breetvelt a.k.a. OpaJaap
|
7 |
* Author URI: http://wppa.opajaap.nl/
|
8 |
* Plugin URI: http://wordpress.org/extend/plugins/wp-photo-album-plus/
|
@@ -24,7 +24,7 @@ global $wp_version;
|
|
24 |
|
25 |
/* WPPA GLOBALS */
|
26 |
global $wppa_api_version;
|
27 |
-
$wppa_api_version = '8.
|
28 |
global $wppa_revno;
|
29 |
$wppa_revno = str_replace( '.', '', $wppa_api_version ); // WPPA db version
|
30 |
|
2 |
/*
|
3 |
* Plugin Name: WP Photo Album Plus
|
4 |
* Description: Easily manage and display your photo albums and slideshows within your WordPress site.
|
5 |
+
* Version: 8.2.01.001
|
6 |
* Author: J.N. Breetvelt a.k.a. OpaJaap
|
7 |
* Author URI: http://wppa.opajaap.nl/
|
8 |
* Plugin URI: http://wordpress.org/extend/plugins/wp-photo-album-plus/
|
24 |
|
25 |
/* WPPA GLOBALS */
|
26 |
global $wppa_api_version;
|
27 |
+
$wppa_api_version = '8.2.01.001'; // WPPA software version
|
28 |
global $wppa_revno;
|
29 |
$wppa_revno = str_replace( '.', '', $wppa_api_version ); // WPPA db version
|
30 |
|