Skip to content
Browse files

Updated iOS Orientationchange Fix to latest version.

  • Loading branch information...
1 parent bb8b126 commit bb67049d32e7d08945867829839a7e3ff594a196 @yellowled committed Jun 1, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 js/2k11.min.js
View
2 js/2k11.min.js
@@ -19,7 +19,7 @@ T();respond.update=T;function A(){K(true);}if(P.addEventListener){P.addEventList
}}})(this);(function(p){if(!(/iPhone|iPad|iPod/.test(navigator.platform)&&navigator.userAgent.indexOf("AppleWebKit")>-1)){return;}var q=p.document;if(!q.querySelector){return;
}var o=q.querySelector("meta[name=viewport]"),B=o&&o.getAttribute("content"),r=B+",maximum-scale=1",y=B+",maximum-scale=10",v=true,s,t,u,z;if(!o){return;
}function w(){o.setAttribute("content",y);v=true;}function A(){o.setAttribute("content",r);v=false;}function x(a){z=a.accelerationIncludingGravity;s=Math.abs(z.x);
-t=Math.abs(z.y);u=Math.abs(z.z);if(!p.orientation&&(s>7||((u>6&&t<8||u<8&&t>6)&&s>5))){if(v){A();}}else{if(!v){w();}}}p.addEventListener("orientationchange",w,false);
+t=Math.abs(z.y);u=Math.abs(z.z);if((!p.orientation||p.orientation===180)&&(s>7||((u>6&&t<8||u<8&&t>6)&&s>5))){if(v){A();}}else{if(!v){w();}}}p.addEventListener("orientationchange",w,false);
p.addEventListener("devicemotion",x,false);})(this);(function(b){b.fn.fitVids=function(a){var h={customSelector:null};var f=document.createElement("div"),g=document.getElementsByTagName("base")[0]||document.getElementsByTagName("script")[0];
f.className="fit-vids-style";f.innerHTML="&shy;<style>.fluid-width-video-wrapper {width: 100%;position: relative;padding: 0;}.fluid-width-video-wrapper iframe,.fluid-width-video-wrapper object,.fluid-width-video-wrapper embed {position: absolute;top: 0;left: 0;width: 100%;height: 100%;}</style>";
g.parentNode.insertBefore(f,g);if(a){b.extend(h,a);}return this.each(function(){var d=["iframe[src*='player.vimeo.com']","iframe[src*='www.youtube.com']","iframe[src*='www.kickstarter.com']","object","embed"];

0 comments on commit bb67049

Please sign in to comment.
Something went wrong with that request. Please try again.