File: /home/thanexcelr/www/wp-content/plugins/nextgen-gallery/freemius/assets/js/postmessage.min.js
!function(t,e){var s=this;s.FS=s.FS||{},s.FS.PostMessage=function(){var e,s=!1,n=new NoJQueryPostMessageMixin("postMessage","receiveMessage"),o={},i=decodeURIComponent(document.location.hash.replace(/^#/,"")),r=i.substring(0,i.indexOf("/","https://"===i.substring(0,"https://".length)?8:7)),a=function(){n.receiveMessage(function(t){var e=JSON.parse(t.data);if(o[e.type])for(var s=0;s<o[e.type].length;s++)o[e.type][s](e.data)},e)},c=""!==i,u=t(window),p=t("html");return{init:function(t,s){e=t,a(),FS.PostMessage.receiveOnce("forward",function(t){window.location=t.url}),s=s||[],s.length>0&&u.on("scroll",function(){for(var t=0;t<s.length;t++)FS.PostMessage.postScroll(s[t])})},init_child:function(){this.init(r),s=!0,t(window).bind("load",function(){FS.PostMessage.postHeight(),FS.PostMessage.post("loaded")})},hasParent:function(){return c},postHeight:function(e,s){e=e||0,s=s||"#wrap_section",this.post("height",{height:e+t(s).outerHeight(!0)})},postScroll:function(t){this.post("scroll",{top:u.scrollTop(),height:u.height()-parseFloat(p.css("paddingTop"))-parseFloat(p.css("marginTop"))},t)},post:function(t,e,s){console.debug("PostMessage.post",t),s?n.postMessage(JSON.stringify({type:t,data:e}),s.src,s.contentWindow):n.postMessage(JSON.stringify({type:t,data:e}),i,window.parent)},receive:function(t,e){console.debug("PostMessage.receive",t),void 0===o[t]&&(o[t]=[]),o[t].push(e)},receiveOnce:function(t,e){this.is_set(t)||this.receive(t,e)},is_set:function(t){return void 0!=o[t]},parent_url:function(){return i},parent_subdomain:function(){return r}}}()}(jQuery);