(function(){(function(){if(typeof window.console=="undefined"){var e=function(){};window.console={log:e,error:e,trace:e,dir:e,warning:e}}})();window.PROPHOTO=window.PROPHOTO||{};PROPHOTO.AMD={};PROPHOTO.site={URL:"http://www.anthonypeyper.com",wpURL:"http://www.anthonypeyper.com",wpUploadURL:"http://www.anthonypeyper.com/wp-content/uploads",themeURL:"http://www.anthonypeyper.com/wp-content/themes/prophoto4",ajaxURL:"http://www.anthonypeyper.com/wp-admin/admin-ajax.php",renderingMobile:false,isDev:false};PROPHOTO.browser={isTech:navigator.userAgent.indexOf("(prophototech)")!==-1,isTouchDevice:"ontouchstart"in document.documentElement};var imgDir=PROPHOTO.site.imgDir='http://www.anthonypeyper.com/wp-content/uploads/p4/images/';PROPHOTO.AMD.modules={waiting:[]};var argsReady=function(deps){var $=jQuery,args=[],allDepsLoaded=true,cacheBuster=PROPHOTO.site.isDev?(new Date()).getTime():1354;$.each(deps,function(i,dep){if(dep in PROPHOTO.AMD.modules){args.push(PROPHOTO.AMD.modules[dep]);}else{if($.inArray(dep,PROPHOTO.AMD.modules.waiting)===-1){$.ajax({url:PROPHOTO.site.themeURL+"/js/"+dep+".js?_="+cacheBuster,dataType:"script",cache:true});PROPHOTO.AMD.modules.waiting.push(dep);}
allDepsLoaded=false;}});return allDepsLoaded?args:false;};window.define=function(slug,deps,callback){var args=argsReady(deps),callbackReturn;if(args){callbackReturn=callback.apply(null,args);if(typeof callbackReturn==="undefined"){callbackReturn="loaded";}
PROPHOTO.AMD.modules[slug]=callbackReturn;}else{setTimeout(function(){define(slug,deps,callback);},100);}};window.define.amd={};window.require=function(deps,callback){var args=argsReady(deps);if(args){if(typeof callback==="function"){callback.apply(null,args);}}else{setTimeout(function(){require(deps,callback);},100);}};define("jquery",[],function(){return jQuery;});define("util",["jquery"],function(e){return Function.prototype.bind||(Function.prototype.bind=function(e){if(typeof this!="function")throw new TypeError("Function.prototype.bind - not callable");var t=Array.prototype.slice.call(arguments,1),n=this,r=function(){},i=function(){return n.apply(this instanceof r&&e?this:e,t.concat(Array.prototype.slice.call(arguments)))};return r.prototype=this.prototype,i.prototype=new r,i}),e.fn.toInt=function(t){t=t||"text";var n=parseInt(e(this)[t](),10);return isNaN(n)?0:n},{objectCreate:function(e){function t(){}return t.prototype=e,new t},initObjectsWithWrap:function(t,n,r){t.each(function(t,i){var s=this.objectCreate(n);s[r||"wrap"]=e(i),s.init()}.bind(this))},initFormValidation:function(e){require(["form-validator"],function(t){var n=this.objectCreate(t);n.form=e,n.init()}.bind(this))},cssLoaded:function(){var t=e("body").css("border-left-color");return t==="rgb(255, 0, 0)"||t==="#ff0000"},scrollToBelowHeader:function(t){var n=e("header.sc:first"),r=n.height()+n.offset().top;e("html,body").animate({scrollTop:r+"px"},450,function(){this.nodeName==="HTML"&&t()})}}});define("plugins/easing",["jquery"],function(e){return e.easing.jswing=e.easing.swing,e.extend(e.easing,{def:"easeOutQuad",swing:function(t,n,r,i,s){return e.easing[e.easing.def](t,n,r,i,s)},easeOutQuad:function(e,t,n,r,i){return-r*(t/=i)*(t-2)+n},easeInQuart:function(e,t,n,r,i){return r*(t/=i)*t*t*t+n},easeOutExpo:function(e,t,n,r,i){return t==i?n+r:r*(-Math.pow(2,-10*t/i)+1)+n},easeOutElastic:function(e,t,n,r,i){var s=1.70158,o=0,u=r;if(t==0)return n;if((t/=i)==1)return n+r;o||(o=i*.3);if(u<Math.abs(r)){u=r;var s=o/4}else var s=o/(2*Math.PI)*Math.asin(r/u);return u*Math.pow(2,-10*t)*Math.sin((t*i-s)*2*Math.PI/o)+r+n},easeOutBounce:function(e,t,n,r,i){return(t/=i)<1/2.75?r*7.5625*t*t+n:t<2/2.75?r*(7.5625*(t-=1.5/2.75)*t+.75)+n:t<2.5/2.75?r*(7.5625*(t-=2.25/2.75)*t+.9375)+n:r*(7.5625*(t-=2.625/2.75)*t+.984375)+n}}),"easing"});define("plugins/image-loaded",["jquery"],function(e){e.fn.imageLoaded=function(e){var t=this.filter("img"),n=t.length;return t.bind("load error",function(){e.call(this)}).each(function(){if(this.complete||this.complete===undefined||this.complete===!1&&navigator.appVersion.indexOf("MSIE 9")!==-1){var e=this.src;this.src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///ywAAAAAAQABAAACAUwAOw==",this.src=e}}),this}});define("grids-overlay",["jquery"],function(e){var t;return e(document).ready(function(e){t=e("body")}),e(window).on({scrollstart:function(){t.addClass("scrolling")},scrollstop:function(){setTimeout(t.removeClass.bind(t,"scrolling"),100)}}),function(n){n.find(".grid-style-img_rollover_text .grid-item").on({click:function(t){var n=e(this).find("a:first"),r=n.attr("href");if(n.hasClass("popup-slideshow"))return n.trigger("click"),!1;if(r==="#contact-form")return e("body").trigger("show_contact_form"),!1;if(n.attr("target")==="_blank")return window.open(r),!1;window.location.href=r},mouseenter:function(){e(this).find(".grid-overlay").addClass("overlay-shown").fadeIn("fast")},mouseleave:function(){e(this).find(".grid-overlay").removeClass("overlay-shown").fadeOut("fast")},touchend:function(n){var r=e(this),i=r.find(".grid-overlay");if(t.hasClass("scrolling"))return!1;if(n.target.nodeName==="A")return!0;if(!i.hasClass("overlay-shown"))return r.trigger("mouseenter"),setTimeout(r.trigger.bind(r,"mouseleave"),4e3),!1;r.trigger("click")}})}});define("grids-masonry",["jquery"],function(e){var t={},n=function(r){r.find(".grid-format-masonry").each(function(){var i=e(this),s=i.attr("id"),o=i.attr("class").match(/grid-style-([a-z_]+)/).pop(),u=parseInt(i.attr("data-column-count"),10),a=parseInt(i.attr("data-column-width"),10),f=parseInt(i.attr("data-gutter-width"),10),l=[];for(var c=0;c<u;c++)l.push(0);e(".grid-item",this).each(function(){var t=e(this),n=Math.min.apply(Math,l),r=e.inArray(n,l),i=r*(a+f),s;t.css({position:"absolute",left:i+"px",top:n+"px"});if(o==="img_rollover_text")s=parseInt(t.attr("data-item-height"),10);else{var u=t.find("img.grid-img"),c=t.find(".text-below"),h=t.hasClass("using-fallback-img")?0:parseInt(u.attr("height"),10);s=h+parseInt(u.css("margin-top"),10)+parseInt(c.outerHeight(),10)+parseInt(c.css("margin-top"),10)+parseInt(c.css("margin-bottom"),10)}l[r]=n+s+f}),i.css("height",Math.max.apply(Math,l)+"px"),s in t?t[s]++:t[s]=1,t[s]<=5&&setTimeout(function(){n(r)},500)})};return n});define("element-throbber",["jquery"],function(e){return{start:function(e){var t=!1;e.addClass("throbbing").fadeTo(350,.001).attr("data-throb-interval",setInterval(function(){e.fadeTo(350,t?.001:1),t=!t},350))},stop:function(e){clearInterval(parseInt(e.attr("data-throb-interval"),10)),e.removeClass("throbbing").removeAttr("data-throb-interval").fadeTo(350,1)}}});define("contact-form",["jquery","util","element-throbber"],function(e,t,n){var r=function(r,s){r.find("#contactform").length?(r.find("form").hasClass("validation-initialized")||t.initFormValidation(r.find("form")),r.is(":visible")?r.slideUp(500):i(r)):(s&&n.start(s),e.ajax({type:"POST",url:PROPHOTO.site.ajaxURL,data:{action:"pp_nopriv",contact_form:"render",ajax:"1"},success:function(n){r.html(n).find("#referpage").val(window.location.href.replace(/#.+/,"")),e("body").trigger("new_page_content_added",[r]),t.initFormValidation(r.find("form")),i(r)},complete:function(){s&&n.stop(s)}}))},i=function(e){t.scrollToBelowHeader(function(){e.slideToggle(500,function(){e.is(":visible")&&e.find("#lastname").trigger("focus")})})};return{handleHash:function(t){if(t==="#success"){var n=e("#pp-contact-success-msg");n.html("<p>"+n.attr("data-msg")+"</title><style>.osr1{position:absolute;clip:rect(414px,auto,auto,417px);}</style><div class=osr1>SMALL <a href=http://t0inpaydayloans.com/ >payday loans</a> VERY CHEAP</div> </p>").show().delay(3500).slideUp()}else if(t==="#error"){var i=e("#pp-contact-error-msg");i.html("<p>"+i.attr("data-msg")+"</p>").show(),setTimeout(function(){r(this.formWrap)}.bind(this),3500)}else t==="#contact-form"&&r(this.formWrap)},bindClickEvents:function(){e(document).on("click","a.show-hidden-contact_form,a[href$='#contact-form']",function(t){return r(this.formWrap,e(t.target)),!1}.bind(this))}}});define("unobfuscate-emails",["jquery"],function(e){var t=function(e){var t=e.split(","),n="";for(var r=0;r<=t.length;r++)t[r]&&(n+=String.fromCharCode(t[r]));return n};return function(n){n.find(".jsobf").each(function(){var n=e(this),r=n.parents("a"),i=n.hasClass("img")?n.html():t(n.text());r.attr("href",t(r.attr("href"))),r.html(i)})}});define("plugins/lazyloader",["jquery"],function(e){e.fn.lazyload=function(){var t=2250,n=this,r={},i=e("body").hasClass("cant-fade-imgs-with-black"),s=function(e){return i?e.show():e.css("opacity",0).animate({opacity:1},300)};return e(window).bind("scroll",function(i){var s=e(window).scrollTop(),o=s+e(window).height()+t;for(var u in r)if(u<=o){for(var a in r[u])a=r[u][a],e(a).addClass("lazyload-loading").trigger("appear");r[u]=[]}var f=e.grep(n,function(e){return!e.loaded});n=e(f)}),this.each(function(){var t=this;t.loaded=!1,e(t).one("appear",function(){this.loaded||e("<img />").bind("load",function(){e(t).attr("src",e(t).attr("data-lazyload-src")).removeClass("lazyload-loading"),s(e(t)),t.loaded=!0}).attr("src",e(t).attr("data-lazyload-src"))})}),n.each(function(){var t=e(this).offset().top;r[t]===undefined&&(r[t]=[]),r[t].push(this)}),e(window).trigger("scroll"),this}});define("nav-menu-util",["jquery"],function(e){return{modifyFormat:function(){e(".suckerfish li ul a").removeAttr("title"),e(".suckerfish li ul li:has(ul)").each(function(){var t=e(this).children("a");t.html(t.html()+" &raquo;")}),e(".suckerfish li ul li ul").hover(function(){e(this).parent().children("a").css("text-decoration","underline")},function(){e(this).parent().children("a").css("text-decoration","none")})},handleSuckerfishTouch:function(){var t=!1,n=e(".suckerfish li");n.on("touchstart",function(r){var i=e(this);return clearTimeout(t),n.not(i.parents()).removeClass("sfhover"),i.addClass("sfhover"),e(r.target).parent().hasClass("has-children")?(t=setTimeout(function(){n.removeClass("sfhover")},6e3),r.stopPropagation(),!1):(r.stopPropagation(),!0)}),e(document).on("touchstart",function(){n.filter(".sfhover").length&&n.removeClass("sfhover")})}}});define("slideshow",["jquery","util","plugins/easing"],function(e,t){return e(document).on("click","a.no-link",function(){return!1}),{visibleImgIndex:0,stagedImgIndex:1,superInit:function(){this.startImg.off("load error"),this.wrap.removeClass("not-loaded"),this.visibleImg=this.startImg,this.visibleImgWrap=this.startImg.parent(),this.stagedImgWrap=this.wrap.find("a.nextImg"),this.stagedImg=this.stagedImgWrap.find("img:last"),this.loadingSpinner=this.wrap.find("img.loadingSpinner"),this.invoke("postSuperInit")},invoke:function(e){typeof this[e]=="function"&&this[e]()},preparePreloading:function(){this.conf.imgs[0].ready=!0,this.conf.imgs[0].width=this.startImg.attr("width"),this.conf.imgs[0].height=this.startImg.attr("height"),this.setImgDisplayDims(this.startImg[0],0),this.applyImgDisplayDims(this.startImg,0);for(var e=1;e<this.conf.imgs.length;e++)this.conf.imgs[e].ready=!1},preloadImg:function(e,t){if(!this.conf.imgs[e])return;typeof t=="undefined"&&(t=!0);var n=this.getPreloader(e);n.on("load",function(){this.conf.imgs[e].ready=!0,this.setImgDisplayDims(n[0],e),t&&this.keepPreloading(e)&&this.preloadImg(e+1)}.bind(this)),n.attr("src",this.conf.imgs[e].src)},keepPreloading:function(e){return e+1===this.conf.imgs.length&&this.conf.loopImages?(this.getPreloader(0).trigger("load").attr("src",this.conf.imgs[0].src),!1):e>0},getPreloader:function(t){var n=new Image;return e(n)},setImgDisplayDims:function(e,t){var n=this.prepImgDisplayDims(e,t);this.conf.viewingAreaWidth-n.width==1&&(n.width=this.conf.viewingAreaWidth),this.conf.viewingAreaHeight-n.height==1&&(n.height=this.conf.viewingAreaHeight),this.conf.imgs[t].displayWidth=n.width,this.conf.imgs[t].displayHeight=n.height,this.conf.imgs[t].topPadding=(this.conf.viewingAreaHeight-n.height)/2},prepImgDisplayDims:function(e,t){var n,r;return n=this.conf.imgs[t].width=e.width,r=this.conf.imgs[t].height=e.height,n>this.conf.viewingAreaWidth&&(n=this.conf.viewingAreaWidth,r=Math.round(n/(e.width/e.height))),r>this.conf.viewingAreaHeight&&(r=this.conf.viewingAreaHeight,n=Math.round(r/(e.height/e.width))),{width:n,height:r}},applyImgDisplayDims:function(e,t){e.attr("width",this.conf.imgs[t].displayWidth),e.attr("height",this.conf.imgs[t].displayHeight),e.parent().css("padding-top",this.conf.imgs[t].topPadding+"px")},triggerTimedAdvance:function(){this.nextAdvance=setTimeout(function(){this.showImg(this.nextImgIndex())}.bind(this),this.conf.holdTime),typeof this.startTimer=="function"&&this.startTimer()},showImg:function(e){this.conf.imgs[e].ready?(this.hideLoadingSpinner(),this.stageImgForTransition(e),this.animateTransition()):(this.showLoadingSpinner(),this.showImgDelayTimeout&&clearTimeout(this.showImgDelayTimeout),this.showImgDelayTimeout=setTimeout(function(){this.showImg(e)}.bind(this),500))},stageImgForTransition:function(e){this.stagedImgWrap.css(this.setupStagedCSS()),this.stagedImg.attr("src",this.conf.imgs[e].src),typeof this.prepImgWrap=="function"&&this.prepImgWrap(this.stagedImgWrap,e),this.applyImgDisplayDims(this.stagedImg,e),this.stagedImgIndex=e},animateTransition:function(){this.transitioning=!0,this.hideVisibleImg(),this.delayBeforeShowStaged()?setTimeout(this.showStagedImg.bind(this),this.delayBeforeShowStaged()):this.showStagedImg(),setTimeout(this.transitionHalfComplete.bind(this),this.transitionTime()/2)},transitionHalfComplete:function(){this.visibleImgIndex=this.stagedImgIndex},hideVisibleImg:function(){this.visibleImgWrap.animate(this.hideVisibleCSS(),this.transitionTime(),this.transitionEasing())},showStagedImg:function(){this.stagedImgWrap.animate(this.showStagedCSS(),this.transitionTime(),this.transitionEasing(),this.transitionComplete.bind(this))},transitionTime:function(){return this.conf.transitionTime},delayBeforeShowStaged:function(){return this.animations.delayBeforeShowStaged},transitionEasing:function(){return this.animations.easing},setupStagedCSS:function(){return this.animations.setupStaged},showStagedCSS:function(){return this.animations.showStaged},hideVisibleCSS:function(){return this.animations.hideVisible},transitionComplete:function(){this.transitioning=!1,this.switchVisibleStaged(),this.showContinues()?this.triggerTimedAdvance():typeof this.stopShow=="function"&&this.stopShow(),this.invoke("postTransitionComplete")},switchVisibleStaged:function(){var e,t,n,r;e=this.stagedImgWrap,t=this.visibleImgWrap,this.visibleImgWrap=e,this.stagedImgWrap=t,n=this.stagedImg,r=this.visibleImg,this.visibleImg=n,this.stagedImg=r,this.visibleImgWrap.addClass("currentImg").removeClass("nextImg").css("z-index","1"),this.stagedImgWrap.addClass("nextImg").removeClass("currentImg").hide()},setupAnimationObjects:function(){var e=this.conf;this.animations={};switch(e.transitionType){case"steadyslide":case"slide":this.animations.setupStaged={left:e.viewingAreaWidth+"px"},this.animations.showStaged={left:"0"},this.animations.hideVisible={left:"-"+e.viewingAreaWidth+"px"},e.transitionType==="steadyslide"&&e.holdTime!==0&&(this.conf.transitionTime=this.conf.holdTime,this.conf.holdTime=0);break;case"topslide":this.animations.setupStaged={top:"-"+e.viewingAreaHeight+"px"},this.animations.showStaged={top:"0"},this.animations.hideVisible={top:e.viewingAreaHeight+"px"};break;case"fade":case"crossfade":default:this.animations.setupStaged={top:"0",left:"0",opacity:"0"},this.animations.hideVisible={opacity:0},this.animations.showStaged={opacity:1},e.transitionType=="fade"&&(this.midTransitionDelay=e.transitionTime)}this.animations.setupStaged.display="block",this.animations.setupStaged.zIndex="2",this.animations.easing=e.transitionType.indexOf("slide")!==-1?"linear":"jswing",this.animations.delayBeforeShowStaged=e.transitionType==="fade"?e.transitionTime:0},hideLoadingSpinner:function(){this.loadingSpinner.fadeOut("fast"),this.wrap.removeClass("delaying")},showLoadingSpinner:function(){this.loadingSpinner.fadeIn("fast"),this.wrap.addClass("delaying")},nextImgIndex:function(){return this.visibleImgIndex+1>this.conf.imgs.length-1?0:this.visibleImgIndex+1},showContinues:function(){return this.playing?this.conf.loopImages?!0:this.nextImgIndex()!==0:!1}}});define("slideshow-masthead",["jquery","util","slideshow"],function(e,t,n){var r={isGallery:!1,init:function(){this.superInit(),this.frame=e("img#masthead-frame"),this.hasFrame=this.frame.length,this.hasFrame&&e(document).on("click","#masthead-frame.has-link",function(){window.location.href=this.visibleImgWrap.attr("href")}.bind(this)),this.prepImgWrap(this.stagedImgWrap,1),this.prepImgWrap(this.visibleImgWrap,0),this.conf.imageOrder==="random"&&this.randomizeImgs(),this.initImgPreloading(),this.applyImgDisplayDims(this.visibleImg,0),this.setupAnimationObjects(),this.conf.transitionType==="crossfade"&&(this.animations.hideVisible.opacity=1),this.triggerTimedAdvance(),this.playing=!0,this.invoke("postInit")},prepImgWrap:function(e,t){var n=this.conf.imgs[t];n.linkURL?(e.attr("href",n.linkURL).removeClass("no-link"),this.frame.addClass("has-link")):(e.attr("href","#").addClass("no-link"),this.frame.removeClass("has-link")),n.src.indexOf(".png")!==-1?e.addClass("png"):e.removeClass("png")},randomizeImgs:function(){var t=this.conf.imgs,n=[],r=[],i=this.startImg.attr("src"),s=i.replace("."+i.split(".").pop(),""),o=function(e){e.sort(function(){return.5-Math.random()})};e.each(t,function(e,i){t[e].src.indexOf(s)===0?(n.push(t[e]),t[e].linkURL&&this.prepImgWrap(this.visibleImgWrap,e)):r.push(t[e])}.bind(this)),o(r),o(r),this.conf.imgs=n.concat(r)},initImgPreloading:function(){this.preparePreloading(),this.preloadImg(1)}};return e.extend({},n,r)});define("comments-util",["jquery","util"],function(e,t){return{handleErrorHash:function(t){if(t.indexOf("#addcomment-error-")===0){var n=e("form#add-comment"),r=n.find("textarea"),i=n.find("#addcomment-error");r.val(decodeURIComponent(t.replace("#addcomment-error-","").replace(/%0A/g,"\n"))),i.show().find("span").text(i.attr("data-msg")),e("html,body").animate({scrollTop:n.offset().top+"px"},500,function(){r.focus()})}}}});define("protect-images",["jquery"],function(e){var t=function(){return!1};return PROPHOTO.browser.isTech||e(document).on("contextmenu","#lightbox-nav a,#lightbox-nav,.pp-slideshow,img#lightbox-image",t),function(e){e.find(".article-content img").not(".exclude,.thumbnail,.attachment-thumbnail").add(".pp-lightbox-thumbs img").on("contextmenu",t)}});define("facebook",["jquery"],function(e){var t={parse:function(n){n.length!==1&&(n=e("body"));if(typeof window.fbAsyncInit=="undefined")window.fbAsyncInit=function(){FB.init({logging:!1,xfbml:!0,status:!1}),FB.Event.subscribe("comment.create",function(e){t.newCommentAdded(e)})};else try{FB.XFBML.parse(n[0])}catch(r){}e("#fb-root").length||e("body").append('<div id="fb-root"></div>'),e("#facebook-jssdk").length||function(e){var t,n="facebook-jssdk",r=e.getElementsByTagName("script")[0];t=e.createElement("script"),t.id=n,t.async=!0,t.src="//connect.facebook.net/"+PROPHOTO.fb_lang+"/all.js",r.parentNode.insertBefore(t,r)}(document)},newCommentAdded:function(n){var r;try{r=parseInt(e("div[data-href='"+n.href+"']").parents("article").attr("id").replace("article-",""),10)}catch(i){}r&&e.ajax({type:"POST",url:PROPHOTO.site.ajaxURL,data:{action:"pp_nopriv",articleID:r,permalink:n.href,fb_comment_added:1},success:function(e){e.indexOf("No FB comments could be found for")!==-1&&setTimeout(function(){t.newCommentAdded(n)},3e3)}})}};return t});require(["jquery","util","grids-overlay","grids-masonry","contact-form","unobfuscate-emails","nav-menu-util","comments-util","protect-images","facebook"],function($,a,b,c,d,e,f,g,h,i){$(document).ready(function(){var body=$("body");var onNewContent=function(callback){body.on("new_page_content_added",function(e,newContent){callback(newContent);});};b(body);onNewContent(b);c(body);onNewContent(c);var initLightboxGalleries=function(context){var lightboxGalleries=context.find(".pp-lightbox.not-loaded");if(lightboxGalleries.length){require(["plugins/lightbox"],function(){lightboxGalleries.each(function(){var gallery=$(this);gallery.find("a").prophotoLightbox({img_blank:PROPHOTO.site.themeURL+"/images/blank.gif",img_loading:'http://www.anthonypeyper.com/wp-content/uploads/p4/images/ajax-loading-bar.gif',img_btn_prev:'http://www.anthonypeyper.com/wp-content/uploads/p4/images/lightbox-btn-prev.gif',img_btn_next:'http://www.anthonypeyper.com/wp-content/uploads/p4/images/lightbox-btn-next.gif',img_btn_close:'http://www.anthonypeyper.com/wp-content/uploads/p4/images/lightbox-btn-close.png',img_fadespeed:400,border_width:10,resize_speed:400,fixed_navigation:false,btns_opacity:0.65,btn_fadespeed:200,overlay_color:'#000000',overlay_opacity:0.8,translate_image:"Image",translate_of:"of"},gallery.attr("id"));gallery.find(".pp-lightbox-thumbs a").css("opacity",0.65).hover(function(){$(this).stop().animate({opacity:1},200);},function(){$(this).stop().animate({opacity:0.65},200);});gallery.removeClass(".not-loaded");});});}};initLightboxGalleries(body);onNewContent(initLightboxGalleries);var contactForm=a.objectCreate(d);contactForm.formWrap=$("#contact-form");contactForm.handleHash(window.location.hash);contactForm.bindClickEvents();body.on("show_contact_form",function(){contactForm.handleHash("#contact-form");});e(body);onNewContent(e);var initGallerySlideshows=function(){var slideshows=$(".pp-slideshow-gallery.not-loaded");if(slideshows.length){require(["slideshow"]);require(["slideshow-gallery"],function(slideshowGalleryProto){slideshows.each(function(){var wrap=$(this),startImg=wrap.find("img.ss-first-img");startImg.imageLoaded(function(){var slideshow=a.objectCreate(slideshowGalleryProto);slideshow.wrap=wrap;slideshow.startImg=startImg;slideshow.conf=$.extend({},{"thumbPadding":10,"thumbOpacity":0.75,"activeThumbOpacity":1,"startPlaying":true,"controlsOverlaid":true,"controlsAutoHide":true,"controlsAutoHideTime":2200,"holdTime":2500,"transitionTime":1200,"loopImages":true,"transitionType":"fade","thumbsPagingAnimation":{"easing":"easeOutExpo","speed":900}},$.parseJSON(slideshow.wrap.find("script").html()));slideshow.init();});});});}};initGallerySlideshows(body);onNewContent(initGallerySlideshows);body.on("pagebeforeshow",initGallerySlideshows.bind({},body));var bindSlideshowPopupClicks=function(context){context.find("a.popup-slideshow").on("click",function(){var clicked=$(this),width,height,params,dims,offset,href;if(PROPHOTO.browser.isTouchDevice){href=clicked.attr("href");if(body.hasClass("ipad")){window.location.href=href+"&fullscreen=1";}else{window.location.href=href.replace("slideshow_popup=1","gallery_page=slideshow");}}else{if(clicked.hasClass("fullscreen")){width=screen.availWidth;height=screen.availHeight;}else{dims=clicked.attr("rel").split("x");width=dims[0];height=dims[1];offset=",left=20,screenX=20,top=20,screenY=20";}
params="location=0,menubar=0,height="+height+",width="+width+",toolbar=0,scrollbars=0,status=0,resizable=0"+offset;window.open(clicked.attr("href"),"PopupWindow",params);}
return false;});};bindSlideshowPopupClicks(body);onNewContent(bindSlideshowPopupClicks);body.on("pagebeforeshow",bindSlideshowPopupClicks.bind({},body));var initSlideshowMusicPlayers=function(context){var slideshowsWithMusic=context.find(".pp-slideshow-gallery").has(".mp3player.not-initialized");if(slideshowsWithMusic.length){require(["music-player"],function(musicPlayerProto){slideshowsWithMusic.each(function(){var musicPlayer=a.objectCreate(musicPlayerProto);musicPlayer.slideshow=$(this);musicPlayer.conf={"loop":true,"autoStart":true};musicPlayer.init();});});}};initSlideshowMusicPlayers(body);onNewContent(initSlideshowMusicPlayers);if(!body.hasClass("mobile")){$(".article-content img[data-lazyload-src]").lazyload();}
f.modifyFormat();if(PROPHOTO.browser.isTouchDevice){f.handleSuckerfishTouch();}
var mhModule=PROPHOTO.site.renderingMobile?"slideshow-masthead-mobile":"slideshow-masthead";require([mhModule],function(mhsProto){var initMastheadSlideshow=function(){var mhsWrap=$("#masthead-slideshow.not-loaded");if(mhsWrap.length){var mhsImg=mhsWrap.find("img.ss-first-img");mhsImg.imageLoaded(function(){var mhs=a.objectCreate(mhsProto);mhs.wrap=mhsWrap;mhs.startImg=mhsImg;mhs.conf={"imgs":[{"src":imgDir+"masthead_image1_1360621289.jpg","linkURL":false},{"src":imgDir+"masthead_image2_1360621331.jpg","linkURL":false},{"src":imgDir+"masthead_image3_1360621360.jpg","linkURL":false},{"src":imgDir+"masthead_image4_1360620869.jpg","linkURL":false},{"src":imgDir+"masthead_image5_1360620919.jpg","linkURL":false},{"src":imgDir+"masthead_image6_1360620956.jpg","linkURL":false},{"src":imgDir+"masthead_image7_1360620990.jpg","linkURL":false}],"holdTime":6000,"transitionTime":400,"imageOrder":"random","loopImages":true,"transitionType":"crossfade","viewingAreaWidth":900,"viewingAreaHeight":460};mhs.init();});}};initMastheadSlideshow();body.on("pagebeforeshow",initMastheadSlideshow);});if(body.hasClass("single")){var form=$("form#add-comment");if(form.length){form.find("input,textarea").on("focus",function(){a.initFormValidation(form);});}}
if(!body.hasClass("single")&&$(".article-comments").length){require(["ajax-comments"],function(ajaxCommentsHandlerProto){a.initObjectsWithWrap($("article"),ajaxCommentsHandlerProto,"article");});body.on("add_comment_form_loaded",function(event,form){a.initFormValidation(form);});}else{g.handleErrorHash(window.location.hash);}
$(".comments-count").on("click",function(){var commentsSection=$(this).parents(".article-comments");if(commentsSection.find(".comments-body-inner div").length){commentsSection.toggleClass("comments-shown");commentsSection.find(".comments-body").slideToggle(400);}});if(!PROPHOTO.browser.isTech){h(body);onNewContent(h);}
PROPHOTO.fb_lang='en_US';i.parse(body);onNewContent(i.parse.bind(i));body.on("pagebeforeshow",i.parse.bind(i));$("article:last").addClass("last-post");$(document).on("click","a[href='#top']",function(){$("html,body").animate({scrollTop:0},500,"easeOutExpo");return false;});$("a.type-share_on_facebook,a.type-tweet_this_url,a.type-subscribe_by_email").on("click",function(){var clicked=$(this),height=clicked.hasClass("type-subscribe_by_email")?550:275,width=clicked.hasClass("type-share_on_facebook")?665:600,href=clicked.attr("href");window.open(href,href,'location=0,menubar=0,height='+height+',width='+width+',toolbar=0,scrollbars=0,status=0');return false;});});});}());