zwplayer-vue2x 1.0.2 → 1.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,52 +1,52 @@
1
- (function(I){function Ma(){return document.fullscreenElement||document.msFullscreenElement||document.mozFullScreenElement||document.webkitFullscreenElement||!1}function ab(p,B,u){var y=new Date;y.setTime(y.getTime()+864E5*u);u="expires="+y.toGMTString();document.cookie=p+"="+B+"; "+u}function Ga(p,B,u){if(p){var y=parseInt(p.style.opacity)||1;y*=100;B=parseInt(B/50);0===B&&(B=1);var F=y/B;5>F&&(F=5);var J=setInterval(function(){0<y?(y-=F,0>y&&(y=0),p.style.opacity=y/100):(clearInterval(J),"function"==
2
- typeof u&&u(p))},50);return J}return null}function Pa(p,B,u){if(p){var y=p.style.opacity;y*=100;B=parseInt(B/50);0===B&&(B=1);var F=(100-y)/B;5>F&&(F=5);var J=null;return J=setInterval(function(){100>y?(y+=F,100<y&&(y=100),p.style.opacity=y/100):(clearInterval(J),"function"==typeof u&&u(p))},50)}return null}function Qa(p,B){if(!p)return!1;if(p==B)return!0;var u=p.indexOf(B);if(0>u)return!1;if(0<u){if(" "==p.charAt(u-1)&&(p.length-u==B.length||" "==p.charAt(u+B.length)))return!0}else if(" "==p.charAt(B.length))return!0;
3
- return!1}function Ra(p,B,u){var y=new XMLHttpRequest;y.onreadystatechange=function(){4===y.readyState&&(200<=y.status&&300>y.status||304===y.status?B(y.response):"function"===typeof u&&u(y))};y.open("GET",p,!0);y.send(null)}function bb(p){const B=function(J,w,L){for(var M=L.length,P=0;P<M;P++)J.setUint8(w+P,L.charCodeAt(P))};var u=function(){var J=new ArrayBuffer(364);let w=new DataView(J);B(w,0,"RIFF");w.setUint32(4,204,!0);B(w,8,"WAVE");B(w,12,"fmt ");w.setUint32(16,16,!0);w.setUint16(20,1,!0);
4
- w.setUint16(22,1,!0);w.setUint32(24,16E3,!0);w.setUint32(28,32E3,!0);w.setUint16(32,4,!0);w.setUint16(34,16,!0);B(w,36,"data");w.setUint32(40,320,!0);let L=44;for(let M=0;160>M;M++)w.setInt16(L,15,!0),L+=2;J=new Uint8Array(J);return"data:audio/x-wav;base64,"+btoa(String.fromCharCode.apply(null,J))}(),y=new Audio(u),F=I.setTimeout(function(){F=0;"function"===typeof p&&p(!1)},500);y.play().then(function(){F&&I.clearTimeout(F);y.pause();p(!0)}).catch(function(J){F&&I.clearTimeout(F);"function"===typeof p&&
5
- p(!1)})}async function cb(p){navigator.clipboard&&navigator.clipboard.write([new ClipboardItem({[p.type]:p})]).then(()=>{console.info("[setClipboard] clipboard suc")}).catch(B=>{console.error("[setClipboard] clipboard err",B)})}function db(){var p=new Date,B=p.getMonth()+1;10>B&&(B="0"+B);var u=p.getDate();10>u&&(u="0"+u);var y=p.getHours();10>y&&(y="0"+y);var F=p.getMinutes();10>F&&(F="0"+F);var J=p.getSeconds();10>J&&(J="0"+J);var w=p.getMilliseconds();10>w?w="00"+w:100>w&&(w="0"+w);return""+p.getFullYear()+
6
- B+u+y+F+J+w}function eb(p){var B={font_size:.4,font_color:"#FFFFFF",background_alpha:.5,background_color:"#9C27B0",Stroke:"none",body:[]},u=function(w){w=w.split(":");if(3!==w.length)return 0;var L=3600*parseInt(w[0],10),M=60*parseInt(w[1],10),P=parseInt(w[2],10),Q=w[2].indexOf(","),Z=0;0<Q&&(Z=parseInt(w[2].substr(Q+1))/1E3);return L+M+P+Z};p=p.replace(/\r/g,"");p=p.split("\n");for(var y=0;y<p.length-2;){var F={},J=p[y].trim();if(J){F.id=parseInt(J);J=p[y+1].split(" --\x3e ");if(2!==J.length)break;
7
- F.from=u(J[0].trim());F.to=u(J[1].trim());F.location=2;F.content=p[y+2].trim();B.body.push(F);y+=3}else y++}return B}function Sa(p){var B={font_size:.4,font_color:"#FFFFFF",background_alpha:.5,background_color:"#9C27B0",Stroke:"none",body:[]},u=function(w){w=w.split(":");var L=0,M=0;if(3===w.length){L=3600*parseInt(w[0],10);M=60*parseInt(w[1],10);var P=parseInt(w[2],10)}else if(2===w.length)M=60*parseInt(w[0],10),P=parseInt(w[1],10);else if(1===w.length)P=parseInt(w[0],10);else return 0;var Q=w.length-
8
- 1,Z=w[Q].indexOf("."),ba=0;0<Z&&(ba=parseInt(w[Q].substr(Z+1))/1E3);return L+M+P+ba};p=p.replace(/\r/g,"");p=p.split("\n");if(2>p.length||"WEBVTT"!==p[0].substr(0,6)||0!==p[1].trim().length)return null;for(var y=2;y<=p.length-2;){var F={};if(!p[y].startsWith("NOTE")&&""!==p[y].trim()){var J=p[y].split(" --\x3e ");if(2!==J.length&&(J=p[y].trim(),F.id=parseInt(J),y++,J=p[y].split(" --\x3e "),2!==J.length)){y++;continue}F.from=u(J[0].trim());F.to=u(J[1].trim());F.location=2;y++;F.content=p[y].trim();
9
- for(y++;y<p.length;){J=p[y].trim();if(!J)break;F.content+="<br/>"+J;y++}B.body.push(F)}y++}return B}function Ta(p){return!(!p.width()&&!p.height())&&"none"!==p.css("display")}function fb(p,B){var u="smilesFaces-view",y=Da.path+"widgets/smiles/p",F=$$(p);if(!F.hasClass("disabled")){u=F.attr("data-viewid");if(!F.attr("data-viewinit")&&0>=$$("#"+u).length){var J=F.closest(".zwp-barrage_form");p='<div id="'+u+'" style="position:absolute;display:none;z-index:1138;" class="zwp-smileview"><table border="0" cellspacing="0" cellpadding="0"><tr>';
10
- for(var w=1;40>=w;w++){var L="[sm-"+w+"]";p+='<td><img src="'+y+w+'.png" onclick="insertSmile(this,\''+L+"');\" /></td>";0==w%8&&(p+="</tr><tr>")}J.append(p+"</tr></table></div>");F.attr("data-viewinit","1");$$(document).click(function(){$$("#"+u).hide()});$$(I).on("resize",function(){var Q=$$("#"+u);Ta(Q)&&(F.offset(),Q.outerHeight(!1),F.outerWidth(!1),Q.outerWidth(!1))})}var M=$$("#"+u);if(Ta(M))M.hide();else{F.offset();M[0].style.opacity=0;M[0].style.display="block";M.outerHeight(!1);F.outerWidth(!1);
11
- M.outerWidth(!1);y=F.parent().children("DIV.zwp-barrage_inp").children(".barrage_inp_text");M.get(0).inputbox=y.get(0);M.css({bottom:"36px",right:"26px"}).show();var P=function(){var Q=parseFloat(M[0].style.opacity);1>=Q&&(Q+=.1,1<Q&&(Q=1),M[0].style.opacity=Q,setTimeout(P,50))};setTimeout(P,50)}if(B=B||I.event)B.preventDefault?(B.preventDefault(),B.stopPropagation()):(I.event.cancelBubble=!0,I.event.returnValue=!1)}}function gb(p,B){if(p.dragableWinInited)"object"===typeof p.zwpDragable&&("oldX"in
1
+ (function(J){function Na(){return document.fullscreenElement||document.msFullscreenElement||document.mozFullScreenElement||document.webkitFullscreenElement||!1}function ab(p,B,u){var y=new Date;y.setTime(y.getTime()+864E5*u);u="expires="+y.toGMTString();document.cookie=p+"="+B+"; "+u}function Ga(p,B,u){if(p){var y=parseInt(p.style.opacity)||1;y*=100;B=parseInt(B/50);0===B&&(B=1);var F=y/B;5>F&&(F=5);var I=setInterval(function(){0<y?(y-=F,0>y&&(y=0),p.style.opacity=y/100):(clearInterval(I),"function"==
2
+ typeof u&&u(p))},50);return I}return null}function Pa(p,B,u){if(p){var y=p.style.opacity;y*=100;B=parseInt(B/50);0===B&&(B=1);var F=(100-y)/B;5>F&&(F=5);var I=null;return I=setInterval(function(){100>y?(y+=F,100<y&&(y=100),p.style.opacity=y/100):(clearInterval(I),"function"==typeof u&&u(p))},50)}return null}function Qa(p,B){if(!p)return!1;if(p==B)return!0;var u=p.indexOf(B);if(0>u)return!1;if(0<u){if(" "==p.charAt(u-1)&&(p.length-u==B.length||" "==p.charAt(u+B.length)))return!0}else if(" "==p.charAt(B.length))return!0;
3
+ return!1}function Ra(p,B,u){var y=new XMLHttpRequest;y.onreadystatechange=function(){4===y.readyState&&(200<=y.status&&300>y.status||304===y.status?B(y.response):"function"===typeof u&&u(y))};y.open("GET",p,!0);y.send(null)}function bb(p){const B=function(I,w,K){for(var L=K.length,O=0;O<L;O++)I.setUint8(w+O,K.charCodeAt(O))};var u=function(){var I=new ArrayBuffer(364);let w=new DataView(I);B(w,0,"RIFF");w.setUint32(4,204,!0);B(w,8,"WAVE");B(w,12,"fmt ");w.setUint32(16,16,!0);w.setUint16(20,1,!0);
4
+ w.setUint16(22,1,!0);w.setUint32(24,16E3,!0);w.setUint32(28,32E3,!0);w.setUint16(32,4,!0);w.setUint16(34,16,!0);B(w,36,"data");w.setUint32(40,320,!0);let K=44;for(let L=0;160>L;L++)w.setInt16(K,15,!0),K+=2;I=new Uint8Array(I);return"data:audio/x-wav;base64,"+btoa(String.fromCharCode.apply(null,I))}(),y=new Audio(u),F=J.setTimeout(function(){F=0;"function"===typeof p&&p(!1)},500);y.play().then(function(){F&&J.clearTimeout(F);y.pause();p(!0)}).catch(function(I){F&&J.clearTimeout(F);"function"===typeof p&&
5
+ p(!1)})}async function cb(p){navigator.clipboard&&navigator.clipboard.write([new ClipboardItem({[p.type]:p})]).then(()=>{console.info("[setClipboard] clipboard suc")}).catch(B=>{console.error("[setClipboard] clipboard err",B)})}function db(){var p=new Date,B=p.getMonth()+1;10>B&&(B="0"+B);var u=p.getDate();10>u&&(u="0"+u);var y=p.getHours();10>y&&(y="0"+y);var F=p.getMinutes();10>F&&(F="0"+F);var I=p.getSeconds();10>I&&(I="0"+I);var w=p.getMilliseconds();10>w?w="00"+w:100>w&&(w="0"+w);return""+p.getFullYear()+
6
+ B+u+y+F+I+w}function eb(p){var B={font_size:.4,font_color:"#FFFFFF",background_alpha:.5,background_color:"#9C27B0",Stroke:"none",body:[]},u=function(w){w=w.split(":");if(3!==w.length)return 0;var K=3600*parseInt(w[0],10),L=60*parseInt(w[1],10),O=parseInt(w[2],10),Q=w[2].indexOf(","),Z=0;0<Q&&(Z=parseInt(w[2].substr(Q+1))/1E3);return K+L+O+Z};p=p.replace(/\r/g,"");p=p.split("\n");for(var y=0;y<p.length-2;){var F={},I=p[y].trim();if(I){F.id=parseInt(I);I=p[y+1].split(" --\x3e ");if(2!==I.length)break;
7
+ F.from=u(I[0].trim());F.to=u(I[1].trim());F.location=2;F.content=p[y+2].trim();B.body.push(F);y+=3}else y++}return B}function Sa(p){var B={font_size:.4,font_color:"#FFFFFF",background_alpha:.5,background_color:"#9C27B0",Stroke:"none",body:[]},u=function(w){w=w.split(":");var K=0,L=0;if(3===w.length){K=3600*parseInt(w[0],10);L=60*parseInt(w[1],10);var O=parseInt(w[2],10)}else if(2===w.length)L=60*parseInt(w[0],10),O=parseInt(w[1],10);else if(1===w.length)O=parseInt(w[0],10);else return 0;var Q=w.length-
8
+ 1,Z=w[Q].indexOf("."),ba=0;0<Z&&(ba=parseInt(w[Q].substr(Z+1))/1E3);return K+L+O+ba};p=p.replace(/\r/g,"");p=p.split("\n");if(2>p.length||"WEBVTT"!==p[0].substr(0,6)||0!==p[1].trim().length)return null;for(var y=2;y<=p.length-2;){var F={};if(!p[y].startsWith("NOTE")&&""!==p[y].trim()){var I=p[y].split(" --\x3e ");if(2!==I.length&&(I=p[y].trim(),F.id=parseInt(I),y++,I=p[y].split(" --\x3e "),2!==I.length)){y++;continue}F.from=u(I[0].trim());F.to=u(I[1].trim());F.location=2;y++;F.content=p[y].trim();
9
+ for(y++;y<p.length;){I=p[y].trim();if(!I)break;F.content+="<br/>"+I;y++}B.body.push(F)}y++}return B}function Ta(p){return!(!p.width()&&!p.height())&&"none"!==p.css("display")}function fb(p,B){var u="smilesFaces-view",y=Da.path+"widgets/smiles/p",F=$$(p);if(!F.hasClass("disabled")){u=F.attr("data-viewid");if(!F.attr("data-viewinit")&&0>=$$("#"+u).length){var I=F.closest(".zwp-barrage_form");p='<div id="'+u+'" style="position:absolute;display:none;z-index:1138;" class="zwp-smileview"><table border="0" cellspacing="0" cellpadding="0"><tr>';
10
+ for(var w=1;40>=w;w++){var K="[sm-"+w+"]";p+='<td><img src="'+y+w+'.png" onclick="insertSmile(this,\''+K+"');\" /></td>";0==w%8&&(p+="</tr><tr>")}I.append(p+"</tr></table></div>");F.attr("data-viewinit","1");$$(document).click(function(){$$("#"+u).hide()});$$(J).on("resize",function(){var Q=$$("#"+u);Ta(Q)&&(F.offset(),Q.outerHeight(!1),F.outerWidth(!1),Q.outerWidth(!1))})}var L=$$("#"+u);if(Ta(L))L.hide();else{F.offset();L[0].style.opacity=0;L[0].style.display="block";L.outerHeight(!1);F.outerWidth(!1);
11
+ L.outerWidth(!1);y=F.parent().children("DIV.zwp-barrage_inp").children(".barrage_inp_text");L.get(0).inputbox=y.get(0);L.css({bottom:"36px",right:"26px"}).show();var O=function(){var Q=parseFloat(L[0].style.opacity);1>=Q&&(Q+=.1,1<Q&&(Q=1),L[0].style.opacity=Q,setTimeout(O,50))};setTimeout(O,50)}if(B=B||J.event)B.preventDefault?(B.preventDefault(),B.stopPropagation()):(J.event.cancelBubble=!0,J.event.returnValue=!1)}}function gb(p,B){if(p.dragableWinInited)"object"===typeof p.zwpDragable&&("oldX"in
12
12
  p.zwpDragable&&(p.style.left=p.zwpDragable.oldX+"px"),"oldY"in p.zwpDragable&&(p.style.top=p.zwpDragable.oldY+"px"),"oldWidth"in p.zwpDragable&&(p.style.width=p.zwpDragable.oldWidth+"px"),"oldHeight"in p.zwpDragable&&(p.style.height=p.zwpDragable.oldHeight+"px"));else{var u='<div class="zwp-captionbar"><button class="closeBtn" title="'+(qa("closeSmallWindow","Close small window")+'"><i class="xicon xicon-close"></i></button></div><div class="zwp-gripper-right"></div><div class="zwp-gripper-bottom"></div><div class="zwp-gripper-bottom-right"></div>');
13
- p.insertAdjacentHTML("beforeend",u);var y=function(P){P.stopPropagation();P.preventDefault();var Q=parseInt(p.offsetLeft),Z=parseInt(p.offsetTop),ba=P.pageX,aa=P.pageY,fa=I.innerWidth-p.offsetWidth-20,ma=I.innerHeight-p.offsetHeight-20,Y=function(ia){var na=Q+ia.pageX-ba;ia=Z+ia.pageY-aa;0>na&&(na=0);0>ia&&(ia=0);na>fa&&(na=fa);ia>ma&&(ia=ma);p.style.left=na+"px";p.style.top=ia+"px";"object"===typeof p.zwpDragable&&(p.zwpDragable.oldX=na,p.zwpDragable.oldY=ia)},ka=function(ia){document.removeEventListener("mousemove",
14
- Y);document.removeEventListener("mouseup",ka)};document.addEventListener("mousemove",Y);document.addEventListener("mouseup",ka)};u=function(P){P.stopPropagation();P.preventDefault();var Q=p.offsetWidth,Z=P.pageX,ba=function(fa){fa=Q+fa.pageX-Z;200>fa&&(fa=200);p.style.width=fa+"px";"object"===typeof p.zwpDragable&&(p.zwpDragable.oldWidth=fa)},aa=function(fa){document.removeEventListener("mousemove",ba);document.removeEventListener("mouseup",aa)};document.addEventListener("mousemove",ba);document.addEventListener("mouseup",
15
- aa)};var F=function(P){P.stopPropagation();P.preventDefault();var Q=p.offsetHeight,Z=P.pageY,ba=function(fa){fa=Q+fa.pageY-Z;180>fa&&(fa=180);p.style.height=fa+"px";"object"===typeof p.zwpDragable&&(p.zwpDragable.oldHeight=fa)},aa=function(fa){document.removeEventListener("mousemove",ba);document.removeEventListener("mouseup",aa)};document.addEventListener("mousemove",ba);document.addEventListener("mouseup",aa)},J=function(P){P.stopPropagation();P.preventDefault();var Q=p.offsetWidth,Z=p.offsetHeight,
16
- ba=P.pageX,aa=P.pageY,fa=function(Y){var ka=Q+Y.pageX-ba;200>ka&&(ka=200);Y=Z+Y.pageY-aa;180>Y&&(Y=180);p.style.width=ka+"px";p.style.height=Y+"px";"object"===typeof p.zwpDragable&&(p.zwpDragable.oldWidth=ka,p.zwpDragable.oldHeight=Y)},ma=function(Y){document.removeEventListener("mousemove",fa);document.removeEventListener("mouseup",ma)};document.addEventListener("mousemove",fa);document.addEventListener("mouseup",ma)};p.zwpDragable={};var w=p.querySelector(".zwp-captionbar");if(w){var L=w.querySelector(".closeBtn");
17
- if(L){var M=B||function(){};L.addEventListener("click",function(P){P.preventDefault();P.stopPropagation();M(p)})}w.addEventListener("mousedown",y);p.zwpDragable.doc_mousedown=y}B=p.querySelector(".zwp-gripper-right");y=p.querySelector(".zwp-gripper-bottom");w=p.querySelector(".zwp-gripper-bottom-right");B&&(B.addEventListener("mousedown",u),p.zwpDragable.gripperR_mousedown=u);y&&(y.addEventListener("mousedown",F),p.zwpDragable.gripperB_mousedown=F);w&&(w.addEventListener("mousedown",J),p.zwpDragable.gripperBR_mousedown=
18
- J);p.dragableWinInited=!0}}(function(p){var B=!1,u=!1,y=0,F=2E3,J=0,w=document,L=p(I),M=[],P=I.requestAnimationFrame||I.webkitRequestAnimationFrame||I.mozRequestAnimationFrame||!1,Q=I.cancelAnimationFrame||I.webkitCancelAnimationFrame||I.mozCancelAnimationFrame||!1;if(P)I.cancelAnimationFrame||(Q=function(e){});else{var Z=0;P=function(e,n){var m=(new Date).getTime(),c=Math.max(0,16-(m-Z));n=I.setTimeout(function(){e(m+c)},c);Z=m+c;return n};Q=function(e){I.clearTimeout(e)}}var ba=I.MutationObserver||
19
- I.WebKitMutationObserver||!1,aa=Date.now||function(){return(new Date).getTime()},fa={zindex:"auto",cursoropacitymin:0,cursoropacitymax:1,cursorcolor:"#424242",cursorwidth:"6px",cursorborder:"1px solid #fff",cursorborderradius:"5px",scrollspeed:40,mousescrollstep:27,touchbehavior:!1,emulatetouch:!1,hwacceleration:!0,usetransition:!0,boxzoom:!1,dblclickzoom:!0,gesturezoom:!0,grabcursorenabled:!0,autohidemode:!0,background:"",iframeautoresize:!0,cursorminheight:32,preservenativescrolling:!0,railoffset:!1,
13
+ p.insertAdjacentHTML("beforeend",u);var y=function(O){O.stopPropagation();O.preventDefault();var Q=parseInt(p.offsetLeft),Z=parseInt(p.offsetTop),ba=O.pageX,aa=O.pageY,fa=J.innerWidth-p.offsetWidth-20,ma=J.innerHeight-p.offsetHeight-20,Y=function(ia){var na=Q+ia.pageX-ba;ia=Z+ia.pageY-aa;0>na&&(na=0);0>ia&&(ia=0);na>fa&&(na=fa);ia>ma&&(ia=ma);p.style.left=na+"px";p.style.top=ia+"px";"object"===typeof p.zwpDragable&&(p.zwpDragable.oldX=na,p.zwpDragable.oldY=ia)},ka=function(ia){document.removeEventListener("mousemove",
14
+ Y);document.removeEventListener("mouseup",ka)};document.addEventListener("mousemove",Y);document.addEventListener("mouseup",ka)};u=function(O){O.stopPropagation();O.preventDefault();var Q=p.offsetWidth,Z=O.pageX,ba=function(fa){fa=Q+fa.pageX-Z;200>fa&&(fa=200);p.style.width=fa+"px";"object"===typeof p.zwpDragable&&(p.zwpDragable.oldWidth=fa)},aa=function(fa){document.removeEventListener("mousemove",ba);document.removeEventListener("mouseup",aa)};document.addEventListener("mousemove",ba);document.addEventListener("mouseup",
15
+ aa)};var F=function(O){O.stopPropagation();O.preventDefault();var Q=p.offsetHeight,Z=O.pageY,ba=function(fa){fa=Q+fa.pageY-Z;180>fa&&(fa=180);p.style.height=fa+"px";"object"===typeof p.zwpDragable&&(p.zwpDragable.oldHeight=fa)},aa=function(fa){document.removeEventListener("mousemove",ba);document.removeEventListener("mouseup",aa)};document.addEventListener("mousemove",ba);document.addEventListener("mouseup",aa)},I=function(O){O.stopPropagation();O.preventDefault();var Q=p.offsetWidth,Z=p.offsetHeight,
16
+ ba=O.pageX,aa=O.pageY,fa=function(Y){var ka=Q+Y.pageX-ba;200>ka&&(ka=200);Y=Z+Y.pageY-aa;180>Y&&(Y=180);p.style.width=ka+"px";p.style.height=Y+"px";"object"===typeof p.zwpDragable&&(p.zwpDragable.oldWidth=ka,p.zwpDragable.oldHeight=Y)},ma=function(Y){document.removeEventListener("mousemove",fa);document.removeEventListener("mouseup",ma)};document.addEventListener("mousemove",fa);document.addEventListener("mouseup",ma)};p.zwpDragable={};var w=p.querySelector(".zwp-captionbar");if(w){var K=w.querySelector(".closeBtn");
17
+ if(K){var L=B||function(){};K.addEventListener("click",function(O){O.preventDefault();O.stopPropagation();L(p)})}w.addEventListener("mousedown",y);p.zwpDragable.doc_mousedown=y}B=p.querySelector(".zwp-gripper-right");y=p.querySelector(".zwp-gripper-bottom");w=p.querySelector(".zwp-gripper-bottom-right");B&&(B.addEventListener("mousedown",u),p.zwpDragable.gripperR_mousedown=u);y&&(y.addEventListener("mousedown",F),p.zwpDragable.gripperB_mousedown=F);w&&(w.addEventListener("mousedown",I),p.zwpDragable.gripperBR_mousedown=
18
+ I);p.dragableWinInited=!0}}(function(p){var B=!1,u=!1,y=0,F=2E3,I=0,w=document,K=p(J),L=[],O=J.requestAnimationFrame||J.webkitRequestAnimationFrame||J.mozRequestAnimationFrame||!1,Q=J.cancelAnimationFrame||J.webkitCancelAnimationFrame||J.mozCancelAnimationFrame||!1;if(O)J.cancelAnimationFrame||(Q=function(e){});else{var Z=0;O=function(e,n){var m=(new Date).getTime(),c=Math.max(0,16-(m-Z));n=J.setTimeout(function(){e(m+c)},c);Z=m+c;return n};Q=function(e){J.clearTimeout(e)}}var ba=J.MutationObserver||
19
+ J.WebKitMutationObserver||!1,aa=Date.now||function(){return(new Date).getTime()},fa={zindex:"auto",cursoropacitymin:0,cursoropacitymax:1,cursorcolor:"#424242",cursorwidth:"6px",cursorborder:"1px solid #fff",cursorborderradius:"5px",scrollspeed:40,mousescrollstep:27,touchbehavior:!1,emulatetouch:!1,hwacceleration:!0,usetransition:!0,boxzoom:!1,dblclickzoom:!0,gesturezoom:!0,grabcursorenabled:!0,autohidemode:!0,background:"",iframeautoresize:!0,cursorminheight:32,preservenativescrolling:!0,railoffset:!1,
20
20
  railhoffset:!1,bouncescroll:!0,spacebarenabled:!0,railpadding:{top:0,right:0,left:0,bottom:0},disableoutline:!0,horizrailenabled:!0,rightdock:0,railalign:"right",railvalign:"bottom",enabletranslate3d:!0,enablemousewheel:!0,enablekeyboard:!0,smoothscroll:!0,sensitiverail:!0,enablemouselockapi:!0,cursorfixedheight:!1,directionlockdeadzone:6,hidecursordelay:400,nativeparentscrolling:!0,enablescrollonselection:!0,overflowx:!0,overflowy:!0,cursordragspeed:.3,rtlmode:"auto",cursordragontouch:!1,oneaxismousemode:"auto",
21
21
  scriptpath:function(){var e;(e=w.currentScript)||(e=w.getElementsByTagName("script"),e=e.length?e[e.length-1]:!1);e=e?e.src.split("?")[0]:"";return 0<e.split("/").length?e.split("/").slice(0,-1).join("/")+"/":""}(),preventmultitouchscrolling:!0,disablemutationobserver:!1,enableobserver:!0,scrollbarid:!1,scrollCLass:!1},ma=!1,Y=function(){if(ma)return ma;var e=w.createElement("DIV"),n=e.style,m=navigator.userAgent,c=navigator.platform,l={};l.haspointerlock="pointerLockElement"in w||"webkitPointerLockElement"in
22
- w||"mozPointerLockElement"in w;l.isopera="opera"in I;l.isopera12=l.isopera&&"getUserMedia"in navigator;l.isoperamini="[object OperaMini]"===Object.prototype.toString.call(I.operamini);l.isie="all"in w&&"attachEvent"in e&&!l.isopera;l.isieold=l.isie&&!("msInterpolationMode"in n);l.isie7=l.isie&&!l.isieold&&(!("documentMode"in w)||7===w.documentMode);l.isie8=l.isie&&"documentMode"in w&&8===w.documentMode;l.isie9=l.isie&&"performance"in I&&9===w.documentMode;l.isie10=l.isie&&"performance"in I&&10===
23
- w.documentMode;l.isie11="msRequestFullscreen"in e&&11<=w.documentMode;l.ismsedge="msCredentials"in I;l.ismozilla="MozAppearance"in n;l.iswebkit=!l.ismsedge&&"WebkitAppearance"in n;l.ischrome=l.iswebkit&&"chrome"in I;l.ischrome38=l.ischrome&&"touchAction"in n;l.ischrome22=!l.ischrome38&&l.ischrome&&l.haspointerlock;l.ischrome26=!l.ischrome38&&l.ischrome&&"transition"in n;l.cantouch="ontouchstart"in w.documentElement||"ontouchstart"in I;l.hasw3ctouch=(I.PointerEvent||!1)&&(0<navigator.maxTouchPoints||
24
- 0<navigator.msMaxTouchPoints);l.hasmstouch=!l.hasw3ctouch&&(I.MSPointerEvent||!1);l.ismac=/^mac$/i.test(c);l.isios=l.cantouch&&/iphone|ipad|ipod/i.test(c);l.isios4=l.isios&&!("seal"in Object);l.isios7=l.isios&&"webkitHidden"in w;l.isios8=l.isios&&"hidden"in w;l.isios10=l.isios&&I.Proxy;l.isandroid=/android/i.test(m);l.haseventlistener="addEventListener"in e;l.trstyle=!1;l.hastransform=!1;l.hastranslate3d=!1;l.transitionstyle=!1;l.hastransition=!1;l.transitionend=!1;l.trstyle="transform";l.hastransform=
25
- "transform"in n||function(){for(var v=["msTransform","webkitTransform","MozTransform","OTransform"],A=0,K=v.length;A<K;A++)if(void 0!==n[v[A]]){l.trstyle=v[A];break}l.hastransform=!!l.trstyle}();l.hastransform&&(n[l.trstyle]="translate3d(1px,2px,3px)",l.hastranslate3d=/translate3d/.test(n[l.trstyle]));l.transitionstyle="transition";l.prefixstyle="";l.transitionend="transitionend";l.hastransition="transition"in n||function(){l.transitionend=!1;for(var v="webkitTransition msTransition MozTransition OTransition OTransition KhtmlTransition".split(" "),
26
- A="-webkit- -ms- -moz- -o- -o -khtml-".split(" "),K="webkitTransitionEnd msTransitionEnd transitionend otransitionend oTransitionEnd KhtmlTransitionEnd".split(" "),b=0,O=v.length;b<O;b++)if(v[b]in n){l.transitionstyle=v[b];l.prefixstyle=A[b];l.transitionend=K[b];break}l.ischrome26&&(l.prefixstyle=A[1]);l.hastransition=l.transitionstyle}();l.cursorgrabvalue=function(){var v=["grab","-webkit-grab","-moz-grab"];if(l.ischrome&&!l.ischrome38||l.isie)v=[];for(var A=0,K=v.length;A<K;A++){var b=v[A];n.cursor=
22
+ w||"mozPointerLockElement"in w;l.isopera="opera"in J;l.isopera12=l.isopera&&"getUserMedia"in navigator;l.isoperamini="[object OperaMini]"===Object.prototype.toString.call(J.operamini);l.isie="all"in w&&"attachEvent"in e&&!l.isopera;l.isieold=l.isie&&!("msInterpolationMode"in n);l.isie7=l.isie&&!l.isieold&&(!("documentMode"in w)||7===w.documentMode);l.isie8=l.isie&&"documentMode"in w&&8===w.documentMode;l.isie9=l.isie&&"performance"in J&&9===w.documentMode;l.isie10=l.isie&&"performance"in J&&10===
23
+ w.documentMode;l.isie11="msRequestFullscreen"in e&&11<=w.documentMode;l.ismsedge="msCredentials"in J;l.ismozilla="MozAppearance"in n;l.iswebkit=!l.ismsedge&&"WebkitAppearance"in n;l.ischrome=l.iswebkit&&"chrome"in J;l.ischrome38=l.ischrome&&"touchAction"in n;l.ischrome22=!l.ischrome38&&l.ischrome&&l.haspointerlock;l.ischrome26=!l.ischrome38&&l.ischrome&&"transition"in n;l.cantouch="ontouchstart"in w.documentElement||"ontouchstart"in J;l.hasw3ctouch=(J.PointerEvent||!1)&&(0<navigator.maxTouchPoints||
24
+ 0<navigator.msMaxTouchPoints);l.hasmstouch=!l.hasw3ctouch&&(J.MSPointerEvent||!1);l.ismac=/^mac$/i.test(c);l.isios=l.cantouch&&/iphone|ipad|ipod/i.test(c);l.isios4=l.isios&&!("seal"in Object);l.isios7=l.isios&&"webkitHidden"in w;l.isios8=l.isios&&"hidden"in w;l.isios10=l.isios&&J.Proxy;l.isandroid=/android/i.test(m);l.haseventlistener="addEventListener"in e;l.trstyle=!1;l.hastransform=!1;l.hastranslate3d=!1;l.transitionstyle=!1;l.hastransition=!1;l.transitionend=!1;l.trstyle="transform";l.hastransform=
25
+ "transform"in n||function(){for(var v=["msTransform","webkitTransform","MozTransform","OTransform"],A=0,M=v.length;A<M;A++)if(void 0!==n[v[A]]){l.trstyle=v[A];break}l.hastransform=!!l.trstyle}();l.hastransform&&(n[l.trstyle]="translate3d(1px,2px,3px)",l.hastranslate3d=/translate3d/.test(n[l.trstyle]));l.transitionstyle="transition";l.prefixstyle="";l.transitionend="transitionend";l.hastransition="transition"in n||function(){l.transitionend=!1;for(var v="webkitTransition msTransition MozTransition OTransition OTransition KhtmlTransition".split(" "),
26
+ A="-webkit- -ms- -moz- -o- -o -khtml-".split(" "),M="webkitTransitionEnd msTransitionEnd transitionend otransitionend oTransitionEnd KhtmlTransitionEnd".split(" "),b=0,P=v.length;b<P;b++)if(v[b]in n){l.transitionstyle=v[b];l.prefixstyle=A[b];l.transitionend=M[b];break}l.ischrome26&&(l.prefixstyle=A[1]);l.hastransition=l.transitionstyle}();l.cursorgrabvalue=function(){var v=["grab","-webkit-grab","-moz-grab"];if(l.ischrome&&!l.ischrome38||l.isie)v=[];for(var A=0,M=v.length;A<M;A++){var b=v[A];n.cursor=
27
27
  b;if(n.cursor==b)return b}return"url("+(fa.scriptpath+"css/openhand.cur),n-resize")}();l.hasmousecapture="setCapture"in e;l.hasMutationObserver=!1!==ba;e=null;return ma=l},ka=function(e,n){function m(){var g=b.doc.css(H.trstyle);return g&&"matrix"==g.substr(0,6)?g.replace(/^.*\((.*)\)$/g,"$1").replace(/px/g,"").split(/, +/):!1}function c(){var g=b.win;if("zIndex"in g)return g.zIndex();for(;0<g.length&&9!=g[0].nodeType;){var t=g.css("zIndex");if(!isNaN(t)&&0!==t)return parseInt(t);g=g.parent()}return!1}
28
- function l(g,t,x){t=g.css(t);g=parseFloat(t);return isNaN(g)?(g=h[t]||0,x=3==g?x?b.win.outerHeight()-b.win.innerHeight():b.win.outerWidth()-b.win.innerWidth():1,b.isie8&&g&&(g+=1),x?g:0):g}function v(g,t,x,f){b._bind(g,t,function(r){r=r||I.event;var D={original:r,target:r.target||r.srcElement,type:"wheel",deltaMode:"MozMousePixelScroll"==r.type?0:1,deltaX:0,deltaZ:0,preventDefault:function(){r.preventDefault?r.preventDefault():r.returnValue=!1;return!1},stopImmediatePropagation:function(){r.stopImmediatePropagation?
28
+ function l(g,t,x){t=g.css(t);g=parseFloat(t);return isNaN(g)?(g=h[t]||0,x=3==g?x?b.win.outerHeight()-b.win.innerHeight():b.win.outerWidth()-b.win.innerWidth():1,b.isie8&&g&&(g+=1),x?g:0):g}function v(g,t,x,f){b._bind(g,t,function(r){r=r||J.event;var D={original:r,target:r.target||r.srcElement,type:"wheel",deltaMode:"MozMousePixelScroll"==r.type?0:1,deltaX:0,deltaZ:0,preventDefault:function(){r.preventDefault?r.preventDefault():r.returnValue=!1;return!1},stopImmediatePropagation:function(){r.stopImmediatePropagation?
29
29
  r.stopImmediatePropagation():r.cancelBubble=!0}};"mousewheel"==t?(r.wheelDeltaX&&(D.deltaX=-.025*r.wheelDeltaX),r.wheelDeltaY&&(D.deltaY=-.025*r.wheelDeltaY),D.deltaY||D.deltaX||(D.deltaY=-.025*r.wheelDelta)):D.deltaY=r.detail;return x.call(g,D)},f)}function A(g,t,x,f){b.scrollrunning||(b.newscrolly=b.getScrollTop(),b.newscrollx=b.getScrollLeft(),S=aa());var r=aa()-S;S=aa();T=350<r?1:T+(2-T)/10;g=g*T|0;t=t*T|0;if(g){if(f)if(0>g){if(b.getScrollLeft()>=b.page.maxw)return!0}else if(0>=b.getScrollLeft())return!0;
30
30
  f=0<g?1:-1;U!==f&&(b.scrollmom&&b.scrollmom.stop(),b.newscrollx=b.getScrollLeft(),U=f);b.lastdeltax-=g}if(t){if(function(){var D=b.getScrollTop();if(0>t){if(D>=b.page.maxh)return!0}else if(0>=D)return!0}()){if(z.nativeparentscrolling&&x&&!b.ispage&&!b.zoomactive)return!0;x=b.view.h>>1;b.newscrolly<-x?(b.newscrolly=-x,t=-1):b.newscrolly>b.page.maxh+x?(b.newscrolly=b.page.maxh+x,t=1):t=0}x=0<t?1:-1;N!==x&&(b.scrollmom&&b.scrollmom.stop(),b.newscrolly=b.getScrollTop(),N=x);b.lastdeltay-=t}(t||g)&&b.synched("relativexy",
31
- function(){var D=b.lastdeltay+b.newscrolly;b.lastdeltay=0;var R=b.lastdeltax+b.newscrollx;b.lastdeltax=0;b.rail.drag||b.doScrollPos(R,D)})}function K(g,t,x){if(!x&&V)return!0;if(0===g.deltaMode){var f=-(z.mousescrollstep/54*g.deltaX)|0;var r=-(z.mousescrollstep/54*g.deltaY)|0}else 1===g.deltaMode&&(f=-(g.deltaX*z.mousescrollstep*50/80)|0,r=-(g.deltaY*z.mousescrollstep*50/80)|0);t&&z.oneaxismousemode&&0===f&&r&&(f=r,r=0,x&&(0>f?b.getScrollLeft()>=b.page.maxw:0>=b.getScrollLeft())&&(r=f,f=0));b.isrtlmode&&
32
- (f=-f);if(A(f,r,x,!0))x&&(V=!0);else return V=!1,g.stopImmediatePropagation(),g.preventDefault()}var b=this;this.version="3.7.6";this.name="nicescroll";this.me=n;var O=p("body"),z=this.opt={doc:O,win:!1};p.extend(z,fa);z.snapbackspeed=80;if(e)for(var la in z)void 0!==e[la]&&(z[la]=e[la]);z.disablemutationobserver&&(ba=!1);this.iddoc=(this.doc=z.doc)&&this.doc[0]?this.doc[0].id||"":"";this.ispage=/^BODY|HTML/.test(z.win?z.win[0].nodeName:this.doc[0].nodeName);this.haswrapper=!1!==z.win;this.win=z.win||
33
- (this.ispage?L:this.doc);this.docscroll=this.ispage&&!this.haswrapper?L:this.win;this.body=O;this.iframe=this.isfixed=this.viewport=!1;this.isiframe="IFRAME"==this.doc[0].nodeName&&"IFRAME"==this.win[0].nodeName;this.istextarea="TEXTAREA"==this.win[0].nodeName;this.forcescreen=!1;this.canshowonmouseevent="scroll"!=z.autohidemode;this.page=this.view=this.onzoomout=this.onzoomin=this.onscrollcancel=this.onscrollend=this.onscrollstart=this.onclick=this.ongesturezoom=this.onkeypress=this.onmousewheel=
34
- this.onmousemove=this.onmouseup=this.onmousedown=!1;this.scroll={x:0,y:0};this.scrollratio={x:0,y:0};this.cursorheight=20;this.scrollvaluemax=0;"auto"==z.rtlmode?(e=this.win[0]==I?this.body:this.win,n=e.css("writing-mode")||e.css("-webkit-writing-mode")||e.css("-ms-writing-mode")||e.css("-moz-writing-mode"),"horizontal-tb"==n||"lr-tb"==n||""===n?(this.isrtlmode="rtl"==e.css("direction"),this.isvertical=!1):(this.isrtlmode="vertical-rl"==n||"tb"==n||"tb-rl"==n||"rl-tb"==n,this.isvertical="vertical-rl"==
31
+ function(){var D=b.lastdeltay+b.newscrolly;b.lastdeltay=0;var R=b.lastdeltax+b.newscrollx;b.lastdeltax=0;b.rail.drag||b.doScrollPos(R,D)})}function M(g,t,x){if(!x&&V)return!0;if(0===g.deltaMode){var f=-(z.mousescrollstep/54*g.deltaX)|0;var r=-(z.mousescrollstep/54*g.deltaY)|0}else 1===g.deltaMode&&(f=-(g.deltaX*z.mousescrollstep*50/80)|0,r=-(g.deltaY*z.mousescrollstep*50/80)|0);t&&z.oneaxismousemode&&0===f&&r&&(f=r,r=0,x&&(0>f?b.getScrollLeft()>=b.page.maxw:0>=b.getScrollLeft())&&(r=f,f=0));b.isrtlmode&&
32
+ (f=-f);if(A(f,r,x,!0))x&&(V=!0);else return V=!1,g.stopImmediatePropagation(),g.preventDefault()}var b=this;this.version="3.7.6";this.name="nicescroll";this.me=n;var P=p("body"),z=this.opt={doc:P,win:!1};p.extend(z,fa);z.snapbackspeed=80;if(e)for(var la in z)void 0!==e[la]&&(z[la]=e[la]);z.disablemutationobserver&&(ba=!1);this.iddoc=(this.doc=z.doc)&&this.doc[0]?this.doc[0].id||"":"";this.ispage=/^BODY|HTML/.test(z.win?z.win[0].nodeName:this.doc[0].nodeName);this.haswrapper=!1!==z.win;this.win=z.win||
33
+ (this.ispage?K:this.doc);this.docscroll=this.ispage&&!this.haswrapper?K:this.win;this.body=P;this.iframe=this.isfixed=this.viewport=!1;this.isiframe="IFRAME"==this.doc[0].nodeName&&"IFRAME"==this.win[0].nodeName;this.istextarea="TEXTAREA"==this.win[0].nodeName;this.forcescreen=!1;this.canshowonmouseevent="scroll"!=z.autohidemode;this.page=this.view=this.onzoomout=this.onzoomin=this.onscrollcancel=this.onscrollend=this.onscrollstart=this.onclick=this.ongesturezoom=this.onkeypress=this.onmousewheel=
34
+ this.onmousemove=this.onmouseup=this.onmousedown=!1;this.scroll={x:0,y:0};this.scrollratio={x:0,y:0};this.cursorheight=20;this.scrollvaluemax=0;"auto"==z.rtlmode?(e=this.win[0]==J?this.body:this.win,n=e.css("writing-mode")||e.css("-webkit-writing-mode")||e.css("-ms-writing-mode")||e.css("-moz-writing-mode"),"horizontal-tb"==n||"lr-tb"==n||""===n?(this.isrtlmode="rtl"==e.css("direction"),this.isvertical=!1):(this.isrtlmode="vertical-rl"==n||"tb"==n||"tb-rl"==n||"rl-tb"==n,this.isvertical="vertical-rl"==
35
35
  n||"tb"==n||"tb-rl"==n)):(this.isrtlmode=!0===z.rtlmode,this.isvertical=!1);this.observerbody=this.observerremover=this.observer=this.scrollmom=this.scrollrunning=!1;if(!1!==z.scrollbarid)this.id=z.scrollbarid;else{do this.id="ascrail"+F++;while(w.getElementById(this.id))}this.hidden=this.locked=this.railslocked=this.hasmousefocus=this.hasfocus=this.zoomactive=this.zoom=this.selectiondrag=this.cursorfreezed=this.cursor=this.rail=!1;this.cursoractive=!0;this.wheelprevented=!1;this.overflowx=z.overflowx;
36
36
  this.overflowy=z.overflowy;this.nativescrollingarea=!1;this.checkarea=0;this.events=[];this.saved={};this.delaylist={};this.synclist={};this.lastdeltay=this.lastdeltax=0;this.detected=Y();var H=p.extend({},this.detected);this.ishwscroll=(this.canhwscroll=H.hastransform&&z.hwacceleration)&&b.haswrapper;this.hasreversehr=this.isrtlmode?this.isvertical?!(H.iswebkit||H.isie||H.isie11):!(H.iswebkit||H.isie&&!H.isie10&&!H.isie11):!1;this.istouchcapable=!1;H.cantouch||!H.hasw3ctouch&&!H.hasmstouch?!H.cantouch||
37
- H.isios||H.isandroid||!H.iswebkit&&!H.ismozilla||(this.istouchcapable=!0):this.istouchcapable=!0;z.enablemouselockapi||(H.hasmousecapture=!1,H.haspointerlock=!1);this.debounced=function(g,t,x){b&&(b.delaylist[g]||(b.delaylist[g]={h:P(function(){b.delaylist[g].fn.call(b);b.delaylist[g]=!1},x)},t.call(b)),b.delaylist[g].fn=t)};this.synched=function(g,t){b.synclist[g]?b.synclist[g]=t:(b.synclist[g]=t,P(function(){b&&(b.synclist[g]&&b.synclist[g].call(b),b.synclist[g]=null)}))};this.unsynched=function(g){b.synclist[g]&&
37
+ H.isios||H.isandroid||!H.iswebkit&&!H.ismozilla||(this.istouchcapable=!0):this.istouchcapable=!0;z.enablemouselockapi||(H.hasmousecapture=!1,H.haspointerlock=!1);this.debounced=function(g,t,x){b&&(b.delaylist[g]||(b.delaylist[g]={h:O(function(){b.delaylist[g].fn.call(b);b.delaylist[g]=!1},x)},t.call(b)),b.delaylist[g].fn=t)};this.synched=function(g,t){b.synclist[g]?b.synclist[g]=t:(b.synclist[g]=t,O(function(){b&&(b.synclist[g]&&b.synclist[g].call(b),b.synclist[g]=null)}))};this.unsynched=function(g){b.synclist[g]&&
38
38
  (b.synclist[g]=!1)};this.css=function(g,t){for(var x in t)b.saved.css.push([g,x,g.css(x)]),g.css(x,t[x])};this.scrollTop=function(g){return void 0===g?b.getScrollTop():b.setScrollTop(g)};this.scrollLeft=function(g){return void 0===g?b.getScrollLeft():b.setScrollLeft(g)};var ja=function(g,t,x,f,r,D,R){this.st=g;this.ed=t;this.spd=x;this.p1=f||0;this.p2=r||1;this.p3=D||0;this.p4=R||1;this.ts=aa();this.df=t-g};ja.prototype={B2:function(g){return 3*(1-g)*(1-g)*g},B3:function(g){return 3*(1-g)*g*g},B4:function(g){return g*
39
39
  g*g},getPos:function(){return(aa()-this.ts)/this.spd},getNow:function(){var g=(aa()-this.ts)/this.spd,t=this.B2(g)+this.B3(g)+this.B4(g);return 1<=g?this.ed:this.st+this.df*t|0},update:function(g,t){this.st=this.getNow();this.ed=g;this.spd=t;this.ts=aa();this.df=this.ed-this.st;return this}};if(this.ishwscroll){this.doc.translate={x:0,y:0,tx:"0px",ty:"0px"};H.hastranslate3d&&H.isios&&this.doc.css("-webkit-backface-visibility","hidden");this.getScrollTop=function(g){if(!g){if(g=m())return 16==g.length?
40
- -g[13]:-g[5];if(b.timerscroll&&b.timerscroll.bz)return b.timerscroll.bz.getNow()}return b.doc.translate.y};this.getScrollLeft=function(g){if(!g){if(g=m())return 16==g.length?-g[12]:-g[4];if(b.timerscroll&&b.timerscroll.bh)return b.timerscroll.bh.getNow()}return b.doc.translate.x};this.notifyScrollEvent=function(g){var t=w.createEvent("UIEvents");t.initUIEvent("scroll",!1,!1,I,1);t.niceevent=!0;g.dispatchEvent(t)};var d=this.isrtlmode?1:-1;H.hastranslate3d&&z.enabletranslate3d?(this.setScrollTop=function(g,
40
+ -g[13]:-g[5];if(b.timerscroll&&b.timerscroll.bz)return b.timerscroll.bz.getNow()}return b.doc.translate.y};this.getScrollLeft=function(g){if(!g){if(g=m())return 16==g.length?-g[12]:-g[4];if(b.timerscroll&&b.timerscroll.bh)return b.timerscroll.bh.getNow()}return b.doc.translate.x};this.notifyScrollEvent=function(g){var t=w.createEvent("UIEvents");t.initUIEvent("scroll",!1,!1,J,1);t.niceevent=!0;g.dispatchEvent(t)};var d=this.isrtlmode?1:-1;H.hastranslate3d&&z.enabletranslate3d?(this.setScrollTop=function(g,
41
41
  t){b.doc.translate.y=g;b.doc.translate.ty=-1*g+"px";b.doc.css(H.trstyle,"translate3d("+b.doc.translate.tx+","+b.doc.translate.ty+",0)");t||b.notifyScrollEvent(b.win[0])},this.setScrollLeft=function(g,t){b.doc.translate.x=g;b.doc.translate.tx=g*d+"px";b.doc.css(H.trstyle,"translate3d("+b.doc.translate.tx+","+b.doc.translate.ty+",0)");t||b.notifyScrollEvent(b.win[0])}):(this.setScrollTop=function(g,t){b.doc.translate.y=g;b.doc.translate.ty=-1*g+"px";b.doc.css(H.trstyle,"translate("+b.doc.translate.tx+
42
42
  ","+b.doc.translate.ty+")");t||b.notifyScrollEvent(b.win[0])},this.setScrollLeft=function(g,t){b.doc.translate.x=g;b.doc.translate.tx=g*d+"px";b.doc.css(H.trstyle,"translate("+b.doc.translate.tx+","+b.doc.translate.ty+")");t||b.notifyScrollEvent(b.win[0])})}else this.getScrollTop=function(){return b.docscroll.scrollTop()},this.setScrollTop=function(g){b.docscroll.scrollTop(g)},this.getScrollLeft=function(){return b.hasreversehr?b.detected.ismozilla?b.page.maxw-Math.abs(b.docscroll.scrollLeft()):b.page.maxw-
43
- b.docscroll.scrollLeft():b.docscroll.scrollLeft()},this.setScrollLeft=function(g){return setTimeout(function(){if(b)return b.hasreversehr&&(g=b.detected.ismozilla?-(b.page.maxw-g):b.page.maxw-g),b.docscroll.scrollLeft(g)},1)};this.getTarget=function(g){return g?g.target?g.target:g.srcElement?g.srcElement:!1:!1};this.hasParent=function(g,t){if(!g)return!1;for(g=g.target||g.srcElement||g||!1;g&&g.id!=t;)g=g.parentNode||!1;return!1!==g};var h={thin:1,medium:3,thick:5};this.getDocumentScrollOffset=function(){return{top:I.pageYOffset||
44
- w.documentElement.scrollTop,left:I.pageXOffset||w.documentElement.scrollLeft}};this.getOffset=function(){if(b.isfixed){var g=b.win.offset(),t=b.getDocumentScrollOffset();g.top-=t.top;g.left-=t.left;return g}g=b.win.offset();if(!b.viewport)return g;t=b.viewport.offset();return{top:g.top-t.top,left:g.left-t.left}};this.updateScrollBar=function(g){var t;if(b.ishwscroll)b.rail.css({height:b.win.innerHeight()-(z.railpadding.top+z.railpadding.bottom)}),b.railh&&b.railh.css({width:b.win.innerWidth()-(z.railpadding.left+
43
+ b.docscroll.scrollLeft():b.docscroll.scrollLeft()},this.setScrollLeft=function(g){return setTimeout(function(){if(b)return b.hasreversehr&&(g=b.detected.ismozilla?-(b.page.maxw-g):b.page.maxw-g),b.docscroll.scrollLeft(g)},1)};this.getTarget=function(g){return g?g.target?g.target:g.srcElement?g.srcElement:!1:!1};this.hasParent=function(g,t){if(!g)return!1;for(g=g.target||g.srcElement||g||!1;g&&g.id!=t;)g=g.parentNode||!1;return!1!==g};var h={thin:1,medium:3,thick:5};this.getDocumentScrollOffset=function(){return{top:J.pageYOffset||
44
+ w.documentElement.scrollTop,left:J.pageXOffset||w.documentElement.scrollLeft}};this.getOffset=function(){if(b.isfixed){var g=b.win.offset(),t=b.getDocumentScrollOffset();g.top-=t.top;g.left-=t.left;return g}g=b.win.offset();if(!b.viewport)return g;t=b.viewport.offset();return{top:g.top-t.top,left:g.left-t.left}};this.updateScrollBar=function(g){var t;if(b.ishwscroll)b.rail.css({height:b.win.innerHeight()-(z.railpadding.top+z.railpadding.bottom)}),b.railh&&b.railh.css({width:b.win.innerWidth()-(z.railpadding.left+
45
45
  z.railpadding.right)});else{var x=b.getOffset();var f=x.top;var r=x.left-(z.railpadding.left+z.railpadding.right);f+=l(b.win,"border-top-width",!0);r+=b.rail.align?b.win.outerWidth()-l(b.win,"border-right-width")-b.rail.width:l(b.win,"border-left-width");if(t=z.railoffset)t.top&&(f+=t.top),t.left&&(r+=t.left);g=(g?g.h:b.win.innerHeight())-(z.railpadding.top+z.railpadding.bottom);t="left";var D=r;"number"===typeof z.rightdock&&(t="right",D=z.rightdock);b.railslocked||b.rail.css({top:f,[t]:D,height:g});
46
46
  b.zoom&&b.zoom.css({top:f+1,left:1==b.rail.align?r-20:r+b.rail.width+4});if(b.railh&&!b.railslocked){f=x.top;r=x.left;if(t=z.railhoffset)t.top&&(f+=t.top),t.left&&(r+=t.left);f=b.railh.align?f+l(b.win,"border-top-width",!0)+b.win.innerHeight()-b.railh.height:f+l(b.win,"border-top-width",!0);r+=l(b.win,"border-left-width");b.railh.css({top:f-(z.railpadding.top+z.railpadding.bottom),left:r,width:b.railh.width})}}};this.doRailClick=function(g,t,x){if(!b.railslocked)if(b.cancelEvent(g),"pageY"in g||(g.pageX=
47
47
  g.clientX+w.documentElement.scrollLeft,g.pageY=g.clientY+w.documentElement.scrollTop),t){t=x?b.doScrollLeft:b.doScrollTop;var f=x?(g.pageX-b.railh.offset().left-b.cursorwidth/2)*b.scrollratio.x:(g.pageY-b.rail.offset().top-b.cursorheight/2)*b.scrollratio.y;b.unsynched("relativexy");t(f|0)}else t=x?b.doScrollLeftBy:b.doScrollBy,f=x?b.scroll.x:b.scroll.y,g=x?g.pageX-b.railh.offset().left:g.pageY-b.rail.offset().top,x=x?b.view.w:b.view.h,t(f>=g?x:-x)};b.newscrolly=b.newscrollx=0;b.hasanimationframe=
48
- "requestAnimationFrame"in I;b.hascancelanimationframe="cancelAnimationFrame"in I;b.hasborderbox=!1;this.init=function(){b.saved.css=[];if(H.isoperamini||H.isandroid&&!("hidden"in w))return!0;z.emulatetouch=z.emulatetouch||z.touchbehavior;b.hasborderbox=I.getComputedStyle&&"border-box"===I.getComputedStyle(w.body)["box-sizing"];var g={"overflow-y":"hidden"};if(H.isie11||H.isie10)g["-ms-overflow-style"]="none";b.ishwscroll&&(this.doc.css(H.transitionstyle,H.prefixstyle+"transform 0ms ease-out"),H.transitionend&&
49
- b.bind(b.doc,H.transitionend,b.onScrollTransitionEnd,!1));b.zindex="auto";b.zindex=b.ispage||"auto"!=z.zindex?z.zindex:c()||"auto";!b.ispage&&"auto"!=b.zindex&&b.zindex>J&&(J=b.zindex);b.isie&&0===b.zindex&&"auto"==z.zindex&&(b.zindex="auto");if(!b.ispage||!H.isieold){var t=b.docscroll;b.ispage&&(t=b.haswrapper?b.win:b.doc);b.css(t,g);b.ispage&&(H.isie11||H.isie)&&b.css(p("html"),g);!H.isios||b.ispage||b.haswrapper||b.css(O,{"-webkit-overflow-scrolling":"touch"});var x=p(w.createElement("div"));x.css({position:"relative",
48
+ "requestAnimationFrame"in J;b.hascancelanimationframe="cancelAnimationFrame"in J;b.hasborderbox=!1;this.init=function(){b.saved.css=[];if(H.isoperamini||H.isandroid&&!("hidden"in w))return!0;z.emulatetouch=z.emulatetouch||z.touchbehavior;b.hasborderbox=J.getComputedStyle&&"border-box"===J.getComputedStyle(w.body)["box-sizing"];var g={"overflow-y":"hidden"};if(H.isie11||H.isie10)g["-ms-overflow-style"]="none";b.ishwscroll&&(this.doc.css(H.transitionstyle,H.prefixstyle+"transform 0ms ease-out"),H.transitionend&&
49
+ b.bind(b.doc,H.transitionend,b.onScrollTransitionEnd,!1));b.zindex="auto";b.zindex=b.ispage||"auto"!=z.zindex?z.zindex:c()||"auto";!b.ispage&&"auto"!=b.zindex&&b.zindex>I&&(I=b.zindex);b.isie&&0===b.zindex&&"auto"==z.zindex&&(b.zindex="auto");if(!b.ispage||!H.isieold){var t=b.docscroll;b.ispage&&(t=b.haswrapper?b.win:b.doc);b.css(t,g);b.ispage&&(H.isie11||H.isie)&&b.css(p("html"),g);!H.isios||b.ispage||b.haswrapper||b.css(P,{"-webkit-overflow-scrolling":"touch"});var x=p(w.createElement("div"));x.css({position:"relative",
50
50
  top:0,"float":"right",width:z.cursorwidth,height:0,"background-color":z.cursorcolor,border:z.cursorborder,"background-clip":"padding-box","-webkit-border-radius":z.cursorborderradius,"-moz-border-radius":z.cursorborderradius,"border-radius":z.cursorborderradius});x.addClass("nicescroll-cursors");b.cursor=x;var f=p(w.createElement("div"));f.attr("id",b.id);f.addClass("nicescroll-rails nicescroll-rails-vr");z.scrollCLass&&f.addClass(z.scrollCLass);var r,D=["left","right","top","bottom"],R;for(R in D){var ea=
51
51
  D[R];(r=z.railpadding[ea]||0)&&f.css("padding-"+ea,r+"px")}f.append(x);f.width=Math.max(parseFloat(z.cursorwidth),x.outerWidth());f.css({width:f.width+"px",zIndex:b.zindex,background:z.background,cursor:"default"});f.visibility=!0;f.scrollable=!0;f.align="left"==z.railalign?0:1;b.rail=f;x=b.rail.drag=!1;!z.boxzoom||b.ispage||H.isieold||(x=w.createElement("div"),b.bind(x,"click",b.doZoom),b.bind(x,"mouseenter",function(){b.zoom.css("opacity",z.cursoropacitymax)}),b.bind(x,"mouseleave",function(){b.zoom.css("opacity",
52
52
  z.cursoropacitymin)}),b.zoom=p(x),b.zoom.css({cursor:"pointer",zIndex:b.zindex,backgroundImage:"url("+z.scriptpath+"zoomico.png)",height:18,width:18,backgroundPosition:"0 0"}),z.dblclickzoom&&b.bind(b.win,"dblclick",b.doZoom),H.cantouch&&z.gesturezoom&&(b.ongesturezoom=function(E){1.5<E.scale&&b.doZoomIn(E);.8>E.scale&&b.doZoomOut(E);return b.cancelEvent(E)},b.bind(b.win,"gestureend",b.ongesturezoom)));b.railh=!1;if(z.horizrailenabled){b.css(t,{overflowX:"hidden"});x=p(w.createElement("div"));x.css({position:"absolute",
@@ -56,7 +56,7 @@ x.outerHeight());da.css({height:da.height+"px",zIndex:b.zindex,background:z.back
56
56
  /fixed|absolute/.test(b.viewport.css("position"))||b.css(b.viewport,{position:"relative"})),f.css({position:t}),b.zoom&&b.zoom.css({position:t}),b.updateScrollBar(),b.body.append(f),b.zoom&&b.body.append(b.zoom),b.railh&&(da.css({position:t}),b.body.append(da))),H.isios&&b.css(b.win,{"-webkit-tap-highlight-color":"rgba(0,0,0,0)","-webkit-touch-callout":"none"}),z.disableoutline&&(H.isie&&b.win.attr("hideFocus","true"),H.iswebkit&&b.win.css("outline","none")));!1===z.autohidemode?(b.autohidedom=!1,
57
57
  b.rail.css({opacity:z.cursoropacitymax}),b.railh&&b.railh.css({opacity:z.cursoropacitymax})):!0===z.autohidemode||"leave"===z.autohidemode?(b.autohidedom=p().add(b.rail),H.isie8&&(b.autohidedom=b.autohidedom.add(b.cursor)),b.railh&&(b.autohidedom=b.autohidedom.add(b.railh)),b.railh&&H.isie8&&(b.autohidedom=b.autohidedom.add(b.cursorh))):"scroll"==z.autohidemode?(b.autohidedom=p().add(b.rail),b.railh&&(b.autohidedom=b.autohidedom.add(b.railh))):"cursor"==z.autohidemode?(b.autohidedom=p().add(b.cursor),
58
58
  b.railh&&(b.autohidedom=b.autohidedom.add(b.cursorh))):"hidden"==z.autohidemode&&(b.autohidedom=!1,b.hide(),b.railslocked=!1);if(H.cantouch||b.istouchcapable||z.emulatetouch||H.hasmstouch){b.scrollmom=new ia(b);b.ontouchstart=function(E){if(b.locked||E.pointerType&&("mouse"===E.pointerType||E.pointerType===E.MSPOINTER_TYPE_MOUSE))return!1;b.hasmoving=!1;b.scrollmom.timer&&(b.triggerScrollEnd(),b.scrollmom.stop());if(!b.railslocked){var X=b.getTarget(E);if(X&&/INPUT/i.test(X.nodeName)&&/range/i.test(X.type))return b.stopPropagation(E);
59
- var pa="mousedown"===E.type;!("clientX"in E)&&"changedTouches"in E&&(E.clientX=E.changedTouches[0].clientX,E.clientY=E.changedTouches[0].clientY);if(b.forcescreen){var ra=E;E={original:E.original?E.original:E};E.clientX=ra.screenX;E.clientY=ra.screenY}b.rail.drag={x:E.clientX,y:E.clientY,sx:b.scroll.x,sy:b.scroll.y,st:b.getScrollTop(),sl:b.getScrollLeft(),pt:2,dl:!1,tg:X};if(b.ispage||!z.directionlockdeadzone)b.rail.drag.dl="f";else{ra=L.width();var sa=L.height(),Ea=b.getContentSize();sa=Ea.h-sa;
59
+ var pa="mousedown"===E.type;!("clientX"in E)&&"changedTouches"in E&&(E.clientX=E.changedTouches[0].clientX,E.clientY=E.changedTouches[0].clientY);if(b.forcescreen){var ra=E;E={original:E.original?E.original:E};E.clientX=ra.screenX;E.clientY=ra.screenY}b.rail.drag={x:E.clientX,y:E.clientY,sx:b.scroll.x,sy:b.scroll.y,st:b.getScrollTop(),sl:b.getScrollLeft(),pt:2,dl:!1,tg:X};if(b.ispage||!z.directionlockdeadzone)b.rail.drag.dl="f";else{ra=K.width();var sa=K.height(),Ea=b.getContentSize();sa=Ea.h-sa;
60
60
  ra=Ea.w-ra;b.rail.drag.ck=b.rail.scrollable&&!b.railh.scrollable?0<sa?"v":!1:!b.rail.scrollable&&b.railh.scrollable?0<ra?"h":!1:!1}z.emulatetouch&&b.isiframe&&H.isie&&(ra=b.win.position(),b.rail.drag.x+=ra.left,b.rail.drag.y+=ra.top);b.hasmoving=!1;b.lastmouseup=!1;b.scrollmom.reset(E.clientX,E.clientY);if(X&&pa){if(!/INPUT|SELECT|BUTTON|TEXTAREA/i.test(X.nodeName))return H.hasmousecapture&&X.setCapture(),z.emulatetouch?(X.onclick&&!X._onclick&&(X._onclick=X.onclick,X.onclick=function(va){if(b.hasmoving)return!1;
61
61
  X._onclick.call(this,va)}),b.cancelEvent(E)):b.stopPropagation(E);/SUBMIT|CANCEL|BUTTON/i.test(p(X).attr("type"))&&(b.preventclick={tg:X,click:!1})}}};b.ontouchend=function(E){if(!b||!b.rail.drag)return!0;if(2==b.rail.drag.pt){if(E.pointerType&&("mouse"===E.pointerType||E.pointerType===E.MSPOINTER_TYPE_MOUSE))return!1;b.rail.drag=!1;var X="mouseup"===E.type;if(b.hasmoving&&(b.scrollmom.doMomentum(),b.lastmouseup=!0,b.hideCursor(),H.hasmousecapture&&w.releaseCapture(),X))return b.cancelEvent(E)}else if(1==
62
62
  b.rail.drag.pt)return b.onmouseup(E)};var wa=z.emulatetouch&&b.isiframe&&!H.hasmousecapture,ta=.3*z.directionlockdeadzone|0;b.ontouchmove=function(E,X){if(!b||!b.rail.drag||E.targetTouches&&z.preventmultitouchscrolling&&1<E.targetTouches.length||E.pointerType&&("mouse"===E.pointerType||E.pointerType===E.MSPOINTER_TYPE_MOUSE))return!0;if(2==b.rail.drag.pt){"changedTouches"in E&&(E.clientX=E.changedTouches[0].clientX,E.clientY=E.changedTouches[0].clientY);var pa;var ra=pa=0;wa&&!X&&(X=b.win.position(),
@@ -80,13 +80,13 @@ b.ontouchendCursor));z.emulatetouch||H.isandroid||H.isios?(b.bind(H.hasmousecapt
80
80
  (b.bind(H.hasmousecapture?b.win:w,"mouseup",b.onmouseup),b.bind(w,"mousemove",b.onmousemove),b.onclick&&b.bind(w,"click",b.onclick),b.bind(b.cursor,"mousedown",b.onmousedown),b.bind(b.cursor,"mouseup",b.onmouseup),b.railh&&(b.bind(b.cursorh,"mousedown",function(E){b.onmousedown(E,!0)}),b.bind(b.cursorh,"mouseup",b.onmouseup)),!b.ispage&&z.enablescrollonselection&&(b.bind(b.win[0],"mousedown",b.onselectionstart),b.bind(w,"mouseup",b.onselectionend),b.bind(b.cursor,"mouseup",b.onselectionend),b.cursorh&&
81
81
  b.bind(b.cursorh,"mouseup",b.onselectionend),b.bind(w,"mousemove",b.onselectiondrag)),b.zoom&&(b.jqbind(b.zoom,"mouseenter",function(){b.canshowonmouseevent&&b.showCursor();b.rail.active=!0}),b.jqbind(b.zoom,"mouseleave",function(){b.rail.active=!1;b.rail.drag||b.hideCursor()})));z.enablemousewheel&&(b.isiframe||b.mousewheel(H.isie&&b.ispage?w:b.win,b.onmousewheel),b.mousewheel(b.rail,b.onmousewheel),b.railh&&b.mousewheel(b.railh,b.onmousewheelhr));b.ispage||H.cantouch||/HTML|^BODY/.test(b.win[0].nodeName)||
82
82
  (b.win.attr("tabindex")||b.win.attr({tabindex:++y}),b.bind(b.win,"focus",function(E){B=b.getTarget(E).id||b.getTarget(E)||!1;b.hasfocus=!0;b.canshowonmouseevent&&b.noticeCursor()}),b.bind(b.win,"blur",function(E){B=!1;b.hasfocus=!1}),b.bind(b.win,"mouseenter",function(E){u=b.getTarget(E).id||b.getTarget(E)||!1;b.hasmousefocus=!0;b.canshowonmouseevent&&b.noticeCursor()}),b.bind(b.win,"mouseleave",function(E){u=!1;b.hasmousefocus=!1;b.rail.drag||b.hideCursor()}));b.onkeypress=function(E){if(b.railslocked&&
83
- 0===b.page.maxh)return!0;E=E||I.event;var X=b.getTarget(E);if(X&&/INPUT|TEXTAREA|SELECT|OPTION/.test(X.nodeName)&&(!X.getAttribute("type")&&!X.type||!/submit|button|cancel/i.tp)||p(X).attr("contenteditable"))return!0;if(b.hasfocus||b.hasmousefocus&&!B||b.ispage&&!B&&!u){X=E.keyCode;if(b.railslocked&&27!=X)return b.cancelEvent(E);var pa=E.ctrlKey||!1,ra=E.shiftKey||!1,sa=!1;switch(X){case 38:case 63233:b.doScrollBy(72);sa=!0;break;case 40:case 63235:b.doScrollBy(-72);sa=!0;break;case 37:case 63232:b.railh&&
83
+ 0===b.page.maxh)return!0;E=E||J.event;var X=b.getTarget(E);if(X&&/INPUT|TEXTAREA|SELECT|OPTION/.test(X.nodeName)&&(!X.getAttribute("type")&&!X.type||!/submit|button|cancel/i.tp)||p(X).attr("contenteditable"))return!0;if(b.hasfocus||b.hasmousefocus&&!B||b.ispage&&!B&&!u){X=E.keyCode;if(b.railslocked&&27!=X)return b.cancelEvent(E);var pa=E.ctrlKey||!1,ra=E.shiftKey||!1,sa=!1;switch(X){case 38:case 63233:b.doScrollBy(72);sa=!0;break;case 40:case 63235:b.doScrollBy(-72);sa=!0;break;case 37:case 63232:b.railh&&
84
84
  (pa?b.doScrollLeft(0):b.doScrollLeftBy(72),sa=!0);break;case 39:case 63234:b.railh&&(pa?b.doScrollLeft(b.page.maxw):b.doScrollLeftBy(-72),sa=!0);break;case 33:case 63276:b.doScrollBy(b.view.h);sa=!0;break;case 34:case 63277:b.doScrollBy(-b.view.h);sa=!0;break;case 36:case 63273:b.railh&&pa?b.doScrollPos(0,0):b.doScrollTo(0);sa=!0;break;case 35:case 63275:b.railh&&pa?b.doScrollPos(b.page.maxw,b.page.maxh):b.doScrollTo(b.page.maxh);sa=!0;break;case 32:z.spacebarenabled&&(ra?b.doScrollBy(b.view.h):b.doScrollBy(-b.view.h),
85
- sa=!0);break;case 27:b.zoomactive&&(b.doZoom(),sa=!0)}if(sa)return b.cancelEvent(E)}};z.enablekeyboard&&b.bind(w,H.isopera&&!H.isopera12?"keypress":"keydown",b.onkeypress);b.bind(w,"keydown",function(E){E.ctrlKey&&(b.wheelprevented=!0)});b.bind(w,"keyup",function(E){E.ctrlKey||(b.wheelprevented=!1)});b.bind(I,"blur",function(E){b.wheelprevented=!1});b.bind(I,"resize",b.onscreenresize);b.bind(I,"orientationchange",b.onscreenresize);b.bind(I,"load",b.lazyResize);if(H.ischrome&&!b.ispage&&!b.haswrapper){var Aa=
86
- b.win.attr("style");f=parseFloat(b.win.css("width"))+1;b.win.css("width",f);b.synched("chromefix",function(){b.win.attr("style",Aa)})}b.onAttributeChange=function(E){b.lazyResize(b.isieold?250:30)};if(z.enableobserver&&(b.isie11||!1===ba||(b.observerbody=new ba(function(E){E.forEach(function(X){if("attributes"==X.type)return O.hasClass("modal-open")&&O.hasClass("modal-dialog")&&!p.contains(p(".modal-dialog")[0],b.doc[0])?b.hide():b.show()});if(b.me.clientWidth!=b.page.width||b.me.clientHeight!=b.page.height)return b.lazyResize(30)}),
85
+ sa=!0);break;case 27:b.zoomactive&&(b.doZoom(),sa=!0)}if(sa)return b.cancelEvent(E)}};z.enablekeyboard&&b.bind(w,H.isopera&&!H.isopera12?"keypress":"keydown",b.onkeypress);b.bind(w,"keydown",function(E){E.ctrlKey&&(b.wheelprevented=!0)});b.bind(w,"keyup",function(E){E.ctrlKey||(b.wheelprevented=!1)});b.bind(J,"blur",function(E){b.wheelprevented=!1});b.bind(J,"resize",b.onscreenresize);b.bind(J,"orientationchange",b.onscreenresize);b.bind(J,"load",b.lazyResize);if(H.ischrome&&!b.ispage&&!b.haswrapper){var Aa=
86
+ b.win.attr("style");f=parseFloat(b.win.css("width"))+1;b.win.css("width",f);b.synched("chromefix",function(){b.win.attr("style",Aa)})}b.onAttributeChange=function(E){b.lazyResize(b.isieold?250:30)};if(z.enableobserver&&(b.isie11||!1===ba||(b.observerbody=new ba(function(E){E.forEach(function(X){if("attributes"==X.type)return P.hasClass("modal-open")&&P.hasClass("modal-dialog")&&!p.contains(p(".modal-dialog")[0],b.doc[0])?b.hide():b.show()});if(b.me.clientWidth!=b.page.width||b.me.clientHeight!=b.page.height)return b.lazyResize(30)}),
87
87
  b.observerbody.observe(w.body,{childList:!0,subtree:!0,characterData:!1,attributes:!0,attributeFilter:["class"]})),!b.ispage&&!b.haswrapper)){var ya=b.win[0];!1!==ba?(b.observer=new ba(function(E){E.forEach(b.onAttributeChange)}),b.observer.observe(ya,{childList:!0,characterData:!1,attributes:!0,subtree:!1}),b.observerremover=new ba(function(E){E.forEach(function(X){if(0<X.removedNodes.length)for(var pa in X.removedNodes)if(b&&X.removedNodes[pa]===ya)return b.remove()})}),b.observerremover.observe(ya.parentNode,
88
- {childList:!0,characterData:!1,attributes:!1,subtree:!1})):(b.bind(ya,H.isie&&!H.isie9?"propertychange":"DOMAttrModified",b.onAttributeChange),H.isie9&&ya.attachEvent("onpropertychange",b.onAttributeChange),b.bind(ya,"DOMNodeRemoved",function(E){E.target===ya&&b.remove()}))}!b.ispage&&z.boxzoom&&b.bind(I,"resize",b.resizeZoom);b.istextarea&&(b.bind(b.win,"keydown",b.lazyResize),b.bind(b.win,"mouseup",b.lazyResize));b.lazyResize(30)}if("IFRAME"==this.doc[0].nodeName){var za=function(){b.iframexd=!1;
89
- try{var E="contentDocument"in this?this.contentDocument:this.contentWindow._doc}catch(pa){b.iframexd=!0,E=!1}if(b.iframexd)return"console"in I&&console.log("NiceScroll error: policy restriced iframe"),!0;b.forcescreen=!0;b.isiframe&&(b.iframe={doc:p(E),html:b.doc.contents().find("html")[0],body:b.doc.contents().find("body")[0]},b.getContentSize=function(){return{w:Math.max(b.iframe.html.scrollWidth,b.iframe.body.scrollWidth),h:Math.max(b.iframe.html.scrollHeight,b.iframe.body.scrollHeight)}},b.docscroll=
88
+ {childList:!0,characterData:!1,attributes:!1,subtree:!1})):(b.bind(ya,H.isie&&!H.isie9?"propertychange":"DOMAttrModified",b.onAttributeChange),H.isie9&&ya.attachEvent("onpropertychange",b.onAttributeChange),b.bind(ya,"DOMNodeRemoved",function(E){E.target===ya&&b.remove()}))}!b.ispage&&z.boxzoom&&b.bind(J,"resize",b.resizeZoom);b.istextarea&&(b.bind(b.win,"keydown",b.lazyResize),b.bind(b.win,"mouseup",b.lazyResize));b.lazyResize(30)}if("IFRAME"==this.doc[0].nodeName){var za=function(){b.iframexd=!1;
89
+ try{var E="contentDocument"in this?this.contentDocument:this.contentWindow._doc}catch(pa){b.iframexd=!0,E=!1}if(b.iframexd)return"console"in J&&console.log("NiceScroll error: policy restriced iframe"),!0;b.forcescreen=!0;b.isiframe&&(b.iframe={doc:p(E),html:b.doc.contents().find("html")[0],body:b.doc.contents().find("body")[0]},b.getContentSize=function(){return{w:Math.max(b.iframe.html.scrollWidth,b.iframe.body.scrollWidth),h:Math.max(b.iframe.html.scrollHeight,b.iframe.body.scrollHeight)}},b.docscroll=
90
90
  p(b.iframe.body));if(!H.isios&&z.iframeautoresize&&!b.isiframe){b.win.scrollTop(0);b.doc.height("");var X=Math.max(E.getElementsByTagName("html")[0].scrollHeight,E.body.scrollHeight);b.doc.height(X)}b.lazyResize(30);b.css(p(b.iframe.body),g);H.isios&&b.haswrapper&&b.css(p(E.body),{"-webkit-transform":"translate3d(0,0,0)"});"contentWindow"in this?b.bind(this.contentWindow,"scroll",b.onscroll):b.bind(E,"scroll",b.onscroll);z.enablemousewheel&&b.mousewheel(E,b.onmousewheel);z.enablekeyboard&&b.bind(E,
91
91
  H.isopera?"keypress":"keydown",b.onkeypress);H.cantouch?(b.bind(E,"touchstart",b.ontouchstart),b.bind(E,"touchmove",b.ontouchmove)):z.emulatetouch&&(b.bind(E,"mousedown",b.ontouchstart),b.bind(E,"mousemove",function(pa){return b.ontouchmove(pa,!0)}),z.grabcursorenabled&&H.cursorgrabvalue&&b.css(p(E.body),{cursor:H.cursorgrabvalue}));b.bind(E,"mouseup",b.ontouchend);b.zoom&&(z.dblclickzoom&&b.bind(E,"dblclick",b.doZoom),b.ongesturezoom&&b.bind(E,"gestureend",b.ongesturezoom))};this.doc[0].readyState&&
92
92
  "complete"===this.doc[0].readyState&&setTimeout(function(){za.call(b.doc[0],!1)},500);b.bind(this.doc,"load",za)}};this.showCursor=function(g,t){b.cursortimeout&&(clearTimeout(b.cursortimeout),b.cursortimeout=0);b.rail&&(b.autohidedom&&(b.autohidedom.stop().css({opacity:z.cursoropacitymax}),b.cursoractive=!0),b.rail.drag&&1==b.rail.drag.pt||(void 0!==g&&!1!==g&&(b.scroll.y=g/b.scrollratio.y|0),void 0!==t&&(b.scroll.x=t/b.scrollratio.x|0)),b.cursor.css({height:b.cursorheight,top:b.scroll.y}),b.cursorh&&
@@ -98,10 +98,10 @@ t){if(!b||!b.win)return!1;g=b.page.maxh;var x=b.page.maxw,f=b.view.h,r=b.view.w;
98
98
  z.cursorfixedheight?z.cursorfixedheight:Math.max(z.cursorminheight,b.cursorwidth);b.scrollvaluemax=b.view.h-b.cursorheight-(z.railpadding.top+z.railpadding.bottom);b.hasborderbox||(b.scrollvaluemax-=b.cursor[0].offsetHeight-b.cursor[0].clientHeight);b.railh&&(b.railh.width=0<b.page.maxh?b.view.w-b.rail.width:b.view.w,b.scrollvaluemaxw=b.railh.width-b.cursorwidth-(z.railpadding.left+z.railpadding.right));b.ispage||b.updateScrollBar(b.view);b.scrollratio={x:b.page.maxw/b.scrollvaluemaxw,y:b.page.maxh/
99
99
  b.scrollvaluemax};b.getScrollTop()>b.page.maxh?b.doScrollTop(b.page.maxh):(b.scroll.y=b.getScrollTop()/b.scrollratio.y|0,b.scroll.x=b.getScrollLeft()/b.scrollratio.x|0,b.cursoractive&&b.noticeCursor());b.scroll.y&&0===b.getScrollTop()&&b.doScrollTo(b.scroll.y*b.scrollratio.y|0);return b};this.resize=b.onResize;var q=0;this.onscreenresize=function(g){clearTimeout(q);var t=!b.ispage&&!b.haswrapper;t&&b.hideRails();q=setTimeout(function(){b&&(t&&b.showRails(),b.resize());q=0},120)};this.lazyResize=function(g){clearTimeout(q);
100
100
  g=isNaN(g)?240:g;q=setTimeout(function(){b&&b.resize();q=0},g);return b};this.jqbind=function(g,t,x){b.events.push({e:g,n:t,f:x,q:!0});p(g).on(t,x)};this.mousewheel=function(g,t,x){g="jquery"in g?g[0]:g;if("onwheel"in w.createElement("div"))b._bind(g,"wheel",t,x||!1);else{var f=void 0!==w.onmousewheel?"mousewheel":"DOMMouseScroll";v(g,f,t,x||!1);"DOMMouseScroll"==f&&v(g,"MozMousePixelScroll",t,x||!1)}};var C=!1;if(H.haseventlistener){try{var G=Object.defineProperty({},"passive",{get:function(){C=
101
- !0}});I.addEventListener("test",null,G)}catch(g){}this.stopPropagation=function(g){if(!g)return!1;g=g.original?g.original:g;g.stopPropagation();return!1};this.cancelEvent=function(g){g.cancelable&&g.preventDefault();g.stopImmediatePropagation();g.preventManipulation&&g.preventManipulation();return!1}}else Event.prototype.preventDefault=function(){this.returnValue=!1},Event.prototype.stopPropagation=function(){this.cancelBubble=!0},I.constructor.prototype.addEventListener=w.constructor.prototype.addEventListener=
102
- Element.prototype.addEventListener=function(g,t,x){this.attachEvent("on"+g,t)},I.constructor.prototype.removeEventListener=w.constructor.prototype.removeEventListener=Element.prototype.removeEventListener=function(g,t,x){this.detachEvent("on"+g,t)},this.cancelEvent=function(g){if(g=g||I.event)g.cancelBubble=!0,g.cancel=!0,g.returnValue=!1;return!1},this.stopPropagation=function(g){if(g=g||I.event)g.cancelBubble=!0;return!1};this.delegate=function(g,t,x,f,r){var D=M[t]||!1;D?b.events.push({e:g,n:t,
103
- f:x,b:f,q:!1}):(D={a:[],l:[],f:function(R){for(var ea=D.l,da=!1,wa=ea.length-1;0<=wa;wa--)if(da=ea[wa].call(R.target,R),!1===da)return!1;return da}},b.bind(g,t,D.f,f,r),M[t]=D);b.ispage?(D.a=[b.id].concat(D.a),D.l=[x].concat(D.l)):(D.a.push(b.id),D.l.push(x))};this.undelegate=function(g,t,x,f,r){if((x=M[t]||!1)&&x.l)for(f=0,r=x.l.length;f<r;f++)x.a[f]===b.id&&(x.a.splice(f),x.l.splice(f),0===x.a.length&&(b._unbind(g,t,x.l.f),M[t]=null))};this.bind=function(g,t,x,f,r){b._bind("jquery"in g?g[0]:g,t,
104
- x,f||!1,r||!1)};this._bind=function(g,t,x,f,r){b.events.push({e:g,n:t,f:x,b:f,q:!1});C&&(r||g==I.document||g==I.document.body||g==I)?g.addEventListener(t,x,{passive:!1,capture:f}):g.addEventListener(t,x,f||!1)};this._unbind=function(g,t,x,f){M[t]?b.undelegate(g,t,x,f):g.removeEventListener(t,x,f)};this.unbindAll=function(){for(var g=0;g<b.events.length;g++){var t=b.events[g];t.q?t.e.unbind(t.n,t.f):b._unbind(t.e,t.n,t.f,t.b)}};this.showRails=function(){return b.showRail().showRailHr()};this.showRail=
101
+ !0}});J.addEventListener("test",null,G)}catch(g){}this.stopPropagation=function(g){if(!g)return!1;g=g.original?g.original:g;g.stopPropagation();return!1};this.cancelEvent=function(g){g.cancelable&&g.preventDefault();g.stopImmediatePropagation();g.preventManipulation&&g.preventManipulation();return!1}}else Event.prototype.preventDefault=function(){this.returnValue=!1},Event.prototype.stopPropagation=function(){this.cancelBubble=!0},J.constructor.prototype.addEventListener=w.constructor.prototype.addEventListener=
102
+ Element.prototype.addEventListener=function(g,t,x){this.attachEvent("on"+g,t)},J.constructor.prototype.removeEventListener=w.constructor.prototype.removeEventListener=Element.prototype.removeEventListener=function(g,t,x){this.detachEvent("on"+g,t)},this.cancelEvent=function(g){if(g=g||J.event)g.cancelBubble=!0,g.cancel=!0,g.returnValue=!1;return!1},this.stopPropagation=function(g){if(g=g||J.event)g.cancelBubble=!0;return!1};this.delegate=function(g,t,x,f,r){var D=L[t]||!1;D?b.events.push({e:g,n:t,
103
+ f:x,b:f,q:!1}):(D={a:[],l:[],f:function(R){for(var ea=D.l,da=!1,wa=ea.length-1;0<=wa;wa--)if(da=ea[wa].call(R.target,R),!1===da)return!1;return da}},b.bind(g,t,D.f,f,r),L[t]=D);b.ispage?(D.a=[b.id].concat(D.a),D.l=[x].concat(D.l)):(D.a.push(b.id),D.l.push(x))};this.undelegate=function(g,t,x,f,r){if((x=L[t]||!1)&&x.l)for(f=0,r=x.l.length;f<r;f++)x.a[f]===b.id&&(x.a.splice(f),x.l.splice(f),0===x.a.length&&(b._unbind(g,t,x.l.f),L[t]=null))};this.bind=function(g,t,x,f,r){b._bind("jquery"in g?g[0]:g,t,
104
+ x,f||!1,r||!1)};this._bind=function(g,t,x,f,r){b.events.push({e:g,n:t,f:x,b:f,q:!1});C&&(r||g==J.document||g==J.document.body||g==J)?g.addEventListener(t,x,{passive:!1,capture:f}):g.addEventListener(t,x,f||!1)};this._unbind=function(g,t,x,f){L[t]?b.undelegate(g,t,x,f):g.removeEventListener(t,x,f)};this.unbindAll=function(){for(var g=0;g<b.events.length;g++){var t=b.events[g];t.q?t.e.unbind(t.n,t.f):b._unbind(t.e,t.n,t.f,t.b)}};this.showRails=function(){return b.showRail().showRailHr()};this.showRail=
105
105
  function(){0===b.page.maxh||!b.ispage&&"none"==b.win.css("display")||(b.rail.visibility=!0,b.rail.css("display","block"));return b};this.showRailHr=function(){b.railh&&0!==b.page.maxw&&(b.ispage||"none"!=b.win.css("display"))&&(b.railh.visibility=!0,b.railh.css("display","block"));return b};this.hideRails=function(){return b.hideRail().hideRailHr()};this.hideRail=function(){b.rail.visibility=!1;b.rail.css("display","none");return b};this.hideRailHr=function(){b.railh&&(b.railh.visibility=!1,b.railh.css("display",
106
106
  "none"));return b};this.show=function(){b.hidden=!1;b.railslocked=!1;return b.showRails()};this.hide=function(){b.hidden=!0;b.railslocked=!0;return b.hideRails()};this.toggle=function(){return b.hidden?b.show():b.hide()};this.remove=function(){b.stop();b.cursortimeout&&clearTimeout(b.cursortimeout);for(var g in b.delaylist)b.delaylist[g]&&Q(b.delaylist[g].h);b.doZoomOut();H.hasw3ctouch?b.undelegate(w,"pointermove",b.ontouchmove):H.hasmstouch?b.undelegate(w,"MSPointerMove",b.ontouchmove):H.cantouch&&
107
107
  b.undelegate(w,"touchmove",b.ontouchmove,!1,!0);b.unbindAll();H.isie9&&b.win[0].detachEvent("onpropertychange",b.onAttributeChange);!1!==b.observer&&b.observer.disconnect();!1!==b.observerremover&&b.observerremover.disconnect();!1!==b.observerbody&&b.observerbody.disconnect();b.events=null;b.cursor&&b.cursor.remove();b.cursorh&&b.cursorh.remove();b.rail&&b.rail.remove();b.railh&&b.railh.remove();b.zoom&&b.zoom.remove();for(g=0;g<b.saved.css.length;g++){var t=b.saved.css[g];t[0].css(t[1],void 0===
@@ -109,158 +109,159 @@ t[2]?"":t[2])}b.saved=!1;b.me.data("__nicescroll","");var x=p.nicescroll;x.each(
109
109
  function(g){this.onzoomout=g;return b};this.isScrollable=function(g){g=g.target?g.target:g;if("OPTION"==g.nodeName)return!0;for(;g&&1==g.nodeType&&g!==this.me[0]&&!/^BODY|HTML/.test(g.nodeName);){var t=p(g);t=t.css("overflowY")||t.css("overflowX")||t.css("overflow")||"";if(/scroll|auto/.test(t))return g.clientHeight!=g.scrollHeight;g=g.parentNode?g.parentNode:!1}return!1};this.getViewport=function(g){for(g=g&&g.parentNode?g.parentNode:!1;g&&1==g.nodeType&&!/^BODY|HTML/.test(g.nodeName);){var t=p(g);
110
110
  if(/fixed|absolute/.test(t.css("position")))return t;var x=t.css("overflowY")||t.css("overflowX")||t.css("overflow")||"";if(/scroll|auto/.test(x)&&g.clientHeight!=g.scrollHeight||0<t.getNiceScroll().length)return t;g=g.parentNode?g.parentNode:!1}return!1};this.triggerScrollStart=function(g,t,x,f,r){b.onscrollstart&&b.onscrollstart.call(b,{type:"scrollstart",current:{x:g,y:t},request:{x,y:f},end:{x:b.newscrollx,y:b.newscrolly},speed:r})};this.triggerScrollEnd=function(){if(b.onscrollend){var g=b.getScrollLeft(),
111
111
  t=b.getScrollTop();b.onscrollend.call(b,{type:"scrollend",current:{x:g,y:t},end:{x:g,y:t}})}};var N=0,U=0,S=0,T=1,V=!1;this.onmousewheel=function(g){if(b.wheelprevented||b.locked)return!1;if(b.railslocked)return b.debounced("checkunlock",b.resize,250),!1;if(b.rail.drag)return b.cancelEvent(g);"auto"===z.oneaxismousemode&&0!==g.deltaX&&(z.oneaxismousemode=!1);if(z.oneaxismousemode&&0===g.deltaX&&!b.rail.scrollable)return b.railh&&b.railh.scrollable?b.onmousewheelhr(g):!0;var t=aa(),x=!1;z.preservenativescrolling&&
112
- b.checkarea+600<t&&(b.nativescrollingarea=b.isScrollable(g),x=!0);b.checkarea=t;if(b.nativescrollingarea)return!0;if(g=K(g,!1,x))b.checkarea=0;return g};this.onmousewheelhr=function(g){if(!b.wheelprevented){if(b.railslocked||!b.railh.scrollable)return!0;if(b.rail.drag)return b.cancelEvent(g);var t=aa(),x=!1;z.preservenativescrolling&&b.checkarea+600<t&&(b.nativescrollingarea=b.isScrollable(g),x=!0);b.checkarea=t;return b.nativescrollingarea?!0:b.railslocked?b.cancelEvent(g):K(g,!0,x)}};this.stop=
112
+ b.checkarea+600<t&&(b.nativescrollingarea=b.isScrollable(g),x=!0);b.checkarea=t;if(b.nativescrollingarea)return!0;if(g=M(g,!1,x))b.checkarea=0;return g};this.onmousewheelhr=function(g){if(!b.wheelprevented){if(b.railslocked||!b.railh.scrollable)return!0;if(b.rail.drag)return b.cancelEvent(g);var t=aa(),x=!1;z.preservenativescrolling&&b.checkarea+600<t&&(b.nativescrollingarea=b.isScrollable(g),x=!0);b.checkarea=t;return b.nativescrollingarea?!0:b.railslocked?b.cancelEvent(g):M(g,!0,x)}};this.stop=
113
113
  function(){b.cancelScroll();b.scrollmon&&b.scrollmon.stop();b.cursorfreezed=!1;b.scroll.y=Math.round(b.getScrollTop()*(1/b.scrollratio.y));b.noticeCursor();return b};this.getTransitionSpeed=function(g){return 80+g/72*z.scrollspeed|0};if(z.smoothscroll)if(b.ishwscroll&&H.hastransition&&z.usetransition&&z.smoothscroll){var W="";this.resetTransition=function(){W="";b.doc.css(H.prefixstyle+"transition-duration","0ms")};this.prepareTransition=function(g,t){g=t?g:b.getTransitionSpeed(g);t=g+"ms";W!==t&&
114
- (W=t,b.doc.css(H.prefixstyle+"transition-duration",t));return g};this.doScrollLeft=function(g,t){var x=b.scrollrunning?b.newscrolly:b.getScrollTop();b.doScrollPos(g,x,t)};this.doScrollTop=function(g,t){var x=b.scrollrunning?b.newscrollx:b.getScrollLeft();b.doScrollPos(x,g,t)};this.cursorupdate={running:!1,start:function(){var g=this;if(!g.running){g.running=!0;var t=function(){g.running&&P(t);b.showCursor(b.getScrollTop(),b.getScrollLeft());b.notifyScrollEvent(b.win[0])};P(t)}},stop:function(){this.running=
114
+ (W=t,b.doc.css(H.prefixstyle+"transition-duration",t));return g};this.doScrollLeft=function(g,t){var x=b.scrollrunning?b.newscrolly:b.getScrollTop();b.doScrollPos(g,x,t)};this.doScrollTop=function(g,t){var x=b.scrollrunning?b.newscrollx:b.getScrollLeft();b.doScrollPos(x,g,t)};this.cursorupdate={running:!1,start:function(){var g=this;if(!g.running){g.running=!0;var t=function(){g.running&&O(t);b.showCursor(b.getScrollTop(),b.getScrollLeft());b.notifyScrollEvent(b.win[0])};O(t)}},stop:function(){this.running=
115
115
  !1}};this.doScrollPos=function(g,t,x){x=b.getScrollTop();var f=b.getScrollLeft();(0>(b.newscrolly-x)*(t-x)||0>(b.newscrollx-f)*(g-f))&&b.cancelScroll();z.bouncescroll?(0>t?t=t/2|0:t>b.page.maxh&&(t=b.page.maxh+(t-b.page.maxh)/2|0),0>g?g=g/2|0:g>b.page.maxw&&(g=b.page.maxw+(g-b.page.maxw)/2|0)):(0>t?t=0:t>b.page.maxh&&(t=b.page.maxh),0>g?g=0:g>b.page.maxw&&(g=b.page.maxw));if(b.scrollrunning&&g==b.newscrollx&&t==b.newscrolly)return!1;b.newscrolly=t;b.newscrollx=g;x=b.getScrollTop();f=b.getScrollLeft();
116
116
  var r=g-f;var D=t-x;r=b.prepareTransition(Math.sqrt(r*r+D*D)|0);b.scrollrunning||(b.scrollrunning=!0,b.triggerScrollStart(f,x,g,t,r),b.cursorupdate.start());b.scrollendtrapped=!0;H.transitionend||(b.scrollendtrapped&&clearTimeout(b.scrollendtrapped),b.scrollendtrapped=setTimeout(b.onScrollTransitionEnd,r));b.setScrollTop(b.newscrolly);b.setScrollLeft(b.newscrollx)};this.cancelScroll=function(){if(!b.scrollendtrapped)return!0;var g=b.getScrollTop(),t=b.getScrollLeft();b.scrollrunning=!1;H.transitionend||
117
117
  clearTimeout(H.transitionend);b.scrollendtrapped=!1;b.resetTransition();b.setScrollTop(g);b.railh&&b.setScrollLeft(t);b.timerscroll&&b.timerscroll.tm&&clearInterval(b.timerscroll.tm);b.timerscroll=!1;b.cursorfreezed=!1;b.cursorupdate.stop();b.showCursor(g,t);return b};this.onScrollTransitionEnd=function(){if(b.scrollendtrapped){var g=b.getScrollTop(),t=b.getScrollLeft();0>g?g=0:g>b.page.maxh&&(g=b.page.maxh);0>t?t=0:t>b.page.maxw&&(t=b.page.maxw);if(g!=b.newscrolly||t!=b.newscrollx)return b.doScrollPos(t,
118
118
  g,z.snapbackspeed);b.scrollrunning&&b.triggerScrollEnd();b.scrollrunning=!1;b.scrollendtrapped=!1;b.resetTransition();b.timerscroll=!1;b.setScrollTop(g);b.railh&&b.setScrollLeft(t);b.cursorupdate.stop();b.noticeCursor(!1,g,t);b.cursorfreezed=!1}}}else this.doScrollLeft=function(g,t){var x=b.scrollrunning?b.newscrolly:b.getScrollTop();b.doScrollPos(g,x,t)},this.doScrollTop=function(g,t){var x=b.scrollrunning?b.newscrollx:b.getScrollLeft();b.doScrollPos(x,g,t)},this.doScrollPos=function(g,t,x){x=b.getScrollTop();
119
119
  var f=b.getScrollLeft();(0>(b.newscrolly-x)*(t-x)||0>(b.newscrollx-f)*(g-f))&&b.cancelScroll();var r=!1;b.bouncescroll&&b.rail.visibility||(0>t?(t=0,r=!0):t>b.page.maxh&&(t=b.page.maxh,r=!0));b.bouncescroll&&b.railh.visibility||(0>g?(g=0,r=!0):g>b.page.maxw&&(g=b.page.maxw,r=!0));if(b.scrollrunning&&b.newscrolly===t&&b.newscrollx===g)return!0;b.newscrolly=t;b.newscrollx=g;b.dst={};b.dst.x=g-f;b.dst.y=t-x;b.dst.px=f;b.dst.py=x;var D=b.getTransitionSpeed(Math.sqrt(b.dst.x*b.dst.x+b.dst.y*b.dst.y)|0);
120
- b.bzscroll={};r=r?1:.58;b.bzscroll.x=new ja(f,b.newscrollx,D,0,0,r,1);b.bzscroll.y=new ja(x,b.newscrolly,D,0,0,r,1);aa();var R=function(){if(b.scrollrunning){var ea=b.bzscroll.y.getPos();b.setScrollLeft(b.bzscroll.x.getNow());b.setScrollTop(b.bzscroll.y.getNow());1>=ea?b.timer=P(R):(b.scrollrunning=!1,b.timer=0,b.triggerScrollEnd())}};b.scrollrunning||(b.triggerScrollStart(f,x,g,t,D),b.scrollrunning=!0,b.timer=P(R))},this.cancelScroll=function(){b.timer&&Q(b.timer);b.timer=0;b.bzscroll=!1;b.scrollrunning=
120
+ b.bzscroll={};r=r?1:.58;b.bzscroll.x=new ja(f,b.newscrollx,D,0,0,r,1);b.bzscroll.y=new ja(x,b.newscrolly,D,0,0,r,1);aa();var R=function(){if(b.scrollrunning){var ea=b.bzscroll.y.getPos();b.setScrollLeft(b.bzscroll.x.getNow());b.setScrollTop(b.bzscroll.y.getNow());1>=ea?b.timer=O(R):(b.scrollrunning=!1,b.timer=0,b.triggerScrollEnd())}};b.scrollrunning||(b.triggerScrollStart(f,x,g,t,D),b.scrollrunning=!0,b.timer=O(R))},this.cancelScroll=function(){b.timer&&Q(b.timer);b.timer=0;b.bzscroll=!1;b.scrollrunning=
121
121
  !1;return b};else this.doScrollLeft=function(g,t){var x=b.getScrollTop();b.doScrollPos(g,x,t)},this.doScrollTop=function(g,t){var x=b.getScrollLeft();b.doScrollPos(x,g,t)},this.doScrollPos=function(g,t,x){var f=g>b.page.maxw?b.page.maxw:g;0>f&&(f=0);var r=t>b.page.maxh?b.page.maxh:t;0>r&&(r=0);b.synched("scroll",function(){b.setScrollTop(r);b.setScrollLeft(f)})},this.cancelScroll=function(){};this.doScrollBy=function(g,t){A(0,g)};this.doScrollLeftBy=function(g,t){A(g,0)};this.doScrollTo=function(g,
122
122
  t){b.cursorfreezed=!1;b.doScrollTop(g)};this.checkContentSize=function(){var g=b.getContentSize();g.h==b.page.h&&g.w==b.page.w||b.resize(!1,g)};b.onscroll=function(g){b.rail.drag||b.cursorfreezed||b.synched("scroll",function(){b.scroll.y=Math.round(b.getScrollTop()/b.scrollratio.y);b.railh&&(b.scroll.x=Math.round(b.getScrollLeft()/b.scrollratio.x));b.noticeCursor()})};b.bind(b.docscroll,"scroll",b.onscroll);this.doZoomIn=function(g){if(!b.zoomactive){b.zoomactive=!0;b.zoomrestore={style:{}};var t=
123
- "position top left zIndex backgroundColor marginTop marginBottom marginLeft marginRight".split(" "),x=b.win[0].style,f;for(f in t){var r=t[f];b.zoomrestore.style[r]=void 0!==x[r]?x[r]:""}b.zoomrestore.style.width=b.win.css("width");b.zoomrestore.style.height=b.win.css("height");b.zoomrestore.padding={w:b.win.outerWidth()-b.win.width(),h:b.win.outerHeight()-b.win.height()};H.isios4&&(b.zoomrestore.scrollTop=L.scrollTop(),L.scrollTop(0));b.win.css({position:H.isios4?"absolute":"fixed",top:0,left:0,
124
- zIndex:J+100,margin:0});t=b.win.css("backgroundColor");(""===t||/transparent|rgba\(0, 0, 0, 0\)|rgba\(0,0,0,0\)/.test(t))&&b.win.css("backgroundColor","#fff");b.rail.css({zIndex:J+101});b.zoom.css({zIndex:J+102});b.zoom.css("backgroundPosition","0 -18px");b.resizeZoom();b.onzoomin&&b.onzoomin.call(b);return b.cancelEvent(g)}};this.doZoomOut=function(g){if(b.zoomactive)return b.zoomactive=!1,b.win.css("margin",""),b.win.css(b.zoomrestore.style),H.isios4&&L.scrollTop(b.zoomrestore.scrollTop),b.rail.css({"z-index":b.zindex}),
125
- b.zoom.css({"z-index":b.zindex}),b.zoomrestore=!1,b.zoom.css("backgroundPosition","0 0"),b.onResize(),b.onzoomout&&b.onzoomout.call(b),b.cancelEvent(g)};this.doZoom=function(g){return b.zoomactive?b.doZoomOut(g):b.doZoomIn(g)};this.resizeZoom=function(){if(b.zoomactive){var g=b.getScrollTop();b.win.css({width:L.width()-b.zoomrestore.padding.w+"px",height:L.height()-b.zoomrestore.padding.h+"px"});b.onResize();b.setScrollTop(Math.min(b.page.maxh,g))}};this.init();p.nicescroll.push(this)},ia=function(e){var n=
126
- this;this.nc=e;this.steptime=this.lasttime=this.speedy=this.speedx=this.lasty=this.lastx=0;this.snapy=this.snapx=!1;this.demuly=this.demulx=0;this.lastscrolly=this.lastscrollx=-1;this.timer=this.chky=this.chkx=0;this.reset=function(m,c){n.stop();n.steptime=0;n.lasttime=aa();n.speedx=0;n.speedy=0;n.lastx=m;n.lasty=c;n.lastscrollx=-1;n.lastscrolly=-1};this.update=function(m,c){var l=aa();n.steptime=l-n.lasttime;n.lasttime=l;l=c-n.lasty;var v=m-n.lastx,A=n.nc.getScrollTop(),K=n.nc.getScrollLeft();A+=
127
- l;K+=v;n.snapx=0>K||K>n.nc.page.maxw;n.snapy=0>A||A>n.nc.page.maxh;n.speedx=v;n.speedy=l;n.lastx=m;n.lasty=c};this.stop=function(){n.nc.unsynched("domomentum2d");n.timer&&clearTimeout(n.timer);n.timer=0;n.lastscrollx=-1;n.lastscrolly=-1};this.doSnapy=function(m,c){var l=!1;0>c?(c=0,l=!0):c>n.nc.page.maxh&&(c=n.nc.page.maxh,l=!0);0>m?(m=0,l=!0):m>n.nc.page.maxw&&(m=n.nc.page.maxw,l=!0);l?n.nc.doScrollPos(m,c,n.nc.opt.snapbackspeed):n.nc.triggerScrollEnd()};this.doMomentum=function(m){var c=aa(),l=
128
- m?c+m:n.lasttime;m=n.nc.getScrollLeft();var v=n.nc.getScrollTop(),A=n.nc.page.maxh,K=n.nc.page.maxw;n.speedx=0<K?Math.min(60,n.speedx):0;n.speedy=0<A?Math.min(60,n.speedy):0;l=l&&60>=c-l;if(0>v||v>A||0>m||m>K)l=!1;m=n.speedx&&l?n.speedx:!1;if(n.speedy&&l&&n.speedy||m){var b=Math.max(16,n.steptime);50<b&&(m=b/50,n.speedx*=m,n.speedy*=m,b=50);n.demulxy=0;n.lastscrollx=n.nc.getScrollLeft();n.chkx=n.lastscrollx;n.lastscrolly=n.nc.getScrollTop();n.chky=n.lastscrolly;var O=n.lastscrollx,z=n.lastscrolly,
129
- la=function(){var H=600<aa()-c?.04:.02;n.speedx&&(O=Math.floor(n.lastscrollx-n.speedx*(1-n.demulxy)),n.lastscrollx=O,0>O||O>K)&&(H=.1);n.speedy&&(z=Math.floor(n.lastscrolly-n.speedy*(1-n.demulxy)),n.lastscrolly=z,0>z||z>A)&&(H=.1);n.demulxy=Math.min(1,n.demulxy+H);n.nc.synched("domomentum2d",function(){n.speedx&&(n.nc.getScrollLeft(),n.chkx=O,n.nc.setScrollLeft(O));n.speedy&&(n.nc.getScrollTop(),n.chky=z,n.nc.setScrollTop(z));n.timer||(n.nc.hideCursor(),n.doSnapy(O,z))});1>n.demulxy?n.timer=setTimeout(la,
130
- b):(n.stop(),n.nc.hideCursor(),n.doSnapy(O,z))};la()}else n.doSnapy(n.nc.getScrollLeft(),n.nc.getScrollTop())}},na=p.fn.scrollTop;"object"===typeof p.cssHooks&&(p.cssHooks.pageYOffset={get:function(e,n,m){return(n=p.data(e,"__nicescroll")||!1)&&n.ishwscroll?n.getScrollTop():na.call(e)},set:function(e,n){var m=p.data(e,"__nicescroll")||!1;m&&m.ishwscroll?m.setScrollTop(parseInt(n)):na.call(e,n);return this}});p.fn.scrollTop=function(e){if(void 0===e){var n=this[0]?p.data(this[0],"__nicescroll")||!1:
123
+ "position top left zIndex backgroundColor marginTop marginBottom marginLeft marginRight".split(" "),x=b.win[0].style,f;for(f in t){var r=t[f];b.zoomrestore.style[r]=void 0!==x[r]?x[r]:""}b.zoomrestore.style.width=b.win.css("width");b.zoomrestore.style.height=b.win.css("height");b.zoomrestore.padding={w:b.win.outerWidth()-b.win.width(),h:b.win.outerHeight()-b.win.height()};H.isios4&&(b.zoomrestore.scrollTop=K.scrollTop(),K.scrollTop(0));b.win.css({position:H.isios4?"absolute":"fixed",top:0,left:0,
124
+ zIndex:I+100,margin:0});t=b.win.css("backgroundColor");(""===t||/transparent|rgba\(0, 0, 0, 0\)|rgba\(0,0,0,0\)/.test(t))&&b.win.css("backgroundColor","#fff");b.rail.css({zIndex:I+101});b.zoom.css({zIndex:I+102});b.zoom.css("backgroundPosition","0 -18px");b.resizeZoom();b.onzoomin&&b.onzoomin.call(b);return b.cancelEvent(g)}};this.doZoomOut=function(g){if(b.zoomactive)return b.zoomactive=!1,b.win.css("margin",""),b.win.css(b.zoomrestore.style),H.isios4&&K.scrollTop(b.zoomrestore.scrollTop),b.rail.css({"z-index":b.zindex}),
125
+ b.zoom.css({"z-index":b.zindex}),b.zoomrestore=!1,b.zoom.css("backgroundPosition","0 0"),b.onResize(),b.onzoomout&&b.onzoomout.call(b),b.cancelEvent(g)};this.doZoom=function(g){return b.zoomactive?b.doZoomOut(g):b.doZoomIn(g)};this.resizeZoom=function(){if(b.zoomactive){var g=b.getScrollTop();b.win.css({width:K.width()-b.zoomrestore.padding.w+"px",height:K.height()-b.zoomrestore.padding.h+"px"});b.onResize();b.setScrollTop(Math.min(b.page.maxh,g))}};this.init();p.nicescroll.push(this)},ia=function(e){var n=
126
+ this;this.nc=e;this.steptime=this.lasttime=this.speedy=this.speedx=this.lasty=this.lastx=0;this.snapy=this.snapx=!1;this.demuly=this.demulx=0;this.lastscrolly=this.lastscrollx=-1;this.timer=this.chky=this.chkx=0;this.reset=function(m,c){n.stop();n.steptime=0;n.lasttime=aa();n.speedx=0;n.speedy=0;n.lastx=m;n.lasty=c;n.lastscrollx=-1;n.lastscrolly=-1};this.update=function(m,c){var l=aa();n.steptime=l-n.lasttime;n.lasttime=l;l=c-n.lasty;var v=m-n.lastx,A=n.nc.getScrollTop(),M=n.nc.getScrollLeft();A+=
127
+ l;M+=v;n.snapx=0>M||M>n.nc.page.maxw;n.snapy=0>A||A>n.nc.page.maxh;n.speedx=v;n.speedy=l;n.lastx=m;n.lasty=c};this.stop=function(){n.nc.unsynched("domomentum2d");n.timer&&clearTimeout(n.timer);n.timer=0;n.lastscrollx=-1;n.lastscrolly=-1};this.doSnapy=function(m,c){var l=!1;0>c?(c=0,l=!0):c>n.nc.page.maxh&&(c=n.nc.page.maxh,l=!0);0>m?(m=0,l=!0):m>n.nc.page.maxw&&(m=n.nc.page.maxw,l=!0);l?n.nc.doScrollPos(m,c,n.nc.opt.snapbackspeed):n.nc.triggerScrollEnd()};this.doMomentum=function(m){var c=aa(),l=
128
+ m?c+m:n.lasttime;m=n.nc.getScrollLeft();var v=n.nc.getScrollTop(),A=n.nc.page.maxh,M=n.nc.page.maxw;n.speedx=0<M?Math.min(60,n.speedx):0;n.speedy=0<A?Math.min(60,n.speedy):0;l=l&&60>=c-l;if(0>v||v>A||0>m||m>M)l=!1;m=n.speedx&&l?n.speedx:!1;if(n.speedy&&l&&n.speedy||m){var b=Math.max(16,n.steptime);50<b&&(m=b/50,n.speedx*=m,n.speedy*=m,b=50);n.demulxy=0;n.lastscrollx=n.nc.getScrollLeft();n.chkx=n.lastscrollx;n.lastscrolly=n.nc.getScrollTop();n.chky=n.lastscrolly;var P=n.lastscrollx,z=n.lastscrolly,
129
+ la=function(){var H=600<aa()-c?.04:.02;n.speedx&&(P=Math.floor(n.lastscrollx-n.speedx*(1-n.demulxy)),n.lastscrollx=P,0>P||P>M)&&(H=.1);n.speedy&&(z=Math.floor(n.lastscrolly-n.speedy*(1-n.demulxy)),n.lastscrolly=z,0>z||z>A)&&(H=.1);n.demulxy=Math.min(1,n.demulxy+H);n.nc.synched("domomentum2d",function(){n.speedx&&(n.nc.getScrollLeft(),n.chkx=P,n.nc.setScrollLeft(P));n.speedy&&(n.nc.getScrollTop(),n.chky=z,n.nc.setScrollTop(z));n.timer||(n.nc.hideCursor(),n.doSnapy(P,z))});1>n.demulxy?n.timer=setTimeout(la,
130
+ b):(n.stop(),n.nc.hideCursor(),n.doSnapy(P,z))};la()}else n.doSnapy(n.nc.getScrollLeft(),n.nc.getScrollTop())}},na=p.fn.scrollTop;"object"===typeof p.cssHooks&&(p.cssHooks.pageYOffset={get:function(e,n,m){return(n=p.data(e,"__nicescroll")||!1)&&n.ishwscroll?n.getScrollTop():na.call(e)},set:function(e,n){var m=p.data(e,"__nicescroll")||!1;m&&m.ishwscroll?m.setScrollTop(parseInt(n)):na.call(e,n);return this}});p.fn.scrollTop=function(e){if(void 0===e){var n=this[0]?p.data(this[0],"__nicescroll")||!1:
131
131
  !1;return n&&n.ishwscroll?n.getScrollTop():na.call(this)}return this.each(function(){var m=p.data(this,"__nicescroll")||!1;m&&m.ishwscroll?m.setScrollTop(parseInt(e)):na.call(p(this),e)})};var ha=p.fn.scrollLeft;"object"===typeof p.cssHooks&&(p.cssHooks.pageXOffset={get:function(e,n,m){return(n=p.data(e,"__nicescroll")||!1)&&n.ishwscroll?n.getScrollLeft():ha.call(e)},set:function(e,n){var m=p.data(e,"__nicescroll")||!1;m&&m.ishwscroll?m.setScrollLeft(parseInt(n)):ha.call(e,n);return this}});p.fn.scrollLeft=
132
132
  function(e){if(void 0===e){var n=this[0]?p.data(this[0],"__nicescroll")||!1:!1;return n&&n.ishwscroll?n.getScrollLeft():ha.call(this)}return this.each(function(){var m=p.data(this,"__nicescroll")||!1;m&&m.ishwscroll?m.setScrollLeft(parseInt(e)):ha.call(p(this),e)})};var ca=function(e){var n=this;this.length=0;this.name="nicescrollarray";this.each=function(l){p.each(n,l);return n};this.push=function(l){n[n.length]=l;n.length++};this.eq=function(l){return n[l]};if(e)for(var m=0;m<e.length;m++){var c=
133
133
  p.data(e[m],"__nicescroll")||!1;c&&(this[this.length]=c,this.length++)}return this};(function(e,n,m){for(var c=0,l=n.length;c<l;c++)m(e,n[c])})(ca.prototype,"show hide toggle onResize resize remove stop doScrollPos".split(" "),function(e,n){e[n]=function(){var m=arguments;return this.each(function(){this[n].apply(this,m)})}});p.fn.getNiceScroll=function(e){return void 0===e?new ca(this):this[e]&&p.data(this[e],"__nicescroll")||!1};if("object"===typeof p.expr){var oa=p.expr.pseudos||p.expr[":"];oa&&
134
- (oa.nicescroll=function(e){return void 0!==p.data(e,"__nicescroll")})}p.fn.niceScroll=function(e,n){void 0!==n||"object"!=typeof e||"jquery"in e||(n=e,e=!1);var m=new ca;this.each(function(){var c=p(this),l=p.extend({},n);if(e){var v=p(e);l.doc=1<v.length?p(e,c):v;l.win=c}"doc"in l&&!("win"in l)&&(l.win=c);v=c.data("__nicescroll")||!1;v||(l.doc=l.doc||c,v=new ka(l,c),c.data("__nicescroll",v));m.push(v)});return 1===m.length?m[0]:m};I.NiceScroll={getjQuery:function(){return p}};p.nicescroll||(p.nicescroll=
135
- new ca,p.nicescroll.options=fa)})(function(p){var B=function(){function u(f){return null==f?String(f):N[U.call(f)]||"object"}function y(f){return"function"==u(f)}function F(f){return null!=f&&f==f.window}function J(f){return"object"==u(f)}function w(f){return J(f)&&!F(f)&&Object.getPrototypeOf(f)==Object.prototype}function L(f){var r=!!f&&"length"in f&&f.length,D=x.type(f);return"function"!=D&&!F(f)&&("array"==D||0===r||"number"==typeof r&&0<r&&r-1 in f)}function M(f){return m.call(f,function(r){return null!=
136
- r})}function P(f){return f.replace(/::/g,"/").replace(/([A-Z]+)([A-Z][a-z])/g,"$1_$2").replace(/([a-z\d])([A-Z])/g,"$1_$2").replace(/_/g,"-").toLowerCase()}function Q(f){return f in A?A[f]:A[f]=new RegExp("(^|\\s)"+f+"(\\s|$)")}function Z(f,r){return"number"!=typeof r||K[P(f)]?r:r+"px"}function ba(f){return"children"in f?c.call(f.children):x.map(f.childNodes,function(r){if(1==r.nodeType)return r})}function aa(f,r){var D,R=f?f.length:0;for(D=0;D<R;D++)this[D]=f[D];this.length=R;this.selector=r||""}
134
+ (oa.nicescroll=function(e){return void 0!==p.data(e,"__nicescroll")})}p.fn.niceScroll=function(e,n){void 0!==n||"object"!=typeof e||"jquery"in e||(n=e,e=!1);var m=new ca;this.each(function(){var c=p(this),l=p.extend({},n);if(e){var v=p(e);l.doc=1<v.length?p(e,c):v;l.win=c}"doc"in l&&!("win"in l)&&(l.win=c);v=c.data("__nicescroll")||!1;v||(l.doc=l.doc||c,v=new ka(l,c),c.data("__nicescroll",v));m.push(v)});return 1===m.length?m[0]:m};J.NiceScroll={getjQuery:function(){return p}};p.nicescroll||(p.nicescroll=
135
+ new ca,p.nicescroll.options=fa)})(function(p){var B=function(){function u(f){return null==f?String(f):N[U.call(f)]||"object"}function y(f){return"function"==u(f)}function F(f){return null!=f&&f==f.window}function I(f){return"object"==u(f)}function w(f){return I(f)&&!F(f)&&Object.getPrototypeOf(f)==Object.prototype}function K(f){var r=!!f&&"length"in f&&f.length,D=x.type(f);return"function"!=D&&!F(f)&&("array"==D||0===r||"number"==typeof r&&0<r&&r-1 in f)}function L(f){return m.call(f,function(r){return null!=
136
+ r})}function O(f){return f.replace(/::/g,"/").replace(/([A-Z]+)([A-Z][a-z])/g,"$1_$2").replace(/([a-z\d])([A-Z])/g,"$1_$2").replace(/_/g,"-").toLowerCase()}function Q(f){return f in A?A[f]:A[f]=new RegExp("(^|\\s)"+f+"(\\s|$)")}function Z(f,r){return"number"!=typeof r||M[O(f)]?r:r+"px"}function ba(f){return"children"in f?c.call(f.children):x.map(f.childNodes,function(r){if(1==r.nodeType)return r})}function aa(f,r){var D,R=f?f.length:0;for(D=0;D<R;D++)this[D]=f[D];this.length=R;this.selector=r||""}
137
137
  function fa(f,r,D){for(ca in r)D&&(w(r[ca])||W(r[ca]))?(w(r[ca])&&!w(f[ca])&&(f[ca]={}),W(r[ca])&&!W(f[ca])&&(f[ca]=[]),fa(f[ca],r[ca],D)):r[ca]!==ha&&(f[ca]=r[ca])}function ma(f,r){return null==r?x(f):x(f).filter(r)}function Y(f,r,D,R){return y(r)?r.call(f,D,R):r}function ka(f,r){var D=f.className||"",R=D&&D.baseVal!==ha;if(r===ha)return R?D.baseVal:D;R?D.baseVal=r:f.className=r}function ia(f){try{return f?"true"==f||("false"==f?!1:"null"==f?null:+f+""==f?+f:/^[\[\{]/.test(f)?x.parseJSON(f):f):f}catch(r){return f}}
138
- function na(f,r){r(f);for(var D=0,R=f.childNodes.length;D<R;D++)na(f.childNodes[D],r)}var ha,ca,oa,e=[],n=e.concat,m=e.filter,c=e.slice,l=p.document,v={},A={},K={"column-count":1,columns:1,"font-weight":1,"line-height":1,opacity:1,"z-index":1,zoom:1},b=/^\s*<(\w+|!)[^>]*>/,O=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,z=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,la=/^(?:body|html)$/i,H=/([A-Z])/g,ja="val css html text data width height offset".split(" "),d=l.createElement("table"),
138
+ function na(f,r){r(f);for(var D=0,R=f.childNodes.length;D<R;D++)na(f.childNodes[D],r)}var ha,ca,oa,e=[],n=e.concat,m=e.filter,c=e.slice,l=p.document,v={},A={},M={"column-count":1,columns:1,"font-weight":1,"line-height":1,opacity:1,"z-index":1,zoom:1},b=/^\s*<(\w+|!)[^>]*>/,P=/^<(\w+)\s*\/?>(?:<\/\1>|)$/,z=/<(?!area|br|col|embed|hr|img|input|link|meta|param)(([\w:]+)[^>]*)\/>/ig,la=/^(?:body|html)$/i,H=/([A-Z])/g,ja="val css html text data width height offset".split(" "),d=l.createElement("table"),
139
139
  h=l.createElement("tr"),q={tr:l.createElement("tbody"),tbody:d,thead:d,tfoot:d,td:h,th:h,"*":l.createElement("div")},C=/complete|loaded|interactive/,G=/^[\w-]*$/,N={},U=N.toString,S={},T=l.createElement("div"),V={tabindex:"tabIndex",readonly:"readOnly","for":"htmlFor","class":"className",maxlength:"maxLength",cellspacing:"cellSpacing",cellpadding:"cellPadding",rowspan:"rowSpan",colspan:"colSpan",usemap:"useMap",frameborder:"frameBorder",contenteditable:"contentEditable"},W=Array.isArray||function(f){return f instanceof
140
- Array};S.matches=function(f,r){if(!r||!f||1!==f.nodeType)return!1;var D=f.matches||f.webkitMatchesSelector||f.mozMatchesSelector||f.oMatchesSelector||f.matchesSelector;if(D)return D.call(f,r);var R=f.parentNode;(D=!R)&&(R=T).appendChild(f);r=~S.qsa(R,r).indexOf(f);D&&T.removeChild(f);return r};var g=function(f){return f.replace(/-+(.)?/g,function(r,D){return D?D.toUpperCase():""})};var t=function(f){return m.call(f,function(r,D){return f.indexOf(r)==D})};S.fragment=function(f,r,D){var R;O.test(f)&&
140
+ Array};S.matches=function(f,r){if(!r||!f||1!==f.nodeType)return!1;var D=f.matches||f.webkitMatchesSelector||f.mozMatchesSelector||f.oMatchesSelector||f.matchesSelector;if(D)return D.call(f,r);var R=f.parentNode;(D=!R)&&(R=T).appendChild(f);r=~S.qsa(R,r).indexOf(f);D&&T.removeChild(f);return r};var g=function(f){return f.replace(/-+(.)?/g,function(r,D){return D?D.toUpperCase():""})};var t=function(f){return m.call(f,function(r,D){return f.indexOf(r)==D})};S.fragment=function(f,r,D){var R;P.test(f)&&
141
141
  (R=x(l.createElement(RegExp.$1)));if(!R){f.replace&&(f=f.replace(z,"<$1></$2>"));r===ha&&(r=b.test(f)&&RegExp.$1);r in q||(r="*");var ea=q[r];ea.innerHTML=""+f;R=x.each(c.call(ea.childNodes),function(){ea.removeChild(this)})}if(w(D)){var da=x(R);x.each(D,function(wa,ta){if(-1<ja.indexOf(wa))da[wa](ta);else da.attr(wa,ta)})}return R};S.Z=function(f,r){return new aa(f,r)};S.isZ=function(f){return f instanceof S.Z};S.init=function(f,r){if(f)if("string"==typeof f)if(f=f.trim(),"<"==f[0]&&b.test(f))r=
142
- S.fragment(f,RegExp.$1,r),f=null;else{if(r!==ha)return x(r).find(f);r=S.qsa(l,f)}else{if(y(f))return x(l).ready(f);if(S.isZ(f))return f;if(W(f))r=M(f);else if(J(f))r=[f],f=null;else if(b.test(f))r=S.fragment(f.trim(),RegExp.$1,r),f=null;else{if(r!==ha)return x(r).find(f);r=S.qsa(l,f)}}else return S.Z();return S.Z(r,f)};var x=function(f,r){return S.init(f,r)};x.extend=function(f){var r=c.call(arguments,1);if("boolean"==typeof f){var D=f;f=r.shift()}r.forEach(function(R){fa(f,R,D)});return f};S.qsa=
142
+ S.fragment(f,RegExp.$1,r),f=null;else{if(r!==ha)return x(r).find(f);r=S.qsa(l,f)}else{if(y(f))return x(l).ready(f);if(S.isZ(f))return f;if(W(f))r=L(f);else if(I(f))r=[f],f=null;else if(b.test(f))r=S.fragment(f.trim(),RegExp.$1,r),f=null;else{if(r!==ha)return x(r).find(f);r=S.qsa(l,f)}}else return S.Z();return S.Z(r,f)};var x=function(f,r){return S.init(f,r)};x.extend=function(f){var r=c.call(arguments,1);if("boolean"==typeof f){var D=f;f=r.shift()}r.forEach(function(R){fa(f,R,D)});return f};S.qsa=
143
143
  function(f,r){var D,R="#"==r[0],ea=!R&&"."==r[0],da=R||ea?r.slice(1):r,wa=G.test(da);return f.getElementById&&wa&&R?(D=f.getElementById(da))?[D]:[]:1!==f.nodeType&&9!==f.nodeType&&11!==f.nodeType?[]:c.call(wa&&!R&&f.getElementsByClassName?ea?f.getElementsByClassName(da):f.getElementsByTagName(r):f.querySelectorAll(r))};x.contains=l.documentElement.contains?function(f,r){return f!==r&&f.contains(r)}:function(f,r){for(;r&&=r.parentNode;)if(r===f)return!0;return!1};x.type=u;x.isFunction=y;x.isWindow=
144
- F;x.isArray=W;x.isPlainObject=w;x.isEmptyObject=function(f){for(var r in f)return!1;return!0};x.isNumeric=function(f){var r=Number(f),D=typeof f;return null!=f&&"boolean"!=D&&("string"!=D||f.length)&&!isNaN(r)&&isFinite(r)||!1};x.inArray=function(f,r,D){return e.indexOf.call(r,f,D)};x.camelCase=g;x.trim=function(f){return null==f?"":String.prototype.trim.call(f)};x.uuid=0;x.support={};x.expr={};x.noop=function(){};x.map=function(f,r){var D=[],R;if(L(f))for(R=0;R<f.length;R++){var ea=r(f[R],R);null!=
145
- ea&&D.push(ea)}else for(R in f)ea=r(f[R],R),null!=ea&&D.push(ea);return 0<D.length?x.fn.concat.apply([],D):D};x.each=function(f,r){var D;if(L(f))for(D=0;D<f.length&&!1!==r.call(f[D],D,f[D]);D++);else for(D in f)if(!1===r.call(f[D],D,f[D]))break;return f};x.grep=function(f,r){return m.call(f,r)};p.JSON&&(x.parseJSON=JSON.parse);x.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(f,r){N["[object "+r+"]"]=r.toLowerCase()});x.data=function(f,r,D){if(D===ha)return"undefined"!==
144
+ F;x.isArray=W;x.isPlainObject=w;x.isEmptyObject=function(f){for(var r in f)return!1;return!0};x.isNumeric=function(f){var r=Number(f),D=typeof f;return null!=f&&"boolean"!=D&&("string"!=D||f.length)&&!isNaN(r)&&isFinite(r)||!1};x.inArray=function(f,r,D){return e.indexOf.call(r,f,D)};x.camelCase=g;x.trim=function(f){return null==f?"":String.prototype.trim.call(f)};x.uuid=0;x.support={};x.expr={};x.noop=function(){};x.map=function(f,r){var D=[],R;if(K(f))for(R=0;R<f.length;R++){var ea=r(f[R],R);null!=
145
+ ea&&D.push(ea)}else for(R in f)ea=r(f[R],R),null!=ea&&D.push(ea);return 0<D.length?x.fn.concat.apply([],D):D};x.each=function(f,r){var D;if(K(f))for(D=0;D<f.length&&!1!==r.call(f[D],D,f[D]);D++);else for(D in f)if(!1===r.call(f[D],D,f[D]))break;return f};x.grep=function(f,r){return m.call(f,r)};p.JSON&&(x.parseJSON=JSON.parse);x.each("Boolean Number String Function Array Date RegExp Object Error".split(" "),function(f,r){N["[object "+r+"]"]=r.toLowerCase()});x.data=function(f,r,D){if(D===ha)return"undefined"!==
146
146
  typeof f[r]?f[r]:ha;null===D?delete f[r]:f[r]=D};x.fn={jquery:"1.2.0",constructor:S.Z,length:0,forEach:e.forEach,reduce:e.reduce,push:e.push,sort:e.sort,splice:e.splice,indexOf:e.indexOf,concat:function(){var f,r=[];for(f=0;f<arguments.length;f++){var D=arguments[f];r[f]=S.isZ(D)?D.toArray():D}return n.apply(S.isZ(this)?this.toArray():this,r)},map:function(f){return x(x.map(this,function(r,D){return f.call(r,D,r)}))},slice:function(){return x(c.apply(this,arguments))},ready:function(f){C.test(l.readyState)&&
147
147
  l.body?f(x):l.addEventListener("DOMContentLoaded",function(){f(x)},!1);return this},get:function(f){return f===ha?c.call(this):this[0<=f?f:f+this.length]},toArray:function(){return this.get()},size:function(){return this.length},remove:function(){return this.each(function(){null!=this.parentNode&&this.parentNode.removeChild(this)})},each:function(f){e.every.call(this,function(r,D){return!1!==f.call(r,D,r)});return this},filter:function(f){return y(f)?this.not(this.not(f)):x(m.call(this,function(r){return S.matches(r,
148
- f)}))},add:function(f,r){return x(t(this.concat(x(f,r))))},is:function(f){return":visible"===f?0<this.length?"none"!==this.css("display"):!1:J(f)?this[0]===f?!0:!1:0<this.length&&S.matches(this[0],f)},not:function(f){var r=[];if(y(f)&&f.call!==ha)this.each(function(R){f.call(this,R)||r.push(this)});else{var D="string"==typeof f?this.filter(f):L(f)&&y(f.item)?c.call(f):x(f);this.forEach(function(R){0>D.indexOf(R)&&r.push(R)})}return x(r)},has:function(f){return this.filter(function(){return J(f)?x.contains(this,
149
- f):x(this).find(f).size()})},eq:function(f){return-1===f?this.slice(f):this.slice(f,+f+1)},first:function(){var f=this[0];return f&&!J(f)?f:x(f)},last:function(){var f=this[this.length-1];return f&&!J(f)?f:x(f)},find:function(f){var r=this;return f?"object"==typeof f?x(f).filter(function(){var D=this;return e.some.call(r,function(R){return x.contains(R,D)})}):1==this.length?x(S.qsa(this[0],f)):this.map(function(){return S.qsa(this,f)}):x()},closest:function(f,r){var D=[],R="object"==typeof f&&x(f);
148
+ f)}))},add:function(f,r){return x(t(this.concat(x(f,r))))},is:function(f){return":visible"===f?0<this.length?"none"!==this.css("display"):!1:I(f)?this[0]===f?!0:!1:0<this.length&&S.matches(this[0],f)},not:function(f){var r=[];if(y(f)&&f.call!==ha)this.each(function(R){f.call(this,R)||r.push(this)});else{var D="string"==typeof f?this.filter(f):K(f)&&y(f.item)?c.call(f):x(f);this.forEach(function(R){0>D.indexOf(R)&&r.push(R)})}return x(r)},has:function(f){return this.filter(function(){return I(f)?x.contains(this,
149
+ f):x(this).find(f).size()})},eq:function(f){return-1===f?this.slice(f):this.slice(f,+f+1)},first:function(){var f=this[0];return f&&!I(f)?f:x(f)},last:function(){var f=this[this.length-1];return f&&!I(f)?f:x(f)},find:function(f){var r=this;return f?"object"==typeof f?x(f).filter(function(){var D=this;return e.some.call(r,function(R){return x.contains(R,D)})}):1==this.length?x(S.qsa(this[0],f)):this.map(function(){return S.qsa(this,f)}):x()},closest:function(f,r){var D=[],R="object"==typeof f&&x(f);
150
150
  this.each(function(ea,da){for(;da&&!(R?0<=R.indexOf(da):S.matches(da,f));)da=da!==r&&!(null!=da&&da.nodeType==da.DOCUMENT_NODE)&&da.parentNode;da&&0>D.indexOf(da)&&D.push(da)});return x(D)},parents:function(f){for(var r=[],D=this;0<D.length;)D=x.map(D,function(R){if((R=R.parentNode)&&(null==R||R.nodeType!=R.DOCUMENT_NODE)&&0>r.indexOf(R))return r.push(R),R});return ma(r,f)},parent:function(f){return ma(t(this.pluck("parentNode")),f)},children:function(f){return ma(this.map(function(){return ba(this)}),
151
151
  f)},contents:function(){return this.map(function(){return this.contentDocument||c.call(this.childNodes)})},siblings:function(f){return ma(this.map(function(r,D){return m.call(ba(D.parentNode),function(R){return R!==D})}),f)},empty:function(){return this.each(function(){this.innerHTML=""})},pluck:function(f){return x.map(this,function(r){return r[f]})},show:function(){return this.each(function(){"none"==this.style.display&&(this.style.display="");if("none"==getComputedStyle(this,"").getPropertyValue("display")){var f=
152
152
  this.style,r=this.nodeName;if(!v[r]){var D=l.createElement(r);l.body.appendChild(D);var R=getComputedStyle(D,"").getPropertyValue("display");D.parentNode.removeChild(D);"none"==R&&(R="block");v[r]=R}f.display=v[r]}})},replaceWith:function(f){return this.before(f).remove()},wrap:function(f){var r=y(f);if(this[0]&&!r)var D=x(f).get(0),R=D.parentNode||1<this.length;return this.each(function(ea){x(this).wrapAll(r?f.call(this,ea):R?D.cloneNode(!0):D)})},wrapAll:function(f){if(this[0]){x(this[0]).before(f=
153
153
  x(f));for(var r;(r=f.children()).length;)f=r.first();x(f).append(this)}return this},wrapInner:function(f){var r=y(f);return this.each(function(D){var R=x(this),ea=R.contents();D=r?f.call(this,D):f;ea.length?ea.wrapAll(D):R.append(D)})},unwrap:function(){this.parent().each(function(){x(this).replaceWith(x(this).children())});return this},clone:function(){return this.map(function(){return this.cloneNode(!0)})},hide:function(){return this.css("display","none")},toggle:function(f){return this.each(function(){var r=
154
154
  x(this);(f===ha?"none"==r.css("display"):f)?r.show():r.hide()})},prev:function(f){return x(this.pluck("previousElementSibling")).filter(f||"*")},next:function(f){return x(this.pluck("nextElementSibling")).filter(f||"*")},html:function(f){return 0 in arguments?this.each(function(r){var D=this.innerHTML;x(this).empty().append(Y(this,f,r,D))}):0 in this?this[0].innerHTML:null},text:function(f){return 0 in arguments?this.each(function(r){r=Y(this,f,r,this.textContent);this.textContent=null==r?"":""+r}):
155
- 0 in this?this.pluck("textContent").join(""):null},attr:function(f,r){var D;return"string"!=typeof f||1 in arguments?this.each(function(R){if(1===this.nodeType)if(J(f))for(ca in f){var ea=ca;R=f[ca];null==R?this.removeAttribute(ea):this.setAttribute(ea,R)}else ea=f,R=Y(this,r,R,this.getAttribute(f)),null==R?this.removeAttribute(ea):this.setAttribute(ea,R)}):0 in this&&1==this[0].nodeType&&null!=(D=this[0].getAttribute(f))?D:ha},removeAttr:function(f){return this.each(function(){1===this.nodeType&&
155
+ 0 in this?this.pluck("textContent").join(""):null},attr:function(f,r){var D;return"string"!=typeof f||1 in arguments?this.each(function(R){if(1===this.nodeType)if(I(f))for(ca in f){var ea=ca;R=f[ca];null==R?this.removeAttribute(ea):this.setAttribute(ea,R)}else ea=f,R=Y(this,r,R,this.getAttribute(f)),null==R?this.removeAttribute(ea):this.setAttribute(ea,R)}):0 in this&&1==this[0].nodeType&&null!=(D=this[0].getAttribute(f))?D:ha},removeAttr:function(f){return this.each(function(){1===this.nodeType&&
156
156
  f.split(" ").forEach(function(r){this.removeAttribute(r)},this)})},prop:function(f,r){f=V[f]||f;return 1 in arguments?this.each(function(D){this[f]=Y(this,r,D,this[f])}):this[0]&&this[0][f]},removeProp:function(f){f=V[f]||f;return this.each(function(){delete this[f]})},data:function(f,r){if("object"===typeof r)this.length&&(this[0][f]=r);else{if("undefined"===typeof r){if(this.length&&"undefined"!==typeof this[0][f])return this[0][f]}else this.length&&("undefined"!==typeof this[0][f]&&delete this[0][f],
157
157
  r&&(this[0][f]=r));var D="data-"+f.replace(H,"-$1").toLowerCase();D=1 in arguments?this.attr(D,r):this.attr(D);return null!==D?ia(D):ha}},val:function(f){return 0 in arguments?(null==f&&(f=""),this.each(function(r){this.value=Y(this,f,r,this.value)})):this[0]&&(this[0].multiple?x(this[0]).find("option").filter(function(){return this.selected}).pluck("value"):this[0].value)},offset:function(f){if(f)return this.each(function(D){var R=x(this);D=Y(this,f,D,R.offset());var ea=R.offsetParent().offset();
158
158
  D={top:D.top-ea.top,left:D.left-ea.left};"static"==R.css("position")&&(D.position="relative");R.css(D)});if(!this.length)return null;if(l.documentElement!==this[0]&&!x.contains(l.documentElement,this[0]))return{top:0,left:0};var r=this[0].getBoundingClientRect();return{left:r.left+p.pageXOffset,top:r.top+p.pageYOffset,width:Math.round(r.width),height:Math.round(r.height)}},css:function(f,r){if(2>arguments.length){var D=this[0];if("string"==typeof f)return D?D.style[g(f)]||getComputedStyle(D,"").getPropertyValue(f):
159
- void 0;if(W(f)){if(!D)return;var R={},ea=getComputedStyle(D,"");x.each(f,function(wa,ta){R[ta]=D.style[g(ta)]||ea.getPropertyValue(ta)});return R}}var da="";if("string"==u(f))r||0===r?da=P(f)+":"+Z(f,r):this.each(function(){this.style.removeProperty(P(f))});else for(ca in f)f[ca]||0===f[ca]?da+=P(ca)+":"+Z(ca,f[ca])+";":this.each(function(){this.style.removeProperty(P(ca))});return this.each(function(){this.style.cssText+=";"+da})},index:function(f){return f?this.indexOf(x(f)[0]):this.parent().children().indexOf(this[0])},
159
+ void 0;if(W(f)){if(!D)return;var R={},ea=getComputedStyle(D,"");x.each(f,function(wa,ta){R[ta]=D.style[g(ta)]||ea.getPropertyValue(ta)});return R}}var da="";if("string"==u(f))r||0===r?da=O(f)+":"+Z(f,r):this.each(function(){this.style.removeProperty(O(f))});else for(ca in f)f[ca]||0===f[ca]?da+=O(ca)+":"+Z(ca,f[ca])+";":this.each(function(){this.style.removeProperty(O(ca))});return this.each(function(){this.style.cssText+=";"+da})},index:function(f){return f?this.indexOf(x(f)[0]):this.parent().children().indexOf(this[0])},
160
160
  hasClass:function(f){return f?e.some.call(this,function(r){return this.test(ka(r))},Q(f)):!1},addClass:function(f){return f?this.each(function(r){if("className"in this){oa=[];var D=ka(this);Y(this,f,r,D).split(/\s+/g).forEach(function(R){x(this).hasClass(R)||oa.push(R)},this);oa.length&&ka(this,D+(D?" ":"")+oa.join(" "))}}):this},removeClass:function(f){return this.each(function(r){if("className"in this){if(f===ha)return ka(this,"");oa=ka(this);Y(this,f,r,oa).split(/\s+/g).forEach(function(D){oa=
161
161
  oa.replace(Q(D)," ")});ka(this,oa.trim())}})},toggleClass:function(f,r){return f?this.each(function(D){var R=x(this);Y(this,f,D,ka(this)).split(/\s+/g).forEach(function(ea){(r===ha?!R.hasClass(ea):r)?R.addClass(ea):R.removeClass(ea)})}):this},scrollTop:function(f){if(this.length){var r="scrollTop"in this[0];return f===ha?r?this[0].scrollTop:this[0].pageYOffset:this.each(r?function(){this.scrollTop=f}:function(){this.scrollTo(this.scrollX,f)})}},scrollLeft:function(f){if(this.length){var r="scrollLeft"in
162
162
  this[0];return f===ha?r?this[0].scrollLeft:this[0].pageXOffset:this.each(r?function(){this.scrollLeft=f}:function(){this.scrollTo(f,this.scrollY)})}},position:function(){if(this.length){var f=this[0],r=this.offsetParent(),D=this.offset(),R=la.test(r[0].nodeName)?{top:0,left:0}:r.offset();D.top-=parseFloat(x(f).css("margin-top"))||0;D.left-=parseFloat(x(f).css("margin-left"))||0;R.top+=parseFloat(x(r[0]).css("border-top-width"))||0;R.left+=parseFloat(x(r[0]).css("border-left-width"))||0;return{top:D.top-
163
163
  R.top,left:D.left-R.left}}},offsetParent:function(){return this.map(function(){for(var f=this.offsetParent||l.body;f&&!la.test(f.nodeName)&&"static"==x(f).css("position");)f=f.offsetParent;return f})}};x.fn.detach=x.fn.remove;["width","height"].forEach(function(f){var r=f.replace(/./,function(D){return D[0].toUpperCase()});x.fn[f]=function(D){var R,ea=this[0];return D===ha?F(ea)?ea["inner"+r]:null!=ea&&ea.nodeType==ea.DOCUMENT_NODE?ea.documentElement["scroll"+r]:(R=this.offset())&&R[f]:this.each(function(da){ea=
164
164
  x(this);ea.css(f,Y(this,D,da,ea[f]()))})}});x.fn.innerWidth=function(){return this.width()};x.fn.innerHeight=function(){return this.height()};["after","prepend","before","append"].forEach(function(f,r){var D=r%2;x.fn[f]=function(){var R,ea=x.map(arguments,function(ta){var ua=[];R=u(ta);return"array"==R?(ta.forEach(function(Aa){if(Aa.nodeType!==ha)return ua.push(Aa);if(x.zepto.isZ(Aa))return ua=ua.concat(Aa.get());ua=ua.concat(S.fragment(Aa))}),ua):"object"==R||null==ta?ta:S.fragment(ta)}),da,wa=1<
165
165
  this.length;return 1>ea.length?this:this.each(function(ta,ua){da=D?ua:ua.parentNode;ua=0==r?ua.nextSibling:1==r?ua.firstChild:2==r?ua:null;var Aa=x.contains(l.documentElement,da);ea.forEach(function(ya){if(wa)ya=ya.cloneNode(!0);else if(!da)return x(ya).remove();da.insertBefore(ya,ua);Aa&&na(ya,function(za){if(!(null==za.nodeName||"SCRIPT"!==za.nodeName.toUpperCase()||za.type&&"text/javascript"!==za.type||za.src)){var E=za.ownerDocument?za.ownerDocument.defaultView:p;E.eval.call(E,za.innerHTML)}})})})};
166
- x.fn[D?f+"To":"insert"+(r?"Before":"After")]=function(R){x(R)[f](this);return this}});S.Z.prototype=aa.prototype=x.fn;S.uniq=t;S.deserializeValue=ia;x.zepto=S;return x}();p.mQuery=B;void 0===p.$$&&(p.$$=B);(function(u){function y(m){return m._zid||(m._zid=Z++)}function F(m,c,l,v){c=J(c);if(c.ns)var A=new RegExp("(?:^| )"+c.ns.replace(" "," .* ?")+"(?: |$)");return(Y[y(m)]||[]).filter(function(K){return K&&(!c.e||K.e==c.e)&&(!c.ns||A.test(K.ns))&&(!l||y(K.fn)===y(l))&&(!v||K.sel==v)})}function J(m){m=
167
- (""+m).split(".");return{e:m[0],ns:m.slice(1).sort().join(" ")}}function w(m){return ha[m]||ia&&na[m]||m}function L(m,c,l,v,A,K,b){var O=y(m),z=Y[O]||(Y[O]=[]);c.split(/\s/).forEach(function(la){if("ready"==la)return u(document).ready(l);var H=J(la);H.fn=l;H.sel=A;H.e in ha&&(l=function(d){var h=d.relatedTarget;if(!h||h!==this&&!u.contains(this,h))return H.fn.apply(this,arguments)});var ja=(H.del=K)||l;H.proxy=function(d){d=P(d);if(!d.isImmediatePropagationStopped()){d.data=v;var h=ja.apply(m,d._args==
168
- ba?[d]:[d].concat(d._args));!1===h&&(d.preventDefault(),d.stopPropagation());return h}};H.i=z.length;z.push(H);"addEventListener"in m&&m.addEventListener(w(H.e),H.proxy,H.del&&!ia&&H.e in na||!!b)})}function M(m,c,l,v,A){var K=y(m);(c||"").split(/\s/).forEach(function(b){F(m,b,l,v).forEach(function(O){delete Y[K][O.i];"removeEventListener"in m&&m.removeEventListener(w(O.e),O.proxy,O.del&&!ia&&O.e in na||!!A)})})}function P(m,c){if(c||!m.isDefaultPrevented)if(c||=m,u.each(n,function(l,v){var A=c[l];
169
- m[l]=function(){this[v]=ca;return A&&A.apply(c,arguments)};m[v]=oa}),m.timeStamp||(m.timeStamp=Date.now()),c.defaultPrevented!==ba?c.defaultPrevented:"returnValue"in c?!1===c.returnValue:c.getPreventDefault&&c.getPreventDefault())m.isDefaultPrevented=ca;return m}function Q(m){var c,l={originalEvent:m};for(c in m)e.test(c)||m[c]===ba||(l[c]=m[c]);return P(l,m)}var Z=1,ba,aa=Array.prototype.slice,fa=u.isFunction,ma=function(m){return"string"==typeof m},Y={},ka={},ia="onfocusin"in p,na={focus:"focusin",
170
- blur:"focusout"},ha={mouseenter:"mouseover",mouseleave:"mouseout"};ka.click=ka.mousedown=ka.mouseup=ka.mousemove="MouseEvents";u.event={add:L,remove:M};u.proxy=function(m,c){var l=2 in arguments&&aa.call(arguments,2);if(fa(m)){var v=function(){return m.apply(c,l?l.concat(aa.call(arguments)):arguments)};v._zid=y(m);return v}if(ma(c))return l?(l.unshift(m[c],m),u.proxy.apply(null,l)):u.proxy(m[c],m);throw new TypeError("expected function");};u.fn.bind=function(m,c,l){return this.on(m,c,l)};u.fn.unbind=
166
+ x.fn[D?f+"To":"insert"+(r?"Before":"After")]=function(R){x(R)[f](this);return this}});S.Z.prototype=aa.prototype=x.fn;S.uniq=t;S.deserializeValue=ia;x.zepto=S;return x}();p.mQuery=B;void 0===p.$$&&(p.$$=B);(function(u){function y(m){return m._zid||(m._zid=Z++)}function F(m,c,l,v){c=I(c);if(c.ns)var A=new RegExp("(?:^| )"+c.ns.replace(" "," .* ?")+"(?: |$)");return(Y[y(m)]||[]).filter(function(M){return M&&(!c.e||M.e==c.e)&&(!c.ns||A.test(M.ns))&&(!l||y(M.fn)===y(l))&&(!v||M.sel==v)})}function I(m){m=
167
+ (""+m).split(".");return{e:m[0],ns:m.slice(1).sort().join(" ")}}function w(m){return ha[m]||ia&&na[m]||m}function K(m,c,l,v,A,M,b){var P=y(m),z=Y[P]||(Y[P]=[]);c.split(/\s/).forEach(function(la){if("ready"==la)return u(document).ready(l);var H=I(la);H.fn=l;H.sel=A;H.e in ha&&(l=function(d){var h=d.relatedTarget;if(!h||h!==this&&!u.contains(this,h))return H.fn.apply(this,arguments)});var ja=(H.del=M)||l;H.proxy=function(d){d=O(d);if(!d.isImmediatePropagationStopped()){d.data=v;var h=ja.apply(m,d._args==
168
+ ba?[d]:[d].concat(d._args));!1===h&&(d.preventDefault(),d.stopPropagation());return h}};H.i=z.length;z.push(H);"addEventListener"in m&&m.addEventListener(w(H.e),H.proxy,H.del&&!ia&&H.e in na||!!b)})}function L(m,c,l,v,A){var M=y(m);(c||"").split(/\s/).forEach(function(b){F(m,b,l,v).forEach(function(P){delete Y[M][P.i];"removeEventListener"in m&&m.removeEventListener(w(P.e),P.proxy,P.del&&!ia&&P.e in na||!!A)})})}function O(m,c){if(c||!m.isDefaultPrevented)if(c||=m,u.each(n,function(l,v){var A=c[l];
169
+ m[l]=function(){this[v]=ca;return A&&A.apply(c,arguments)};m[v]=oa}),m.timeStamp||(m.timeStamp=Date.now()),c.defaultPrevented!==ba?c.defaultPrevented:"returnValue"in c?!1===c.returnValue:c.getPreventDefault&&c.getPreventDefault())m.isDefaultPrevented=ca;return m}function Q(m){var c,l={originalEvent:m};for(c in m)e.test(c)||m[c]===ba||(l[c]=m[c]);return O(l,m)}var Z=1,ba,aa=Array.prototype.slice,fa=u.isFunction,ma=function(m){return"string"==typeof m},Y={},ka={},ia="onfocusin"in p,na={focus:"focusin",
170
+ blur:"focusout"},ha={mouseenter:"mouseover",mouseleave:"mouseout"};ka.click=ka.mousedown=ka.mouseup=ka.mousemove="MouseEvents";u.event={add:K,remove:L};u.proxy=function(m,c){var l=2 in arguments&&aa.call(arguments,2);if(fa(m)){var v=function(){return m.apply(c,l?l.concat(aa.call(arguments)):arguments)};v._zid=y(m);return v}if(ma(c))return l?(l.unshift(m[c],m),u.proxy.apply(null,l)):u.proxy(m[c],m);throw new TypeError("expected function");};u.fn.bind=function(m,c,l){return this.on(m,c,l)};u.fn.unbind=
171
171
  function(m,c){return this.off(m,c)};u.fn.one=function(m,c,l,v){return this.on(m,c,l,v,1)};var ca=function(){return!0},oa=function(){return!1},e=/^([A-Z]|returnValue$|layer[XY]$|webkitMovement[XY]$)/,n={preventDefault:"isDefaultPrevented",stopImmediatePropagation:"isImmediatePropagationStopped",stopPropagation:"isPropagationStopped"};u.fn.delegate=function(m,c,l){return this.on(c,m,l)};u.fn.undelegate=function(m,c,l){return this.off(c,m,l)};u.fn.live=function(m,c){u(document.body).delegate(this.selector,
172
- m,c);return this};u.fn.die=function(m,c){u(document.body).undelegate(this.selector,m,c);return this};u.fn.on=function(m,c,l,v,A){var K,b,O=this;if(m&&!ma(m))return u.each(m,function(z,la){O.on(z,c,l,la,A)}),O;ma(c)||fa(v)||!1===v||(v=l,l=c,c=ba);if(v===ba||!1===l)v=l,l=ba;!1===v&&(v=oa);return O.each(function(z,la){A&&(K=function(H){M(la,H.type,v);return v.apply(this,arguments)});c&&(b=function(H){var ja=u(H.target).closest(c,la).get(0);if(ja&&ja!==la){var d=u.extend(Q(H),{currentTarget:ja,liveFired:la});
173
- return(K||v).apply(ja,[d].concat(aa.call(arguments,1)))}});L(la,m,v,l,c,b||K)})};u.fn.off=function(m,c,l){var v=this;if(m&&!ma(m))return u.each(m,function(A,K){v.off(A,c,K)}),v;ma(c)||fa(l)||!1===l||(l=c,c=ba);!1===l&&(l=oa);return v.each(function(){M(this,m,l,c)})};u.fn.trigger=function(m,c){m=ma(m)||u.isPlainObject(m)?u.Event(m):P(m);m._args=c;return this.each(function(){if(m.type in na&&"function"==typeof this[m.type])this[m.type]();else"dispatchEvent"in this?this.dispatchEvent(m):u(this).triggerHandler(m,
174
- c)})};u.fn.triggerHandler=function(m,c){var l,v;this.each(function(A,K){l=Q(ma(m)?u.Event(m):m);l._args=c;l.target=K;u.each(F(K,m.type||m),function(b,O){v=O.proxy(l);if(l.isImmediatePropagationStopped())return!1})});return v};"focusin focusout focus blur load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select keydown keypress keyup error".split(" ").forEach(function(m){u.fn[m]=function(c){return 0 in arguments?this.bind(m,c):this.trigger(m)}});
175
- u.Event=function(m,c){ma(m)||(c=m,m=c.type);var l=document.createEvent(ka[m]||"Events"),v=!0;if(c)for(var A in c)"bubbles"==A?v=!!c[A]:l[A]=c[A];l.initEvent(m,v,!0);return P(l)}})(B);(function(u){["width","height"].forEach(function(y){var F=y.replace(/./,function(J){return J[0].toUpperCase()});u.fn["outer"+F]=function(J){var w=this;if(w){var L=w[y]();({width:["left","right"],height:["top","bottom"]})[y].forEach(function(M){J&&(L+=parseInt(w.css("margin-"+M),10))});return L}return null}})})(B);(function(u){function y(m,
176
- c,l,v){if(m.global)return m=c||Y,l=u.Event(l),u(m).trigger(l,v),!l.isDefaultPrevented()}function F(m){m.global&&0===u.active++&&y(m,null,"ajaxStart")}function J(m,c){var l=c.context;if(!1===c.beforeSend.call(l,m,c)||!1===y(c,l,"ajaxBeforeSend",[m,c]))return!1;y(c,l,"ajaxSend",[m,c])}function w(m,c,l,v){var A=l.context;l.success.call(A,m,"success",c);v&&v.resolveWith(A,[m,"success",c]);y(l,A,"ajaxSuccess",[c,l,m]);M("success",c,l)}function L(m,c,l,v,A){var K=v.context;v.error.call(K,l,c,m);A&&A.rejectWith(K,
177
- [l,c,m]);y(v,K,"ajaxError",[l,v,m||c]);M(c,l,v)}function M(m,c,l){var v=l.context;l.complete.call(v,c,m);y(l,v,"ajaxComplete",[c,l]);l.global&&!--u.active&&y(l,null,"ajaxStop")}function P(){}function Q(m){m&&=m.split(";",2)[0];return m&&("text/html"==m?"html":"application/json"==m?"json":ha.test(m)?"script":ca.test(m)&&"xml")||"text"}function Z(m,c){return""==c?m:(m+"&"+c).replace(/[&?]{1,2}/,"?")}function ba(m){m.processData&&m.data&&"string"!=u.type(m.data)&&(m.data=u.param(m.data,m.traditional));
178
- !m.data||m.type&&"GET"!=m.type.toUpperCase()&&"jsonp"!=m.dataType||(m.url=Z(m.url,m.data),m.data=void 0)}function aa(m,c,l,v){u.isFunction(c)&&(v=l,l=c,c=void 0);u.isFunction(l)||(v=l,l=void 0);return{url:m,data:c,success:l,dataType:v}}function fa(m,c,l,v){var A,K=u.isArray(c),b=u.isPlainObject(c);u.each(c,function(O,z){A=u.type(z);v&&(O=l?v:v+"["+(b||"object"==A||"array"==A?O:"")+"]");!v&&K?m.add(z.name,z.value):"array"==A||!l&&"object"==A?fa(m,z,l,O):m.add(O,z)})}var ma=+new Date,Y=p.document,ka,
179
- ia,na=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,ha=/^(?:text|application)\/javascript/i,ca=/^(?:text|application)\/xml/i,oa=/^\s*$/,e=Y.createElement("a");e.href=p.location.href;u.active=0;u.ajaxJSONP=function(m,c){if(!("type"in m))return u.ajax(m);var l=m.jsonpCallback,v=(u.isFunction(l)?l():l)||"Zepto"+ma++,A=Y.createElement("script"),K=p[v],b,O=function(H){u(A).triggerHandler("error",H||"abort")},z={abort:O},la;c&&c.promise(z);u(A).on("load error",function(H,ja){clearTimeout(la);u(A).off().remove();
180
- "error"!=H.type&&b?w(b[0],z,m,c):L(null,ja||"error",z,m,c);p[v]=K;b&&u.isFunction(K)&&K(b[0]);K=b=void 0});if(!1===J(z,m))return O("abort"),z;p[v]=function(){b=arguments};A.src=m.url.replace(/\?(.+)=\?/,"?$1="+v);Y.head.appendChild(A);0<m.timeout&&(la=setTimeout(function(){O("timeout")},m.timeout));return z};u.ajaxSettings={type:"GET",beforeSend:P,success:P,error:P,complete:P,context:null,global:!0,xhr:function(){return new p.XMLHttpRequest},accepts:{script:"text/javascript, application/javascript, application/x-javascript",
181
- json:"application/json",xml:"application/xml, text/xml",html:"text/html",text:"text/plain"},crossDomain:!1,timeout:0,processData:!0,cache:!0,dataFilter:P};u.ajax=function(m){var c=u.extend({},m||{}),l=u.Deferred&&u.Deferred();for(ka in u.ajaxSettings)void 0===c[ka]&&(c[ka]=u.ajaxSettings[ka]);F(c);if(!c.crossDomain){var v=Y.createElement("a");v.href=c.url;v.href=v.href;c.crossDomain=e.protocol+"//"+e.host!==v.protocol+"//"+v.host}c.url||(c.url=p.location.toString());-1<(v=c.url.indexOf("#"))&&(c.url=
182
- c.url.slice(0,v));ba(c);var A=c.dataType;(v=/\?.+=\?/.test(c.url))&&(A="jsonp");!1!==c.cache&&(m&&!0===m.cache||"script"!=A&&"jsonp"!=A)||(c.url=Z(c.url,"_="+Date.now()));if("jsonp"==A)return v||(c.url=Z(c.url,c.jsonp?c.jsonp+"=?":!1===c.jsonp?"":"callback=?")),u.ajaxJSONP(c,l);m=c.accepts[A];var K={};v=function(H,ja){K[H.toLowerCase()]=[H,ja]};var b=/^([\w-]+:)\/\//.test(c.url)?RegExp.$1:p.location.protocol,O=c.xhr(),z=O.setRequestHeader,la;l&&l.promise(O);c.crossDomain||v("X-Requested-With","XMLHttpRequest");
183
- v("Accept",m||"*/*");if(m=c.mimeType||m)-1<m.indexOf(",")&&(m=m.split(",",2)[0]),O.overrideMimeType&&O.overrideMimeType(m);(c.contentType||!1!==c.contentType&&c.data&&"GET"!=c.type.toUpperCase())&&v("Content-Type",c.contentType||"application/x-www-form-urlencoded");if(c.headers)for(ia in c.headers)v(ia,c.headers[ia]);O.setRequestHeader=v;O.onreadystatechange=function(){if(4==O.readyState){O.onreadystatechange=P;clearTimeout(la);var H=!1;if(200<=O.status&&300>O.status||304==O.status||0==O.status&&
184
- "file:"==b){A=A||Q(c.mimeType||O.getResponseHeader("content-type"));if("arraybuffer"==O.responseType||"blob"==O.responseType)var ja=O.response;else{ja=O.responseText;try{ja=c.dataFilter==P?ja:c.dataFilter.call(c.context,ja,A),"script"==A?(0,eval)(ja):"xml"==A?ja=O.responseXML:"json"==A&&(ja=oa.test(ja)?null:u.parseJSON(ja))}catch(d){H=d}if(H)return L(H,"parsererror",O,c,l)}w(ja,O,c,l)}else L(O.statusText||null,O.status?"error":"abort",O,c,l)}};if(!1===J(O,c))return O.abort(),L(null,"abort",O,c,l),
185
- O;O.open(c.type,c.url,"async"in c?c.async:!0,c.username,c.password);if(c.xhrFields)for(ia in c.xhrFields)O[ia]=c.xhrFields[ia];for(ia in K)z.apply(O,K[ia]);0<c.timeout&&(la=setTimeout(function(){O.onreadystatechange=P;O.abort();L(null,"timeout",O,c,l)},c.timeout));O.send(c.data?c.data:null);return O};u.get=function(){return u.ajax(aa.apply(null,arguments))};u.post=function(){var m=aa.apply(null,arguments);m.type="POST";return u.ajax(m)};u.getJSON=function(){var m=aa.apply(null,arguments);m.dataType=
186
- "json";return u.ajax(m)};u.fn.load=function(m,c,l){if(!this.length)return this;var v=this,A=m.split(/\s/);m=aa(m,c,l);var K=m.success;if(1<A.length){m.url=A[0];var b=A[1]}m.success=function(O){v.html(b?u("<div>").html(O.replace(na,"")).find(b):O);K&&K.apply(v,arguments)};u.ajax(m);return this};var n=encodeURIComponent;u.param=function(m,c){var l=[];l.add=function(v,A){u.isFunction(A)&&(A=A());null==A&&(A="");this.push(n(v)+"="+n(A))};fa(l,m,c);return l.join("&").replace(/%20/g,"+")}})(B);(function(u){u.fn.serializeArray=
187
- function(){var y,F,J=[],w=function(L){if(L.forEach)return L.forEach(w);J.push({name:y,value:L})};this[0]&&u.each(this[0].elements,function(L,M){F=M.type;(y=M.name)&&"fieldset"!=M.nodeName.toLowerCase()&&!M.disabled&&"submit"!=F&&"reset"!=F&&"button"!=F&&"file"!=F&&("radio"!=F&&"checkbox"!=F||M.checked)&&w(u(M).val())});return J};u.fn.serialize=function(){var y=[];this.serializeArray().forEach(function(F){y.push(encodeURIComponent(F.name)+"="+encodeURIComponent(F.value))});return y.join("&")};u.fn.submit=
188
- function(y){if(0 in arguments)this.bind("submit",y);else if(this.length){var F=u.Event("submit");this.eq(0).trigger(F);F.isDefaultPrevented()||this.get(0).submit()}return this}})(B);(function(u,y){function F(ha){return w?w+ha:ha.toLowerCase()}var J="",w,L={Webkit:"webkit",Moz:"",O:"o"},M=document.createElement("div"),P=/^((translate|rotate|scale)(X|Y|Z|3d)?|matrix(3d)?|perspective|skew(X|Y)?)$/i,Q,Z,ba,aa,fa,ma,Y,ka,ia={};M.style.transform===y&&u.each(L,function(ha,ca){if(M.style[ha+"TransitionProperty"]!==
189
- y)return J="-"+ha.toLowerCase()+"-",w=ca,!1});var na=J+"transform";ia[Q=J+"transition-property"]=ia[Z=J+"transition-duration"]=ia[aa=J+"transition-delay"]=ia[ba=J+"transition-timing-function"]=ia[fa=J+"animation-name"]=ia[ma=J+"animation-duration"]=ia[ka=J+"animation-delay"]=ia[Y=J+"animation-timing-function"]="";u.fx={off:w===y&&M.style.transitionProperty===y,speeds:{_default:400,fast:200,slow:600},cssPrefix:J,transitionEnd:F("TransitionEnd"),animationEnd:F("AnimationEnd")};u.fn.animate=function(ha,
190
- ca,oa,e,n){u.isFunction(ca)&&(e=ca,ca=oa=y);u.isFunction(oa)&&(e=oa,oa=y);u.isPlainObject(ca)&&(oa=ca.easing,e=ca.complete,n=ca.delay,ca=ca.duration);ca&&=("number"==typeof ca?ca:u.fx.speeds[ca]||u.fx.speeds._default)/1E3;n&&=parseFloat(n)/1E3;return this.anim(ha,ca,oa,e,n)};u.fn.anim=function(ha,ca,oa,e,n){var m,c={},l="",v=this,A=u.fx.transitionEnd,K=!1;ca===y&&(ca=u.fx.speeds._default/1E3);n===y&&(n=0);u.fx.off&&(ca=0);if("string"==typeof ha)c[fa]=ha,c[ma]=ca+"s",c[ka]=n+"s",c[Y]=oa||"linear",
191
- A=u.fx.animationEnd;else{var b=[];for(m in ha)P.test(m)?l+=m+"("+ha[m]+") ":(c[m]=ha[m],b.push(m.replace(/([A-Z])/g,"-$1").toLowerCase()));l&&(c[na]=l,b.push(na));0<ca&&"object"===typeof ha&&(c[Q]=b.join(", "),c[Z]=ca+"s",c[aa]=n+"s",c[ba]=oa||"linear")}var O=function(z){if("undefined"!==typeof z){if(z.target!==z.currentTarget)return;u(z.target).unbind(A,O)}else u(this).unbind(A,O);K=!0;u(this).css(ia);e&&e.call(this)};0<ca&&(this.bind(A,O),setTimeout(function(){K||O.call(v)},1E3*(ca+n)+25));this.size()&&
192
- this.get(0).clientLeft;this.css(c);0>=ca&&setTimeout(function(){v.each(function(){O.call(this)})},0);return this};u.fn.stop=function(ha,ca){return this};M=null})(B);(function(){try{getComputedStyle(void 0)}catch(y){var u=getComputedStyle;p.getComputedStyle=function(F,J){try{return u(F,J)}catch(w){return null}}}})();return B}(I));var Da=function(){if(document.currentScript)var p=document.currentScript.src;else{p=document.scripts;for(var B=p.length-1,u,y=B;0<y;y--)if("interactive"===p[y].readyState){u=
193
- p[y].src;break}p=u||p[B].src}B=p.indexOf("v=");B=0<B?p.substr(B+2):2023;p=p.substring(0,p.lastIndexOf("/")+1);p.endsWith("zwplayer/")||(p+="js/");return{path:p,v:B}}(),Ia=Da.path+"plugins/",Ja=function(p,B,u){var y=document.getElementsByTagName("head");if(0==y.length){y=document.createElement("head");var F=document.getElementsByTagName("body");if(0<F.length)F=F[0],document.insertBefore(y,F);else return alert("Invalid html document: no HEAD tag"),!1}else{y=y[0];F=y.childNodes;for(var J=0;J<F.length;J++){var w=
194
- F[J];if("SCRIPT"===w.nodeName.toUpperCase()&&w.id&&w.id==p){if("true"!=w.getAttribute("loadstate")){var L=function(){"true"!=w.getAttribute("loadstate")?setTimeout(L,50):"function"==typeof u&&u(p)};setTimeout(L,50);return!1}"function"==typeof u&&u(p);return!0}}}var M=document.createElement("script");M.type="text/javascript";M.readyState?M.onreadystatechange=function(){if("loaded"==M.readyState||"complete"==M.readyState)M.onreadystatechange=null,M.setAttribute("loadstate","true"),"function"==typeof u&&
195
- u(p)}:M.onload=function(){M.setAttribute("loadstate","true");"function"==typeof u&&u(p)};M.id=p;M.src=B;y.appendChild(M);return!1};(function(p,B,u){var y=document.getElementsByTagName("head");if(0==y.length){y=document.createElement("head");var F=document.getElementsByTagName("body");if(0<F.length)F=F[0],document.insertBefore(y,F);else return alert("Invalid html document: no HEAD tag found"),!1}else{y=y[0];F=y.childNodes;for(var J=0;J<F.length;J++){var w=F[J];if("link"===w.nodeName.toUpperCase()&&
196
- w.id&&w.id==p){if("true"!==w.getAttribute("loadstate")){var L=function(){"true"!==w.getAttribute("loadstate")?setTimeout(L,50):"function"===typeof u&&u(p)};setTimeout(L,50);return!1}"function"===typeof u&&u(p);return!0}}}var M=document.createElement("link");M.type="text/css";M.setAttribute("rel","stylesheet");M.readyState?M.onreadystatechange=function(){if("loaded"==M.readyState||"complete"==M.readyState)M.onreadystatechange=null,M.setAttribute("loadstate","true"),"function"==typeof u&&u(p)}:M.onload=
197
- function(){M.setAttribute("loadstate","true");"function"==typeof u&&u(p)};M.id=p;M.href=B;y.appendChild(M);return!1})("zwplayer-css",Da.path+"css/zwplayer.css?v="+Da.v,function(p){console.log("zwplayer.css["+p+"] is loaded")});var Ua=function(p){return"object"===typeof HTMLElement?p instanceof HTMLElement:!(!p||"object"!==typeof p||1!==p.nodeType&&9!==p.nodeType||"string"!==typeof p.nodeName)};Array.isArray||(Array.isArray=function(p){return"[object Array]"===Object.prototype.toString.call(p)});var Va=
172
+ m,c);return this};u.fn.die=function(m,c){u(document.body).undelegate(this.selector,m,c);return this};u.fn.on=function(m,c,l,v,A){var M,b,P=this;if(m&&!ma(m))return u.each(m,function(z,la){P.on(z,c,l,la,A)}),P;ma(c)||fa(v)||!1===v||(v=l,l=c,c=ba);if(v===ba||!1===l)v=l,l=ba;!1===v&&(v=oa);return P.each(function(z,la){A&&(M=function(H){L(la,H.type,v);return v.apply(this,arguments)});c&&(b=function(H){var ja=u(H.target).closest(c,la).get(0);if(ja&&ja!==la){var d=u.extend(Q(H),{currentTarget:ja,liveFired:la});
173
+ return(M||v).apply(ja,[d].concat(aa.call(arguments,1)))}});K(la,m,v,l,c,b||M)})};u.fn.off=function(m,c,l){var v=this;if(m&&!ma(m))return u.each(m,function(A,M){v.off(A,c,M)}),v;ma(c)||fa(l)||!1===l||(l=c,c=ba);!1===l&&(l=oa);return v.each(function(){L(this,m,l,c)})};u.fn.trigger=function(m,c){m=ma(m)||u.isPlainObject(m)?u.Event(m):O(m);m._args=c;return this.each(function(){if(m.type in na&&"function"==typeof this[m.type])this[m.type]();else"dispatchEvent"in this?this.dispatchEvent(m):u(this).triggerHandler(m,
174
+ c)})};u.fn.triggerHandler=function(m,c){var l,v;this.each(function(A,M){l=Q(ma(m)?u.Event(m):m);l._args=c;l.target=M;u.each(F(M,m.type||m),function(b,P){v=P.proxy(l);if(l.isImmediatePropagationStopped())return!1})});return v};"focusin focusout focus blur load resize scroll unload click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select keydown keypress keyup error".split(" ").forEach(function(m){u.fn[m]=function(c){return 0 in arguments?this.bind(m,c):this.trigger(m)}});
175
+ u.Event=function(m,c){ma(m)||(c=m,m=c.type);var l=document.createEvent(ka[m]||"Events"),v=!0;if(c)for(var A in c)"bubbles"==A?v=!!c[A]:l[A]=c[A];l.initEvent(m,v,!0);return O(l)}})(B);(function(u){["width","height"].forEach(function(y){var F=y.replace(/./,function(I){return I[0].toUpperCase()});u.fn["outer"+F]=function(I){var w=this;if(w){var K=w[y]();({width:["left","right"],height:["top","bottom"]})[y].forEach(function(L){I&&(K+=parseInt(w.css("margin-"+L),10))});return K}return null}})})(B);(function(u){function y(m,
176
+ c,l,v){if(m.global)return m=c||Y,l=u.Event(l),u(m).trigger(l,v),!l.isDefaultPrevented()}function F(m){m.global&&0===u.active++&&y(m,null,"ajaxStart")}function I(m,c){var l=c.context;if(!1===c.beforeSend.call(l,m,c)||!1===y(c,l,"ajaxBeforeSend",[m,c]))return!1;y(c,l,"ajaxSend",[m,c])}function w(m,c,l,v){var A=l.context;l.success.call(A,m,"success",c);v&&v.resolveWith(A,[m,"success",c]);y(l,A,"ajaxSuccess",[c,l,m]);L("success",c,l)}function K(m,c,l,v,A){var M=v.context;v.error.call(M,l,c,m);A&&A.rejectWith(M,
177
+ [l,c,m]);y(v,M,"ajaxError",[l,v,m||c]);L(c,l,v)}function L(m,c,l){var v=l.context;l.complete.call(v,c,m);y(l,v,"ajaxComplete",[c,l]);l.global&&!--u.active&&y(l,null,"ajaxStop")}function O(){}function Q(m){m&&=m.split(";",2)[0];return m&&("text/html"==m?"html":"application/json"==m?"json":ha.test(m)?"script":ca.test(m)&&"xml")||"text"}function Z(m,c){return""==c?m:(m+"&"+c).replace(/[&?]{1,2}/,"?")}function ba(m){m.processData&&m.data&&"string"!=u.type(m.data)&&(m.data=u.param(m.data,m.traditional));
178
+ !m.data||m.type&&"GET"!=m.type.toUpperCase()&&"jsonp"!=m.dataType||(m.url=Z(m.url,m.data),m.data=void 0)}function aa(m,c,l,v){u.isFunction(c)&&(v=l,l=c,c=void 0);u.isFunction(l)||(v=l,l=void 0);return{url:m,data:c,success:l,dataType:v}}function fa(m,c,l,v){var A,M=u.isArray(c),b=u.isPlainObject(c);u.each(c,function(P,z){A=u.type(z);v&&(P=l?v:v+"["+(b||"object"==A||"array"==A?P:"")+"]");!v&&M?m.add(z.name,z.value):"array"==A||!l&&"object"==A?fa(m,z,l,P):m.add(P,z)})}var ma=+new Date,Y=p.document,ka,
179
+ ia,na=/<script\b[^<]*(?:(?!<\/script>)<[^<]*)*<\/script>/gi,ha=/^(?:text|application)\/javascript/i,ca=/^(?:text|application)\/xml/i,oa=/^\s*$/,e=Y.createElement("a");e.href=p.location.href;u.active=0;u.ajaxJSONP=function(m,c){if(!("type"in m))return u.ajax(m);var l=m.jsonpCallback,v=(u.isFunction(l)?l():l)||"Zepto"+ma++,A=Y.createElement("script"),M=p[v],b,P=function(H){u(A).triggerHandler("error",H||"abort")},z={abort:P},la;c&&c.promise(z);u(A).on("load error",function(H,ja){clearTimeout(la);u(A).off().remove();
180
+ "error"!=H.type&&b?w(b[0],z,m,c):K(null,ja||"error",z,m,c);p[v]=M;b&&u.isFunction(M)&&M(b[0]);M=b=void 0});if(!1===I(z,m))return P("abort"),z;p[v]=function(){b=arguments};A.src=m.url.replace(/\?(.+)=\?/,"?$1="+v);Y.head.appendChild(A);0<m.timeout&&(la=setTimeout(function(){P("timeout")},m.timeout));return z};u.ajaxSettings={type:"GET",beforeSend:O,success:O,error:O,complete:O,context:null,global:!0,xhr:function(){return new p.XMLHttpRequest},accepts:{script:"text/javascript, application/javascript, application/x-javascript",
181
+ json:"application/json",xml:"application/xml, text/xml",html:"text/html",text:"text/plain"},crossDomain:!1,timeout:0,processData:!0,cache:!0,dataFilter:O};u.ajax=function(m){var c=u.extend({},m||{}),l=u.Deferred&&u.Deferred();for(ka in u.ajaxSettings)void 0===c[ka]&&(c[ka]=u.ajaxSettings[ka]);F(c);if(!c.crossDomain){var v=Y.createElement("a");v.href=c.url;v.href=v.href;c.crossDomain=e.protocol+"//"+e.host!==v.protocol+"//"+v.host}c.url||(c.url=p.location.toString());-1<(v=c.url.indexOf("#"))&&(c.url=
182
+ c.url.slice(0,v));ba(c);var A=c.dataType;(v=/\?.+=\?/.test(c.url))&&(A="jsonp");!1!==c.cache&&(m&&!0===m.cache||"script"!=A&&"jsonp"!=A)||(c.url=Z(c.url,"_="+Date.now()));if("jsonp"==A)return v||(c.url=Z(c.url,c.jsonp?c.jsonp+"=?":!1===c.jsonp?"":"callback=?")),u.ajaxJSONP(c,l);m=c.accepts[A];var M={};v=function(H,ja){M[H.toLowerCase()]=[H,ja]};var b=/^([\w-]+:)\/\//.test(c.url)?RegExp.$1:p.location.protocol,P=c.xhr(),z=P.setRequestHeader,la;l&&l.promise(P);c.crossDomain||v("X-Requested-With","XMLHttpRequest");
183
+ v("Accept",m||"*/*");if(m=c.mimeType||m)-1<m.indexOf(",")&&(m=m.split(",",2)[0]),P.overrideMimeType&&P.overrideMimeType(m);(c.contentType||!1!==c.contentType&&c.data&&"GET"!=c.type.toUpperCase())&&v("Content-Type",c.contentType||"application/x-www-form-urlencoded");if(c.headers)for(ia in c.headers)v(ia,c.headers[ia]);P.setRequestHeader=v;P.onreadystatechange=function(){if(4==P.readyState){P.onreadystatechange=O;clearTimeout(la);var H=!1;if(200<=P.status&&300>P.status||304==P.status||0==P.status&&
184
+ "file:"==b){A=A||Q(c.mimeType||P.getResponseHeader("content-type"));if("arraybuffer"==P.responseType||"blob"==P.responseType)var ja=P.response;else{ja=P.responseText;try{ja=c.dataFilter==O?ja:c.dataFilter.call(c.context,ja,A),"script"==A?(0,eval)(ja):"xml"==A?ja=P.responseXML:"json"==A&&(ja=oa.test(ja)?null:u.parseJSON(ja))}catch(d){H=d}if(H)return K(H,"parsererror",P,c,l)}w(ja,P,c,l)}else K(P.statusText||null,P.status?"error":"abort",P,c,l)}};if(!1===I(P,c))return P.abort(),K(null,"abort",P,c,l),
185
+ P;P.open(c.type,c.url,"async"in c?c.async:!0,c.username,c.password);if(c.xhrFields)for(ia in c.xhrFields)P[ia]=c.xhrFields[ia];for(ia in M)z.apply(P,M[ia]);0<c.timeout&&(la=setTimeout(function(){P.onreadystatechange=O;P.abort();K(null,"timeout",P,c,l)},c.timeout));P.send(c.data?c.data:null);return P};u.get=function(){return u.ajax(aa.apply(null,arguments))};u.post=function(){var m=aa.apply(null,arguments);m.type="POST";return u.ajax(m)};u.getJSON=function(){var m=aa.apply(null,arguments);m.dataType=
186
+ "json";return u.ajax(m)};u.fn.load=function(m,c,l){if(!this.length)return this;var v=this,A=m.split(/\s/);m=aa(m,c,l);var M=m.success;if(1<A.length){m.url=A[0];var b=A[1]}m.success=function(P){v.html(b?u("<div>").html(P.replace(na,"")).find(b):P);M&&M.apply(v,arguments)};u.ajax(m);return this};var n=encodeURIComponent;u.param=function(m,c){var l=[];l.add=function(v,A){u.isFunction(A)&&(A=A());null==A&&(A="");this.push(n(v)+"="+n(A))};fa(l,m,c);return l.join("&").replace(/%20/g,"+")}})(B);(function(u){u.fn.serializeArray=
187
+ function(){var y,F,I=[],w=function(K){if(K.forEach)return K.forEach(w);I.push({name:y,value:K})};this[0]&&u.each(this[0].elements,function(K,L){F=L.type;(y=L.name)&&"fieldset"!=L.nodeName.toLowerCase()&&!L.disabled&&"submit"!=F&&"reset"!=F&&"button"!=F&&"file"!=F&&("radio"!=F&&"checkbox"!=F||L.checked)&&w(u(L).val())});return I};u.fn.serialize=function(){var y=[];this.serializeArray().forEach(function(F){y.push(encodeURIComponent(F.name)+"="+encodeURIComponent(F.value))});return y.join("&")};u.fn.submit=
188
+ function(y){if(0 in arguments)this.bind("submit",y);else if(this.length){var F=u.Event("submit");this.eq(0).trigger(F);F.isDefaultPrevented()||this.get(0).submit()}return this}})(B);(function(u,y){function F(ha){return w?w+ha:ha.toLowerCase()}var I="",w,K={Webkit:"webkit",Moz:"",O:"o"},L=document.createElement("div"),O=/^((translate|rotate|scale)(X|Y|Z|3d)?|matrix(3d)?|perspective|skew(X|Y)?)$/i,Q,Z,ba,aa,fa,ma,Y,ka,ia={};L.style.transform===y&&u.each(K,function(ha,ca){if(L.style[ha+"TransitionProperty"]!==
189
+ y)return I="-"+ha.toLowerCase()+"-",w=ca,!1});var na=I+"transform";ia[Q=I+"transition-property"]=ia[Z=I+"transition-duration"]=ia[aa=I+"transition-delay"]=ia[ba=I+"transition-timing-function"]=ia[fa=I+"animation-name"]=ia[ma=I+"animation-duration"]=ia[ka=I+"animation-delay"]=ia[Y=I+"animation-timing-function"]="";u.fx={off:w===y&&L.style.transitionProperty===y,speeds:{_default:400,fast:200,slow:600},cssPrefix:I,transitionEnd:F("TransitionEnd"),animationEnd:F("AnimationEnd")};u.fn.animate=function(ha,
190
+ ca,oa,e,n){u.isFunction(ca)&&(e=ca,ca=oa=y);u.isFunction(oa)&&(e=oa,oa=y);u.isPlainObject(ca)&&(oa=ca.easing,e=ca.complete,n=ca.delay,ca=ca.duration);ca&&=("number"==typeof ca?ca:u.fx.speeds[ca]||u.fx.speeds._default)/1E3;n&&=parseFloat(n)/1E3;return this.anim(ha,ca,oa,e,n)};u.fn.anim=function(ha,ca,oa,e,n){var m,c={},l="",v=this,A=u.fx.transitionEnd,M=!1;ca===y&&(ca=u.fx.speeds._default/1E3);n===y&&(n=0);u.fx.off&&(ca=0);if("string"==typeof ha)c[fa]=ha,c[ma]=ca+"s",c[ka]=n+"s",c[Y]=oa||"linear",
191
+ A=u.fx.animationEnd;else{var b=[];for(m in ha)O.test(m)?l+=m+"("+ha[m]+") ":(c[m]=ha[m],b.push(m.replace(/([A-Z])/g,"-$1").toLowerCase()));l&&(c[na]=l,b.push(na));0<ca&&"object"===typeof ha&&(c[Q]=b.join(", "),c[Z]=ca+"s",c[aa]=n+"s",c[ba]=oa||"linear")}var P=function(z){if("undefined"!==typeof z){if(z.target!==z.currentTarget)return;u(z.target).unbind(A,P)}else u(this).unbind(A,P);M=!0;u(this).css(ia);e&&e.call(this)};0<ca&&(this.bind(A,P),setTimeout(function(){M||P.call(v)},1E3*(ca+n)+25));this.size()&&
192
+ this.get(0).clientLeft;this.css(c);0>=ca&&setTimeout(function(){v.each(function(){P.call(this)})},0);return this};u.fn.stop=function(ha,ca){return this};L=null})(B);(function(){try{getComputedStyle(void 0)}catch(y){var u=getComputedStyle;p.getComputedStyle=function(F,I){try{return u(F,I)}catch(w){return null}}}})();return B}(J));var Da=function(){if(document.currentScript)var p=document.currentScript.src;else{p=document.scripts;for(var B=p.length-1,u,y=B;0<y;y--)if("interactive"===p[y].readyState){u=
193
+ p[y].src;break}p=u||p[B].src}B=p.indexOf("v=");B=0<B?p.substr(B+2):2023;p=p.substring(0,p.lastIndexOf("/")+1);p.endsWith("zwplayer/")||(p+="js/");return{path:p,v:B}}(),Ia=Da.path+"plugins/",Ja=function(p,B,u){var y=document.getElementsByTagName("head");if(0==y.length){y=document.createElement("head");var F=document.getElementsByTagName("body");if(0<F.length)F=F[0],document.insertBefore(y,F);else return alert("Invalid html document: no HEAD tag"),!1}else{y=y[0];F=y.childNodes;for(var I=0;I<F.length;I++){var w=
194
+ F[I];if("SCRIPT"===w.nodeName.toUpperCase()&&w.id&&w.id==p){if("true"!=w.getAttribute("loadstate")){var K=function(){"true"!=w.getAttribute("loadstate")?setTimeout(K,50):"function"==typeof u&&u(p)};setTimeout(K,50);return!1}"function"==typeof u&&u(p);return!0}}}var L=document.createElement("script");L.type="text/javascript";L.readyState?L.onreadystatechange=function(){if("loaded"==L.readyState||"complete"==L.readyState)L.onreadystatechange=null,L.setAttribute("loadstate","true"),"function"==typeof u&&
195
+ u(p)}:L.onload=function(){L.setAttribute("loadstate","true");"function"==typeof u&&u(p)};L.id=p;L.src=B;y.appendChild(L);return!1};(function(p,B,u){var y=document.getElementsByTagName("head");if(0==y.length){y=document.createElement("head");var F=document.getElementsByTagName("body");if(0<F.length)F=F[0],document.insertBefore(y,F);else return alert("Invalid html document: no HEAD tag found"),!1}else{y=y[0];F=y.childNodes;for(var I=0;I<F.length;I++){var w=F[I];if("link"===w.nodeName.toUpperCase()&&
196
+ w.id&&w.id==p){if("true"!==w.getAttribute("loadstate")){var K=function(){"true"!==w.getAttribute("loadstate")?setTimeout(K,50):"function"===typeof u&&u(p)};setTimeout(K,50);return!1}"function"===typeof u&&u(p);return!0}}}var L=document.createElement("link");L.type="text/css";L.setAttribute("rel","stylesheet");L.readyState?L.onreadystatechange=function(){if("loaded"==L.readyState||"complete"==L.readyState)L.onreadystatechange=null,L.setAttribute("loadstate","true"),"function"==typeof u&&u(p)}:L.onload=
197
+ function(){L.setAttribute("loadstate","true");"function"==typeof u&&u(p)};L.id=p;L.href=B;y.appendChild(L);return!1})("zwplayer-css",Da.path+"css/zwplayer.css?v="+Da.v,function(p){console.log("zwplayer.css["+p+"] is loaded")});var Ua=function(p){return"object"===typeof HTMLElement?p instanceof HTMLElement:!(!p||"object"!==typeof p||1!==p.nodeType&&9!==p.nodeType||"string"!==typeof p.nodeName)};Array.isArray||(Array.isArray=function(p){return"[object Array]"===Object.prototype.toString.call(p)});var Va=
198
198
  /iPhone|iPad|iPod/.test(navigator.userAgent);(function(p){p+="=";for(var B=document.cookie.split(";"),u=0;u<B.length;u++){var y=B[u].trim();if(0==y.indexOf(p))return y.substring(p.length,y.length)}return""})("ZWPlayer")||ab("ZWPlayer","V1.0",365);var hb=function(p){for(var B=navigator.languages&&navigator.languages.length?navigator.languages:[navigator.language],u=0;u<p.length;u++)for(var y=0;y<B.length;y++)if(p[u].lang&&B[y]&&-1<B[y].indexOf(p[u].lang))return p[u].text;return 1===p.length?p[0].text:
199
199
  null};HUAYI={};HUAYI.Danmu=function(){var p={playerObj:null,opacity:70,onInit:null,onClose:null,onResize:null};return{create:function(B){var u={};for(k in p)u[k]=p[k];for(k in B)u[k]=B[k];"undefined"==typeof u.playerId&&(u.playerId="video-body");return new function(y){y=y.playerId;this.rows=[];this.timerId=this.rowCount=0;this.frameDuration=40;this.Danmulayer=null;this.danmuMargin=50;this.speedX=100;this.hasTransition=!0;this.rowHeight=28;this.topMargin=10;this.layerHeight=this.layerWidth=0;this.fontSize=
200
- "25px";if("string"==typeof y)this.vPlayer=document.getElementById(y);else if("object"==typeof y)this.vPlayer=y;else return;this.vPlayer||(this.vPlayer=document.getElementById("video-body"));if(this.vPlayer&&(y=this.vPlayer.childNodes,0<y.length))for(var F=0;F<y.length;F++){var J=y[F];if("DIV"==J.nodeName&&Qa(J.className,"danmuplayer")){this.wrapObj=J;break}}if(this.wrapObj){if(y=this.wrapObj.childNodes,0<y.length)for(F=0;F<y.length;F++)if(J=y[F],"DIV"==J.nodeName&&Qa(J.className,"danmu-layer")){this.Danmulayer=
201
- J;break}}else this.wrapObj=document.createElement("div"),this.wrapObj.className="danmuplayer",this.vPlayer.appendChild(this.wrapObj),this.Danmulayer=document.createElement("div"),this.Danmulayer.className="danmu-layer",this.wrapObj.appendChild(this.Danmulayer),Ka.ie&&9>Ka.ver&&(this.wrapObj.style.height=this.vPlayer.offsetHeight-45+"px");if(this.Danmulayer){this.hasTransition="undefined"!=typeof this.Danmulayer.style.transition;this.rowCount=Math.floor(Math.floor(2*(this.Danmulayer.offsetHeight-this.topMargin)/
202
- 3)/this.rowHeight);if(0<this.rowCount)for(F=0;F<this.rowCount;F++)this.rows.push({top:this.topMargin+this.rowHeight*F,count:0,last:null,idx:F});this.layerWidth=this.Danmulayer.offsetWidth;this.layerHeight=this.Danmulayer.offsetHeight;Ba.addElement(this.Danmulayer);this.Danmulayer.addEventListener("resize",function(w){this.reCalcLayout()}.bind(this))}this.start=function(w){this.timerId&&(clearInterval(this.timerId),this.timerId=0);if(!this.hasTransition){var L=this;this.timerId=setInterval(function(){var M=
203
- L.Danmulayer,P=M.childNodes;if(0<P.length){for(var Q=[],Z=0;Z<P.length;Z++){var ba=P[Z];if("DIV"==ba.tagName){var aa=parseFloat(ba.style.left);0>aa+ba.offsetWidth?Q.push(ba):ba.style.left=aa-4.5+"px"}}if(0<Q.length){for(Z=0;Z<Q.length;Z++)P=Q[Z],P.rowIdx&&(L.rows[P.rowIdx].last==this&&(L.rows[P.rowIdx].last=null),L.rows[P.rowIdx].count--),M.removeChild(Q[Z]);Q.splice(0,Q.length)}}},this.frameDuration)}};this.stop=function(){this.timerId&&(clearInterval(this.timerId),this.timerId=0);var w=this.Danmulayer.childNodes;
204
- if(0<w.length)for(var L=0;L<w.length;L++)w[L].style.display="none";this.Danmulayer.style.display="none"};this.destroy=function(){this.Danmulayer&&(Ba.removeElement(this.Danmulayer),delete this.Danmulayer);this.timerId&&(clearInterval(this.timerId),this.timerId=0);this.wrapObj&&this.vPlayer&&this.vPlayer.removeChild(this.wrapObj)};this.addDanmu=function(w,L){L||={};var M=document.createElement("div");M.className="danmu";"undefined"==typeof w.color||L.isFilterColorFont||(M.style.color=w.color);"undefined"!=
205
- typeof w.border&&(M.style.border="1px solid #666");M.style.fontSize=L.forcedFontSizeValue?parseInt(25*L.forcedFontSizeValue/100)+"px":"25px";this.fontSize!=M.style.fontSize&&(this.rowHeight=parseInt(M.style.fontSize)+3,this.layerHeight=0,this.reCalcLayout(),this.fontSize=M.style.fontSize);w.outlineColor&&(M.style.outlineStyle="solid",M.style.outlineWidth="2px",M.style.outlineColor=w.outlineColor);M.style.opacity=L.opacityValue?L.opacityValue/100:"0.9";M.innerHTML="function"==typeof I.replaceSmileDanmu?
206
- I.replaceSmileDanmu(w.text,this.rowHeight,L):w.text;var P=w=0,Q=999999;this.rowCount>this.rows.length&&(this.rowCount=this.rows.length);for(;w<this.rowCount;w++)if(0==this.rows[w].count){P=w;Q=this.layerWidth;break}else if(this.rows[w].last){var Z=this.rows[w].last;Z=Z.getBoundingClientRect().left+Z.offsetWidth+this.danmuMargin;if(Z<Q&&(P=w,Q=Z,Q<this.layerWidth))break}Q<this.layerWidth&&(Q=this.layerWidth);M.style.fontFamily='SimHei, "Microsoft JhengHei", Arial, Helvetica, sans-serif';M.style.textShadow=
207
- "rgb(0, 0, 0) 1px 0px 1px, rgb(0, 0, 0) 0px 1px 1px, rgb(0, 0, 0) 0px -1px 1px, rgb(0, 0, 0) -1px 0px 1px";M.style.cursor="pointer";M.style.left=Q+"px";M.style.top=this.rows[P].top+"px";M.rowIdx=P;this.rows[P].last=M;this.rows[P].count++;this.Danmulayer.appendChild(M);var ba=this;M.onmouseover=function(aa){this.pause||(this.pause=!0)};M.onmouseout=function(aa){this.pause&&(this.pause=!1)};this.hasTransition&&(M.addEventListener("transitionend",function(){"number"==typeof this.rowIdx&&(ba.rows[this.rowIdx].last==
208
- this&&(ba.rows[this.rowIdx].last=null),ba.rows[this.rowIdx].count--);ba.Danmulayer.removeChild(this)}),w=Q+M.offsetWidth,L.speedValue?(L=parseInt(this.speedX*parseFloat(L.speedValue)),0==L&&(L=1),L=w/L+4*Math.random()):L=w/this.speedX+4*Math.random(),M.style.transition="transform "+L+"s linear",M.style.transform="translateX(-"+w+"px)")};this.reCalcLayout=function(){if(this.Danmulayer){Ka.ie&&9>Ka.ver&&(this.wrapObj.style.height=this.vPlayer.offsetHeight-45+"px");var w=this.Danmulayer.offsetHeight;
209
- if(w!=this.layerHeight){this.rowCount=Math.floor(Math.floor(2*(w-this.topMargin)/3)/this.rowHeight);if(0<this.rowCount)if(this.rowCount>this.rows.length)for(var L=this.rows.length;L<this.rowCount;L++)this.rows.push({top:this.topMargin+this.rowHeight*L,count:0,last:null,idx:L});else for(L=0;L<this.rowCount;L++)this.rows[L].top=this.topMargin+this.rowHeight*L;this.layerHeight=w}if(this.Danmulayer.offsetWidth!=this.layerWidth){w=this.Danmulayer.childNodes;if(0<w.length)for(L=0;L<w.length;L++);this.layerWidth=
210
- this.Danmulayer.offsetWidth}}};this.hasTransition||this.start()}(u)}}}();var Ba={_onResize:function(p){var B=p.target||p.srcElement;if(B=B.__resizeTrigger__?B.__resizeTrigger__:B){var u=B.__z_resizeListeners;if(u)for(var y=u.length,F=0;F<y;F++){var J=u[F],w=J.handler;(J=J.context)||(J=B);if(w)w.apply(J,[p]);else if("resize"===p.type||"[object ResizeObserverEntry]"===Object.prototype.toString.call(p))w=document.createEvent("Event"),w.initEvent("resize",!1,!1),B.dispatchEvent(w)}}},addElement:function(p,
211
- B,u){var y=p.__z_resizeListeners;if(!y)if(y=[],p.__z_resizeListeners=y,"function"===typeof I.ResizeObserver)this.resizeObserver||(this.resizeObserver=new ResizeObserver(function(J){for(var w=0;w<J.length;w++)this._onResize(J[w])}.bind(this))),this.resizeObserver.observe(p);else{"static"===getComputedStyle(p,null).position&&(p.style.position="relative");var F=document.createElement("object");F.resizer=this;F.__resizeElement__=p;F.setAttribute("style","display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; opacity: 0; pointer-events: none; z-index: -9999;");
212
- F.type="text/html";F.data="about:blank";F.onload=function(J){this.contentDocument.defaultView.__resizeTrigger__=this.__resizeElement__;this.contentDocument.defaultView.addEventListener("resize",this.resizer._onResize)};p.appendChild(F);p.__resizeDetector__=F}y.push({handler:B,context:u})},removeElement:function(p,B,u){var y=p.__z_resizeListeners;if(y){for(var F=y.length,J=0;J<F;J++){var w=y[J];if(w.handler===B&&w.context===u){y.splice(J,1);break}}if(0===y.length){if(B=p.__resizeDetector__)B.contentDocument.defaultView.removeEventListener("resize",
213
- this._onResize),p.removeChild(B),delete p.__resizeDetector__;delete p.__z_resizeListeners;this.resizeObserver&&this.resizeObserver.unobserve(p)}}}},Ka=function(){var p,B,u,y,F,J,w=navigator.userAgent.toLowerCase(),L;(L=w.match(/chrome\/([\d.]+)/),L)?p=L[1]:(L=w.match(/firefox\/([\d.]+)/),L)?B=L[1]:(L=w.match(/edge\/([\d.]+)/),L)?u=L[1]:(L=w.match(/rv:([\d.]+)\) like gecko/),L)?y=L[1]:(L=w.match(/msie ([\d.]+)/),L)?y=L[1]:(L=w.match(/opera.([\d.]+)/),L)?F=L[1]:(L=w.match(/version\/([\d.]+).*safari/),
214
- L)?J=L[1]:J=!1;return p?{broswer:"Chrome",version:p,chrome:!0,ver:parseInt(p)}:B?{broswer:"Firefox",version:B,firefox:!0,ver:parseInt(B)}:J?{broswer:"Safari",version:J,ver:parseInt(J)}:u?{broswer:"Edge",version:u,edge:!0,ver:parseInt(u)}:y?{broswer:"IE",version:y,ie:!0,ver:parseInt(y)}:F?{broswer:"Opera",version:F,opera:!0,ver:parseInt(F)}:{broswer:"",version:"0",ver:0}}(),Fa={about:"\u5173\u4e8e",current:"\u5f53\u524d","qs-auto":"\u81ea\u52a8\u5207\u6362",enterFullScreen:"\u8fdb\u5165\u5168\u5c4f",
215
- exitFullScreen:"\u9000\u51fa\u5168\u5c4f",subtitleOff:"\u5b57\u5e55\u5173\u95ed",FULL_HD1:"\u539f\u753b",allSubtitle:"\u5b57\u5e55\u603b\u5f00\u5173",closeSmallWindow:"\u5173\u95ed\u5c0f\u7a97\u53e3\u6a21\u5f0f",mainSubtitle:"\u9ed8\u8ba4\u5b57\u5e55\u5f00\u5173",secondSubtitle:"\u7b2c\u4e8c\u5b57\u5e55\u5f00\u5173",speed:"\u500d\u901f",muted:"\u9759\u97f3",unmuted:"\u53d6\u6d88\u9759\u97f3",level:"\u7ea7\u522b","media-prop":"\u5a92\u4f53\u6d41\u5c5e\u6027","player-help":"\u4f7f\u7528\u8bf4\u660e",
216
- "version-update":"\u7248\u672c\u66f4\u65b0",HD1:"\u8d85\u6e05",SD1:"\u9ad8\u6e05",SD2:"\u6807\u6e05",HD:"\u9ad8\u6e05",FHD:"\u5168\u9ad8\u6e05",BD:"\u84dd\u5149","BD 4M":"\u84dd\u51494M","BD 8M":"\u84dd\u51498M"},Ha={},Wa={FULL_HD1:"RAW",HD1:"FHD",SD1:"HD",SD2:"SD"},Xa="en",ib={"zh-CN":Fa,zh:Fa,"zh-HK":Ha,"zh-TW":Ha,"en-US":Wa,en:Wa};Fa="en";I.navigator&&(Ha=(I.navigator.language||I.navigator.browserLanguage).toLowerCase(),-1!=Ha.indexOf("zh")?Fa="zh-CN":-1!=Ha.indexOf("zh-tw")&&(Fa="zh-Hant"));Xa=
217
- Fa;var qa=function(p,B){var u=ib[Xa]||B;return u?u[p]||B:B},jb=function(){for(var p='<div class="zwp-button zwp-speedButton"><button class="zwpbtn zwp-speedBtn" data-action="showSpeedMenu" data-name="speedbtn">'+qa("speed","Speed")+'</button><ul class="zwp-speedMenu">',B="2.0x 1.5x 1.25x 1.0x 0.75x 0.5x 0.25x".split(" "),u="",y=0;y<B.length;y++)u=3===y?u+('<li class="zwp-speed-item active">'+B[y]+"</li>"):u+('<li class="zwp-speed-item">'+B[y]+"</li>");return p+u+"</ul></div>"},Ya=function(){var p=
218
- '<div class="zwp-option-item main"><label class="zwp-option-item-label">'+qa("allSubtitle","All subtitle")+'</label><div class="zwp-option-item-value">'+Ca("","subtitleOn")+"</div></div>";p+='<div class="zwp-option-item sub1" style="display: none;"><label class="zwp-option-item-label">'+qa("mainSubtitle","Main subtitle")+'</label><div class="zwp-option-item-value">'+Ca("","subtitleDefault")+"</div></div>";return p+='<div class="zwp-option-item sub2" style="display: none;"><label class="zwp-option-item-label">'+
219
- qa("secondSubtitle","Second subtitle")+'</label><div class="zwp-option-item-value">'+Ca("","subtitleSecond")+"</div></div>"},kb=function(p){var B='<li class="zwp-subtitles-item" data-id="-1">'+qa("subtitleOff","Captions off")+"</li>";for(var u=0;u<p.length;u++)B=0===u?B+('<li class="zwp-subtitles-item active" data-id="'+p[u].id+'">'+p[u].name+"</li>"):B+('<li class="zwp-subtitles-item" data-id="'+p[u].id+'">'+p[u].name+"</li>");return'<ul class="zwp-subtitlesMenu">'+B+"</ul>"},lb=function(){var p=
220
- "",B=(new Date).getTime();p=p+'<div class="zwp-toolbox-ground-right zwp-dmform zwp_danmu-controlbar"> <div class="zwp_switch_group"> <div class="zwp_switch_text">\u5f39\u5e55</div> <div class="zwp_switch" id="danmuSwitch-'+(B+'"><i class="switch_inner"></i></div> </div> <div class="zwp_dmconfig zwp_dmicon" id="danmu-config-btn-')+(B+'" title="\u5f39\u5e55\u8bbe\u7f6e"><i class="xicon xicon-subtitles"></i></div> <div class="zwp-barrage_form" id="barrage_form-')+(B+'"> <div class="zwp-barrage_inp logined"> <input id="barrage_inp_text-')+
221
- (B+'" type="text" class="barrage_inp_text" maxlength="40" disabled="disabled" readonly="readonly"> <div class="barrage_login" href="#login"><span class="barrage_text">\u767b\u5f55</span>\u540e\u53ef\u4ee5\u53c2\u4e0e\u5f39\u5e55</div> </div>');p+=' <a class="btn_bubble disabled" href="javascript:void(0);" title="\u9009\u62e9\u8868\u60c5" data-viewid="smilesFaces-view-'+B+'"><i class="xicon xicon-smile"></i></a> <button type="submit" class="btn_submit vtb_disabled" title="\u767b\u5f55\u540e\u624d\u53ef\u4ee5\u53d1\u9001\u5f39\u5e55\u54e6" disabled="disabled">\u53d1\u9001</button> </div>';
222
- p+=' <div class="zwp-barrage-set hidden" data-barrage-panel="panel" data-render="0"></div>';return p+="</div>"},Na=function(p){p=p.split(":");return 2===p.length?60*parseInt(p[0])+parseInt(p[1]):3===p.length?3600*parseInt(p[0])+60*parseInt(p[1])+parseInt(p[2]):1===p.length?parseFloat(p[0]):3<p.length?9.999999999999999E8:0},mb=function y(B,u){var F=(y.canvas||(y.canvas=document.createElement("canvas"))).getContext("2d");F.font=u;return F.measureText(B).width},nb=function(B,u){var y="";if(!u||!Array.isArray(u))return"";
223
- for(var F=0;F<u.length;F++){var J=u[F],w=Na(J.time);w>=B||(y+='<span class="zwp__chapter_dot" style="left: '+(100*w/B+'%" title="')+J.title+'" data-time="'+J.time+'" data-desc="'+J.desc+'">&nbsp;</span>')}return y},ob=function(B){if(!B||!Array.isArray(B)||0===B.length)return null;var u='<div class="zwp-button zwp-chapterButton"><button class="zwpbtn zwp-chapterBtn" data-action="showChapterListview" data-name="chapterbtn"><i class="xicon xicon-chapter"></i> \u7ae0\u8282</button><div class="zwp-chapterPanel zwp-popupwindow"><button class="closeBtn"><i class="xicon xicon-close"></i></button><div class="form-row form-title">\u7ae0\u8282\u5217\u8868</div><div class="zwp-list-inner"><ul class="zwp-chapterlist">';
224
- for(var y=0,F=0;F<B.length;F++){var J=B[F],w='<li class="chapter-item" data-time="'+J.time+'">';w+='<span class="item-time">'+J.time+"</span>";w+='<div class="item-content"><span class="title">'+J.title+"</span>";w+='<span class="desc">'+J.desc+"</span></div>";w+="</li>";u+=w;J=mb(J.title,'bold 16px "Microsoft YaHei", "Segoe UI","PingFang SC","Hiragino Sans GB","Helvetica Neue",Helvetica,Arial,sans-serif,-apple-system,BlinkMacSystemFont');J>y&&(y=J)}return{html:u+"</ul></div></div></div>",titleWidth:y}};
225
- I.insertSmile=function(B,u){B=$$(B).closest("div.zwp-smileview");if(0<B.length&&(B=B.get(0).inputbox))if(B.createTextRange&&(B.caretPos=document.selection.createRange().duplicate()),document.all)B.createTextRange&&B.caretPos?(B=B.caretPos,B.text=" "==B.text.charAt(B.text.length-1)?u+" ":u):B.value=u;else if(B.setSelectionRange){var y=B.selectionEnd,F=B.value.substring(0,B.selectionStart);y=B.value.substring(y);B.value=F+u+y}else alert("This version of Mozilla based browser does not support setSelectionRange")};
226
- I.replaceSmileDanmu=function(B,u,y){if("string"!=typeof B)return"";0<=B.indexOf("<")&&(B=B.replace(/</g,"&lt;").replace(/>/g,"&gt;"));var F=B.indexOf("[sm-");if(0>F)return B;var J=Da.path+"widgets/smiles/p",w="",L=B.substring(0,F);for(""!=L&&(w+=L);0<=F;){L=B.indexOf("]",F+4);if(0>L){L=B.substring(F);""!=L&&(w+=L);break}F=B.substring(F+4,L);""!=F&&(y.isFilterImage||(w+='<img style="opacity: 1;" src="'+J+F+'.png" height="'+u+'">'));F=B.indexOf("[sm-",L+1);0>F?(L=B.substring(L+1),""!=L&&(w+=L)):F>L+
227
- 1&&(w+=B.substring(L+1,F))}return w};var Oa=function(B){hasClass(B,"switch_on")?removeClass(B,"switch_on"):addClass(B,"switch_on")},pb=function(B,u){var y=$$;B=y(u).closest("div.zwp-dmform").children(".zwp-barrage-set");if(0!=B.length){if("1"!=B.attr("data-render")){var F=u.zwplayer,J=B.get(0);y.get(Da.path+"widgets/danmu_setting.html?v="+Da.v,{},function(M){var P=y(J);P.html(M);P.find("a.barrage-tab-link").click(function(Q){Q.preventDefault();Q=y(this).parent();Q.hasClass("selected")||(Q.addClass("selected").siblings().removeClass("selected"),
228
- Q=y(Q.attr("data-tab")),Q.hasClass("hidden")&&(Q.removeClass("hidden"),Q.siblings().addClass("hidden")))});M=y("#fsBox_tab");M.find("div.color-box").children("a").click(function(Q){Q.preventDefault();Q=y(this);Q.hasClass("selected")||(Q.siblings().removeClass("selected"),Q.addClass("selected"),F&&(F.danmuSetting.color=Q.attr("data-color")))});M.find("div.other-box").children("a.checkbox-wrap").click(function(Q){Q.preventDefault();var Z=y(this);Z.toggleClass("selected");Q=Z.attr("data-content");Z=
200
+ "25px";if("string"==typeof y)this.vPlayer=document.getElementById(y);else if("object"==typeof y)this.vPlayer=y;else return;this.vPlayer||(this.vPlayer=document.getElementById("video-body"));if(this.vPlayer&&(y=this.vPlayer.childNodes,0<y.length))for(var F=0;F<y.length;F++){var I=y[F];if("DIV"==I.nodeName&&Qa(I.className,"danmuplayer")){this.wrapObj=I;break}}if(this.wrapObj){if(y=this.wrapObj.childNodes,0<y.length)for(F=0;F<y.length;F++)if(I=y[F],"DIV"==I.nodeName&&Qa(I.className,"danmu-layer")){this.Danmulayer=
201
+ I;break}}else this.wrapObj=document.createElement("div"),this.wrapObj.className="danmuplayer",this.vPlayer.appendChild(this.wrapObj),this.Danmulayer=document.createElement("div"),this.Danmulayer.className="danmu-layer",this.wrapObj.appendChild(this.Danmulayer),Ka.ie&&9>Ka.ver&&(this.wrapObj.style.height=this.vPlayer.offsetHeight-45+"px");if(this.Danmulayer){this.hasTransition="undefined"!=typeof this.Danmulayer.style.transition;this.rowCount=Math.floor(Math.floor(2*(this.Danmulayer.offsetHeight-this.topMargin)/
202
+ 3)/this.rowHeight);if(0<this.rowCount)for(F=0;F<this.rowCount;F++)this.rows.push({top:this.topMargin+this.rowHeight*F,count:0,last:null,idx:F});this.layerWidth=this.Danmulayer.offsetWidth;this.layerHeight=this.Danmulayer.offsetHeight;Ba.addElement(this.Danmulayer);this.Danmulayer.addEventListener("resize",function(w){this.reCalcLayout()}.bind(this))}this.start=function(w){this.timerId&&(clearInterval(this.timerId),this.timerId=0);if(!this.hasTransition){var K=this;this.timerId=setInterval(function(){var L=
203
+ K.Danmulayer,O=L.childNodes;if(0<O.length){for(var Q=[],Z=0;Z<O.length;Z++){var ba=O[Z];if("DIV"==ba.tagName){var aa=parseFloat(ba.style.left);0>aa+ba.offsetWidth?Q.push(ba):ba.style.left=aa-4.5+"px"}}if(0<Q.length){for(Z=0;Z<Q.length;Z++)O=Q[Z],O.rowIdx&&(K.rows[O.rowIdx].last==this&&(K.rows[O.rowIdx].last=null),K.rows[O.rowIdx].count--),L.removeChild(Q[Z]);Q.splice(0,Q.length)}}},this.frameDuration)}};this.stop=function(){this.timerId&&(clearInterval(this.timerId),this.timerId=0);var w=this.Danmulayer.childNodes;
204
+ if(0<w.length)for(var K=0;K<w.length;K++)w[K].style.display="none";this.Danmulayer.style.display="none"};this.destroy=function(){this.Danmulayer&&(Ba.removeElement(this.Danmulayer),delete this.Danmulayer);this.timerId&&(clearInterval(this.timerId),this.timerId=0);this.wrapObj&&this.vPlayer&&this.vPlayer.removeChild(this.wrapObj)};this.addDanmu=function(w,K){K||={};var L=document.createElement("div");L.className="danmu";"undefined"==typeof w.color||K.isFilterColorFont||(L.style.color=w.color);"undefined"!=
205
+ typeof w.border&&(L.style.border="1px solid #666");L.style.fontSize=K.forcedFontSizeValue?parseInt(25*K.forcedFontSizeValue/100)+"px":"25px";this.fontSize!=L.style.fontSize&&(this.rowHeight=parseInt(L.style.fontSize)+3,this.layerHeight=0,this.reCalcLayout(),this.fontSize=L.style.fontSize);w.outlineColor&&(L.style.outlineStyle="solid",L.style.outlineWidth="2px",L.style.outlineColor=w.outlineColor);L.style.opacity=K.opacityValue?K.opacityValue/100:"0.9";L.innerHTML="function"==typeof J.replaceSmileDanmu?
206
+ J.replaceSmileDanmu(w.text,this.rowHeight,K):w.text;var O=w=0,Q=999999;this.rowCount>this.rows.length&&(this.rowCount=this.rows.length);for(;w<this.rowCount;w++)if(0==this.rows[w].count){O=w;Q=this.layerWidth;break}else if(this.rows[w].last){var Z=this.rows[w].last;Z=Z.getBoundingClientRect().left+Z.offsetWidth+this.danmuMargin;if(Z<Q&&(O=w,Q=Z,Q<this.layerWidth))break}Q<this.layerWidth&&(Q=this.layerWidth);L.style.fontFamily='SimHei, "Microsoft JhengHei", Arial, Helvetica, sans-serif';L.style.textShadow=
207
+ "rgb(0, 0, 0) 1px 0px 1px, rgb(0, 0, 0) 0px 1px 1px, rgb(0, 0, 0) 0px -1px 1px, rgb(0, 0, 0) -1px 0px 1px";L.style.cursor="pointer";L.style.left=Q+"px";L.style.top=this.rows[O].top+"px";L.rowIdx=O;this.rows[O].last=L;this.rows[O].count++;this.Danmulayer.appendChild(L);var ba=this;L.onmouseover=function(aa){this.pause||(this.pause=!0)};L.onmouseout=function(aa){this.pause&&(this.pause=!1)};this.hasTransition&&(L.addEventListener("transitionend",function(){"number"==typeof this.rowIdx&&(ba.rows[this.rowIdx].last==
208
+ this&&(ba.rows[this.rowIdx].last=null),ba.rows[this.rowIdx].count--);ba.Danmulayer.removeChild(this)}),w=Q+L.offsetWidth,K.speedValue?(K=parseInt(this.speedX*parseFloat(K.speedValue)),0==K&&(K=1),K=w/K+4*Math.random()):K=w/this.speedX+4*Math.random(),L.style.transition="transform "+K+"s linear",L.style.transform="translateX(-"+w+"px)")};this.reCalcLayout=function(){if(this.Danmulayer){Ka.ie&&9>Ka.ver&&(this.wrapObj.style.height=this.vPlayer.offsetHeight-45+"px");var w=this.Danmulayer.offsetHeight;
209
+ if(w!=this.layerHeight){this.rowCount=Math.floor(Math.floor(2*(w-this.topMargin)/3)/this.rowHeight);if(0<this.rowCount)if(this.rowCount>this.rows.length)for(var K=this.rows.length;K<this.rowCount;K++)this.rows.push({top:this.topMargin+this.rowHeight*K,count:0,last:null,idx:K});else for(K=0;K<this.rowCount;K++)this.rows[K].top=this.topMargin+this.rowHeight*K;this.layerHeight=w}if(this.Danmulayer.offsetWidth!=this.layerWidth){w=this.Danmulayer.childNodes;if(0<w.length)for(K=0;K<w.length;K++);this.layerWidth=
210
+ this.Danmulayer.offsetWidth}}};this.hasTransition||this.start()}(u)}}}();var Ba={_onResize:function(p){var B=p.target||p.srcElement;if(B=B.__resizeTrigger__?B.__resizeTrigger__:B){var u=B.__z_resizeListeners;if(u)for(var y=u.length,F=0;F<y;F++){var I=u[F],w=I.handler;(I=I.context)||(I=B);if(w)w.apply(I,[p]);else if("resize"===p.type||"[object ResizeObserverEntry]"===Object.prototype.toString.call(p))w=document.createEvent("Event"),w.initEvent("resize",!1,!1),B.dispatchEvent(w)}}},addElement:function(p,
211
+ B,u){var y=p.__z_resizeListeners;if(!y)if(y=[],p.__z_resizeListeners=y,"function"===typeof J.ResizeObserver)this.resizeObserver||(this.resizeObserver=new ResizeObserver(function(I){for(var w=0;w<I.length;w++)this._onResize(I[w])}.bind(this))),this.resizeObserver.observe(p);else{"static"===getComputedStyle(p,null).position&&(p.style.position="relative");var F=document.createElement("object");F.resizer=this;F.__resizeElement__=p;F.setAttribute("style","display: block; position: absolute; top: 0; left: 0; height: 100%; width: 100%; opacity: 0; pointer-events: none; z-index: -9999;");
212
+ F.type="text/html";F.data="about:blank";F.onload=function(I){this.contentDocument.defaultView.__resizeTrigger__=this.__resizeElement__;this.contentDocument.defaultView.addEventListener("resize",this.resizer._onResize)};p.appendChild(F);p.__resizeDetector__=F}y.push({handler:B,context:u})},removeElement:function(p,B,u){var y=p.__z_resizeListeners;if(y){for(var F=y.length,I=0;I<F;I++){var w=y[I];if(w.handler===B&&w.context===u){y.splice(I,1);break}}if(0===y.length){if(B=p.__resizeDetector__)B.contentDocument.defaultView.removeEventListener("resize",
213
+ this._onResize),p.removeChild(B),delete p.__resizeDetector__;delete p.__z_resizeListeners;this.resizeObserver&&this.resizeObserver.unobserve(p)}}}},Ka=function(){var p,B,u,y,F,I,w=navigator.userAgent.toLowerCase(),K;(K=w.match(/chrome\/([\d.]+)/),K)?p=K[1]:(K=w.match(/firefox\/([\d.]+)/),K)?B=K[1]:(K=w.match(/edge\/([\d.]+)/),K)?u=K[1]:(K=w.match(/rv:([\d.]+)\) like gecko/),K)?y=K[1]:(K=w.match(/msie ([\d.]+)/),K)?y=K[1]:(K=w.match(/opera.([\d.]+)/),K)?F=K[1]:(K=w.match(/version\/([\d.]+).*safari/),
214
+ K)?I=K[1]:I=!1;return p?{broswer:"Chrome",version:p,chrome:!0,ver:parseInt(p)}:B?{broswer:"Firefox",version:B,firefox:!0,ver:parseInt(B)}:I?{broswer:"Safari",version:I,ver:parseInt(I)}:u?{broswer:"Edge",version:u,edge:!0,ver:parseInt(u)}:y?{broswer:"IE",version:y,ie:!0,ver:parseInt(y)}:F?{broswer:"Opera",version:F,opera:!0,ver:parseInt(F)}:{broswer:"",version:"0",ver:0}}(),Fa={about:"\u5173\u4e8e",current:"\u5f53\u524d","qs-auto":"\u81ea\u52a8\u5207\u6362",enterFullScreen:"\u8fdb\u5165\u5168\u5c4f",
215
+ exitFullScreen:"\u9000\u51fa\u5168\u5c4f",subtitleOff:"\u5b57\u5e55\u5173\u95ed",FULL_HD1:"\u539f\u753b",allSubtitle:"\u5b57\u5e55\u603b\u5f00\u5173",closeSmallWindow:"\u5173\u95ed\u5c0f\u7a97\u53e3\u6a21\u5f0f",mainSubtitle:"\u9ed8\u8ba4\u5b57\u5e55",secondSubtitle:"\u7b2c\u4e8c\u5b57\u5e55",speed:"\u500d\u901f",muted:"\u9759\u97f3",unmuted:"\u53d6\u6d88\u9759\u97f3",level:"\u7ea7\u522b","media-prop":"\u5a92\u4f53\u6d41\u5c5e\u6027","player-help":"\u4f7f\u7528\u8bf4\u660e","version-update":"\u7248\u672c\u66f4\u65b0",
216
+ HD1:"\u8d85\u6e05",SD1:"\u9ad8\u6e05",SD2:"\u6807\u6e05",HD:"\u9ad8\u6e05",FHD:"\u5168\u9ad8\u6e05",BD:"\u84dd\u5149","BD 4M":"\u84dd\u51494M","BD 8M":"\u84dd\u51498M"},Ha={},Wa={FULL_HD1:"RAW",HD1:"FHD",SD1:"HD",SD2:"SD"},Xa="en",ib={"zh-CN":Fa,zh:Fa,"zh-HK":Ha,"zh-TW":Ha,"en-US":Wa,en:Wa};Fa="en";J.navigator&&(Ha=(J.navigator.language||J.navigator.browserLanguage).toLowerCase(),-1!=Ha.indexOf("zh")?Fa="zh-CN":-1!=Ha.indexOf("zh-tw")&&(Fa="zh-Hant"));Xa=Fa;var qa=function(p,B){var u=ib[Xa]||B;return u?
217
+ u[p]||B:B},jb=function(){for(var p='<div class="zwp-button zwp-speedButton"><button class="zwpbtn zwp-speedBtn" data-action="showSpeedMenu" data-name="speedbtn">'+qa("speed","Speed")+'</button><ul class="zwp-speedMenu">',B="2.0x 1.5x 1.25x 1.0x 0.75x 0.5x 0.25x".split(" "),u="",y=0;y<B.length;y++)u=3===y?u+('<li class="zwp-speed-item active">'+B[y]+"</li>"):u+('<li class="zwp-speed-item">'+B[y]+"</li>");return p+u+"</ul></div>"},Ya=function(){var p='<div class="zwp-option-item main"><label class="zwp-option-item-label">'+
218
+ qa("allSubtitle","All subtitle")+'</label><div class="zwp-option-item-value">'+Ca("","subtitleOn")+"</div></div>";p+='<div class="zwp-option-item sub1" style="display: none;"><label class="zwp-option-item-label">'+qa("mainSubtitle","Main subtitle")+'</label><div class="zwp-option-item-value">'+Ca("","subtitleDefault")+"</div></div>";return p+='<div class="zwp-option-item sub2" style="display: none;"><label class="zwp-option-item-label">'+qa("secondSubtitle","Second subtitle")+'</label><div class="zwp-option-item-value">'+
219
+ Ca("","subtitleSecond")+"</div></div>"},kb=function(p){var B='<li class="zwp-subtitles-item" data-id="-1">'+qa("subtitleOff","Captions off")+"</li>";for(var u=0;u<p.length;u++)B=0===u?B+('<li class="zwp-subtitles-item active" data-id="'+p[u].id+'">'+p[u].name+"</li>"):B+('<li class="zwp-subtitles-item" data-id="'+p[u].id+'">'+p[u].name+"</li>");return'<ul class="zwp-subtitlesMenu">'+B+"</ul>"},lb=function(){var p="",B=(new Date).getTime();p=p+'<div class="zwp-toolbox-ground-right zwp-dmform zwp_danmu-controlbar"> <div class="zwp_switch_group"> <div class="zwp_switch_text">\u5f39\u5e55</div> <div class="zwp_switch" id="danmuSwitch-'+
220
+ (B+'"><i class="switch_inner"></i></div> </div> <div class="zwp_dmconfig zwp_dmicon" id="danmu-config-btn-')+(B+'" title="\u5f39\u5e55\u8bbe\u7f6e"><i class="xicon xicon-subtitles"></i></div> <div class="zwp-barrage_form" id="barrage_form-')+(B+'"> <div class="zwp-barrage_inp logined"> <input id="barrage_inp_text-')+(B+'" type="text" class="barrage_inp_text" maxlength="40" disabled="disabled" readonly="readonly"> <div class="barrage_login" href="#login"><span class="barrage_text">\u767b\u5f55</span>\u540e\u53ef\u4ee5\u53c2\u4e0e\u5f39\u5e55</div> </div>');
221
+ p+=' <a class="btn_bubble disabled" href="javascript:void(0);" title="\u9009\u62e9\u8868\u60c5" data-viewid="smilesFaces-view-'+B+'"><i class="xicon xicon-smile"></i></a> <button type="submit" class="btn_submit vtb_disabled" title="\u767b\u5f55\u540e\u624d\u53ef\u4ee5\u53d1\u9001\u5f39\u5e55\u54e6" disabled="disabled">\u53d1\u9001</button> </div>';p+=' <div class="zwp-barrage-set hidden" data-barrage-panel="panel" data-render="0"></div>';return p+="</div>"},La=function(p){if("number"===typeof p)return p;
222
+ p=p.split(":");return 2===p.length?60*parseInt(p[0])+parseInt(p[1]):3===p.length?3600*parseInt(p[0])+60*parseInt(p[1])+parseInt(p[2]):1===p.length?parseFloat(p[0]):3<p.length?9.999999999999999E8:0},mb=function y(B,u){var F=(y.canvas||(y.canvas=document.createElement("canvas"))).getContext("2d");F.font=u;return F.measureText(B).width},nb=function(B,u){var y="";if(!u||!Array.isArray(u))return"";for(var F=0;F<u.length;F++){var I=u[F],w=La(I.time);if(!(w>=B)){var K=100*w/B+"%",L=I.title||I.text||I.time+
223
+ "";if("undefined"!==typeof I.duration){var O="red";I.style&&"undefined"!==typeof I.style.background&&(O=I.style.background);var Q=La(I.duration);w+Q>B&&(Q=B-w);y+='<span class="zwp__chapter_dot zwp_bar" style="left: '+K+"; width: "+(100*Q/B+"%; border-radius: 3px; background-color: ")+O+';" title="'+L+'" data-time="'+I.time+'" data-desc="'+I.desc+'">&nbsp;</span>'}else y+='<span class="zwp__chapter_dot" style="left: '+K+'" title="'+L+'" data-time="'+I.time+'" data-desc="'+I.desc+'">&nbsp;</span>'}}return y},
224
+ ob=function(B){if(!B||!Array.isArray(B)||0===B.length)return null;var u='<div class="zwp-button zwp-chapterButton"><button class="zwpbtn zwp-chapterBtn" data-action="showChapterListview" data-name="chapterbtn"><i class="xicon xicon-chapter"></i> \u7ae0\u8282</button><div class="zwp-chapterPanel zwp-popupwindow"><button class="closeBtn"><i class="xicon xicon-close"></i></button><div class="form-row form-title">\u7ae0\u8282\u5217\u8868</div><div class="zwp-list-inner"><ul class="zwp-chapterlist">';
225
+ for(var y=0,F=0;F<B.length;F++){var I=B[F],w='<li class="chapter-item" data-time="'+I.time+'">';w+='<span class="item-time">'+I.time+"</span>";w+='<div class="item-content"><span class="title">'+I.title+"</span>";w+='<span class="desc">'+I.desc+"</span></div>";w+="</li>";u+=w;I=mb(I.title,'bold 16px "Microsoft YaHei", "Segoe UI","PingFang SC","Hiragino Sans GB","Helvetica Neue",Helvetica,Arial,sans-serif,-apple-system,BlinkMacSystemFont');I>y&&(y=I)}return{html:u+"</ul></div></div></div>",titleWidth:y}};
226
+ J.insertSmile=function(B,u){B=$$(B).closest("div.zwp-smileview");if(0<B.length&&(B=B.get(0).inputbox))if(B.createTextRange&&(B.caretPos=document.selection.createRange().duplicate()),document.all)B.createTextRange&&B.caretPos?(B=B.caretPos,B.text=" "==B.text.charAt(B.text.length-1)?u+" ":u):B.value=u;else if(B.setSelectionRange){var y=B.selectionEnd,F=B.value.substring(0,B.selectionStart);y=B.value.substring(y);B.value=F+u+y}else alert("This version of Mozilla based browser does not support setSelectionRange")};
227
+ J.replaceSmileDanmu=function(B,u,y){if("string"!=typeof B)return"";0<=B.indexOf("<")&&(B=B.replace(/</g,"&lt;").replace(/>/g,"&gt;"));var F=B.indexOf("[sm-");if(0>F)return B;var I=Da.path+"widgets/smiles/p",w="",K=B.substring(0,F);for(""!=K&&(w+=K);0<=F;){K=B.indexOf("]",F+4);if(0>K){K=B.substring(F);""!=K&&(w+=K);break}F=B.substring(F+4,K);""!=F&&(y.isFilterImage||(w+='<img style="opacity: 1;" src="'+I+F+'.png" height="'+u+'">'));F=B.indexOf("[sm-",K+1);0>F?(K=B.substring(K+1),""!=K&&(w+=K)):F>K+
228
+ 1&&(w+=B.substring(K+1,F))}return w};var Oa=function(B){hasClass(B,"switch_on")?removeClass(B,"switch_on"):addClass(B,"switch_on")},pb=function(B,u){var y=$$;B=y(u).closest("div.zwp-dmform").children(".zwp-barrage-set");if(0!=B.length){if("1"!=B.attr("data-render")){var F=u.zwplayer,I=B.get(0);y.get(Da.path+"widgets/danmu_setting.html?v="+Da.v,{},function(L){var O=y(I);O.html(L);O.find("a.barrage-tab-link").click(function(Q){Q.preventDefault();Q=y(this).parent();Q.hasClass("selected")||(Q.addClass("selected").siblings().removeClass("selected"),
229
+ Q=y(Q.attr("data-tab")),Q.hasClass("hidden")&&(Q.removeClass("hidden"),Q.siblings().addClass("hidden")))});L=y("#fsBox_tab");L.find("div.color-box").children("a").click(function(Q){Q.preventDefault();Q=y(this);Q.hasClass("selected")||(Q.siblings().removeClass("selected"),Q.addClass("selected"),F&&(F.danmuSetting.color=Q.attr("data-color")))});L.find("div.other-box").children("a.checkbox-wrap").click(function(Q){Q.preventDefault();var Z=y(this);Z.toggleClass("selected");Q=Z.attr("data-content");Z=
229
230
  Z.hasClass("selected");F&&(F.danmuSetting[Q]=Z)});y("#bfBox_tab").find("a.zwp-barrage-icons").mousedown(function(Q){if(0==Q.button){this.isMousePressed=!0;var Z=y(this).position().left,ba=Q.clientX-Z,aa=this,fa=function(Y){Y=Y.clientX-ba;0>Y?Y=0:134<Y&&(Y=134);y(aa).css({left:Y+"px"});var ka=y(aa).siblings("div.bar-t");0<ka.length&&ka.width(Y+3);aa.valuePanel||(aa.valuePanel=y(aa).parent().siblings("div.set-rol-right").get(0));if("object"==typeof aa.valuePanel){ka=y(aa.valuePanel);var ia=ka.attr("data-barrage-content");
230
231
  "opacityValue"==ia?(Y=parseInt(100*Y/138),F&&(F.danmuSetting.opacityValue=Y),ka.html(Y+"%")):"forcedFontSizeValue"==ia?(Y=50+parseInt(150*Y/138),F&&(F.danmuSetting.forcedFontSizeValue=Y),ka.html(Y+"%")):"speedValue"==ia?(Y=(.5+parseFloat(Y/69)).toFixed(1),F&&(F.danmuSetting.speedValue=Y),ka.html(Y+"x")):"densityValue"==ia&&(Y=parseInt(100*Y/46),F&&(F.danmuSetting.densityValue=Y),ka.html(Y+"\u6761"))}return!1},ma=function(Y){y(document).unbind("mousemove",fa).unbind("mouseup",ma)};y(document).bind("mousemove",
231
232
  fa).bind("mouseup",ma)}return!1});y("#pbBox_tab").find("a.pb-link").click(function(Q){Q.preventDefault();var Z=y(this).parent();Z.toggleClass("selected");Q=y(this).attr("data-content");Z=Z.hasClass("selected");F&&(F.danmuSetting[Q]=Z)});y("#barrage-set-bot").children("a").click(function(Q){Q.preventDefault();if("reset"==y(this).attr("data-content")){if(F)for(a in F.danmuSetting)delete F.danmuSetting[a];y("#fsBox_tab").find(".color-box a").removeClass("selected").eq(0).addClass("selected");y("#fsBox_tab").find(".other-box a").removeClass("selected");
232
233
  var Z={opacityTrigger:[128,124,"90%"],forcedFontSizeTrigger:[50,46,"100%"],speedTrigger:[39,35,"1.0x"],densityTrigger:[18,14,"30\u6761"]};y("#bfBox_tab").find("a.zwp-barrage-icons").each(function(ba,aa){ba=y(aa).attr("data-barrage-content");if(Z[ba]){var fa=Z[ba];ba=fa[1];var ma=fa[0];fa=fa[2];aa=y(aa);aa.css({left:ba+"px"});aa.siblings(".bar-t").width(ma+"px");aa.parent().siblings(".set-rol-right").text(fa)}});y("#pbBox_tab").find("li.selected").removeClass("selected")}})},"html");B.attr("data-render",
233
- "1")}if(B.hasClass("hidden")){J=B.get(0);var w=this,L=function(M){var P=y(J);if(M.target==w)w=null;else if(hasClass(M.target,"xicon-close")||!P.is(M.target)&&0===P.has(M.target).length)P.addClass("hidden"),y(document).off("click",L),delete u.zwplayer};B.removeClass("hidden");y(document).on("click",L)}}},Za=function(B){I.ctrlInitId||(I.ctrlInitId=(new Date).getTime());var u=I.ctrlInitId++;return B+u},Ca=function(B,u){return'<div class="zwp_switch action-item" id="'+(B||Za("switch-"))+'" data-action="'+
234
- (u||"none")+'"><i class="switch_inner"></i></div>'},$a=function(B){var u=B.parentNode;u&&(u=u.querySelector(".zwp-slider-value"))&&(u.innerHTML=B.value)},La=function(B,u){B=B||Za("zwp_slider-");return'<input type="range" id="'+B+'" name="slider'+B+'" data-action="'+u+'" class="zwp-slider" value="0" min="-100" max="100"/><span class="zwp-slider-value">0</span>'},qb=function(B){var u="";B.infoButton&&(u='<div class="zwp-button zwp-infoButton"><button class="zwpbtn zwp-infoBtn" data-action="showMediainfo" data-name="infobtn"><i class="xicon xicon-info"></i></button></div>');
235
- var y="",F="",J="",w="",L="",M="",P="",Q=B.defVolume||61.25;B.speedButton&&!B.isLive&&(y="");B.optionButton&&(J='<div class="zwp-button zwp-optionButton"><button class="zwpbtn zwp-optionBtn" data-action="showConfigPanel" data-name="optionbtn" title="\u8bbe\u7f6e"><i class="xicon xicon-config"></i></button><div class="zwp-optionPanel"><div class="zwp-option-item"><label class="zwp-option-item-label">\u5de6\u53f3\u7ffb\u8f6c</label><div class="zwp-option-item-value">'+(Ca("","mirror")+'</div></div><div class="zwp-option-item"><label class="zwp-option-item-label">\u4e0a\u4e0b\u7ffb\u8f6c</label><div class="zwp-option-item-value">'+
234
+ "1")}if(B.hasClass("hidden")){I=B.get(0);var w=this,K=function(L){var O=y(I);if(L.target==w)w=null;else if(hasClass(L.target,"xicon-close")||!O.is(L.target)&&0===O.has(L.target).length)O.addClass("hidden"),y(document).off("click",K),delete u.zwplayer};B.removeClass("hidden");y(document).on("click",K)}}},Za=function(B){J.ctrlInitId||(J.ctrlInitId=(new Date).getTime());var u=J.ctrlInitId++;return B+u},Ca=function(B,u){return'<div class="zwp_switch action-item" id="'+(B||Za("switch-"))+'" data-action="'+
235
+ (u||"none")+'"><i class="switch_inner"></i></div>'},$a=function(B){var u=B.parentNode;u&&(u=u.querySelector(".zwp-slider-value"))&&(u.innerHTML=B.value)},Ma=function(B,u){B=B||Za("zwp_slider-");return'<input type="range" id="'+B+'" name="slider'+B+'" data-action="'+u+'" class="zwp-slider" value="0" min="-100" max="100"/><span class="zwp-slider-value">0</span>'},qb=function(B){var u="";B.infoButton&&(u='<div class="zwp-button zwp-infoButton"><button class="zwpbtn zwp-infoBtn" data-action="showMediainfo" data-name="infobtn"><i class="xicon xicon-info"></i></button></div>');
236
+ var y="",F="",I="",w="",K="",L="",O="",Q=B.defVolume||61.25;B.speedButton&&!B.isLive&&(y="");B.optionButton&&(I='<div class="zwp-button zwp-optionButton"><button class="zwpbtn zwp-optionBtn" data-action="showConfigPanel" data-name="optionbtn" title="\u8bbe\u7f6e"><i class="xicon xicon-config"></i></button><div class="zwp-optionPanel"><div class="zwp-option-item"><label class="zwp-option-item-label">\u5de6\u53f3\u7ffb\u8f6c</label><div class="zwp-option-item-value">'+(Ca("","mirror")+'</div></div><div class="zwp-option-item"><label class="zwp-option-item-label">\u4e0a\u4e0b\u7ffb\u8f6c</label><div class="zwp-option-item-value">'+
236
237
  Ca("","flip")+'</div></div><div class="zwp-option-item"><label class="zwp-option-item-label">\u987a90\u5ea6\u7ffb\u8f6c</label><div class="zwp-option-item-value">'+Ca("","rotated90")+'</div></div><div class="zwp-option-item"><label class="zwp-option-item-label">\u900690\u5ea6\u7ffb\u8f6c</label><div class="zwp-option-item-value">'+Ca("","rotated270")+'</div></div><div class="zwp-option-h-separator"><hr/></div><div class="zwp-option-item"><label class="zwp-option-item-label">\u5faa\u73af\u64ad\u653e</label><div class="zwp-option-item-value">'+
237
- Ca("","loop")+'</div></div><div class="zwp-option-item zwp-lefticon"><span class="zwp-liteicon"><i class="xicon xicon-hue"></i></span> <button class="zwp-option-button action-item" data-action="showColorConfig">\u89c6\u9891\u8272\u5ea6\u8c03\u8282...</button></div></div></div>'));B.disableVolumeControl||(P='<div class="zwp-button zwp-volume-docker"><button class="zwpbtn zwp-muteBtn" data-action="mute" data-name="mutebtn"><i class="xicon xicon-speaker"></i></button><div class="zwp-volume-slider"><div class="zwp-volume-total"><div class="zwp-volume-current" style="bottom: 0px; height: '+
238
- Q+'%;"></div><div class="zwp-volume-handle" style="bottom: '+Q+'%; margin-bottom: -7px;"></div></div></div></div>');B.disableFullscreenWin||(w='<div class="zwp-button zwp-fullscrWinButton"><button class="zwpbtn zwp-fullscrWinBtn" data-action="enterfullscreenWin" data-name="fullscrWinbtn" title="\u7f51\u9875\u5168\u5c4f"><i class="xicon xicon-fullScreen-win"></i></button></div>');B.snapshotButton&&(L='<div class="zwp-button zwp-snapshotButton"><button class="zwpbtn zwp-snapshotBtn" data-action="snapshot" data-name="snapshotbtn" title="\u6293\u53d6\u56fe\u50cf"><i class="xicon xicon-camera"></i></button></div>');
239
- B.disablePicInPic||document.pictureInPictureEnabled&&(M='<div class="zwp-button zwp-picInPicButton"><button class="zwpbtn zwp-picInPicBtn" data-action="pictureInPicture" data-name="picInPicbtn" title="\u753b\u4e2d\u753b\u6a21\u5f0f"><i class="xicon xicon-pic-in-pic"></i></button></div>');B.isLive||(F='<div class="zwp__time-rail"></div>');B='<div class="zwp-button zwp-subtitleButton" style="display: none;"><button class="zwpbtn zwp-subtitleBtn" data-action="showSubtitleMenu" data-name="subtitlebtn" title="\u5916\u6302\u5b57\u5e55"><i class="xicon xicon-cc"></i></button><div class="zwp-subtitleMenu">'+
238
+ Ca("","loop")+'</div></div><div class="zwp-option-item zwp-lefticon"><span class="zwp-liteicon"><i class="xicon xicon-hue"></i></span> <button class="zwp-option-button action-item" data-action="showColorConfig">\u89c6\u9891\u8272\u5ea6\u8c03\u8282...</button></div></div></div>'));B.disableVolumeControl||(O='<div class="zwp-button zwp-volume-docker"><button class="zwpbtn zwp-muteBtn" data-action="mute" data-name="mutebtn"><i class="xicon xicon-speaker"></i></button><div class="zwp-volume-slider"><div class="zwp-volume-total"><div class="zwp-volume-current" style="bottom: 0px; height: '+
239
+ Q+'%;"></div><div class="zwp-volume-handle" style="bottom: '+Q+'%; margin-bottom: -7px;"></div></div></div></div>');B.disableFullscreenWin||(w='<div class="zwp-button zwp-fullscrWinButton"><button class="zwpbtn zwp-fullscrWinBtn" data-action="enterfullscreenWin" data-name="fullscrWinbtn" title="\u7f51\u9875\u5168\u5c4f"><i class="xicon xicon-fullScreen-win"></i></button></div>');B.snapshotButton&&(K='<div class="zwp-button zwp-snapshotButton"><button class="zwpbtn zwp-snapshotBtn" data-action="snapshot" data-name="snapshotbtn" title="\u6293\u53d6\u56fe\u50cf"><i class="xicon xicon-camera"></i></button></div>');
240
+ B.disablePicInPic||document.pictureInPictureEnabled&&(L='<div class="zwp-button zwp-picInPicButton"><button class="zwpbtn zwp-picInPicBtn" data-action="pictureInPicture" data-name="picInPicbtn" title="\u753b\u4e2d\u753b\u6a21\u5f0f"><i class="xicon xicon-pic-in-pic"></i></button></div>');B.isLive||(F='<div class="zwp__time-rail"></div>');B='<div class="zwp-button zwp-subtitleButton" style="display: none;"><button class="zwpbtn zwp-subtitleBtn" data-action="showSubtitleMenu" data-name="subtitlebtn" title="\u5916\u6302\u5b57\u5e55"><i class="xicon xicon-cc"></i></button><div class="zwp-subtitleMenu">'+
240
241
  Ya()+"</div></div>";Q=["1920","1280","720","480"];for(var Z="",ba=0;ba<Q.length;ba++)Z=3===ba?Z+('<li class="zwp-quality-item active">'+Q[ba]+"</li>"):Z+('<li class="zwp-quality-item">'+Q[ba]+"</li>");return'<div class="zwp-button zwp_playbtn"><button class="zwpbtn zwp-playbtn" data-action="play" data-name="playbtn"><i class="xicon xicon-play"></i></button></div><div class="zwp__time zwp__currenttime-container" role="timer" aria-live="on"><span class="zwp__currenttime">00:00</span></div><div class="zwp__time zwp__duration-container" style="display: none;"><span class="zwp__time_divider">/</span> <span class="zwp__duration">0:00:00</span></div><div class="zwp__time-info "></div>'+
241
- L+B+('<div class="zwp-button zwp-qualityButton" style="display: none;"><button class="zwpbtn zwp-qualityBtn" data-action="showQualityMenu" data-name="qualitybtn" title="\u6e05\u6670\u5ea6\u9009\u62e9"><i class="xicon xicon-hd"></i></button><ul class="zwp-qualityMenu">'+Z+"</ul></div>")+y+u+J+P+M+w+'<div class="zwp-button"><button class="zwpbtn zwp-fullscrBtn" data-action="enterfullscreen" data-name="fullscrbtn" title="'+qa("enterFullScreen","\u8fdb\u5165\u5168\u5c4f")+'"><i class="xicon xicon-fullScreen"></i></button></div>'+
242
- F};(function(B,u){"function"===typeof I.define&&I.define.amd?I.define([],u):"object"===typeof exports?module.exports=u():B.ZWPlayer=u()})(I,function(){function B(e){e=e.getBoundingClientRect();return{top:e.top+(I.pageYOffset||document.documentElement.scrollTop),left:e.left+(I.pageXOffset||document.documentElement.scrollLeft)}}function u(e){var n=e.offsetTop;for(e=e.offsetParent;null!==e;)n+=e.offsetTop,e=e.offsetParent;return n}var y=function(){return(new Date).getTime()};"undefined"!=typeof performance&&
243
- performance.now&&(y=function(){return performance.now()});var F=y(),J=function(e){var n="";e.startsWith("webrtc://")&&(n="/rtc/v1/play/");var m=e.indexOf("://");if(-1==m)return!1;var c="";if(0<=e.indexOf("?")){var l=e.indexOf("?");c=e.substr(l+1);e=e.substr(0,l)}var v=e.indexOf("/",m+3);l=e.substr(0,m);m=e.substring(m+3,v);var A=e.substring(v),K=A.lastIndexOf("/");v="";var b=m.indexOf(":");0<b&&(v=m.substring(b+1),m=m.substring(0,b));b=A.substring(1,K);A=A.substring(K+1);K=A.lastIndexOf(".");0<K&&
244
- (A=A.substring(0,K));K="";0<c.indexOf("vhost=")&&(K=c.substr(c.indexOf("vhost=")+6),0<K.indexOf("&")&&(K=K.substr(0,K.indexOf("&"))));m===K&&/^(\d+)\.(\d+)\.(\d+)\.(\d+)$/.test(m)&&(K="_default_vhost_");e={url:e,schema:l,server:m,port:v,vhost:K,app:b,stream:A};e.user_query={};if(0!==c.length){0<=c.indexOf("?")&&(c=c.split("?")[1]);c=c.split("&");for(v=0;v<c.length;v++)K=c[v].split("="),e[K[0]]=K[1],e.user_query[K[0]]=K[1];e.domain&&(e.vhost=e.domain)}if("webrtc"===l||"rtc"===l)l="",e.port||("https"===
245
- e.user_query.schema?(e.port=443,l=e.user_query.schema||"https"):0===I.location.href.indexOf("https://")?(e.port=443,l=e.user_query.schema||"https"):e.port=1985);m="rtmp://"+m+"/"+b+"/"+A;l=l?l+":":I.location.protocol;(v=e.port)||(v="https:"===l?v||443:v||1985);n=n||"/live/webrtc/play/";n.lastIndexOf("/")!==n.length-1&&(n+="/");c=l+"//"+e.server+":"+v+n;for(var O in e.user_query)"api"!==O&&"play"!==O&&(c+="&"+O+"="+e.user_query[O]);c=c.replace(n+"&",n+"?");O={apiUrl:c,streamUrl:m,schema:l,urlObject:e,
246
- port:v};O.tid=Number(parseInt((new Date).getTime()*Math.random()*100)).toString(16).slice(0,7);return O},w=function(e,n,m,c){let l=null;l=I.XMLHttpRequest?new I.XMLHttpRequest:new I.ActiveXObject("Microsoft.XMLHTTP");l.addEventListener("error",function(v){c&&c("REQUEST:"+v.type)});l.onreadystatechange=function(){if(4===l.readyState)if(200===l.status){var v=JSON.parse(l.responseText);m&&m(v)}else c&&c("STATUS:"+l.status+":"+l.statusText)};l.open("POST",e,!0);l.setRequestHeader("Content-Type","application/json");
247
- l.send(n);return l},L=function(e){var n=e.lastIndexOf("/"),m=e.indexOf("?");n=e.indexOf(".",n+1);var c="";0<n&&(0<m?n>m||(c=e.substring(n,m).toLowerCase()):c=e.substring(n).toLowerCase(),n=c.lastIndexOf("."),0<n&&(c=c.substring(n)));return c},M=void 0,P=void 0,Q=void 0;"classList"in document.documentElement?(M=function(e,n){return void 0!==e.classList&&e.classList.contains(n)},P=function(e,n){return e.classList.add(n)},Q=function(e,n){return e.classList.remove(n)}):(M=function(e,n){return(new RegExp("\\b"+
248
- n+"\\b")).test(e.className)},P=function(e,n){M(e,n)||(e.className+=" "+n)},Q=function(e,n){e.className=e.className.replace(new RegExp("\\b"+n+"\\b","g"),"")});I.hasClass=M;I.addClass=P;I.removeClass=Q;/MSIE 8\.0/.test(navigator.userAgent);var Z=function(e){e=parseInt(e);var n=parseInt(e/3600),m=parseInt(e%3600/60);e=parseInt(e%60);var c="";0<n&&(c+=n+":");c=10<=m?c+(m+":"):0<m?c+("0"+m+":"):c+"00:";return 10<=e?c+e:c+("0"+e)},ba=function(e){var n=!1,m=!1,c=this;c._config=e||{};c.peer_conn=null;c.danmuSetting=
249
- {};"undefined"===typeof c._config.controlbar&&(c._config.controlbar=!0);c._config.hideControlbarTimeout||(c._config.hideControlbarTimeout=1E4);"undefined"===typeof c._config.defVolume&&(c._config.defVolume=61.25);c.setRtcstream=function(d){this.videoEl&&(this.videoEl.srcObject=d,this.videoEl.play(),this.setplaystate(!0),this.startHideControlbar(this))};c.onfullscrchange=function(d){Ma()?(this.isFullscr=!0,this.setupFullscrBtn&&this.setupFullscrBtn.setAttribute("title",qa("exitFullScreen","Exit full screen"))):
242
+ K+B+('<div class="zwp-button zwp-qualityButton" style="display: none;"><button class="zwpbtn zwp-qualityBtn" data-action="showQualityMenu" data-name="qualitybtn" title="\u6e05\u6670\u5ea6\u9009\u62e9"><i class="xicon xicon-hd"></i></button><ul class="zwp-qualityMenu">'+Z+"</ul></div>")+y+u+I+O+L+w+'<div class="zwp-button"><button class="zwpbtn zwp-fullscrBtn" data-action="enterfullscreen" data-name="fullscrbtn" title="'+qa("enterFullScreen","\u8fdb\u5165\u5168\u5c4f")+'"><i class="xicon xicon-fullScreen"></i></button></div>'+
243
+ F};(function(B,u){"function"===typeof J.define&&J.define.amd?J.define([],u):"object"===typeof exports?module.exports=u():B.ZWPlayer=u()})(J,function(){function B(e){e=e.getBoundingClientRect();return{top:e.top+(J.pageYOffset||document.documentElement.scrollTop),left:e.left+(J.pageXOffset||document.documentElement.scrollLeft)}}function u(e){var n=e.offsetTop;for(e=e.offsetParent;null!==e;)n+=e.offsetTop,e=e.offsetParent;return n}var y=function(){return(new Date).getTime()};"undefined"!=typeof performance&&
244
+ performance.now&&(y=function(){return performance.now()});var F=y(),I=function(e){var n="";e.startsWith("webrtc://")&&(n="/rtc/v1/play/");var m=e.indexOf("://");if(-1==m)return!1;var c="";if(0<=e.indexOf("?")){var l=e.indexOf("?");c=e.substr(l+1);e=e.substr(0,l)}var v=e.indexOf("/",m+3);l=e.substr(0,m);m=e.substring(m+3,v);var A=e.substring(v),M=A.lastIndexOf("/");v="";var b=m.indexOf(":");0<b&&(v=m.substring(b+1),m=m.substring(0,b));b=A.substring(1,M);A=A.substring(M+1);M=A.lastIndexOf(".");0<M&&
245
+ (A=A.substring(0,M));M="";0<c.indexOf("vhost=")&&(M=c.substr(c.indexOf("vhost=")+6),0<M.indexOf("&")&&(M=M.substr(0,M.indexOf("&"))));m===M&&/^(\d+)\.(\d+)\.(\d+)\.(\d+)$/.test(m)&&(M="_default_vhost_");e={url:e,schema:l,server:m,port:v,vhost:M,app:b,stream:A};e.user_query={};if(0!==c.length){0<=c.indexOf("?")&&(c=c.split("?")[1]);c=c.split("&");for(v=0;v<c.length;v++)M=c[v].split("="),e[M[0]]=M[1],e.user_query[M[0]]=M[1];e.domain&&(e.vhost=e.domain)}if("webrtc"===l||"rtc"===l)l="",e.port||("https"===
246
+ e.user_query.schema?(e.port=443,l=e.user_query.schema||"https"):0===J.location.href.indexOf("https://")?(e.port=443,l=e.user_query.schema||"https"):e.port=1985);m="rtmp://"+m+"/"+b+"/"+A;l=l?l+":":J.location.protocol;(v=e.port)||(v="https:"===l?v||443:v||1985);n=n||"/live/webrtc/play/";n.lastIndexOf("/")!==n.length-1&&(n+="/");c=l+"//"+e.server+":"+v+n;for(var P in e.user_query)"api"!==P&&"play"!==P&&(c+="&"+P+"="+e.user_query[P]);c=c.replace(n+"&",n+"?");P={apiUrl:c,streamUrl:m,schema:l,urlObject:e,
247
+ port:v};P.tid=Number(parseInt((new Date).getTime()*Math.random()*100)).toString(16).slice(0,7);return P},w=function(e,n,m,c){let l=null;l=J.XMLHttpRequest?new J.XMLHttpRequest:new J.ActiveXObject("Microsoft.XMLHTTP");l.addEventListener("error",function(v){c&&c("REQUEST:"+v.type)});l.onreadystatechange=function(){if(4===l.readyState)if(200===l.status){var v=JSON.parse(l.responseText);m&&m(v)}else c&&c("STATUS:"+l.status+":"+l.statusText)};l.open("POST",e,!0);l.setRequestHeader("Content-Type","application/json");
248
+ l.send(n);return l},K=function(e){var n=e.lastIndexOf("/"),m=e.indexOf("?");n=e.indexOf(".",n+1);var c="";0<n&&(0<m?n>m||(c=e.substring(n,m).toLowerCase()):c=e.substring(n).toLowerCase(),n=c.lastIndexOf("."),0<n&&(c=c.substring(n)));return c},L=void 0,O=void 0,Q=void 0;"classList"in document.documentElement?(L=function(e,n){return void 0!==e.classList&&e.classList.contains(n)},O=function(e,n){return e.classList.add(n)},Q=function(e,n){return e.classList.remove(n)}):(L=function(e,n){return(new RegExp("\\b"+
249
+ n+"\\b")).test(e.className)},O=function(e,n){L(e,n)||(e.className+=" "+n)},Q=function(e,n){e.className=e.className.replace(new RegExp("\\b"+n+"\\b","g"),"")});J.hasClass=L;J.addClass=O;J.removeClass=Q;/MSIE 8\.0/.test(navigator.userAgent);var Z=function(e){e=parseInt(e);var n=parseInt(e/3600),m=parseInt(e%3600/60);e=parseInt(e%60);var c="";0<n&&(c+=n+":");c=10<=m?c+(m+":"):0<m?c+("0"+m+":"):c+"00:";return 10<=e?c+e:c+("0"+e)},ba=function(e){var n=!1,m=!1,c=this;c._config=e||{};c.peer_conn=null;c.danmuSetting=
250
+ {};"undefined"===typeof c._config.controlbar&&(c._config.controlbar=!0);c._config.hideControlbarTimeout||(c._config.hideControlbarTimeout=1E4);"undefined"===typeof c._config.defVolume&&(c._config.defVolume=61.25);c.setRtcstream=function(d){this.videoEl&&(this.videoEl.srcObject=d,this.videoEl.play(),this.setplaystate(!0),this.startHideControlbar(this))};c.onfullscrchange=function(d){Na()?(this.isFullscr=!0,this.setupFullscrBtn&&this.setupFullscrBtn.setAttribute("title",qa("exitFullScreen","Exit full screen"))):
250
251
  (this.setupFullscrBtn&&(Q(this.playerElm,"zwp-fullscreen"),this.setupFullscrBtn.setAttribute("data-action","enterfullscreen"),this.setupFullscrBtn.setAttribute("title",qa("enterFullScreen","Enter full screen"))),this.isFullscr=!1);this.isFullscrWin||this.reposDanmuToolbar(this.isFullscr);console.log("fullscrchange:"+d.type)}.bind(c);c.on_btnclick=function(d){if(d.currentTarget&&this.btnBindZwp){d=d.currentTarget;var h=d.getAttribute("data-action");"play"===h?this._config.disablePlayBtn||(this.isPlaying?
251
252
  this.videoEl&&(this.videoEl.paused||this.videoEl.ended)&&(this.videoEl.play(),this.setplaystate(!0)):this._config.url&&this.play(this._config.url)):"pause"===h?this._config.disablePlayBtn||!this.videoEl||this.videoEl.paused||this.videoEl.ended||(this.videoEl.pause(),this.setplaystate(!1)):"mute"===h?this.videoEl&&(this.videoEl.muted||this.setMuted(!0)):"unmute"===h?this.videoEl&&this.videoEl.muted&&this.setMuted(!1):"enterfullscreen"===h?this.setFullscreen(!0,d):"exitfullscreen"===h?this.setFullscreen(!1,
252
- d):"enterfullscreenWin"===h?this.setFullscreenWin(!0,d):"exitfullscreenWin"===h?this.setFullscreenWin(!1,d):"showMediainfo"===h?this.showMediainfo():"snapshot"===h?this.doSnapshot():"pictureInPicture"===h&&this.togglePictureInPicture()}}.bind(c);c.setFullscreen=function(d,h){if(d){if(!Ma()&&this.playerElm){d=this.playerElm;var q=this.videoEl;d.requestFullscreen?d.requestFullscreen():d.webkitRequestFullscreen?d.webkitRequestFullScreen():d.mozRequestFullScreen?d.mozRequestFullScreen():d.msRequestFullscreen?
253
+ d):"enterfullscreenWin"===h?this.setFullscreenWin(!0,d):"exitfullscreenWin"===h?this.setFullscreenWin(!1,d):"showMediainfo"===h?this.showMediainfo():"snapshot"===h?this.doSnapshot():"pictureInPicture"===h&&this.togglePictureInPicture()}}.bind(c);c.setFullscreen=function(d,h){if(d){if(!Na()&&this.playerElm){d=this.playerElm;var q=this.videoEl;d.requestFullscreen?d.requestFullscreen():d.webkitRequestFullscreen?d.webkitRequestFullScreen():d.mozRequestFullScreen?d.mozRequestFullScreen():d.msRequestFullscreen?
253
254
  d.msRequestFullscreen():d.oRequestFullscreen?d.oRequestFullscreen():q.webkitEnterFullScreen?q.webkitEnterFullScreen():(q=document.documentElement,q.requestFullscreen?q.requestFullscreen():q.mozRequestFullScreen?q.mozRequestFullScreen():q.webkitRequestFullScreen?q.webkitRequestFullScreen():(q=document.body,document.documentElement.style.cssText="width:100%;height:100%;overflow:hidden;",q.style.cssText="width:100%;height:100%;overflow:hidden;",d.style.cssText="width:100%;height:100%;overflow:hidden;;margin:0px;padding:0px;",
254
- document.IsFullScreen=!0));P(this.playerElm,"zwp-fullscreen");h.setAttribute("data-action","exitfullscreen");if(!this.setupFullscrBtn){d=this.onfullscrchange;q=this.videoEl;var C=document.webkitExitFullscreen||document.webkitCancelFullScreen?"webkitfullscreenchange":document.mozCancelFullScreen?"mozfullscreenchange":document.msExitFullscreen?"MSFullscreenChange":"webkitfullscreenchange";document.addEventListener("fullscreenchange",d,!1);C&&document.addEventListener(C,d,!1);q&&Va&&(q.addEventListener("webkitbeginfullscreen",
255
- d),q.addEventListener("webkitendfullscreen",d));this.setupFullscrBtn=h}}}else Ma()&&this.playerElm&&(d=this.playerElm,q=document.documentElement,q.exitFullscreen?q.exitFullscreen():q.mozCancelFullScreen?q.mozCancelFullScreen():q.webkitCancelFullScreen?q.webkitCancelFullScreen():document.exitFullscreen?document.exitFullscreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.msExitFullscreen?document.msExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():
256
- document.oRequestFullscreen?document.oCancelFullScreen():document.webkitExitFullscreen?document.webkitExitFullscreen():(q=document.body,document.documentElement.style.cssText="",q.style.cssText="",d.style.cssText="",document.IsFullScreen=!1),Q(this.playerElm,"zwp-fullscreen"),h.setAttribute("data-action","enterfullscreen"))}.bind(c);c.setFullscreenWin=function(d,h){this.playerElm&&(d?this.isFullscrWin||(P(this.playerElm,"zwp-fullscreen-win"),h.setAttribute("data-action","exitfullscreenWin"),this.isFullscrWin=
255
+ document.IsFullScreen=!0));O(this.playerElm,"zwp-fullscreen");h.setAttribute("data-action","exitfullscreen");if(!this.setupFullscrBtn){d=this.onfullscrchange;q=this.videoEl;var C=document.webkitExitFullscreen||document.webkitCancelFullScreen?"webkitfullscreenchange":document.mozCancelFullScreen?"mozfullscreenchange":document.msExitFullscreen?"MSFullscreenChange":"webkitfullscreenchange";document.addEventListener("fullscreenchange",d,!1);C&&document.addEventListener(C,d,!1);q&&Va&&(q.addEventListener("webkitbeginfullscreen",
256
+ d),q.addEventListener("webkitendfullscreen",d));this.setupFullscrBtn=h}}}else Na()&&this.playerElm&&(d=this.playerElm,q=document.documentElement,q.exitFullscreen?q.exitFullscreen():q.mozCancelFullScreen?q.mozCancelFullScreen():q.webkitCancelFullScreen?q.webkitCancelFullScreen():document.exitFullscreen?document.exitFullscreen():document.webkitCancelFullScreen?document.webkitCancelFullScreen():document.msExitFullscreen?document.msExitFullscreen():document.mozCancelFullScreen?document.mozCancelFullScreen():
257
+ document.oRequestFullscreen?document.oCancelFullScreen():document.webkitExitFullscreen?document.webkitExitFullscreen():(q=document.body,document.documentElement.style.cssText="",q.style.cssText="",d.style.cssText="",document.IsFullScreen=!1),Q(this.playerElm,"zwp-fullscreen"),h.setAttribute("data-action","enterfullscreen"))}.bind(c);c.setFullscreenWin=function(d,h){this.playerElm&&(d?this.isFullscrWin||(O(this.playerElm,"zwp-fullscreen-win"),h.setAttribute("data-action","exitfullscreenWin"),this.isFullscrWin=
257
258
  !0,this.reposDanmuToolbar(!0),(d=this.playerElm.parentNode)&&"BODY"!==d.tagName&&(this.oldWrapZIndex=d.style.zIndex,d.style.zIndex=99999999)):this.isFullscrWin&&("undefined"!==typeof this.oldWrapZIndex&&(d=this.playerElm.parentNode,d.style.zIndex=this.oldWrapZIndex,delete this.oldWrapZIndex),Q(this.playerElm,"zwp-fullscreen-win"),h.setAttribute("data-action","enterfullscreenWin"),delete this.isFullscrWin,this.reposDanmuToolbar(!1)))}.bind(c);c.setMuted=function(d){this.videoEl&&(this.videoEl.muted=
258
- d)&&(this.oldVolume=this.videoEl.volume);d?(P(this.playerElm,"zwp-muted"),this.muteBtn&&this.muteBtn.setAttribute("data-action","unmute")):(this.oldVolume&&(this.videoEl.volume=this.oldVolume,delete this.oldVolume),Q(this.playerElm,"zwp-muted"),this.muteBtn&&this.muteBtn.setAttribute("data-action","mute"));this.mutedTipBox&&(this.popup_layers.removeChild(this.mutedTipBox),delete this.mutedTipBox)}.bind(c);c.setVolume=function(d){this.videoEl&&(this.videoEl.volume=d)}.bind(c);c.startHideControlbar=
259
- function(d){d.controlbar&&!d._config.fixedControlbar&&(d.hideControlbarTime=(new Date).getTime()+d._config.hideControlbarTimeout,d.hideControlbarTimer||(d.hideControlbarTimer=I.setInterval(function(){(new Date).getTime()>=d.hideControlbarTime&&(I.clearInterval(d.hideControlbarTimer),delete d.hideControlbarTimer,Ga(d.controlbar,1E3,function(h){h.style.display="none";P(d.playerElm,"hide-cursor");d.isControlbarhidden=!0;"function"==typeof d._config.onhideControlbar&&d._config.onhideControlbar.call(d)}))},
260
- 1E3)))}.bind(c);c.buildProgressBar=function(){var d={};if(this.controlbar){var h=this.controlbar;d.rail=h.querySelector(".zwp__time-rail");d.timeInfo=h.querySelector(".zwp__time-info");if(this._config.isLive)d.rail&&(Q(d.rail,"has-duration"),P(d.rail,"zwp-hidden")),this.progressBar&&this.progressBar.streamtype||(d.timeInfo&&(d.timeInfo.innerHTML='<div class="zwp-streamtype zwp-label">Live</div>',d.streamtype=h.querySelector(".zwp-streamtype")),this.progressBar=d);else if(d.timeInfo&&(this.progressBar&&
261
- this.progressBar.streamtype?this.progressBar.streamtype.innerHTML="VOD":(d.timeInfo.innerHTML='<div class="zwp-streamtype zwp-label">VOD</div>',d.streamtype=h.querySelector(".zwp-streamtype"))),d.rail||(h.insertAdjacentHTML("beforeend",'<div class="zwp__time-rail"></div>'),d.rail=h.querySelector(".zwp__time-rail")),Q(d.rail,"zwp-hidden"),P(d.rail,"has-duration"),this._config.disableSeek&&P(d.rail,"zwp_disabled"),this.progressBar&&this.progressBar.total)this.progressBar.rail&&this._config.useProgressTooltip&&
259
+ d)&&(this.oldVolume=this.videoEl.volume);d?(O(this.playerElm,"zwp-muted"),this.muteBtn&&this.muteBtn.setAttribute("data-action","unmute")):(this.oldVolume&&(this.videoEl.volume=this.oldVolume,delete this.oldVolume),Q(this.playerElm,"zwp-muted"),this.muteBtn&&this.muteBtn.setAttribute("data-action","mute"));this.mutedTipBox&&(this.popup_layers.removeChild(this.mutedTipBox),delete this.mutedTipBox)}.bind(c);c.setVolume=function(d){this.videoEl&&(this.videoEl.volume=d)}.bind(c);c.startHideControlbar=
260
+ function(d){d.controlbar&&!d._config.fixedControlbar&&(d.hideControlbarTime=(new Date).getTime()+d._config.hideControlbarTimeout,d.hideControlbarTimer||(d.hideControlbarTimer=J.setInterval(function(){(new Date).getTime()>=d.hideControlbarTime&&(J.clearInterval(d.hideControlbarTimer),delete d.hideControlbarTimer,Ga(d.controlbar,1E3,function(h){h.style.display="none";O(d.playerElm,"hide-cursor");d.isControlbarhidden=!0;"function"==typeof d._config.onhideControlbar&&d._config.onhideControlbar.call(d)}))},
261
+ 1E3)))}.bind(c);c.buildProgressBar=function(){var d={};if(this.controlbar){var h=this.controlbar;d.rail=h.querySelector(".zwp__time-rail");d.timeInfo=h.querySelector(".zwp__time-info");if(this._config.isLive)d.rail&&(Q(d.rail,"has-duration"),O(d.rail,"zwp-hidden")),this.progressBar&&this.progressBar.streamtype||(d.timeInfo&&(d.timeInfo.innerHTML='<div class="zwp-streamtype zwp-label">Live</div>',d.streamtype=h.querySelector(".zwp-streamtype")),this.progressBar=d);else if(d.timeInfo&&(this.progressBar&&
262
+ this.progressBar.streamtype?this.progressBar.streamtype.innerHTML="VOD":(d.timeInfo.innerHTML='<div class="zwp-streamtype zwp-label">VOD</div>',d.streamtype=h.querySelector(".zwp-streamtype"))),d.rail||(h.insertAdjacentHTML("beforeend",'<div class="zwp__time-rail"></div>'),d.rail=h.querySelector(".zwp__time-rail")),Q(d.rail,"zwp-hidden"),O(d.rail,"has-duration"),this._config.disableSeek&&O(d.rail,"zwp_disabled"),this.progressBar&&this.progressBar.total)this.progressBar.rail&&this._config.useProgressTooltip&&
262
263
  (h=this.progressBar.rail.querySelector(".zwp__time-float"))&&(q=h.querySelector(".zwp__time-thumbnail"),q||(h.insertAdjacentHTML("afterbegin",'<div class="zwp__time-thumbnail"></div>'),q=h.querySelector(".zwp__time-thumbnail"),this.progressBar.thumbnails=q),this._config.thumbnails?(U=this._config.thumbnails,q&&(U.rowsize="number"==typeof U.row?U.row:Math.ceil(Math.sqrt(U.total)),q.style.width=U.width+"px",q.style.height=U.height+"px",q.style.backgroundImage="url("+U.url+")"),h.style.width=4+U.width+
263
- "px",h.style.height=4+U.height+"px",P(h,"zwp__thumbnail")):(h.style.width=null,h.style.height=null,q&&(q.style.width="0px",q.style.height="0px",q.style.backgroundImage=null),Q(h,"zwp__thumbnail")));else{var q='<span class="zwp__time-total zwp__time-slider"><span class="zwp__bar zwp__time-buffering"></span><span class="zwp__bar zwp__time-loaded"></span><span class="zwp__bar zwp__time-current"></span><span class="zwp__time-chapter"></span><span class="zwp__time-hovered no-hover"></span><span class="zwp__time-thumb"><span class="zwp__time-thumb-content"></span></span>';
264
+ "px",h.style.height=4+U.height+"px",O(h,"zwp__thumbnail")):(h.style.width=null,h.style.height=null,q&&(q.style.width="0px",q.style.height="0px",q.style.backgroundImage=null),Q(h,"zwp__thumbnail")));else{var q='<span class="zwp__time-total zwp__time-slider"><span class="zwp__bar zwp__time-buffering"></span><span class="zwp__bar zwp__time-loaded"></span><span class="zwp__bar zwp__time-current"></span><span class="zwp__time-chapter"></span><span class="zwp__time-hovered no-hover"></span><span class="zwp__time-thumb"><span class="zwp__time-thumb-content"></span></span>';
264
265
  if(this._config.useProgressTooltip){var C="",G="",N="";if("object"===typeof this._config.thumbnails&&null!=this._config.thumbnails){var U=this._config.thumbnails;"number"==typeof U.width&&"number"==typeof U.height&&"number"==typeof U.total&&(U.rowsize="number"==typeof U.row?U.row:Math.ceil(Math.sqrt(U.total)),N=' style="width: '+(4+U.width)+"px; height: "+(4+U.height)+'px;"',G=" zwp__thumbnail",C='<div class="zwp__time-thumbnail" style="width: '+U.width+"px;height: "+U.height+"px; background-image: url("+
265
266
  U.url+');"></div>')}q+='<div class="zwp__time-float'+G+'"'+N+">"+C+'<span class="zwp__time-float-current">0:00</span><span class="zwp__time-float-corner corner_external"></span><span class="zwp__time-float-corner corner_internal"></span></div>'}d.rail.innerHTML=q+"</span>";d.buffering=h.querySelector(".zwp__time-buffering");d.total=h.querySelector(".zwp__time-total");d.loaded=h.querySelector(".zwp__time-loaded");d.current=h.querySelector(".zwp__time-current");d.thumb=h.querySelector(".zwp__time-thumb");
266
267
  d.timefloat=h.querySelector(".zwp__time-float");d.timefloatcurrent=h.querySelector(".zwp__time-float-current");d.thumbnails=h.querySelector(".zwp__time-thumbnail");d.slider=h.querySelector(".zwp__time-slider");d.hovered=h.querySelector(".zwp__time-hovered");d.chapters=h.querySelector(".zwp__time-chapter");d.newTime=0;d.forcedHandlePause=!1;d.buffering.style.display="none";d.slider.addEventListener("dragstart",function(){return!1});this.progressBar=d;this.showTimefloat=function(T){if(this._config.useProgressTooltip){var V=
@@ -270,27 +271,27 @@ g.target;(t===d.slider||t.closest(".zwp__time-slider"))&&V.showTimefloat(g)}),d.
270
271
  V?(W.seekTimeProgress(g),W.lastSeekProgress=g):"undefined"!=typeof W.lastSeekProgress&&1<Math.abs(g-W.lastSeekProgress)&&(W.lastSeekProgress=g,W.seekTimer||(W.seekTimer=setTimeout(function(){W.seekTimeProgress(W.lastSeekProgress);delete W.seekTimer},1E3)));T.preventDefault();T.stopPropagation()}.bind(this);this.on_progressbar_mousemove=function(T){var V=T.target,W;if(W=n)a:if(W=d.slider,V===W)W=!0;else{for(;V.parentNode;){if(V.parentNode===W){W=!0;break a}V=V.parentNode}W=!1}W&&S(T)}.bind(this);this.on_progressbar_mouseup=
271
272
  function(T){if(n){document.removeEventListener("mousemove",this.on_progressbar_mousemove);document.removeEventListener("mouseup",this.on_progressbar_mouseup);n=!1;delete this.isTrackingProgress;this.seekTimer&&(clearTimeout(this.seekTimer),delete this.seekTimer);if(T.target&&(T.target.parentNode==d.thumb||T.target==d.thumb)){var V=d.slider.offsetWidth,W=B(d.slider);T=T.pageX-W.left;0>T?T=0:T>V&&(T=V);V=(100*T/V).toFixed(4);"undefined"!=typeof this.lastSeekProgress?1<Math.abs(V-this.lastSeekProgress)&&
272
273
  this.seekTimeProgress(V):this.seekTimeProgress(V)}delete this.lastSeekProgress}}.bind(this);this.on_progressbar_mousedown=function(T){n||this._config.disableSeek||(c.isTrackingProgress=!0,S(T,!0),document.addEventListener("mousemove",this.on_progressbar_mousemove),document.addEventListener("mouseup",this.on_progressbar_mouseup),n=!0,T.preventDefault(),T.stopPropagation())}.bind(this);d.slider.addEventListener("mousedown",this.on_progressbar_mousedown)}}}.bind(c);c.updateProgressBarType=function(){if(this.controlbar){var d=
273
- this.controlbar.querySelector(".zwp__time-rail");this._config.isLive?(d&&(Q(d,"has-duration"),P(d,"zwp-hidden")),this.progressBar&&this.progressBar.streamtype&&(this.progressBar.streamtype.innerHTML="Live",this.progressBar.streamtype.style.display="block")):(d&&(Q(d,"zwp-hidden"),P(d,"has-duration"),this._config.disableSeek&&P(d,"zwp_disabled")),this.progressBar&&this.progressBar.streamtype&&(this.progressBar.streamtype.innerHTML="VOD",this.progressBar.streamtype.style.display="block"))}}.bind(c);
274
+ this.controlbar.querySelector(".zwp__time-rail");this._config.isLive?(d&&(Q(d,"has-duration"),O(d,"zwp-hidden")),this.progressBar&&this.progressBar.streamtype&&(this.progressBar.streamtype.innerHTML="Live",this.progressBar.streamtype.style.display="block")):(d&&(Q(d,"zwp-hidden"),O(d,"has-duration"),this._config.disableSeek&&O(d,"zwp_disabled")),this.progressBar&&this.progressBar.streamtype&&(this.progressBar.streamtype.innerHTML="VOD",this.progressBar.streamtype.style.display="block"))}}.bind(c);
274
275
  c.updateDuration=function(d){if(d.controlbar){var h=d.controlbar.querySelector(".zwp__duration-container"),q=d.videoEl.duration;if(isNaN(q)||Infinity===q)h.style.display="none",d._config.isLive=!0;else{h.style.display="block";h=h.querySelector(".zwp__duration");var C=parseInt(q/3600),G=parseInt(q%3600/60);q=parseInt(q%60);var N="";0<C&&(N+=C+":");N=10<=G?N+(G+":"):0<G?N+("0"+G+":"):N+"00:";h.innerHTML=10<=q?N+q:N+("0"+q);d.chapters&&setTimeout(function(){this.loadChapters()}.bind(d),1E3)}d.updateProgressBarType();
275
276
  d.syncUI()}}.bind(c);c.setProgressRail=function(d){var h=void 0!==d?d.target||d.detail.target:this.videoEl,q=null;h&&h.buffered&&0<h.buffered.length&&h.buffered.end&&this.videoEl.duration?q=h.buffered.end(h.buffered.length-1)/this.videoEl.duration:h&&void 0!==h.bytesTotal&&0<h.bytesTotal&&void 0!==h.bufferedBytes?q=h.bufferedBytes/h.bytesTotal:d&&d.lengthComputable&&0!==d.total&&(q=d.loaded/d.total);null!==q&&(q=Math.min(1,Math.max(0,q)),this.progressBar&&this.progressBar.loaded&&(this.progressBar.loaded.style.width=
276
277
  100*q+"%"))}.bind(c);c.updateProgress=function(d){if(!this.isTrackingProgress&&this.progressBar&&this.progressBar.thumb){var h=this.videoEl.duration;!isNaN(h)&&Infinity!==h&&0<h&&(d+.3>=h&&(d=h),d=d/h*100,this.progressBar.thumb.style.left=d+"%",this.progressBar.current&&(this.progressBar.current.style.width=d/100*100+"%"))}}.bind(c);c.seekTimeProgress=function(d){if(this.videoEl){var h=this.videoEl.duration;isNaN(h)||Infinity===h||(this.videoEl.currentTime=h*d/100,this.progressBar.current&&(this.progressBar.current.style.width=
277
- d+"%"))}}.bind(c);c.seekTimeProgressByTime=function(d){if(this.videoEl){var h=this.videoEl.duration;isNaN(h)||Infinity===h||(this.videoEl.currentTime=d,this.progressBar.current&&(this.progressBar.current.style.width=d/h*100+"%"))}}.bind(c);c.on_speedItemclick=function(d){d.stopPropagation();d=d.currentTarget;if(!M(d,"active")){var h=parseFloat(d.innerText),q=d.parentNode.querySelector(".active");q&&Q(q,"active");P(d,"active");this.videoEl&&(this.videoEl.playbackRate=h);if(q=this.controlbar.querySelector(".zwp-speedBtn"))q.innerHTML=
278
- 1==h?qa("speed","Speed"):d.innerText}var C=d.parentNode;C.style.display="none";setTimeout(function(){C.style.display=null},1E3)}.bind(c);c.resetSpeedMenu=function(){if(this.controlbar){var d=this.controlbar.querySelector(".zwp-speed-item.active");if(d&&"1.0x"!==d.innerText){var h=this.controlbar.querySelector(".zwp-speedBtn");h&&(h.innerHTML=qa("speed","Speed"));Q(d,"active");d=d.parentNode.querySelectorAll("li.zwp-speed-item");if(0<d.length)for(h=0;h<d.length;h++)if("1.0x"===d[h].innerText){P(d[h],
278
+ d+"%"))}}.bind(c);c.seekTimeProgressByTime=function(d){if(this.videoEl){var h=this.videoEl.duration;isNaN(h)||Infinity===h||(this.videoEl.currentTime=d,this.progressBar.current&&(this.progressBar.current.style.width=d/h*100+"%"))}}.bind(c);c.on_speedItemclick=function(d){d.stopPropagation();d=d.currentTarget;if(!L(d,"active")){var h=parseFloat(d.innerText),q=d.parentNode.querySelector(".active");q&&Q(q,"active");O(d,"active");this.videoEl&&(this.videoEl.playbackRate=h);if(q=this.controlbar.querySelector(".zwp-speedBtn"))q.innerHTML=
279
+ 1==h?qa("speed","Speed"):d.innerText}var C=d.parentNode;C.style.display="none";setTimeout(function(){C.style.display=null},1E3)}.bind(c);c.resetSpeedMenu=function(){if(this.controlbar){var d=this.controlbar.querySelector(".zwp-speed-item.active");if(d&&"1.0x"!==d.innerText){var h=this.controlbar.querySelector(".zwp-speedBtn");h&&(h.innerHTML=qa("speed","Speed"));Q(d,"active");d=d.parentNode.querySelectorAll("li.zwp-speed-item");if(0<d.length)for(h=0;h<d.length;h++)if("1.0x"===d[h].innerText){O(d[h],
279
280
  "active");break}}}}.bind(c);c.syncUI=function(){if(this._config.isLive){var d=this.controlbar.querySelector(".zwp-speedButton");d&&this.controlbar.removeChild(d);Q(this.controlbar,"zwp-vodplayer")}else{if(this._config.speedButton&&(d=this.controlbar.querySelector(".zwp-speedButton"),!d)){var h=this.controlbar.querySelector(".zwp-infoButton")||this.controlbar.querySelector(".zwp-optionButton")||this.controlbar.querySelector(".zwp-volume-docker");if(h){var q=jb();d=document.createElement("div");this.controlbar.insertBefore(d,
280
- h);d.outerHTML=q;d=this.controlbar.querySelectorAll(".zwp-speedMenu>li.zwp-speed-item");0<d.length&&d.forEach(function(C){C.addEventListener("click",c.on_speedItemclick)})}}P(this.controlbar,"zwp-vodplayer")}}.bind(c);c.onKeydown=function(d){if(d)if(27===d.keyCode)if(this.contextMenu)this.hideContextMenu(),d.stopPropagation(),d.preventDefault();else{if(this.isFullscrWin&&this.controlbar){var h=this.controlbar.querySelector(".zwp-fullscrWinBtn");h&&(this.setFullscreenWin(!1,h),d.stopPropagation(),
281
+ h);d.outerHTML=q;d=this.controlbar.querySelectorAll(".zwp-speedMenu>li.zwp-speed-item");0<d.length&&d.forEach(function(C){C.addEventListener("click",c.on_speedItemclick)})}}O(this.controlbar,"zwp-vodplayer")}}.bind(c);c.onKeydown=function(d){if(d)if(27===d.keyCode)if(this.contextMenu)this.hideContextMenu(),d.stopPropagation(),d.preventDefault();else{if(this.isFullscrWin&&this.controlbar){var h=this.controlbar.querySelector(".zwp-fullscrWinBtn");h&&(this.setFullscreenWin(!1,h),d.stopPropagation(),
281
282
  d.preventDefault())}}else 13!==d.keyCode&&(38===d.keyCode?(d.preventDefault(),this.videoEl&&(d=this.videoEl.volume,d+=.05,1<d&&(d=1),this.setVolume(d),this.setMuted(!1),h=parseInt(100*d)+"%",h={icon:"speaker",text:h},this.toast(h,1200,!1),this.positionVolumeThumb&&this.positionVolumeThumb(d))):40===d.keyCode?(d.preventDefault(),this.videoEl&&(d=this.videoEl.volume,d-=.05,0>d&&(d=0),this.setVolume(d),this.setMuted(0===d),h=parseInt(100*d)+"%",0===d&&(h=qa("muted","Muted")),h={icon:"speaker",text:h},
282
283
  this.toast(h,1200,!1),this.positionVolumeThumb&&this.positionVolumeThumb(d))):32===d.keyCode?(d.preventDefault(),this._config.isLive||this._config.disablePlayBtn||!this.videoEl||(this.videoEl.paused||this.videoEl.ended?(this.videoEl.play(),this.setplaystate(!0)):(this.videoEl.pause(),this.setplaystate(!1)))):77!==d.keyCode&&109!==d.keyCode||!this.videoEl||(this.videoEl.muted?(this.toast(qa("unmuted","Unmuted"),1E3,!1,!0),this.setMuted(!1)):(this.toast(qa("muted","Muted"),1E3,!1,!0),this.setMuted(!0))))}.bind(c);
283
284
  c.on_colorSliderChange=function(d){var h=d.currentTarget;d=h.getAttribute("data-action");this.colors||(this.colors={brightness:0,contrast:0,saturation:0,hue:0});$a(h);if("undefined"!==typeof this.colors[d]&&(h=parseInt(h.value),"hue"===d?this.colors.hue=parseInt(180*h/100):this.colors[d]=h,this.videoEl)){d=null;h=this.colors;h.brightness&&(d="brightness("+(100+h.brightness)+"%)");if(h.contrast){var q=100+h.contrast;d=(d?d+" ":"")+("contrast("+q+"%)")}h.saturation&&(q=100+h.saturation,d=(d?d+" ":"")+
284
- ("saturate("+q+"%)"));h.hue&&(h=h.hue,d=(d?d+" ":"")+("hue-rotate("+h+"deg)"));this.videoEl.style.filter=d}}.bind(c);c.createColorSettingPanel=function(){var d=this,h='<div class="zwp-colorSettingPanel zwp-popupwindow"><button class="closeBtn"><i class="xicon xicon-close"></i></button><div class="form-row form-title">\u89c6\u9891\u8272\u5f69\u8c03\u6574</div><div class="form-row"><label class="row-label">\u4eae\u5ea6</label><div class="row-content">'+La("","brightness")+'</div></div><div class="form-row"><label class="row-label">\u5bf9\u6bd4\u5ea6</label><div class="row-content">'+
285
- La("","contrast")+'</div></div><div class="form-row"><label class="row-label">\u9971\u548c\u5ea6</label><div class="row-content">'+La("","saturation")+'</div></div><div class="form-row"><label class="row-label">\u8272\u8c03</label><div class="row-content">'+La("","hue")+'</div></div><div class="form-row form-bottombar"><button class="zwp-form-button action-item" data-action="resetcolors">\u91cd\u7f6e</button></div></div>';d.overlay_layers.insertAdjacentHTML("beforeend",h);h=d.overlay_layers.querySelector(":scope > .zwp-colorSettingPanel");
285
+ ("saturate("+q+"%)"));h.hue&&(h=h.hue,d=(d?d+" ":"")+("hue-rotate("+h+"deg)"));this.videoEl.style.filter=d}}.bind(c);c.createColorSettingPanel=function(){var d=this,h='<div class="zwp-colorSettingPanel zwp-popupwindow"><button class="closeBtn"><i class="xicon xicon-close"></i></button><div class="form-row form-title">\u89c6\u9891\u8272\u5f69\u8c03\u6574</div><div class="form-row"><label class="row-label">\u4eae\u5ea6</label><div class="row-content">'+Ma("","brightness")+'</div></div><div class="form-row"><label class="row-label">\u5bf9\u6bd4\u5ea6</label><div class="row-content">'+
286
+ Ma("","contrast")+'</div></div><div class="form-row"><label class="row-label">\u9971\u548c\u5ea6</label><div class="row-content">'+Ma("","saturation")+'</div></div><div class="form-row"><label class="row-label">\u8272\u8c03</label><div class="row-content">'+Ma("","hue")+'</div></div><div class="form-row form-bottombar"><button class="zwp-form-button action-item" data-action="resetcolors">\u91cd\u7f6e</button></div></div>';d.overlay_layers.insertAdjacentHTML("beforeend",h);h=d.overlay_layers.querySelector(":scope > .zwp-colorSettingPanel");
286
287
  var q=h.querySelector(".closeBtn");q&&q.addEventListener("click",function(C){C.stopPropagation();var G=C.currentTarget.closest(".zwp-colorSettingPanel");Ga(G,500,function(){G.remove()});delete d.colorSettingPanel});q=h.querySelectorAll('input[type="range"]');0<q.length&&q.forEach(function(C){C.addEventListener("input",c.on_colorSliderChange);if(d.colors){var G=C.getAttribute("data-action");"undefined"!==typeof d.colors[G]&&(C.value=d.colors[G],$a(C))}});h.addEventListener("mousedown",function(C){C.stopPropagation()});
287
288
  h.addEventListener("dblclick",function(C){C.stopPropagation()});h.addEventListener("click",function(C){C.stopPropagation()});(q=h.querySelector(".zwp-form-button"))&&q.addEventListener("click",function(C){C.preventDefault();C.stopPropagation();C=C.currentTarget.closest(".zwp-colorSettingPanel").querySelectorAll('input[type="range"]');0<C.length&&C.forEach(function(G){if(0!==parseInt(G.value))if(G.value=0,document.createEvent){const N=document.createEvent("HTMLEvents");N.initEvent("input",!0,!1);G.dispatchEvent(N)}else document.createEventObject&&
288
- G.fireEvent("input")})});return d.colorSettingPanel=h}.bind(c);var l=function(d,h){if(d=d.querySelector(".zwp-optionPanel"))d=d.querySelectorAll(".zwp_switch"),0<d.length&&d.forEach(function(q){var C=q.getAttribute("data-action");-1!==h.indexOf(C)&&M(q,"switch_on")&&Q(q,"switch_on")})};c.on_optionItemclick=function(d){d.stopPropagation();d=d.currentTarget;M(d,"zwp_switch")&&Oa(d);var h=d.getAttribute("data-action");if("mirror"===h)this.videoEl&&(d=M(d,"switch_on"),this._config.video_mirror=d,this.flipMirrorVideo(),
289
- d&&(this._config.video_rotated=0,l(this.controlbar,["rotated270","rotated90"])));else if("flip"===h)this.videoEl&&(d=M(d,"switch_on"),this._config.video_flip=d,this.flipMirrorVideo(),d&&(this._config.video_rotated=0,l(this.controlbar,["rotated270","rotated90"])));else if("rotated90"===h)this.videoEl&&(d=M(d,"switch_on"),this._config.video_rotated=d?90:0,this.rotateVideo(),d&&(this._config.video_mirror=!1,this._config.video_flip=!1,l(this.controlbar,["mirror","flip","rotated270"])));else if("rotated270"===
290
- h)this.videoEl&&(d=M(d,"switch_on"),this._config.video_rotated=d?270:0,this.rotateVideo(),d&&(this._config.video_mirror=!1,this._config.video_flip=!1,l(this.controlbar,["mirror","flip","rotated90"])));else if("loop"===h)d=M(d,"switch_on"),this._config.loop=d;else if("showColorConfig"===h){var q=d.closest(".zwp-optionPanel");if(q&&q.closest(".zwp-optionButton")){d=this.overlay_layers.querySelector(":scope > .zwp-colorSettingPanel");if(!d&&(d=this.createColorSettingPanel(),!d))return;d.style.display=
289
+ G.fireEvent("input")})});return d.colorSettingPanel=h}.bind(c);var l=function(d,h){if(d=d.querySelector(".zwp-optionPanel"))d=d.querySelectorAll(".zwp_switch"),0<d.length&&d.forEach(function(q){var C=q.getAttribute("data-action");-1!==h.indexOf(C)&&L(q,"switch_on")&&Q(q,"switch_on")})};c.on_optionItemclick=function(d){d.stopPropagation();d=d.currentTarget;L(d,"zwp_switch")&&Oa(d);var h=d.getAttribute("data-action");if("mirror"===h)this.videoEl&&(d=L(d,"switch_on"),this._config.video_mirror=d,this.flipMirrorVideo(),
290
+ d&&(this._config.video_rotated=0,l(this.controlbar,["rotated270","rotated90"])));else if("flip"===h)this.videoEl&&(d=L(d,"switch_on"),this._config.video_flip=d,this.flipMirrorVideo(),d&&(this._config.video_rotated=0,l(this.controlbar,["rotated270","rotated90"])));else if("rotated90"===h)this.videoEl&&(d=L(d,"switch_on"),this._config.video_rotated=d?90:0,this.rotateVideo(),d&&(this._config.video_mirror=!1,this._config.video_flip=!1,l(this.controlbar,["mirror","flip","rotated270"])));else if("rotated270"===
291
+ h)this.videoEl&&(d=L(d,"switch_on"),this._config.video_rotated=d?270:0,this.rotateVideo(),d&&(this._config.video_mirror=!1,this._config.video_flip=!1,l(this.controlbar,["mirror","flip","rotated90"])));else if("loop"===h)d=L(d,"switch_on"),this._config.loop=d;else if("showColorConfig"===h){var q=d.closest(".zwp-optionPanel");if(q&&q.closest(".zwp-optionButton")){d=this.overlay_layers.querySelector(":scope > .zwp-colorSettingPanel");if(!d&&(d=this.createColorSettingPanel(),!d))return;d.style.display=
291
292
  "block";q.style.display="none";setTimeout(function(){q.style.display=null},1E3)}}}.bind(c);c.flipMirrorVideo=function(){var d=null;this._config.video_flip&&(d="rotateX(180.00deg)");this._config.video_mirror&&(d=d?d+" rotateY(180.00deg)":" rotateY(180.00deg)");this.videoEl.style.width="100%";this.videoEl.style.height="100%";this.videoEl.style.transform=d}.bind(c);c.rotateVideo=function(){var d=null,h=this.videoEl.parentNode;if(h&&h===this.videoWrapper)if(this._config.video_rotated){var q=h.offsetHeight;
292
293
  h=h.offsetWidth;var C=this.videoEl.videoHeight;this.videoEl.videoWidth&&C&&(this.videoEl.style.width=q+"px",this.videoEl.style.height=h+"px",this.videoEl.style.transformOrigin="center center",C=(h-q)/2,q=(q-h)/2,90===this._config.video_rotated?d="translate("+C+"px, "+q+"px) rotate(0.25turn)":270===this._config.video_rotated&&(d="translate("+C+"px, "+q+"px) rotate(0.75turn)"),this.videoEl.style.transform=d)}else this.videoEl.style.transform&&(this.videoEl.style.transform=null,this.videoEl.style.width=
293
- "100%",this.videoEl.style.height="100%")}.bind(c);c.setupEventsHandler=function(){var d=this,h=function(N){d.loadingOverlay&&(d.loadingOverlay.style.display="none");d.videoEl.play();d.setplaystate(!0);d.updateDuration(d);d._config.isLive&&d.controlbar&&(d.controlbar.querySelector(".zwp__duration-container").style.display="none");d.buildProgressBar()};d.videoEl.addEventListener("loadedmetadata",h);var q=d.videoEl,C=function(N){var U=!0;"ended"===N.type?!d._config.isLive&&d._config.loop?(I.setTimeout(function(){d.videoEl.currentTime=
294
+ "100%",this.videoEl.style.height="100%")}.bind(c);c.setupEventsHandler=function(){var d=this,h=function(N){d.loadingOverlay&&(d.loadingOverlay.style.display="none");d.videoEl.play();d.setplaystate(!0);d.updateDuration(d);d._config.isLive&&d.controlbar&&(d.controlbar.querySelector(".zwp__duration-container").style.display="none");d.buildProgressBar()};d.videoEl.addEventListener("loadedmetadata",h);var q=d.videoEl,C=function(N){var U=!0;"ended"===N.type?!d._config.isLive&&d._config.loop?(J.setTimeout(function(){d.videoEl.currentTime=
294
295
  0;d.videoEl.play()},1E3),U=!1):(d.isEnded=!0,d.setplaystate(!1),d._config.reconnect&&d.mpegtsPlayer&&(setTimeout(function(){d.lastDecodedFrames=0;d.closecall(d);d.openMpegts()},1E3),U=!1)):"play"===N.type?(delete d.isEnded,"undefined"!==typeof d.postSeekTime&&(d.seekTimeProgressByTime(d.postSeekTime),delete d.postSeekTime)):"pause"===N.type?d.setplaystate(!1):"playing"===N.type&&d.setplaystate(!0);d.progressBar&&d.progressBar.buffering&&("play playing pause seeked ended error".split(" ").includes(N.type)?
295
296
  d.progressBar.buffering.style.display="none":["seeking","waiting","loadeddata"].includes(N.type)&&(d.progressBar.buffering.style.display=""));U&&"function"===typeof d._config.onmediaevent&&d._config.onmediaevent.call(d,N)},G=function(N){var U=this.currentTime;"undefined"!==typeof d.postSeekTime&&(U=d.postSeekTime);if("function"===typeof d._config.ontimeupdate)d._config.ontimeupdate(U);!d.timeSpan&&d.controlbar&&(d.timeSpan=d.controlbar.querySelector(".zwp__currenttime"));d.timeSpan&&(d.timeSpan.innerHTML=
296
297
  Z(U));d.updateProgress(U);d.setProgressRail(N);d.renderSubtitles(U)};q.addEventListener("play",C);q.addEventListener("playing",C);q.addEventListener("pause",C);q.addEventListener("seeked",C);q.addEventListener("ended",C);q.addEventListener("error",C);q.addEventListener("seeking",C);q.addEventListener("waiting",C);q.addEventListener("timeupdate",G);document.addEventListener("keydown",d.onKeydown);c.videoEventsSetuped=!0;c.removeVideoEventHandlers=function(){if(this.videoEventsSetuped){var N=this.videoEl;
@@ -302,123 +303,123 @@ d+='<div class="info-item"><span class="info-label">Height</span><span class="in
302
303
  function(N){N.stopPropagation()});var G=function(N){N.preventDefault();N.stopPropagation();Ga(q,500,function(){q.remove()});h.overlay_layers.removeEventListener("click",G);delete h.infoViewer};d=q.querySelector(".closeBtn");d.addEventListener("click",G);h.infoViewer=q}}}.bind(c);c.setMediainfo=function(d,h){d={engine:d,hasVideo:h.hasVideo,hasAudio:h.hasAudio};if(h.hasVideo){var q=h.videoCodec;q=0<=q.indexOf("avc1")?"H264/AVC":0<=q.indexOf("hvc")?"H265/HEVC":"Unknown";d.vCodec=q;d.width=h.width;d.height=
303
304
  h.height;d.fps=h.fps;"number"===typeof d.fps&&(d.fps=d.fps.toFixed(2));d.profile=h.profile;d.level=h.level}h.hasAudio&&(q=h.audioCodec,q=0<=q.indexOf("mp4a.40.2")?"AAC-LC":0<=q.indexOf("mp4a.40.5")?"HE-AAC":0<=q.indexOf("mp3")?"MP3":"Unknown",d.aCodec=q,d.sampleRate=h.audioSampleRate,d.channels=h.audioChannelCount);this.mediaInfo=d}.bind(c);c.loadChapters=function(){var d=this;if(d.chapters){if("string"===typeof d.chapters)if("["===d.chapters.charAt(0))d.chapters=JSON.parse(d.chapters);else{if("http"===
304
305
  d.chapters.substr(0,4))Ra(d.chapters,function(S){if("WEBVTT"===S.substr(0,6))d.chapters=S,d.loadChapters();else if(S=JSON.parse(S))d.chapters=S,d.loadChapters()},function(S){console.warn("get chapter list from "+d.chapters+" failed!")});else if("WEBVTT"===d.chapters.substr(0,6)){var h=Sa(d.chapters);if(h){for(var q=[],C=0;C<h.body.length;C++){var G=h.body[C];q.push({title:G.content,time:Z(G.from),desc:"no desc",image:null})}d.chapters=q;d.loadChapters()}else delete d.chapters}else delete d.chapters;
305
- return}else if(!Array.isArray(d.chapters))return;h=d.videoEl.duration;if(!isNaN(h)&&Infinity!==h){if(h=nb(h,d.chapters))if(q=d.controlbar.querySelector(".zwp__time-chapter"))q.innerHTML=h,h=q.querySelectorAll(".zwp__chapter_dot"),0<h.length&&h.forEach(function(S){S.addEventListener("mousedown",function(T){T.stopPropagation();T=Na(this.getAttribute("data-time"));d.seekTimeProgressByTime(T)})});if(d._config.chapterButton&&(h=d.controlbar.querySelector(".zwp__time-info"))){var N=h.querySelector(".zwp-chapterButton");
306
- N&&N.remove();var U=ob(d.chapters);U&&((q=h.querySelector(".zwp_danmuBarDock"))?q.insertAdjacentHTML("beforebegin",U.html):h.insertAdjacentHTML("beforeend",U.html),N=h.querySelector(".zwp-chapterButton"),h=N.querySelector(".zwp-chapterlist"),q=h.querySelectorAll(".chapter-item"),0<q.length&&q.forEach(function(S){S.addEventListener("click",function(T){T.stopPropagation();T=Na(this.getAttribute("data-time"));d.seekTimeProgressByTime(T)})}),h.addEventListener("mousedown",function(S){S.stopPropagation()}),
306
+ return}else if(!Array.isArray(d.chapters))return;h=d.videoEl.duration;if(!isNaN(h)&&Infinity!==h){if(h=nb(h,d.chapters))if(q=d.controlbar.querySelector(".zwp__time-chapter"))q.innerHTML=h,h=q.querySelectorAll(".zwp__chapter_dot"),0<h.length&&h.forEach(function(S){S.addEventListener("mousedown",function(T){T.stopPropagation();T=La(this.getAttribute("data-time"));d.seekTimeProgressByTime(T)})});if(d._config.chapterButton&&(h=d.controlbar.querySelector(".zwp__time-info"))){var N=h.querySelector(".zwp-chapterButton");
307
+ N&&N.remove();var U=ob(d.chapters);U&&((q=h.querySelector(".zwp_danmuBarDock"))?q.insertAdjacentHTML("beforebegin",U.html):h.insertAdjacentHTML("beforeend",U.html),N=h.querySelector(".zwp-chapterButton"),h=N.querySelector(".zwp-chapterlist"),q=h.querySelectorAll(".chapter-item"),0<q.length&&q.forEach(function(S){S.addEventListener("click",function(T){T.stopPropagation();T=La(this.getAttribute("data-time"));d.seekTimeProgressByTime(T)})}),h.addEventListener("mousedown",function(S){S.stopPropagation()}),
307
308
  h.addEventListener("dblclick",function(S){S.stopPropagation()}),N.querySelector(".zwp-chapterBtn").addEventListener("click",function(S){S.stopPropagation();if(S=N.querySelector(".zwp-chapterPanel")){var T=d.overlay_layers.offsetHeight;if(!(100>T)){T-=100;400<T&&(T=400);var V=U.titleWidth;200<V&&(V=200);S.style.height=T+"px";S.style.width=80+V+10+"px";"block"!==S.style.display?(T=S.querySelector(".zwp-list-inner"),$$(T).niceScroll({cursorborder:"",cursorcolor:"rgb(179 178 178 / 67%)",boxzoom:!1,rightdock:4}),
308
309
  S.style.opacity=1,S.style.display="block"):S.style.display="none"}}}),(h=N.querySelector(".closeBtn"))&&h.addEventListener("click",function(S){S.stopPropagation();var T=S.currentTarget.closest(".zwp-chapterPanel");Ga(T,500,function(){T.style.display="none"})}))}}}}.bind(c);c.removeChapters=function(){if(this.chapters){if(this.controlbar){var d=this.controlbar.querySelector(".zwp__time-chapter");d&&(d.innerHTML="")}(d=this.controlbar.querySelector(".zwp__time-info"))&&(d=d.querySelector(".zwp-chapterButton"))&&
309
310
  d.remove();delete this.chapters}}.bind(c);c.doSnapshot=function(){if(this.videoEl&&this.videoEl.videoWidth){if(!this.snapCanvas&&(this.snapCanvas=document.createElement("canvas"),!this.snapCanvas))return;var d=this.videoEl,h=this.snapCanvas;h.width=this.videoEl.videoWidth;h.height=this.videoEl.videoHeight;var q=h.getContext("2d");q.fillStyle="#000000";q.beginPath();q.fillRect(0,0,d.videoWidth,d.videoHeight);q.closePath();q.drawImage(d,0,0,d.videoWidth,d.videoHeight);if("function"==typeof h.toBlob){var C=
310
311
  "SNAP-"+db();try{h.toBlob(function(G){const N=document.createElement("a");N.download=`${C}.jpg`;N.href=URL.createObjectURL(G);N.click();cb(G)},"image/jpg",.99)}catch(G){console.error("\u89c6\u9891\u6e90\u53d7CORS\u6807\u8bc6\u9650\u5236\uff0c\u65e0\u6cd5\u76f4\u63a5\u4e0b\u8f7d\u622a\u56fe\uff0c\u89c1\uff1a\n https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS")}}else console.error("\u6d4f\u89c8\u5668\u529f\u80fd\u9650\u5236\uff0c\u65e0\u6cd5\u622a\u53d6\u56fe\u50cf")}}.bind(c);c.togglePictureInPicture=
311
- function(){var d=this;if(d.videoEl)if(document.pictureInPictureElement)document.exitPictureInPicture();else{var h=d.videoEl;d.smallWindowMode||(h.bindPicInPicEvent||(h.addEventListener("enterpictureinpicture",function(q){console.log(q.width,q.height);P(d.playerElm,"zwp-picInPic");d.overlay_layers.insertAdjacentHTML("beforeEnd",'<div class="zwp-pipPlaceHolder">\t<div class="zwp-pipControl">\t\t<div class="zwp-pipTiptext">\u6b63\u5728\u300c\u753b\u4e2d\u753b\u300d\u6a21\u5f0f\u4e0b\u64ad\u653e</div>\t\t<div class="zwp-pipExitButton">\u9000\u51fa\u753b\u4e2d\u753b</div>\t</div></div>');
312
+ function(){var d=this;if(d.videoEl)if(document.pictureInPictureElement)document.exitPictureInPicture();else{var h=d.videoEl;d.smallWindowMode||(h.bindPicInPicEvent||(h.addEventListener("enterpictureinpicture",function(q){console.log(q.width,q.height);O(d.playerElm,"zwp-picInPic");d.overlay_layers.insertAdjacentHTML("beforeEnd",'<div class="zwp-pipPlaceHolder">\t<div class="zwp-pipControl">\t\t<div class="zwp-pipTiptext">\u6b63\u5728\u300c\u753b\u4e2d\u753b\u300d\u6a21\u5f0f\u4e0b\u64ad\u653e</div>\t\t<div class="zwp-pipExitButton">\u9000\u51fa\u753b\u4e2d\u753b</div>\t</div></div>');
312
313
  (q=d.overlay_layers.querySelector(".zwp-pipExitButton"))&&q.addEventListener("click",function(C){C.stopPropagation();document.pictureInPictureElement&&document.exitPictureInPicture()});d.isInPicInPic=!0}),h.addEventListener("leavepictureinpicture",function(){Q(d.playerElm,"zwp-picInPic");var q=d.overlay_layers.querySelector(".zwp-pipPlaceHolder");q&&d.overlay_layers.removeChild(q);setTimeout(function(){},500);delete d.isInPicInPic}),h.bindPicInPicEvent=!0),h.requestPictureInPicture())}}.bind(c);c.showSubtitle=
313
314
  function(d){var h=this;if(h.overlay_layers){var q=h.overlay_layers.querySelector(".zwp-subtitles-show");if(q){if(d?"block"!==q.style.display&&(q.style.opacity=0,q.style.display="block",Pa(q,500,function(){})):Ga(q,500,function(){Ba.removeElement(q);q.remove();delete h.subtitleShow;delete h.subtitle1;delete h.subtitle2}),h.controlbar){var C=h.controlbar.querySelector(".zwp-subtitleButton");C&&(C.style.display=d?"block":"none")}}else if(d){q=document.createElement("div");q.setAttribute("class","zwp-subtitles-show");
314
315
  q.innerHTML='<div class="zwp-subtitles-viever"><div class="zwp-subtitle subtitle-1"><span class="subtitle-text"></span></div><div class="zwp-subtitle subtitle-2"><span class="subtitle-text"></span></div></div>';h.overlay_layers.appendChild(q);q.addEventListener("click",function(V){V.preventDefault();V.stopPropagation()});Ba.addElement(q);q.addEventListener("resize",function(V){this.updateSubtitlePosition()}.bind(h));h.subtitleShow=q;h.subtitle1=q.querySelector(".subtitle-1 > .subtitle-text");h.subtitle2=
315
- q.querySelector(".subtitle-2 > .subtitle-text");h.subtitle2.style.display="none";var G=q.querySelector(".zwp-subtitles-viever"),N=!1,U=0,S=0;d="onpointerout"in document;var T="ontouchstart"in document.documentElement||"ontouchstart"in I;h.on_subtitle_mousemove=function(V){var W=V.target;if(!N||W!==this.subtitle1&&W!==this.subtitle2)console.log("out subtitle");else{W=V.pageY;var g=!0;"touchmove"==V.type&&(V.changedTouches&&(W=V.changedTouches[0].pageY),g=!1);g&&V.preventDefault();V.stopPropagation();
316
+ q.querySelector(".subtitle-2 > .subtitle-text");h.subtitle2.style.display="none";var G=q.querySelector(".zwp-subtitles-viever"),N=!1,U=0,S=0;d="onpointerout"in document;var T="ontouchstart"in document.documentElement||"ontouchstart"in J;h.on_subtitle_mousemove=function(V){var W=V.target;if(!N||W!==this.subtitle1&&W!==this.subtitle2)console.log("out subtitle");else{W=V.pageY;var g=!0;"touchmove"==V.type&&(V.changedTouches&&(W=V.changedTouches[0].pageY),g=!1);g&&V.preventDefault();V.stopPropagation();
316
317
  V=U-W;54>=G.offsetTop&&0<V||(V=S+V,54>V&&(console.log("mouse move 0"),V=54),G.style.bottom=V+"px",console.log("move x: ",V))}}.bind(h);h.on_subtitle_mouseup=function(V){N&&("onpointerout"in document?(document.removeEventListener("pointermove",this.on_subtitle_mousemove),document.removeEventListener("pointerup",this.on_subtitle_mouseup)):T?(document.removeEventListener("touchmove",this.on_subtitle_mousemove),document.removeEventListener("touchend",this.on_subtitle_mouseup)):(document.removeEventListener("mousemove",
317
318
  this.on_subtitle_mousemove),document.removeEventListener("mouseup",this.on_subtitle_mouseup)),N=!1)}.bind(h);h.on_subtitle_mousedown=function(V){"onpointerout"in document?(document.addEventListener("pointermove",this.on_subtitle_mousemove),document.addEventListener("pointerup",this.on_subtitle_mouseup)):T?(document.addEventListener("touchmove",this.on_subtitle_mousemove),document.addEventListener("touchend",this.on_subtitle_mouseup)):(document.addEventListener("mousemove",this.on_subtitle_mousemove),
318
- document.addEventListener("mouseup",this.on_subtitle_mouseup));N=!0;U=V.pageY;var W=parseInt(G.offsetTop+G.offsetHeight);S=this.subtitleShow.offsetHeight-W;V.stopPropagation();V.preventDefault()}.bind(h);h.on_subtitleItemclick=function(V){V.stopPropagation();var W=V.currentTarget;M(W,"zwp_switch")&&Oa(W);V=W.getAttribute("data-action");W=M(W,"switch_on");"subtitleOn"===V?this.subtitleShow&&(this.subtitleShow.style.display=W?"block":"none"):"subtitleDefault"===V?this.subtitles["1"]&&(W?this.subtitles["1"].hidden&&
319
+ document.addEventListener("mouseup",this.on_subtitle_mouseup));N=!0;U=V.pageY;var W=parseInt(G.offsetTop+G.offsetHeight);S=this.subtitleShow.offsetHeight-W;V.stopPropagation();V.preventDefault()}.bind(h);h.on_subtitleItemclick=function(V){V.stopPropagation();var W=V.currentTarget;L(W,"zwp_switch")&&Oa(W);V=W.getAttribute("data-action");W=L(W,"switch_on");"subtitleOn"===V?this.subtitleShow&&(this.subtitleShow.style.display=W?"block":"none"):"subtitleDefault"===V?this.subtitles["1"]&&(W?this.subtitles["1"].hidden&&
319
320
  (delete this.subtitles["1"].hidden,this.subtitle1.style.display="block"):(this.subtitles["1"].hidden=!0,this.subtitle1.style.display="none")):"subtitleSecond"===V&&this.subtitles["2"]&&(W?this.subtitles["2"].hidden&&(delete this.subtitles["2"].hidden,this.subtitle2.style.display="block"):(this.subtitles["2"].hidden=!0,this.subtitle2.style.display="none"))}.bind(h);d?G.addEventListener("pointerdown",h.on_subtitle_mousedown):canTouch?G.addEventListener("touchstart",h.on_subtitle_mousedown):G.addEventListener("mousedown",
320
- h.on_subtitle_mousedown);if(h.controlbar){if(C=h.controlbar.querySelector(".zwp-subtitleButton"))C.style.display="block";(d=O.querySelector(".zwp-subtitleMenu"))&&!d.bindSwitchEvent&&(C=d.querySelectorAll(".action-item"),0<C.length&&C.forEach(function(V){V.addEventListener("click",h.on_subtitleItemclick);var W=V.getAttribute("data-action");"subtitleOn"!==W&&"subtitleDefault"!==W||P(V,"switch_on")}),d.bindSwitchEvent=!0)}}}}.bind(c);c.getSimpleSubtitleRenderer=function(){if(!this.overlay_layers)return null;
321
+ h.on_subtitle_mousedown);if(h.controlbar){if(C=h.controlbar.querySelector(".zwp-subtitleButton"))C.style.display="block";(d=P.querySelector(".zwp-subtitleMenu"))&&!d.bindSwitchEvent&&(C=d.querySelectorAll(".action-item"),0<C.length&&C.forEach(function(V){V.addEventListener("click",h.on_subtitleItemclick);var W=V.getAttribute("data-action");"subtitleOn"!==W&&"subtitleDefault"!==W||O(V,"switch_on")}),d.bindSwitchEvent=!0)}}}}.bind(c);c.getSimpleSubtitleRenderer=function(){if(!this.overlay_layers)return null;
321
322
  var d=this.overlay_layers.querySelector(".zwp-subtitles-show");if(d){var h=d.querySelector(".zwp-simple-subtitles-viever");h||(d.innerHTML='<div class="zwp-simple-subtitles-viever"></div>',h=d.querySelector(".zwp-simple-subtitles-viever"));return h}d=document.createElement("div");d.setAttribute("class","zwp-subtitles-show");d.innerHTML='<div class="zwp-simple-subtitles-viever"></div>';this.overlay_layers.appendChild(d);d.addEventListener("click",function(q){q.preventDefault();q.stopPropagation()});
322
- Ba.addElement(d);d.addEventListener("resize",function(q){this.updateSubtitlePosition()}.bind(this));this.subtitleShow=d;return d.querySelector(".zwp-simple-subtitles-viever")}.bind(c);c.loadSubtitle=function(d,h,q){var C=this;"1"!==h&&"2"!==h||Ra(d,function(G){var N=L(d);if(".srt"===N)var U=eb(G);else if(".vtt"===N)U=Sa(G);else if(".json"===N||".bcc"===N)U=JSON.parse(G);if(U){C.subtitles||(C.subtitles={});q&&(U.title=q);"2"===h&&C._config.secondSubtitleHidden&&(U.hidden=!0);if(C.controlbar&&(N=C.controlbar.querySelector(".zwp-subtitleMenu"))){N.querySelector(".main")||
323
- (N.innerHTML=Ya(),Q(N,"zwp-autosize"));if("1"===h&&(G=N.querySelector(".sub1"))){q||=qa("mainSubtitle","Main subtitle");var S=G.querySelector(".zwp-option-item-label");S&&(S.innerHTML=q);G.style.display="block"}if("2"===h&&(G=N.querySelector(".sub2"))){q||=qa("secondSubtitle","Second subtitle");if(S=G.querySelector(".zwp-option-item-label"))S.innerHTML=q;U.hidden||(N=G.querySelector(".zwp_switch"))&&P(N,"switch_on");G.style.display="block"}}C.subtitles[h]=U;C.showSubtitleTimer||(C.showSubtitleTimer=
323
+ Ba.addElement(d);d.addEventListener("resize",function(q){this.updateSubtitlePosition()}.bind(this));this.subtitleShow=d;return d.querySelector(".zwp-simple-subtitles-viever")}.bind(c);c.loadSubtitle=function(d,h,q){var C=this;"1"!==h&&"2"!==h||Ra(d,function(G){var N=K(d);if(".srt"===N)var U=eb(G);else if(".vtt"===N)U=Sa(G);else if(".json"===N||".bcc"===N)U=JSON.parse(G);if(U){C.subtitles||(C.subtitles={});q&&(U.title=q);"2"===h&&C._config.secondSubtitleHidden&&(U.hidden=!0);if(C.controlbar&&(N=C.controlbar.querySelector(".zwp-subtitleMenu"))){N.querySelector(".main")||
324
+ (N.innerHTML=Ya(),Q(N,"zwp-autosize"));if("1"===h&&(G=N.querySelector(".sub1"))){q||=qa("mainSubtitle","Main subtitle");var S=G.querySelector(".zwp-option-item-label");S&&(S.innerHTML=q);G.style.display="block"}if("2"===h&&(G=N.querySelector(".sub2"))){q||=qa("secondSubtitle","Second subtitle");if(S=G.querySelector(".zwp-option-item-label"))S.innerHTML=q;U.hidden||(N=G.querySelector(".zwp_switch"))&&O(N,"switch_on");G.style.display="block"}}C.subtitles[h]=U;C.showSubtitleTimer||(C.showSubtitleTimer=
324
325
  setTimeout(function(){this.showSubtitle(!0);delete this.showSubtitleTimer}.bind(C),300))}else console.warn("Invalid subtitle file from "+d)},function(G){console.warn("get subtitle from "+d+" failed!")})}.bind(c);c.renderSubtitles=function(d){if(this.subtitleShow&&this.subtitles&&"none"!==this.subtitleShow.style.display)for(var h=["1","2"],q=0;q<h.length;q++){var C=h[q];if(this.subtitles[C]){var G="subtitle"+C;C=this.subtitles[C];var N=!1;if(!C.hidden){if(C.current){if(d<C.current.from)N=!0;else if(d<
325
326
  C.current.to)continue;this[G]&&(this[G].innerHTML="",this[G].style.display="none");C.current=null}var U=C.nextSubtitleIdx||0,S=!0;if(N){var T=U-4;0>T&&(T=0);for(var V=U-2;V>=T;V--)if(N=C.body[V],d<=N.to){if(d>=N.from){C.current=N;C.nextSubtitleIdx=V+1;S=!1;break}}else{C.nextSubtitleIdx=U;S=!1;break}if(S&&0<T){U=0;for(V=T-1;U<=V;)if(T=parseInt((U+V)/2),N=C.body[T],d<N.from)V=T-1;else if(d>N.to)U=T+1;else{C.current=N;C.nextSubtitleIdx=T+1;S=!1;break}S&&(C.nextSubtitleIdx=U)}}else{T=U+2;T>C.body.length&&
326
327
  (T=C.body.length);for(V=U;V<T;V++)if(N=C.body[V],d>=N.from){if(d<=N.to){C.current=N;C.nextSubtitleIdx=V+1;S=!1;break}}else{C.nextSubtitleIdx=U;S=!1;break}if(S){U=T;V=C.body.length-1;for(T>=C.body.length?d<C.body[C.body.length-1].from&&(U=0):d<C.body[T].from&&(U=0);U<=V;)if(T=parseInt((U+V)/2),N=C.body[T],d<N.from)V=T-1;else if(d>N.to)U=T+1;else{C.current=N;C.nextSubtitleIdx=T+1;S=!1;break}S&&(C.nextSubtitleIdx=U)}}C.current&&this[G]&&(this[G].innerHTML=C.current.content,this[G].style.display="block")}}}}.bind(c);
327
328
  c.updateSubtitlePosition=function(){if(this.subtitleShow&&this.subtitles){var d=["1","2"],h=this.subtitleShow.offsetWidth,q=this.subtitleShow.offsetHeight;if(h&&q)for(h/=1024,q/=576,q=32*(h>q?q:h),h=0;h<d.length;h++){var C=d[h];this.subtitles[C]&&(C="subtitle"+C,this[C]&&(this[C].style.fontSize=q.toFixed(2)+"px"))}}}.bind(c);c.resetQualitiesMenu=function(){if(this&&!this.multiStreams&&this.controlbar){var d=this.controlbar.querySelector(".zwp-qualityButton");if(d){var h=d.querySelector(".zwp-qualityMenu");
328
329
  h&&(h.innerHTML='<li class="zwp-quality-item zwp-disabled" data-index="-1">No quality</li>');d.style.display="none"}}}.bind(c);c.createQualitiesMenu=function(d){var h=this;if(1>=d.length)h.resetQualitiesMenu();else{var q=h.controlbar.querySelector(".zwp-qualityButton");if(q){var C="",G=qa("level","Level")+" ";C+='<li class="zwp-quality-item active" data-idx="-1">'+qa("qs-auto","AUTO SWITCH")+"</li>";for(var N=0;N<d.length;N++){var U="";"undefined"!==typeof d[N]&&(U=d[N].width&&d[N].height?d[N].width+
329
- "x"+d[N].height:G+(N+1));"undefined"!==typeof d[N].bitrate&&(U+=" ("+parseInt(d[N].bitrate/1E3)+"kbps)");C+='<li class="zwp-quality-item" data-br="'+d[N].bitrate+'" data-idx="'+d[N].qualityIndex+'" data-vh="'+d[N].height+'">'+U+"</li>"}if(d=q.querySelector(".zwp-qualityMenu"))d.innerHTML=C,I.mQuery(d).find(".zwp-quality-item").click(function(S){S.preventDefault();S.stopPropagation();S=I.mQuery(this);S.hasClass("active")||(S.siblings().removeClass("active"),S.addClass("active"),S=this.getAttribute("data-idx"),
330
- "function"===typeof h.switchQualityLevel&&h.switchQualityLevel(S))});q.style.display="block"}}}.bind(c);c.updateQualityLevel=function(d,h){if(this&&this.controlbar){var q=this.controlbar.querySelector(".zwp-qualityButton");q&&(q=q.querySelector(".zwp-qualityMenu"))&&I.mQuery(q).children(".zwp-quality-item").each(function(C,G){C=parseInt(G.getAttribute("data-idx"));G=I.mQuery(G);-1===C?h&&!G.hasClass("active")&&(G.siblings(".active").removeClass("active"),G.addClass("active")):d===C?(h||G.hasClass("active")||
330
+ "x"+d[N].height:G+(N+1));"undefined"!==typeof d[N].bitrate&&(U+=" ("+parseInt(d[N].bitrate/1E3)+"kbps)");C+='<li class="zwp-quality-item" data-br="'+d[N].bitrate+'" data-idx="'+d[N].qualityIndex+'" data-vh="'+d[N].height+'">'+U+"</li>"}if(d=q.querySelector(".zwp-qualityMenu"))d.innerHTML=C,J.mQuery(d).find(".zwp-quality-item").click(function(S){S.preventDefault();S.stopPropagation();S=J.mQuery(this);S.hasClass("active")||(S.siblings().removeClass("active"),S.addClass("active"),S=this.getAttribute("data-idx"),
331
+ "function"===typeof h.switchQualityLevel&&h.switchQualityLevel(S))});q.style.display="block"}}}.bind(c);c.updateQualityLevel=function(d,h){if(this&&this.controlbar){var q=this.controlbar.querySelector(".zwp-qualityButton");q&&(q=q.querySelector(".zwp-qualityMenu"))&&J.mQuery(q).children(".zwp-quality-item").each(function(C,G){C=parseInt(G.getAttribute("data-idx"));G=J.mQuery(G);-1===C?h&&!G.hasClass("active")&&(G.siblings(".active").removeClass("active"),G.addClass("active")):d===C?(h||G.hasClass("active")||
331
332
  (G.siblings(".active").removeClass("active"),G.addClass("active")),G.hasClass("current")||(G.siblings(".current").removeClass("current"),G.addClass("current"))):G.hasClass("current")&&G.removeClass("current")})}}.bind(c);c.buildStreamSelector=function(){var d=this;if(d.multiStreams){var h=d.controlbar.querySelector(".zwp-qualityButton");if(h){var q="",C=d.multiStreams.murls;if(!Array.isArray(C)||1!==C.length){for(var G in C){var N=C[G];N="object"===typeof N?N.name:G;q+='<li class="zwp-quality-item" data-stream="'+
332
- N+'">'+qa(N,N)+"</li>"}if(C=h.querySelector(".zwp-qualityMenu"))C.innerHTML=q,q=I.mQuery(C).find(".zwp-quality-item"),q.click(function(U){U.preventDefault();U.stopPropagation();U=this.getAttribute("data-stream");if(d.multiStreams.curStream!==U){var S=d.multiStreams.murls;if(Array.isArray(S))for(var T in S){var V=S[T];if(V.name===U){var W=V.url;break}}else W=S[U];d.__switchStream(W);d.multiStreams.curStream=U;W=I.mQuery(this);W.hasClass("active")||(W.siblings(".active").removeClass("active"),W.addClass("active"));
333
- U=qa(U,U);d.toast("\u5df2\u7ecf\u4e3a\u60a8\u5207\u6362\u5230"+U+"\u753b\u8d28")}}),q.each(function(U,S){U=this.getAttribute("data-stream");if(d.multiStreams.curStream===U&&(U=I.mQuery(this),!U.hasClass("active")))return U.siblings(".active").removeClass("active"),U.addClass("active"),!1});h.style.display="block"}}}}.bind(c);c.createSubtitlesMenu=function(d,h){var q=this;q.controlbar&&(h=q.controlbar.querySelector(".zwp-subtitleMenu"),d=kb(d),h.innerHTML=d,delete h.bindSwitchEvent,P(h,"zwp-autosize"),
334
- I.mQuery(h).find(".zwp-subtitles-item").click(function(C){C.preventDefault();C.stopPropagation();C=I.mQuery(this);C.hasClass("active")||(C.siblings().removeClass("active"),C.addClass("active"),C=this.getAttribute("data-id"),"function"===typeof q.switchSubtitleTrack&&q.switchSubtitleTrack(C))}),d=q.controlbar.querySelector(".zwp-subtitleButton"))&&(d.style.display="block")}.bind(c);c.updateSubtitleTrack=function(d){}.bind(c);c.resetSubtitleMenu=function(){if(this.controlbar){var d=this.controlbar.querySelector(".zwp-subtitleButton");
335
- d&&(d.style.display="none")}}.bind(c);c.__getDanmuBarDock=function(){var d=this.progressBar.timeInfo.querySelector(".zwp_danmuBarDock");d||(d=document.createElement("DIV"),d.setAttribute("class","zwp_danmuBarDock"),this.progressBar.timeInfo.appendChild(d),Ba.addElement(d),d.addEventListener("resize",function(h){var q=this;q.resizeTimer||(q.resizeTimer=I.setTimeout(function(){console.log("danmuBarDock resize");350>d.clientWidth?P(d,"zwp-mini"):Q(d,"zwp-mini");delete q.resizeTimer},50))}.bind(this)));
336
- return d}.bind(c);c.buildDanmuToolbar=function(d,h){var q=this,C;if(!q.danmuToolbar){d&&(C=document.querySelector("#"+d));if(!C){if(!q.overlay_layers)return;h=null;C=q.progressBar&&q.progressBar.timeInfo?q.__getDanmuBarDock():q.overlay_layers}d=lb();C.insertAdjacentHTML("beforeend",d);q.danmuToolbar=C.querySelector(".zwp_danmu-controlbar");h&&P(q.danmuToolbar,h);C.appendChild(q.danmuToolbar);(h=q.danmuToolbar.querySelector(".zwp_switch"))&&h.addEventListener("click",function(G){G.stopPropagation();
337
- G=G.currentTarget;if(M(G,"zwp_switch")){Oa(G);var N=M(G,"switch_on");G=I.$$(this.danmuToolbar);if(N){var U=G.find("button.btn_submit");U.removeClass("vtb_disabled").removeAttr("disabled");this.setEnableDanmu(!0);N=G.find(".barrage_inp_text");N.removeAttr("readonly").removeAttr("disabled").removeClass("disabled");"on"!=N.attr("keydown")&&(N.keydown(function(S){13==S.which&&0<U.length&&U.trigger("click")}),N.attr("keydown","on"));G.find(".zwp-barrage_form").css("background-color","#28303db3").children("a.btn_bubble").toggleClass("disabled")}else G.find("button.btn_submit").addClass("vtb_disabled").attr({disabled:"disabled"}),
333
+ N+'">'+qa(N,N)+"</li>"}if(C=h.querySelector(".zwp-qualityMenu"))C.innerHTML=q,q=J.mQuery(C).find(".zwp-quality-item"),q.click(function(U){U.preventDefault();U.stopPropagation();U=this.getAttribute("data-stream");if(d.multiStreams.curStream!==U){var S=d.multiStreams.murls;if(Array.isArray(S))for(var T in S){var V=S[T];if(V.name===U){var W=V.url;break}}else W=S[U];d.__switchStream(W);d.multiStreams.curStream=U;W=J.mQuery(this);W.hasClass("active")||(W.siblings(".active").removeClass("active"),W.addClass("active"));
334
+ U=qa(U,U);d.toast("\u5df2\u7ecf\u4e3a\u60a8\u5207\u6362\u5230"+U+"\u753b\u8d28")}}),q.each(function(U,S){U=this.getAttribute("data-stream");if(d.multiStreams.curStream===U&&(U=J.mQuery(this),!U.hasClass("active")))return U.siblings(".active").removeClass("active"),U.addClass("active"),!1});h.style.display="block"}}}}.bind(c);c.createSubtitlesMenu=function(d,h){var q=this;q.controlbar&&(h=q.controlbar.querySelector(".zwp-subtitleMenu"),d=kb(d),h.innerHTML=d,delete h.bindSwitchEvent,O(h,"zwp-autosize"),
335
+ J.mQuery(h).find(".zwp-subtitles-item").click(function(C){C.preventDefault();C.stopPropagation();C=J.mQuery(this);C.hasClass("active")||(C.siblings().removeClass("active"),C.addClass("active"),C=this.getAttribute("data-id"),"function"===typeof q.switchSubtitleTrack&&q.switchSubtitleTrack(C))}),d=q.controlbar.querySelector(".zwp-subtitleButton"))&&(d.style.display="block")}.bind(c);c.updateSubtitleTrack=function(d){}.bind(c);c.resetSubtitleMenu=function(){if(this.controlbar){var d=this.controlbar.querySelector(".zwp-subtitleButton");
336
+ d&&(d.style.display="none")}}.bind(c);c.__getDanmuBarDock=function(){var d=this.progressBar.timeInfo.querySelector(".zwp_danmuBarDock");d||(d=document.createElement("DIV"),d.setAttribute("class","zwp_danmuBarDock"),this.progressBar.timeInfo.appendChild(d),Ba.addElement(d),d.addEventListener("resize",function(h){var q=this;q.resizeTimer||(q.resizeTimer=J.setTimeout(function(){console.log("danmuBarDock resize");350>d.clientWidth?O(d,"zwp-mini"):Q(d,"zwp-mini");delete q.resizeTimer},50))}.bind(this)));
337
+ return d}.bind(c);c.buildDanmuToolbar=function(d,h){var q=this,C;if(!q.danmuToolbar){d&&(C=document.querySelector("#"+d));if(!C){if(!q.overlay_layers)return;h=null;C=q.progressBar&&q.progressBar.timeInfo?q.__getDanmuBarDock():q.overlay_layers}d=lb();C.insertAdjacentHTML("beforeend",d);q.danmuToolbar=C.querySelector(".zwp_danmu-controlbar");h&&O(q.danmuToolbar,h);C.appendChild(q.danmuToolbar);(h=q.danmuToolbar.querySelector(".zwp_switch"))&&h.addEventListener("click",function(G){G.stopPropagation();
338
+ G=G.currentTarget;if(L(G,"zwp_switch")){Oa(G);var N=L(G,"switch_on");G=J.$$(this.danmuToolbar);if(N){var U=G.find("button.btn_submit");U.removeClass("vtb_disabled").removeAttr("disabled");this.setEnableDanmu(!0);N=G.find(".barrage_inp_text");N.removeAttr("readonly").removeAttr("disabled").removeClass("disabled");"on"!=N.attr("keydown")&&(N.keydown(function(S){13==S.which&&0<U.length&&U.trigger("click")}),N.attr("keydown","on"));G.find(".zwp-barrage_form").css("background-color","#28303db3").children("a.btn_bubble").toggleClass("disabled")}else G.find("button.btn_submit").addClass("vtb_disabled").attr({disabled:"disabled"}),
338
339
  this.setEnableDanmu(!1),G.find(".barrage_inp_text").attr("readonly","readonly").attr("disabled","disabled").addClass("disabled"),G.find(".zwp-barrage_form").css("background-color","#202020b3").children("a.btn_bubble").toggleClass("disabled")}}.bind(q));(h=q.danmuToolbar.querySelector(".barrage_login"))&&h.addEventListener("click",function(G){G.preventDefault();G.stopPropagation();alert("login")});(h=q.danmuToolbar.querySelector(".zwp_dmconfig"))&&h.addEventListener("click",function(G){G.preventDefault();
339
340
  G.stopPropagation();this.zwplayer=q;pb(G,this)});(h=q.danmuToolbar.querySelector(".btn_bubble"))&&h.addEventListener("click",function(G){G.preventDefault();G.stopPropagation();fb(this,G)});(h=q.danmuToolbar.querySelector(".btn_submit"))&&h.addEventListener("click",function(G){G.preventDefault();G.stopPropagation();a:{if(!this.inpbox){$inpbox=$$(this).parent().children("DIV.zwp-barrage_inp").children(".barrage_inp_text");if(!$inpbox)break a;this.inpbox=$inpbox}if(q){G=this.inpbox.val();if(""==G)break a;
340
341
  -1!=G.indexOf("&")&&(G=G.replace(/&/g,"&amp;"));-1!=G.indexOf("<")&&(G=G.replace(/</g,"&lt;"));-1!=G.indexOf(">")&&(G=G.replace(/>/g,"&gt;"));-1!=G.indexOf('"')&&(G=G.replace(/"/g,"&quot;"));-1!=G.indexOf("'")&&(G=G.replace(/'/g,"&#039;"));if(!q.sendDanmu(G))break a}this.inpbox.val("")}})}}.bind(c);c.reposDanmuToolbar=function(d){if(this.danmuToolbar&&this.progressBar&&this.progressBar.timeInfo){var h=this.__getDanmuBarDock(),q=this.danmuToolbar.parentNode;q&&(d?q!==h&&(q.removeChild(this.danmuToolbar),
341
342
  h.appendChild(this.danmuToolbar),this.oldDanmuParentNode=q):this.oldDanmuParentNode&&(h.removeChild(this.danmuToolbar),this.oldDanmuParentNode.appendChild(this.danmuToolbar),delete this.oldDanmuParentNode))}}.bind(c);c.sendDanmu=function(d){if("function"===typeof this._config.sendDanmu){var h="";this.danmuSetting.border&&(h+=',"border":"1"');this.danmuSetting.color&&(h+=',"color":"#'+this.danmuSetting.color+'"');this._config.sendDanmu('{"type":"danmu","text":"'+d+'"'+h+"}");return!0}alert("No danmu send function is setup");
342
343
  return!1}.bind(c);c.showContextMenu=function(d){var h=this,q=d.offsetX;d=d.offsetY;var C=h.playerContainer.getBoundingClientRect(),G=C.width;C=C.height;var N="left",U="top",S=q,T=d;q+180>G&&(N="right",S=G-q);d+148>C&&(U="bottom",T=C-d);if(h.contextMenu)h.contextMenu.style["left"===N?"right":"left"]=null,h.contextMenu.style["top"===U?"bottom":"top"]=null,h.contextMenu.style[N]=S+"px",h.contextMenu.style[U]=T+"px";else{q='<div class="zwp-popupmenu" style="'+N+": "+S+"px; "+U+":"+T+'px;"><a class="zwp-menuitem" data-action="document" href="https://www.zwplayer.com/docment" target="zwplayer-doc"><span class="zwp-menucaption">'+
343
344
  (qa("player-help","Help and document")+"</span></a>");q+='<a class="zwp-menuitem" data-action="version" href="https://www.zwplayer.com/version?v=3.1.2" title="Build: 20240507" target="zwplayer-version"><span class="zwp-menucaption">'+qa("version-update","Version update")+' (<span class="zwp-version">'+qa("current")+": v3.1.2</span>) </span></a>";q=q+'<span class="zwp-menuseperator" action="version"></span><a class="zwp-menuitem" data-action="about" href="https://www.zwplayer.com/about"><span class="zwp-menucaption">'+
344
- (qa("about","About")+" zwplayer</span></a>");h.playerContainer.insertAdjacentHTML("beforeEnd",q+"</div>");h.contextMenu=h.playerContainer.querySelector(".zwp-popupmenu");var V=function(W){W.stopPropagation();W.preventDefault();var g=this.getAttribute("data-action");this.getAttribute("target");var t=this.getAttribute("href");h.hideContextMenu();setTimeout(function(){"about"===g?I.open(t,"zwplayer-about"):"version"===g?I.open(t,"zwplayer-version"):"document"===g&&I.open(t,"zwplayer-doc")},10)};h.contextMenu.querySelectorAll("a.zwp-menuitem").forEach(function(W){W.addEventListener("click",
345
+ (qa("about","About")+" zwplayer</span></a>");h.playerContainer.insertAdjacentHTML("beforeEnd",q+"</div>");h.contextMenu=h.playerContainer.querySelector(".zwp-popupmenu");var V=function(W){W.stopPropagation();W.preventDefault();var g=this.getAttribute("data-action");this.getAttribute("target");var t=this.getAttribute("href");h.hideContextMenu();setTimeout(function(){"about"===g?J.open(t,"zwplayer-about"):"version"===g?J.open(t,"zwplayer-version"):"document"===g&&J.open(t,"zwplayer-doc")},10)};h.contextMenu.querySelectorAll("a.zwp-menuitem").forEach(function(W){W.addEventListener("click",
345
346
  V,!1)});document.addEventListener("click",h.hideContextMenu)}}.bind(c);c.hideContextMenu=function(){this.contextMenu&&(this.playerContainer.removeChild(this.contextMenu),delete this.contextMenu,document.removeEventListener("click",this.hideContextMenu))}.bind(c);c.toast=function(d,h,q,C){var G=this;h=h||2E3;G.toastTimerId&&(clearTimeout(G.toastTimerId),G.toastBox&&(G.overlay_layers.removeChild(G.toastBox),delete G.toastBox));if("object"===typeof d){if("icon"in d)var N=d.icon;d=d.text}var U=document.createElement("div"),
346
347
  S="",T="zwp-toast zwp-center";N&&(T+=" zwp-toast-icon",S='<i class="xicon xicon-'+N+'"></i>');q&&(S+='<a href="javascript:void(0)" class="zwp-toast-closebtn"><i class="xicon xicon-close"></i></a>',T+=" zwp-use-close");C&&(T+=" zwp-lite");S+='<span class="zwp-toast-text">'+d+"</span>";U.setAttribute("class",T);U.innerHTML=S;G.overlay_layers.appendChild(U);G.toastBox=U;var V=function(W){if(G.toastBox){var g=G.toastBox.querySelector(".zwp-toast-closebtn");g&&g.removeEventListener("click",V);G.overlay_layers.removeChild(G.toastBox);
347
- delete G.toastBox}G.toastTimerId&&(W&&"click"===W.type&&clearTimeout(G.toastTimerId),delete G.toastTimerId)};G.toastTimerId=I.setTimeout(V,h);q&&(q=U.querySelector(".zwp-toast-closebtn"))&&q.addEventListener("click",V)}.bind(c);c.mutedConfirmBox=function(){var d=this;d.popup_layers||(d.popup_layers=document.createElement("div"),d.popup_layers.setAttribute("class","zwp__popup_layers"),d.playerContainer.appendChild(d.popup_layers));var h=document.createElement("div");h.setAttribute("class","zwp-toast zwp-confirm zwp-center");
348
+ delete G.toastBox}G.toastTimerId&&(W&&"click"===W.type&&clearTimeout(G.toastTimerId),delete G.toastTimerId)};G.toastTimerId=J.setTimeout(V,h);q&&(q=U.querySelector(".zwp-toast-closebtn"))&&q.addEventListener("click",V)}.bind(c);c.mutedConfirmBox=function(){var d=this;d.popup_layers||(d.popup_layers=document.createElement("div"),d.popup_layers.setAttribute("class","zwp__popup_layers"),d.playerContainer.appendChild(d.popup_layers));var h=document.createElement("div");h.setAttribute("class","zwp-toast zwp-confirm zwp-center");
348
349
  h.innerHTML='<span class="zwp-toast-text">\u56e0<a href="#mutemore" class="mutemore">\u6d4f\u89c8\u5668\u9650\u5236</a>\uff0c\u9700\u8981\u70b9\u51fb<a href="#openaudio" class="openaudio">\u6253\u5f00\u58f0\u97f3</a><button class="closeBtn" title="\u5173\u95ed\u63d0\u793a"><i class="xicon xicon-close"></i></button></span>';d.popup_layers.appendChild(h);d.mutedTipBox=h;var q=h.querySelector(".closeBtn");q&&q.addEventListener("click",function(C){C.preventDefault();d.mutedTipBox&&(d.popup_layers.removeChild(d.mutedTipBox),
349
- d.popup_layers.style.display=null,delete d.mutedTipBox);I.allowAutoAudioPlay=!0});(q=h.querySelector(".openaudio"))&&q.addEventListener("click",function(C){C.preventDefault();C.stopPropagation();d.mutedTipBox&&(d.popup_layers.removeChild(d.mutedTipBox),d.popup_layers.style.display=null,delete d.mutedTipBox);d.setMuted(!1);I.allowAutoAudioPlay=!0});(q=h.querySelector(".mutemore"))&&q.addEventListener("click",function(C){C.preventDefault();C.stopPropagation();var G=h.querySelector(".moreInfoBox");G||
350
+ d.popup_layers.style.display=null,delete d.mutedTipBox);J.allowAutoAudioPlay=!0});(q=h.querySelector(".openaudio"))&&q.addEventListener("click",function(C){C.preventDefault();C.stopPropagation();d.mutedTipBox&&(d.popup_layers.removeChild(d.mutedTipBox),d.popup_layers.style.display=null,delete d.mutedTipBox);d.setMuted(!1);J.allowAutoAudioPlay=!0});(q=h.querySelector(".mutemore"))&&q.addEventListener("click",function(C){C.preventDefault();C.stopPropagation();var G=h.querySelector(".moreInfoBox");G||
350
351
  (h.insertAdjacentHTML("beforeend",'<div class="moreInfoBox"><div class="info-text">\u5f53\u4f60\u8bbf\u95ee\u672c\u7f51\u7ad9\u7684\u6b21\u6570\u8f83\u5c11\uff0c\u6216\u7ecf\u5e38\u9759\u97f3\u64ad\u653e\u65f6\uff0c\u6d4f\u89c8\u5668\u53ef\u80fd\u4f1a\u9650\u5236\u7f51\u7ad9\u97f3\u91cf\uff0c\u4f7f\u7f51\u7ad9\u65e0\u6cd5\u81ea\u52a8\u6267\u884c\u6709\u58f0\u64ad\u653e</div><div class="info-control"><button class="info-btn">\u6211\u77e5\u9053\u4e86</button></div></div>'),G=h.querySelector(".moreInfoBox"),
351
- G.querySelector(".info-btn").addEventListener("click",function(N){N.preventDefault();N.stopPropagation();G.style.display="none"}));G&&(G.style.display="block");I.allowAutoAudioPlay=!0});d.popup_layers.style.display="block"}.bind(c);"string"==typeof c._config.playerElm?(e=c._config.playerElm,"#"!=e.charAt(0)&&(e="#"+e),c.playerElm=document.querySelector(e)):Ua(c._config.playerElm)&&(c.playerElm=c._config.playerElm);c.playerElm?M(c.playerElm,"zwp-wrap")||(c.playerElmOldClass=c.playerElm.getAttribute("class"),
352
- P(c.playerElm,"zwp-wrap"),c.doRemovePlayerClass=!0):(e="","string"==typeof c._config.playerElm?(e=c._config.playerElm,"#"==e.charAt(0)&&(e=e.substr(1))):e="ZWP-"+(new Date).getTime(),c.playerElm=document.createElement("DIV"),c.playerElm.id=e,c.playerElm.style.position="absolute",c.playerElm.style.left=0,c.playerElm.style.top=0,c.playerElm.style.width="640px",c.playerElm.style.height="360px",document.body.appendChild(c.playerElm),c.playerElm.setAttribute("class","zwp-wrap"),c.doDeletePlayerElm=!0);
352
+ G.querySelector(".info-btn").addEventListener("click",function(N){N.preventDefault();N.stopPropagation();G.style.display="none"}));G&&(G.style.display="block");J.allowAutoAudioPlay=!0});d.popup_layers.style.display="block"}.bind(c);"string"==typeof c._config.playerElm?(e=c._config.playerElm,"#"!=e.charAt(0)&&(e="#"+e),c.playerElm=document.querySelector(e)):Ua(c._config.playerElm)&&(c.playerElm=c._config.playerElm);c.playerElm?L(c.playerElm,"zwp-wrap")||(c.playerElmOldClass=c.playerElm.getAttribute("class"),
353
+ O(c.playerElm,"zwp-wrap"),c.doRemovePlayerClass=!0):(e="","string"==typeof c._config.playerElm?(e=c._config.playerElm,"#"==e.charAt(0)&&(e=e.substr(1))):e="ZWP-"+(new Date).getTime(),c.playerElm=document.createElement("DIV"),c.playerElm.id=e,c.playerElm.style.position="absolute",c.playerElm.style.left=0,c.playerElm.style.top=0,c.playerElm.style.width="640px",c.playerElm.style.height="360px",document.body.appendChild(c.playerElm),c.playerElm.setAttribute("class","zwp-wrap"),c.doDeletePlayerElm=!0);
353
354
  c.playerContainer=document.createElement("DIV");c.playerContainer.setAttribute("class","zwp-container");c.playerElm.appendChild(c.playerContainer);"string"==typeof c._config.videoElm?(e=c._config.videoElm,"#"!=e.charAt(0)&&(e="#"+e),c.videoEl=document.querySelector(e)):Ua(c._config.videoElm)&&(c.videoEl=c._config.videoElm);if(!c.videoEl){var v=document.createElement("DIV");v.setAttribute("class","zwp-videoWrapper");c.playerContainer.appendChild(v);Ba.addElement(v);v.addEventListener("resize",function(d){this._config.video_rotated&&
354
355
  this.rotateVideo()}.bind(c));c.videoWrapper=v;c.videoEl=document.createElement("VIDEO");"string"==typeof c._config.videostyle&&c.videoEl.setAttribute("style",c._config.videostyle);"string"==typeof c._config.videoclass&&c.videoEl.setAttribute("class",c._config.videoclass);c._config.videostyle||c._config.videoclass||c.videoEl.setAttribute("style","width:100%;height:100%;");"string"==typeof c._config.videoElm&&(e=c._config.videoElm,"#"==e.charAt(0)&&(e=e.substr(1)),c.videoEl.id=e);c.videoEl.setAttribute("playsinline",
355
356
  "");c.videoEl.setAttribute("webkit-playsinline","");c.videoEl.setAttribute("autoplay","");v.appendChild(c.videoEl);c.videoRemoveWhenClose=!0}c.videoEl.volume=c._config.defVolume/100;c._config.poster&&c.videoEl.setAttribute("poster",c._config.poster);if(!c._config.disableOverlayLayer&&(e=document.createElement("div"),e.setAttribute("class","zwp__layers"),e.innerHTML='<div class="zwp__overlay zwp__layer zwp_loadingicon" style="width: 100%; height: 100%; display: none;"><div class="zwp__overlay-loading"><span class="zwp__overlay-loading-bg-img"><svg width="80px" height="80px" viewBox="0 0 38 38" xmlns="http://www.w3.org/2000/svg" stroke="#fff"><g fill="none" fill-rule="evenodd"><g transform="translate(1 1)" stroke-width="2"><circle stroke-opacity=".5" cx="18" cy="18" r="18"/><path d="M36 18c0-9.94-8.06-18-18-18"><animateTransform attributeName="transform" type="rotate" from="0 18 18" to="360 18 18" dur="1s" repeatCount="indefinite"/></path></g></g></svg></span></div></div><div class="zwp__overlay zwp__layer zwp__overlay-play" style="width: 100%; height: 100%; display: none;"><div class="zwp__overlay-button" role="button" tabindex="0" aria-label="play" aria-pressed="false" data-action="play"><svg class="icon" width="96px" height="96px" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg"><path fill="#c2c2c2" d="M512.61025 48.820024a463.790226 463.790226 0 1 0 463.790227 463.790226A463.790226 463.790226 0 0 0 512.61025 48.820024z m0 854.350417a390.560191 390.560191 0 1 1 390.560191-390.560191 390.560191 390.560191 0 0 1-390.560191 390.560191z m166.720382-414.970203l-120.341359-70.300834-127.908463-74.694636a22.945411 22.945411 0 0 0-32.465315 24.410011v288.526341a22.945411 22.945411 0 0 0 32.465315 24.410012l127.908463-74.694636 120.341359-70.056734a28.559714 28.559714 0 0 0 0-47.599524z" /></svg></div></div>',
356
- c.playerContainer.appendChild(e),c.overlay_layers=e,c.bigPlayOverlay=e.querySelector(".zwp__overlay-play"),c.bigPlayBtn=c.bigPlayOverlay.querySelector(".zwp__overlay-button"),c.loadingOverlay=e.querySelector(".zwp_loadingicon"),c._config.disablePlayBtn?P(c.bigPlayBtn,"zwp_disabled"):c.bigPlayBtn.addEventListener("click",function(d){d.preventDefault();d.stopPropagation();this.on_btnclick(d)}.bind(c)),c._config.enableDanmu&&(c.danmuPlayer=HUAYI.Danmu.create({playerId:e})),e.addEventListener("contextmenu",
357
- function(d){d.preventDefault();d.stopPropagation();Va||this.showContextMenu(d)}.bind(c)),e.addEventListener("click",function(d){var h=this;d=function(q){q=q.querySelector(".closeBtn");var C=document.createEvent("Event");C.initEvent("click",!0,!0);q.dispatchEvent(C)};h.infoViewer?d(h.infoViewer):h.colorSettingPanel?d(h.colorSettingPanel):h.contextMenu?h.hideContextMenu():h._config.disableClickPause||h._config.disablePlayBtn||h._config.isLive||(h.overlayLayerClickTimer&&(I.clearTimeout(h.overlayLayerClickTimer),
358
- delete h.overlayLayerClickTimer),h.videoEl&&(h.overlayLayerClickTimer=I.setTimeout(function(){h.videoEl.paused||h.videoEl.ended?(h.videoEl.play(),h.setplaystate(!0)):(h.videoEl.pause(),h.setplaystate(!1));delete h.overlayLayerClickTimer},300)))}.bind(c)),c._config.logo)){if("object"===typeof c._config.logo){if("string"===typeof c._config.logo.icon)var A=c._config.logo.icon}else"string"===typeof c._config.logo&&(A=c._config.logo);if(A){v='<div class="zwp-logo"';if("object"===typeof c._config.logo){var K=
359
- "";"dock"in c._config.logo?K+=("left"===c._config.logo.dock?"left":"right")+": "+(c._config.logo.x||"5%")+";":"x"in c._config.logo&&(K+="right: "+c._config.logo.x+";");"y"in c._config.logo&&(K+="top: "+c._config.logo.y+";");"width"in c._config.logo&&(K+="width: "+c._config.logo.width+";");if("opacity"in c._config.logo){var b=c._config.logo.opacity/100;1<b&&(b=1);K+="opacity: "+b+";"}K&&(v+=' style="'+K+'"')}e.insertAdjacentHTML("afterbegin",v+('><img src="'+A+'"></div>'))}}if(c._config.nativecontrols)c.videoEl.setAttribute("controls",
360
- "controls"),c.overlay_layers&&(c.overlay_layers.style.bottom="70px"),c.videoEl.addEventListener("fullscreenchange",function(d){return!1}.bind(c));else if(c._config.controlbar){var O=document.createElement("div");O.setAttribute("class","zwp-controlbar");c._config.isLive||P(O,"zwp-vodplayer");O.innerHTML=qb(c._config);c.playerContainer.appendChild(O);c.controlbar=O;if(c.controlbar){O.addEventListener("dblclick",function(d){d.stopPropagation()});A=O.querySelectorAll("button.zwpbtn");0<A.length&&(c.btnBindZwp=
361
- !0,A.forEach(function(d){d.addEventListener("click",c.on_btnclick)}));c._config.disablePlayBtn&&(A=O.querySelector(".zwp_playbtn"),P(A,"zwp_disabled"),A.setAttribute("disabled","disabled"));A=O.querySelectorAll(".zwp-speedMenu>li.zwp-speed-item");0<A.length&&A.forEach(function(d){d.addEventListener("click",c.on_speedItemclick)});var z=O.querySelector(".zwp-volume-docker");if(z){c.muteBtn=z.querySelector("button.zwp-muteBtn");c.volslider=z.querySelector(".zwp-volume-slider");c.voltotal=z.querySelector(".zwp-volume-total");
362
- c.volcurrent=c.volslider.querySelector(".zwp-volume-current");c.volthumb=c.volslider.querySelector(".zwp-volume-handle");var la=function(d){if(null!==d&&!isNaN(d)&&void 0!==d){d=Math.max(0,d);d=Math.min(d,1);if(0===d){Q(z,"zwp__mute");P(z,"zwp__unmute");var h=c.muteBtn;h.setAttribute("title","unmute");h.setAttribute("aria-label","unmute")}else Q(z,"zwp__unmute"),P(z,"zwp__mute"),h=c.muteBtn,h.setAttribute("title","muted"),h.setAttribute("aria-label","muted");h=c.volthumb;var q=c.volcurrent;d=100*
357
+ c.playerContainer.appendChild(e),c.overlay_layers=e,c.bigPlayOverlay=e.querySelector(".zwp__overlay-play"),c.bigPlayBtn=c.bigPlayOverlay.querySelector(".zwp__overlay-button"),c.loadingOverlay=e.querySelector(".zwp_loadingicon"),c._config.disablePlayBtn?O(c.bigPlayBtn,"zwp_disabled"):c.bigPlayBtn.addEventListener("click",function(d){d.preventDefault();d.stopPropagation();this.on_btnclick(d)}.bind(c)),c._config.enableDanmu&&(c.danmuPlayer=HUAYI.Danmu.create({playerId:e})),e.addEventListener("contextmenu",
358
+ function(d){d.preventDefault();d.stopPropagation();Va||this.showContextMenu(d)}.bind(c)),e.addEventListener("click",function(d){var h=this;d=function(q){q=q.querySelector(".closeBtn");var C=document.createEvent("Event");C.initEvent("click",!0,!0);q.dispatchEvent(C)};h.infoViewer?d(h.infoViewer):h.colorSettingPanel?d(h.colorSettingPanel):h.contextMenu?h.hideContextMenu():h._config.disableClickPause||h._config.disablePlayBtn||h._config.isLive||(h.overlayLayerClickTimer&&(J.clearTimeout(h.overlayLayerClickTimer),
359
+ delete h.overlayLayerClickTimer),h.videoEl&&(h.overlayLayerClickTimer=J.setTimeout(function(){h.videoEl.paused||h.videoEl.ended?(h.videoEl.play(),h.setplaystate(!0)):(h.videoEl.pause(),h.setplaystate(!1));delete h.overlayLayerClickTimer},300)))}.bind(c)),c._config.logo)){if("object"===typeof c._config.logo){if("string"===typeof c._config.logo.icon)var A=c._config.logo.icon}else"string"===typeof c._config.logo&&(A=c._config.logo);if(A){v='<div class="zwp-logo"';if("object"===typeof c._config.logo){var M=
360
+ "";"dock"in c._config.logo?M+=("left"===c._config.logo.dock?"left":"right")+": "+(c._config.logo.x||"5%")+";":"x"in c._config.logo&&(M+="right: "+c._config.logo.x+";");"y"in c._config.logo&&(M+="top: "+c._config.logo.y+";");"width"in c._config.logo&&(M+="width: "+c._config.logo.width+";");if("opacity"in c._config.logo){var b=c._config.logo.opacity/100;1<b&&(b=1);M+="opacity: "+b+";"}M&&(v+=' style="'+M+'"')}e.insertAdjacentHTML("afterbegin",v+('><img src="'+A+'"></div>'))}}if(c._config.nativecontrols)c.videoEl.setAttribute("controls",
361
+ "controls"),c.overlay_layers&&(c.overlay_layers.style.bottom="70px"),c.videoEl.addEventListener("fullscreenchange",function(d){return!1}.bind(c));else if(c._config.controlbar){var P=document.createElement("div");P.setAttribute("class","zwp-controlbar");c._config.isLive||O(P,"zwp-vodplayer");P.innerHTML=qb(c._config);c.playerContainer.appendChild(P);c.controlbar=P;if(c.controlbar){P.addEventListener("dblclick",function(d){d.stopPropagation()});A=P.querySelectorAll("button.zwpbtn");0<A.length&&(c.btnBindZwp=
362
+ !0,A.forEach(function(d){d.addEventListener("click",c.on_btnclick)}));c._config.disablePlayBtn&&(A=P.querySelector(".zwp_playbtn"),O(A,"zwp_disabled"),A.setAttribute("disabled","disabled"));A=P.querySelectorAll(".zwp-speedMenu>li.zwp-speed-item");0<A.length&&A.forEach(function(d){d.addEventListener("click",c.on_speedItemclick)});var z=P.querySelector(".zwp-volume-docker");if(z){c.muteBtn=z.querySelector("button.zwp-muteBtn");c.volslider=z.querySelector(".zwp-volume-slider");c.voltotal=z.querySelector(".zwp-volume-total");
363
+ c.volcurrent=c.volslider.querySelector(".zwp-volume-current");c.volthumb=c.volslider.querySelector(".zwp-volume-handle");var la=function(d){if(null!==d&&!isNaN(d)&&void 0!==d){d=Math.max(0,d);d=Math.min(d,1);if(0===d){Q(z,"zwp__mute");O(z,"zwp__unmute");var h=c.muteBtn;h.setAttribute("title","unmute");h.setAttribute("aria-label","unmute")}else Q(z,"zwp__unmute"),O(z,"zwp__mute"),h=c.muteBtn,h.setAttribute("title","muted"),h.setAttribute("aria-label","muted");h=c.volthumb;var q=c.volcurrent;d=100*
363
364
  d+"%";var C=getComputedStyle(h);q.style.bottom=0;q.style.height=d;h.style.bottom=d;h.style.marginBottom=-parseFloat(C.height)/2+"px"}},H=function(d){var h=B(c.voltotal),q=getComputedStyle(c.voltotal),C=!0;"touchmove"==d.type&&(d.changedTouches&&(C=d.changedTouches[0],d.pageX=C.pageX,d.pageY=C.pageY),C=!1);q=parseFloat(q.height);q=(q-(d.pageY-h.top))/q;0!==h.top&&0!==h.left&&(q=Math.max(0,q),q=Math.min(q,1),la(q),c.setMuted(0===q),c.setVolume(q),C&&d.preventDefault(),d.stopPropagation())};c.positionVolumeThumb=
364
365
  la;c.on_volthumb_mousemove=function(d){var h=d.target;n&&(h===c.volslider||h.closest(".zwp-volume-slider"))&&H(d)}.bind(c);c.on_volthumb_mouseup=function(d){n&&("onpointerout"in document?(document.removeEventListener("pointermove",c.on_volthumb_mousemove),document.removeEventListener("pointerup",c.on_volthumb_mouseup),document.removeEventListener("touchmove",c.on_volthumb_mousemove),document.removeEventListener("touchend",c.on_volthumb_mouseup)):(document.removeEventListener("mousemove",c.on_volthumb_mousemove),
365
366
  document.removeEventListener("mouseup",c.on_volthumb_mouseup)),n=!1);m||(c.volslider.style.display="none");console.log("volthumb_mouseup:"+d.type)}.bind(c);c.on_volthumb_mousedown=function(d){H(d);"onpointerout"in document?(document.addEventListener("pointermove",c.on_volthumb_mousemove),document.addEventListener("pointerup",c.on_volthumb_mouseup),document.addEventListener("touchmove",c.on_volthumb_mousemove),document.addEventListener("touchend",c.on_volthumb_mouseup)):(document.addEventListener("mousemove",
366
367
  c.on_volthumb_mousemove),document.addEventListener("mouseup",c.on_volthumb_mouseup));n=!0;d.preventDefault();d.stopPropagation()}.bind(c);var ja=c.volslider;z.addEventListener("mouseenter",function(d){d.target===z&&(ja.style.display="block",m=!0,d.preventDefault(),d.stopPropagation())});z.addEventListener("focusin",function(){ja.style.display="block";m=!0});z.addEventListener("focusout",function(d){if(!d.relatedTarget||d.relatedTarget&&!d.relatedTarget.matches(".zwp-volume-slider"))ja.style.display=
367
368
  "none"});z.addEventListener("mouseleave",function(){m=!1;n||(ja.style.display="none")});z.addEventListener("focusout",function(){m=!1});z.addEventListener("keydown",function(d){var h=d.which||d.keyCode||0;d.preventDefault();d.stopPropagation();32==h&&(c.videoEl.muted?c.setMuted(!1):c.setMuted(!0))});ja.addEventListener("dragstart",function(){return!1});ja.addEventListener("mouseover",function(){m=!0});ja.addEventListener("focusin",function(){ja.style.display="block";m=!0});ja.addEventListener("focusout",
368
- function(){m=!1;n||(ja.style.display="none")});ja.addEventListener("mousedown",c.on_volthumb_mousedown)}if(A=O.querySelector(".zwp-optionPanel"))A=A.querySelectorAll(".action-item"),0<A.length&&A.forEach(function(d){d.addEventListener("click",c.on_optionItemclick)})}}c._config.autoSmallWindow&&!c.windowScrollHandler&&(c.windowScrollHandler=function(d){if(!this.isFullscr&&!this.isFullscrWin&&this.videoEl&&this.playerElm&&this.isPlaying&&!this.isInPicInPic)if(d=u(this.playerElm),(document.documentElement.scrollTop||
369
- document.body.scrollTop)>=d+this.playerElm.offsetHeight-100){if(!this.smallWindowMode){var h=this.playerContainer;gb(h,function(){Q(h,"zwp-smallwindow");h.style.left=null;h.style.top=null;h.style.width=null;h.style.height=null});P(h,"zwp-smallwindow");this.smallWindowMode=!0}}else this.smallWindowMode&&(h=this.playerContainer,Q(h,"zwp-smallwindow"),h.style.left=null,h.style.top=null,h.style.width=null,h.style.height=null,delete this.smallWindowMode)}.bind(c),I.addEventListener("scroll",c.windowScrollHandler));
370
- c._config.clientip||(c._config.clientip="");c.videoEl&&(c._config.muted?c.setMuted(!0):"undefined"===typeof I.allowAutoAudioPlay?(c.setMuted(!0),bb(function(d){d?c.setMuted(!1):c.mutedConfirmBox();I.allowAutoAudioPlay=d})):I.allowAutoAudioPlay||(c.setMuted(!0),c.mutedConfirmBox()),(c._config.snapshotButton||c._config.allowSnapshot)&&c.videoEl.setAttribute("crossorigin","Anonymous"));A=function(d){var h=this;if(h.controlbar)if(h.isControlbarhidden){h.controlbar.style.display="flex";Q(h.playerElm,"hide-cursor");
371
- d=d||I.event;if(d.srcElement!=h.controlbar&&h.overlay_layers){var q=h.overlay_layers.offsetHeight,C=0;"undefined"!==typeof d.offsetY?C=q-d.offsetY:"undefined"!==typeof d.layerY&&(C=q-d.layerY);if(80<C)return}Pa(h.controlbar,500,function(G){G&&h.startHideControlbar(h)});h.isControlbarhidden=!1}else h.startHideControlbar(h)}.bind(c);c.playerElm.addEventListener("mousemove",A);c.playerElm.addEventListener("touchmove",A);c.playerElm.addEventListener("dblclick",function(d){this.overlayLayerClickTimer&&
372
- (I.clearTimeout(this.overlayLayerClickTimer),delete this.overlayLayerClickTimer);if(this.controlbar&&(d={},d.currentTarget=this.controlbar.querySelector(".zwp-fullscrBtn"),d.currentTarget))this.on_btnclick(d)}.bind(c));"undefined"==typeof c._config.autoplay&&(c._config.autoplay=!0);c._config.url&&c._config.autoplay&&c.play(c._config.url);"function"==typeof c._config.onready&&c._config.onready.call(c);c._config.chapters&&(c.chapters=c._config.chapters);c._config.lostFocusPause&&"undefined"!==typeof document.visibilityState&&
373
- document.addEventListener("visibilitychange",function(){this._config.isLive||this.isInPicInPic||("visible"===document.visibilityState?this.focusPaused&&this.videoEl.paused&&!this.videoEl.ended&&(this.videoEl.play(),this.setplaystate(!0),delete this.focusPaused):this.focusPaused||this.videoEl.paused||this.videoEl.ended||(this.videoEl.pause(),this.setplaystate(!1),this.focusPaused=!0))}.bind(c))},aa=async function(e){if("undefined"==typeof I.RTCPeerConnection)return alert("This browser does not support the stream.\r\nPlease play this stream in chrome!"),
374
- !1;var n=J(e.murl);if(!n)return e.toast("Invalid url"),!1;e.peer_conn=new RTCPeerConnection("function"==typeof RTCPeerConnection.prototype.addTransceiver?{iceServers:[],iceTransportPolicy:"all",bundlePolicy:"max-bundle",rtcpMuxPolicy:"require",sdpSemantics:"unified-plan"}:null);e.mediaStream=new MediaStream;e.peer_conn.ontrack=function(c){if(!this.hasTracks){this.setRtcstream(e.mediaStream);var l=y();console.log("start usetime:"+(F-l))}this.hasTracks++;this.mediaStream.addTrack(c.track);e.baseTrack&&
375
- "video"!=c.track.kind||(e.baseTrack=c.track);e.rtcstatsTimerId||(e.packetsReceived=0,e.framesDecoded=0,e.emptyCount=0,e.rtcstatsTimerId=I.setInterval(function(){e.baseTrack&&e.peer_conn.getStats(e.baseTrack).then(v=>{v.forEach(A=>{"inbound-rtp"==A.type&&"video"==A.kind&&(A.framesDecoded!=e.framesDecoded?(e.framesDecoded=A.framesDecoded,e.packetsReceived=A.packetsReceived,e.emptyCount=0):0<e.framesDecoded&&(e.emptyCount++,3<e.emptyCount&&(console.warn("Rtp Data break for "+e.emptyCount),e.closecall(e),
369
+ function(){m=!1;n||(ja.style.display="none")});ja.addEventListener("mousedown",c.on_volthumb_mousedown)}if(A=P.querySelector(".zwp-optionPanel"))A=A.querySelectorAll(".action-item"),0<A.length&&A.forEach(function(d){d.addEventListener("click",c.on_optionItemclick)})}}c._config.autoSmallWindow&&!c.windowScrollHandler&&(c.windowScrollHandler=function(d){if(!this.isFullscr&&!this.isFullscrWin&&this.videoEl&&this.playerElm&&this.isPlaying&&!this.isInPicInPic)if(d=u(this.playerElm),(document.documentElement.scrollTop||
370
+ document.body.scrollTop)>=d+this.playerElm.offsetHeight-100){if(!this.smallWindowMode){var h=this.playerContainer;gb(h,function(){Q(h,"zwp-smallwindow");h.style.left=null;h.style.top=null;h.style.width=null;h.style.height=null});O(h,"zwp-smallwindow");this.smallWindowMode=!0}}else this.smallWindowMode&&(h=this.playerContainer,Q(h,"zwp-smallwindow"),h.style.left=null,h.style.top=null,h.style.width=null,h.style.height=null,delete this.smallWindowMode)}.bind(c),J.addEventListener("scroll",c.windowScrollHandler));
371
+ c._config.clientip||(c._config.clientip="");c.videoEl&&(c._config.muted?c.setMuted(!0):"undefined"===typeof J.allowAutoAudioPlay?(c.setMuted(!0),bb(function(d){d?c.setMuted(!1):c.mutedConfirmBox();J.allowAutoAudioPlay=d})):J.allowAutoAudioPlay||(c.setMuted(!0),c.mutedConfirmBox()),(c._config.snapshotButton||c._config.allowSnapshot)&&c.videoEl.setAttribute("crossorigin","Anonymous"));A=function(d){var h=this;if(h.controlbar)if(h.isControlbarhidden){h.controlbar.style.display="flex";Q(h.playerElm,"hide-cursor");
372
+ d=d||J.event;if(d.srcElement!=h.controlbar&&h.overlay_layers){var q=h.overlay_layers.offsetHeight,C=0;"undefined"!==typeof d.offsetY?C=q-d.offsetY:"undefined"!==typeof d.layerY&&(C=q-d.layerY);if(80<C)return}Pa(h.controlbar,500,function(G){G&&h.startHideControlbar(h)});h.isControlbarhidden=!1}else h.startHideControlbar(h)}.bind(c);c.playerElm.addEventListener("mousemove",A);c.playerElm.addEventListener("touchmove",A);c.playerElm.addEventListener("dblclick",function(d){this.overlayLayerClickTimer&&
373
+ (J.clearTimeout(this.overlayLayerClickTimer),delete this.overlayLayerClickTimer);if(this.controlbar&&(d={},d.currentTarget=this.controlbar.querySelector(".zwp-fullscrBtn"),d.currentTarget))this.on_btnclick(d)}.bind(c));"undefined"==typeof c._config.autoplay&&(c._config.autoplay=!0);c._config.url&&c._config.autoplay&&c.play(c._config.url);"function"==typeof c._config.onready&&c._config.onready.call(c);c._config.chapters&&(c.chapters=c._config.chapters);c._config.lostFocusPause&&"undefined"!==typeof document.visibilityState&&
374
+ document.addEventListener("visibilitychange",function(){this._config.isLive||this.isInPicInPic||("visible"===document.visibilityState?this.focusPaused&&this.videoEl.paused&&!this.videoEl.ended&&(this.videoEl.play(),this.setplaystate(!0),delete this.focusPaused):this.focusPaused||this.videoEl.paused||this.videoEl.ended||(this.videoEl.pause(),this.setplaystate(!1),this.focusPaused=!0))}.bind(c))},aa=async function(e){if("undefined"==typeof J.RTCPeerConnection)return alert("This browser does not support the stream.\r\nPlease play this stream in chrome!"),
375
+ !1;var n=I(e.murl);if(!n)return e.toast("Invalid url"),!1;e.peer_conn=new RTCPeerConnection("function"==typeof RTCPeerConnection.prototype.addTransceiver?{iceServers:[],iceTransportPolicy:"all",bundlePolicy:"max-bundle",rtcpMuxPolicy:"require",sdpSemantics:"unified-plan"}:null);e.mediaStream=new MediaStream;e.peer_conn.ontrack=function(c){if(!this.hasTracks){this.setRtcstream(e.mediaStream);var l=y();console.log("start usetime:"+(F-l))}this.hasTracks++;this.mediaStream.addTrack(c.track);e.baseTrack&&
376
+ "video"!=c.track.kind||(e.baseTrack=c.track);e.rtcstatsTimerId||(e.packetsReceived=0,e.framesDecoded=0,e.emptyCount=0,e.rtcstatsTimerId=J.setInterval(function(){e.baseTrack&&e.peer_conn.getStats(e.baseTrack).then(v=>{v.forEach(A=>{"inbound-rtp"==A.type&&"video"==A.kind&&(A.framesDecoded!=e.framesDecoded?(e.framesDecoded=A.framesDecoded,e.packetsReceived=A.packetsReceived,e.emptyCount=0):0<e.framesDecoded&&(e.emptyCount++,3<e.emptyCount&&(console.warn("Rtp Data break for "+e.emptyCount),e.closecall(e),
376
377
  aa(e))))})})},1E3))}.bind(e);e.hasTracks=0;if("function"==typeof e.peer_conn.addTransceiver){("undefined"===typeof e._config.hasAudio||e._config.hasAudio)&&await e.peer_conn.addTransceiver("audio",{direction:"recvonly"});await e.peer_conn.addTransceiver("video",{direction:"recvonly"});var m=await e.peer_conn.createOffer()}else m=await e.peer_conn.createOffer({offerToReceiveAudio:"undefined"===typeof e._config.hasAudio||e._config.hasAudio,offerToReceiveVideo:!0});await e.peer_conn.setLocalDescription(m);
377
- (new Promise(function(c,l){var v={api:n.apiUrl,rtcstream:n.streamUrl,clientip:null,sdp:m.sdp};"webrtc"===n.urlObject.schema&&(delete v.rtcstream,v.streamurl=n.streamUrl);console.log("Generated offer: ",v);w(n.apiUrl,JSON.stringify(v),function(A){console.log("Got answer: ",A);A.code?l(A):c(A)},function(A){"REQUEST:error"==A&&(e.tryStartPlayTimer=I.setTimeout(function(){delete e.tryStartPlayTimer;e.closecall(e);aa(e)},1E3));l(A)})})).then(c=>{e.peer_conn.setRemoteDescription(new RTCSessionDescription({type:"answer",
378
- sdp:c.sdp}))}).catch(c=>{console.log(c);e.peer_conn.close();e.peer_conn=null});e.closecall=function(c){c.rtcstatsTimerId&&(I.clearInterval(c.rtcstatsTimerId),delete c.rtcstatsTimerId);c.tryStartPlayTimer&&(I.clearTimeout(c.tryStartPlayTimer),delete c.tryStartPlayTimer);"undefined"!=typeof c.baseTrack&&delete c.baseTrack;c.peer_conn&&(c.videoEl&&(c.videoEl.srcObject=null),c.mediaStream&&delete c.mediaStream,c.peer_conn.close(),c.peer_conn=null)};return!0},fa=async function(e){var n=e._config.xmc_url||
379
- I.xmc_url;if(!n)return e.toast("The rtsp protocol is not supported without setting XMC."),!1;n+="play";e.wsclient&&(e.wsclient.close(),delete e.wsclient);n=n.replace("http","ws");var m=new WebSocket(n);m.onopen=function(){var c="undefined"===typeof e._config.rtspOverTcp?1:e._config.rtspOverTcp,l="boolean"===typeof e._config.rtsp_bypass?e._config.rtsp_bypass:0,v="undefined"===typeof e._config.use_audio?0:e._config.use_audio,A="MediaSource"in I&&I.MediaSource.isTypeSupported("video/mp4;codecs=hvc1.1.1.L93.B0")?
380
- 1:0;c=JSON.stringify({msgtype:"playurl",data:{sourceurl:e.murl,rtsp_over_tcp:c,has_audio:v,has_hevc:A,rtsp_bypass:l}});m.send(c)};m.onmessage=function(c){console.log(c.data);c=JSON.parse(c.data);if("object"==typeof c&&"onresult"===c.type&&"playurl"===c.event&&"object"===typeof c.streaminfo)if(e.closecall2=function(v){v.waitSignTimer&&(I.clearTimeout(v.waitSignTimer),delete v.waitSignTimer);v.wsclient&&(v.wsclient.close(),v.wsclient=null,delete v.wsclient)},c.snapshot&&e.videoEl&&e.videoEl.setAttribute("poster",
378
+ (new Promise(function(c,l){var v={api:n.apiUrl,rtcstream:n.streamUrl,clientip:null,sdp:m.sdp};"webrtc"===n.urlObject.schema&&(delete v.rtcstream,v.streamurl=n.streamUrl);console.log("Generated offer: ",v);w(n.apiUrl,JSON.stringify(v),function(A){console.log("Got answer: ",A);A.code?l(A):c(A)},function(A){"REQUEST:error"==A&&(e.tryStartPlayTimer=J.setTimeout(function(){delete e.tryStartPlayTimer;e.closecall(e);aa(e)},1E3));l(A)})})).then(c=>{e.peer_conn.setRemoteDescription(new RTCSessionDescription({type:"answer",
379
+ sdp:c.sdp}))}).catch(c=>{console.log(c);e.peer_conn.close();e.peer_conn=null});e.closecall=function(c){c.rtcstatsTimerId&&(J.clearInterval(c.rtcstatsTimerId),delete c.rtcstatsTimerId);c.tryStartPlayTimer&&(J.clearTimeout(c.tryStartPlayTimer),delete c.tryStartPlayTimer);"undefined"!=typeof c.baseTrack&&delete c.baseTrack;c.peer_conn&&(c.videoEl&&(c.videoEl.srcObject=null),c.mediaStream&&delete c.mediaStream,c.peer_conn.close(),c.peer_conn=null)};return!0},fa=async function(e){var n=e._config.xmc_url||
380
+ J.xmc_url;if(!n)return e.toast("The rtsp protocol is not supported without setting XMC."),!1;n+="play";e.wsclient&&(e.wsclient.close(),delete e.wsclient);n=n.replace("http","ws");var m=new WebSocket(n);m.onopen=function(){var c="undefined"===typeof e._config.rtspOverTcp?1:e._config.rtspOverTcp,l="boolean"===typeof e._config.rtsp_bypass?e._config.rtsp_bypass:0,v="undefined"===typeof e._config.use_audio?0:e._config.use_audio,A="MediaSource"in J&&J.MediaSource.isTypeSupported("video/mp4;codecs=hvc1.1.1.L93.B0")?
381
+ 1:0;c=JSON.stringify({msgtype:"playurl",data:{sourceurl:e.murl,rtsp_over_tcp:c,has_audio:v,has_hevc:A,rtsp_bypass:l}});m.send(c)};m.onmessage=function(c){console.log(c.data);c=JSON.parse(c.data);if("object"==typeof c&&"onresult"===c.type&&"playurl"===c.event&&"object"===typeof c.streaminfo)if(e.closecall2=function(v){v.waitSignTimer&&(J.clearTimeout(v.waitSignTimer),delete v.waitSignTimer);v.wsclient&&(v.wsclient.close(),v.wsclient=null,delete v.wsclient)},c.snapshot&&e.videoEl&&e.videoEl.setAttribute("poster",
381
382
  c.snapshot),e._config.useFlv||"string"!==typeof c.streaminfo.rtc_playurl)"string"===typeof c.streaminfo.http_playurl?(l=c.streaminfo.http_playurl+c.streaminfo.stream+".flv",e.murl=l,Y(e)):e.closecall2(e);else{var l=c.streaminfo.rtc_playurl+c.streaminfo.stream+".rtc";c.first?e.waitSignTimer=setTimeout(function(){e.murl=l;aa(e);delete e.waitSignTimer},1E3):(e.murl=l,aa(e))}};m.onclose=function(){e.wsclient&&delete e.wsclient};m.onerror=function(){};e.wsclient=m;return!0},ma=function(e){Ja("flv_js",
382
- Ia+"flv.min.js",function(n){console.log("js:"+n+" is load!");var m=I.flvjs;if(!m.isSupported())return!1;var c={type:"flv",isLive:!0,url:e.murl};var l={enableWorker:!1,enableStashBuffer:!1,stashInitialSize:0,lazyLoad:!1,autoCleanupSourceBuffer:!0,lazyLoadMaxDuration:0,isLive:!0};e.openFlv=function(){var v=m.createPlayer(c,l);v.on(m.Events.METADATA_ARRIVED,function(A){e.loadingOverlay&&(e.loadingOverlay.style.display="none");"object"==typeof A&&console.log("flvplayer:"+A.type)});v.on(m.Events.ERROR,
383
+ Ia+"flv.min.js",function(n){console.log("js:"+n+" is load!");var m=J.flvjs;if(!m.isSupported())return!1;var c={type:"flv",isLive:!0,url:e.murl};var l={enableWorker:!1,enableStashBuffer:!1,stashInitialSize:0,lazyLoad:!1,autoCleanupSourceBuffer:!0,lazyLoadMaxDuration:0,isLive:!0};e.openFlv=function(){var v=m.createPlayer(c,l);v.on(m.Events.METADATA_ARRIVED,function(A){e.loadingOverlay&&(e.loadingOverlay.style.display="none");"object"==typeof A&&console.log("flvplayer:"+A.type)});v.on(m.Events.ERROR,
383
384
  function(A){"object"==typeof A?console.log("flvplayer:"+A.type):console.log("flvplayer:"+A)});v.attachMediaElement(e.videoEl);e.videoEl.playbackRate=1;e.onFlvStaticInfo=function(A){this.videoEl.paused||(this.lastDecodedFrames?this.lastDecodedFrames!=A.decodedFrames?this.lastDecodedFrames=A.decodedFrames:(this.lastDecodedFrames=0,this.flvPlayer&&(this.closecall(this),this.openFlv(),this.setplaystate(!0))):this.lastDecodedFrames=A.decodedFrames)}.bind(e);e.onFlvError=function(A){"NetworkError"!==A||
384
- e.reconnectTimer||(e.reconnectTimer=I.setTimeout(function(){e.flvPlayer&&(e.closecall(e),e.openFlv(),e.setplaystate(!0));delete e.reconnectTimer},1E3))}.bind(e);e.onMediainfoCb=function(A){A&&this.setMediainfo("flvjs",A)}.bind(e);v.on(m.Events.ERROR,e.onFlvError);v.on(m.Events.STATISTICS_INFO,e.onFlvStaticInfo);v.on(m.Events.MEDIA_INFO,e.onMediainfoCb);e.delayCheckTimerId=I.setInterval(function(){if(this.flvPlayer&&!this.videoEl.paused){var A=this.flvPlayer;if(A.buffered.length){let K=A.buffered.end(0)-
385
- A.currentTime;6<=K?A.currentTime=A.buffered.end(0)-.2:3<K&&(e.videoEl.playbackRate=1.5,e.fastForwardTimerId=setTimeout(function(){e.videoEl.playbackRate=1;delete e.fastForwardTimerId},2E3*K))}}}.bind(e),2E3);v.load();v.play();e.flvPlayer=v;e.closecall=function(A){if(A.flvPlayer){var K=A.flvPlayer;K.off(m.Events.ERROR,A.onFlvError);K.off(m.Events.STATISTICS_INFO,A.onFlvStaticInfo);K.off(m.Events.MEDIA_INFO,A.onMediainfoCb);delete A.onFlvError;delete A.onFlvStaticInfo;delete A.onMediainfoCb;A.delayCheckTimerId&&
386
- (I.clearInterval(A.delayCheckTimerId),delete A.delayCheckTimerId);A.fastForwardTimerId&&(I.clearTimeout(A.fastForwardTimerId),delete A.fastForwardTimerId);A.reconnectTimer&&(I.clearTimeout(A.reconnectTimer),delete A.reconnectTimer);K.pause();K.unload();K.detachMediaElement();K.destroy();delete A.flvPlayer}}};e.openFlv();e.setplaystate(!0)});return!0},Y=function(e){Ja("mpeg_js",Ia+"mpeg.min.js?v=2",function(n){console.log("js:"+n+" is load!");n=mpegts.getFeatureList();if(!mpegts.isSupported()||!n.mseLivePlayback)return!1;
385
+ e.reconnectTimer||(e.reconnectTimer=J.setTimeout(function(){e.flvPlayer&&(e.closecall(e),e.openFlv(),e.setplaystate(!0));delete e.reconnectTimer},1E3))}.bind(e);e.onMediainfoCb=function(A){A&&this.setMediainfo("flvjs",A)}.bind(e);v.on(m.Events.ERROR,e.onFlvError);v.on(m.Events.STATISTICS_INFO,e.onFlvStaticInfo);v.on(m.Events.MEDIA_INFO,e.onMediainfoCb);e.delayCheckTimerId=J.setInterval(function(){if(this.flvPlayer&&!this.videoEl.paused){var A=this.flvPlayer;if(A.buffered.length){let M=A.buffered.end(0)-
386
+ A.currentTime;6<=M?A.currentTime=A.buffered.end(0)-.2:3<M&&(e.videoEl.playbackRate=1.5,e.fastForwardTimerId=setTimeout(function(){e.videoEl.playbackRate=1;delete e.fastForwardTimerId},2E3*M))}}}.bind(e),2E3);v.load();v.play();e.flvPlayer=v;e.closecall=function(A){if(A.flvPlayer){var M=A.flvPlayer;M.off(m.Events.ERROR,A.onFlvError);M.off(m.Events.STATISTICS_INFO,A.onFlvStaticInfo);M.off(m.Events.MEDIA_INFO,A.onMediainfoCb);delete A.onFlvError;delete A.onFlvStaticInfo;delete A.onMediainfoCb;A.delayCheckTimerId&&
387
+ (J.clearInterval(A.delayCheckTimerId),delete A.delayCheckTimerId);A.fastForwardTimerId&&(J.clearTimeout(A.fastForwardTimerId),delete A.fastForwardTimerId);A.reconnectTimer&&(J.clearTimeout(A.reconnectTimer),delete A.reconnectTimer);M.pause();M.unload();M.detachMediaElement();M.destroy();delete A.flvPlayer}}};e.openFlv();e.setplaystate(!0)});return!0},Y=function(e){Ja("mpeg_js",Ia+"mpeg.min.js?v=2",function(n){console.log("js:"+n+" is load!");n=mpegts.getFeatureList();if(!mpegts.isSupported()||!n.mseLivePlayback)return!1;
387
388
  e.openMpegts=function(){var m=e.videoEl,c=void 0,l=void 0;"boolean"===typeof e._config.hasAudio&&(c=e._config.hasAudio);"boolean"===typeof e._config.hasVideo&&(l=e._config.hasVideo);c=mpegts.createPlayer({type:"mse",isLive:!0,hasAudio:c,hasVideo:l,url:e.murl},{autoCleanupSourceBuffer:!0,stashInitialSize:128,autoCleanupMaxBackwardDuration:20,autoCleanupMinBackwardDuration:10,enableWorker:!0,enableStashBuffer:!1});e.onErrorCb=function(v){var A=this;v!==mpegts.ErrorTypes.NETWORK_ERROR||A.reconnectTimer||
388
- (A.reconnectTimer=I.setTimeout(function(){A.mpegtsPlayer&&(A.closecall(A),A.openMpegts());delete A.reconnectTimer},1E3))}.bind(e);e.onEventCb=function(v){console.log(v)}.bind(e);e.onMetadataCb=function(v){console.log(v)}.bind(e);e.onMediaInfoCb=function(v){v&&this.setMediainfo("mpegts",v)}.bind(e);e.onStatisCb=function(v){this.videoEl.paused||(this.lastDecodedFrames?this.lastDecodedFrames!=v.decodedFrames?(this.lastDecodedFrames=v.decodedFrames,delete this.waitDecodedFrames):("undefined"===typeof this.waitDecodedFrames?
389
- this.waitDecodedFrames=0:this.waitDecodedFrames++,1<this.waitDecodedFrames&&(this.lastDecodedFrames=0,delete this.waitDecodedFrames,this.mpegtsPlayer&&(this.closecall(this),this.openMpegts()))):this.lastDecodedFrames=v.decodedFrames)}.bind(e);e.closecall=function(v){v.checkDelayTimerId&&(I.clearInterval(v.checkDelayTimerId),delete v.checkDelayTimerId);v.reconnectTimer||(I.clearTimeout(v.reconnectTimer),delete v.reconnectTimer);v.fastForwardTimerId&&(I.clearTimeout(v.fastForwardTimerId),delete v.fastForwardTimerId);
390
- if(v.mpegtsPlayer){var A=v.mpegtsPlayer;A.pause();A.off(mpegts.Events.ERROR,v.onErrorCb);A.off(mpegts.Events.MEDIA_INFO,v.onMediaInfoCb);A.off(mpegts.Events.METADATA_ARRIVED,v.onMetadataCb);A.off(mpegts.Events.STATISTICS_INFO,v.onStatisCb);A.unload();A.detachMediaElement();A.destroy();delete v.onErrorCb;delete v.onMediaInfoCb;delete v.onMetadataCb;delete v.onStatisCb;delete v.onEventCb;delete v.mpegtsPlayer}};e.checkDelayTimerId=I.setInterval(function(){var v=this;if(v.mpegtsPlayer&&!v.videoEl.paused&&
389
+ (A.reconnectTimer=J.setTimeout(function(){A.mpegtsPlayer&&(A.closecall(A),A.openMpegts());delete A.reconnectTimer},1E3))}.bind(e);e.onEventCb=function(v){console.log(v)}.bind(e);e.onMetadataCb=function(v){console.log(v)}.bind(e);e.onMediaInfoCb=function(v){v&&this.setMediainfo("mpegts",v)}.bind(e);e.onStatisCb=function(v){this.videoEl.paused||(this.lastDecodedFrames?this.lastDecodedFrames!=v.decodedFrames?(this.lastDecodedFrames=v.decodedFrames,delete this.waitDecodedFrames):("undefined"===typeof this.waitDecodedFrames?
390
+ this.waitDecodedFrames=0:this.waitDecodedFrames++,1<this.waitDecodedFrames&&(this.lastDecodedFrames=0,delete this.waitDecodedFrames,this.mpegtsPlayer&&(this.closecall(this),this.openMpegts()))):this.lastDecodedFrames=v.decodedFrames)}.bind(e);e.closecall=function(v){v.checkDelayTimerId&&(J.clearInterval(v.checkDelayTimerId),delete v.checkDelayTimerId);v.reconnectTimer||(J.clearTimeout(v.reconnectTimer),delete v.reconnectTimer);v.fastForwardTimerId&&(J.clearTimeout(v.fastForwardTimerId),delete v.fastForwardTimerId);
391
+ if(v.mpegtsPlayer){var A=v.mpegtsPlayer;A.pause();A.off(mpegts.Events.ERROR,v.onErrorCb);A.off(mpegts.Events.MEDIA_INFO,v.onMediaInfoCb);A.off(mpegts.Events.METADATA_ARRIVED,v.onMetadataCb);A.off(mpegts.Events.STATISTICS_INFO,v.onStatisCb);A.unload();A.detachMediaElement();A.destroy();delete v.onErrorCb;delete v.onMediaInfoCb;delete v.onMetadataCb;delete v.onStatisCb;delete v.onEventCb;delete v.mpegtsPlayer}};e.checkDelayTimerId=J.setInterval(function(){var v=this;if(v.mpegtsPlayer&&!v.videoEl.paused&&
391
392
  v.mpegtsPlayer.buffered.length){var A=v.mpegtsPlayer.buffered.end(0)-v.mpegtsPlayer.currentTime;6<=A?v.mpegtsPlayer.currentTime=v.mpegtsPlayer.buffered.end(0)-.2:3<A&&(v.videoEl.playbackRate=1.5,v.fastForwardTimerId=setTimeout(function(){v.videoEl.playbackRate=1;delete v.fastForwardTimerId},2E3*A))}}.bind(e),2E3);c.on(mpegts.Events.ERROR,e.onErrorCb);c.on(mpegts.Events.MEDIA_INFO,e.onMediaInfoCb);c.on(mpegts.Events.METADATA_ARRIVED,e.onMetadataCb);c.on(mpegts.Events.STATISTICS_INFO,e.onStatisCb);
392
- c.attachMediaElement(m);c.load();c.play();e.mpegtsPlayer=c};e.openMpegts()});return!0},ka=function(e){Ja("hls_js",Ia+"hls.min.js",function(n){console.log("js:"+n+" is load!");var m=I.Hls;if(m.isSupported()){var c=e,l=new m;l.attachMedia(e.videoEl);l.on(m.Events.MEDIA_ATTACHED,function(){console.log("video and hlsPlayer are now bound together !");l.loadSource(e.murl);l.on(m.Events.MANIFEST_PARSED,function(K,b){console.log("HLSPlayer manifest loaded, found "+b.levels.length+" quality level");c.loadingOverlay&&
393
- (c.loadingOverlay.style.display="none");c.videoEl.play();c.setplaystate(!0)})});l.on(m.Events.ERROR,function(K,b){if(b.fatal)switch(b.type){case m.ErrorTypes.NETWORK_ERROR:console.log("fatal network error encountered, try to recover");l.startLoad();break;case m.ErrorTypes.MEDIA_ERROR:console.log("fatal media error encountered, try to recover");l.recoverMediaError();break;default:l.destroy(),delete e.hlsPlayer,c.setplaystate(!1)}});c.onHlsManifestParsed=function(K,b){var O=this;if(1<b.levels.length){var z=
394
- [];for(K=0;K<b.levels.length;K++){var la={mediaType:"video",bitrate:b.levels[K].bitrate,height:b.levels[K].height,width:b.levels[K].width,qualityIndex:K,name:b.levels[K].name||"q"+K};z.push(la)}O.switchQualityLevel=function(H){l.nextLevel=parseInt(H)}.bind(O);O.createQualitiesMenu(z);l.on(m.Events.LEVEL_SWITCHED,function(H,ja){O.updateQualityLevel(l.currentLevel,l.autoLevelEnabled)},O)}else O.resetQualitiesMenu();if(b.subtitleTracks&&0<b.subtitleTracks.length){z=[];for(K=0;K<b.subtitleTracks.length;K++)la=
395
- b.subtitleTracks[K],la.forced||(la={"default":la.default,id:la.id,lang:la.lang,name:la.name,url:la.url},z.push(la));O.switchSubtitleTrack=function(H){H=parseInt(H);-1===H?l.subtitleDisplay=!1:(l.subtitleDisplay=!0,l.subtitleTrack=H)};O.createSubtitlesMenu(z);l.on(m.Events.SUBTITLE_TRACK_SWITCH,function(H,ja){O.updateSubtitleTrack(ja.id)})}}.bind(c);l.on(m.Events.MANIFEST_PARSED,c.onHlsManifestParsed);c.hlsPlayer=l;c.closecall=function(K){K.hlsPlayer&&(K.hlsPlayer.off(m.Events.MANIFEST_PARSED,K.onHlsManifestParsed),
396
- K.hlsPlayer.detachMedia(),K.hlsPlayer.destroy(),delete K.hlsPlayer,delete K.onHlsManifestParsed)}}else if(e.videoEl.canPlayType("application/vnd.apple.mpegurl")){c=e;e.videoEl.zwplayer=e;var v=function(){"object"==typeof this.zwplayer&&(this.play(),this.zwplayer.setplaystate(!0))},A=function(){"object"==typeof this.zwplayer&&console.log("HLS fatal media error encountered, try to recover")};c.videoEl.addEventListener("loadedmetadata",v);c.videoEl.addEventListener("error",A);c.closecall=function(K){"object"===
397
- typeof K.videoEl&&(K.videoEl.pause(),K.videoEl.src="",K.videoEl.removeEventListener("loadedmetadata",v),K.videoEl.removeEventListener("error",A),"object"==typeof K.videoEl.zwplayer&&delete K.videoEl.zwplayer)};c.videoEl.src=c.murl}else return e.toast("player cannot play hls media"),!1});return!0},ia=function(e){Ja("dash_js",Ia+"dash.all.min.js",function(n){console.log("js:"+n+" is load!");var m=I.dashjs,c=m.MediaPlayer().create();c.initialize(e.videoEl,e.murl,!0);n=e.getSimpleSubtitleRenderer();c.attachTTMLRenderingDiv(n);
393
+ c.attachMediaElement(m);c.load();c.play();e.mpegtsPlayer=c};e.openMpegts()});return!0},ka=function(e){Ja("hls_js",Ia+"hls.min.js",function(n){console.log("js:"+n+" is load!");var m=J.Hls;if(m.isSupported()){var c=e,l=new m;l.attachMedia(e.videoEl);l.on(m.Events.MEDIA_ATTACHED,function(){console.log("video and hlsPlayer are now bound together !");l.loadSource(e.murl);l.on(m.Events.MANIFEST_PARSED,function(M,b){console.log("HLSPlayer manifest loaded, found "+b.levels.length+" quality level");c.loadingOverlay&&
394
+ (c.loadingOverlay.style.display="none");c.videoEl.play();c.setplaystate(!0)})});l.on(m.Events.ERROR,function(M,b){if(b.fatal)switch(b.type){case m.ErrorTypes.NETWORK_ERROR:console.log("fatal network error encountered, try to recover");l.startLoad();break;case m.ErrorTypes.MEDIA_ERROR:console.log("fatal media error encountered, try to recover");l.recoverMediaError();break;default:l.destroy(),delete e.hlsPlayer,c.setplaystate(!1)}});c.onHlsManifestParsed=function(M,b){var P=this;if(1<b.levels.length){var z=
395
+ [];for(M=0;M<b.levels.length;M++){var la={mediaType:"video",bitrate:b.levels[M].bitrate,height:b.levels[M].height,width:b.levels[M].width,qualityIndex:M,name:b.levels[M].name||"q"+M};z.push(la)}P.switchQualityLevel=function(H){l.nextLevel=parseInt(H)}.bind(P);P.createQualitiesMenu(z);l.on(m.Events.LEVEL_SWITCHED,function(H,ja){P.updateQualityLevel(l.currentLevel,l.autoLevelEnabled)},P)}else P.resetQualitiesMenu();if(b.subtitleTracks&&0<b.subtitleTracks.length){z=[];for(M=0;M<b.subtitleTracks.length;M++)la=
396
+ b.subtitleTracks[M],la.forced||(la={"default":la.default,id:la.id,lang:la.lang,name:la.name,url:la.url},z.push(la));P.switchSubtitleTrack=function(H){H=parseInt(H);-1===H?l.subtitleDisplay=!1:(l.subtitleDisplay=!0,l.subtitleTrack=H)};P.createSubtitlesMenu(z);l.on(m.Events.SUBTITLE_TRACK_SWITCH,function(H,ja){P.updateSubtitleTrack(ja.id)})}}.bind(c);l.on(m.Events.MANIFEST_PARSED,c.onHlsManifestParsed);c.hlsPlayer=l;c.closecall=function(M){M.hlsPlayer&&(M.hlsPlayer.off(m.Events.MANIFEST_PARSED,M.onHlsManifestParsed),
397
+ M.hlsPlayer.detachMedia(),M.hlsPlayer.destroy(),delete M.hlsPlayer,delete M.onHlsManifestParsed)}}else if(e.videoEl.canPlayType("application/vnd.apple.mpegurl")){c=e;e.videoEl.zwplayer=e;var v=function(){"object"==typeof this.zwplayer&&(this.play(),this.zwplayer.setplaystate(!0))},A=function(){"object"==typeof this.zwplayer&&console.log("HLS fatal media error encountered, try to recover")};c.videoEl.addEventListener("loadedmetadata",v);c.videoEl.addEventListener("error",A);c.closecall=function(M){"object"===
398
+ typeof M.videoEl&&(M.videoEl.pause(),M.videoEl.src="",M.videoEl.removeEventListener("loadedmetadata",v),M.videoEl.removeEventListener("error",A),"object"==typeof M.videoEl.zwplayer&&delete M.videoEl.zwplayer)};c.videoEl.src=c.murl}else return e.toast("player cannot play hls media"),!1});return!0},ia=function(e){Ja("dash_js",Ia+"dash.all.min.js",function(n){console.log("js:"+n+" is load!");var m=J.dashjs,c=m.MediaPlayer().create();c.initialize(e.videoEl,e.murl,!0);n=e.getSimpleSubtitleRenderer();c.attachTTMLRenderingDiv(n);
398
399
  e.dashTextTrackList={};e.onDashMetadata=function(l){l&&console.log(l);this.loadingOverlay&&(this.loadingOverlay.style.display="none");this.videoEl.play();this.setplaystate(!0)}.bind(e);e.onDashQualityChanged=function(l){l=c.getQualityFor("video");var v=c.getSettings().streaming.abr.autoSwitchBitrate.video||!1;e.updateQualityLevel(l,v)}.bind(e);e.onDashStreamInitialized=function(l){c.getBitrateInfoListFor("audio");l=c.getBitrateInfoListFor("video")||[];1<l.length?(this.switchQualityLevel=function(v){v=
399
400
  parseInt(v);var A={streaming:{abr:{autoSwitchBitrate:{}}}};0<=v?(A.streaming.abr.autoSwitchBitrate.video=!1,c.updateSettings(A),c.setQualityFor("video",v,!1)):(A.streaming.abr.autoSwitchBitrate.video=!0,c.updateSettings(A))}.bind(this),this.createQualitiesMenu(l),c.on(m.MediaPlayer.events.QUALITY_CHANGE_RENDERED,this.onDashQualityChanged,this)):this.resetQualitiesMenu()}.bind(e);e.onDashTracksAdded=function(l){var v=this.dashTextTrackList;v[l.streamId]||(v[l.streamId]=[]);v[l.streamId]=v[l.streamId].concat(l.tracks)};
400
- e.onDashStreamDeactivated=function(l){var v=this.dashTextTrackList;l.streamInfo&&v[l.streamInfo.id]&&delete v[l.streamInfo.id]}.bind(e);e.onDashStreamActivated=function(l){l=l.streamInfo.id||"none";var v=this.dashTextTrackList;if(v[l]&&(l=v[l],!(1>l.length))){v=[];for(var A=0;A<l.length;A++){var K=l[A],b=hb(K.labels);b?b+=" : "+K.type:(b=K.label||K.lang,b+=" : "+K.kind);v.push({"default":K.defaultTrack,id:A,lang:K.lang,name:b,url:K.url||""})}this.switchSubtitleTrack=function(O){var z=this.dashPlayer||
401
- null;z&&(parseInt(O),z.setTextTrack(O))}.bind(this);this.createSubtitlesMenu(v)}}.bind(e);c.on(m.MediaPlayer.events.PLAYBACK_METADATA_LOADED,e.onDashMetadata,e);c.on(m.MediaPlayer.events.STREAM_INITIALIZED,e.onDashStreamInitialized,e);c.on(m.MediaPlayer.events.STREAM_ACTIVATED,e.onDashStreamActivated,e);c.on(m.MediaPlayer.events.STREAM_DEACTIVATED,e.onDashStreamDeactivated,e);c.on(m.MediaPlayer.events.TEXT_TRACKS_ADDED,e.onDashTracksAdded,e);e.dashPlayer=c;e.closecall=function(l){l.dashPlayer&&(l.dashPlayer.pause(),
401
+ e.onDashStreamDeactivated=function(l){var v=this.dashTextTrackList;l.streamInfo&&v[l.streamInfo.id]&&delete v[l.streamInfo.id]}.bind(e);e.onDashStreamActivated=function(l){l=l.streamInfo.id||"none";var v=this.dashTextTrackList;if(v[l]&&(l=v[l],!(1>l.length))){v=[];for(var A=0;A<l.length;A++){var M=l[A],b=hb(M.labels);b?b+=" : "+M.type:(b=M.label||M.lang,b+=" : "+M.kind);v.push({"default":M.defaultTrack,id:A,lang:M.lang,name:b,url:M.url||""})}this.switchSubtitleTrack=function(P){var z=this.dashPlayer||
402
+ null;z&&(parseInt(P),z.setTextTrack(P))}.bind(this);this.createSubtitlesMenu(v)}}.bind(e);c.on(m.MediaPlayer.events.PLAYBACK_METADATA_LOADED,e.onDashMetadata,e);c.on(m.MediaPlayer.events.STREAM_INITIALIZED,e.onDashStreamInitialized,e);c.on(m.MediaPlayer.events.STREAM_ACTIVATED,e.onDashStreamActivated,e);c.on(m.MediaPlayer.events.STREAM_DEACTIVATED,e.onDashStreamDeactivated,e);c.on(m.MediaPlayer.events.TEXT_TRACKS_ADDED,e.onDashTracksAdded,e);e.dashPlayer=c;e.closecall=function(l){l.dashPlayer&&(l.dashPlayer.pause(),
402
403
  l.dashPlayer.off(m.MediaPlayer.events.PLAYBACK_METADATA_LOADED,l.onDashMetadata,l),l.dashPlayer.off(m.MediaPlayer.events.STREAM_INITIALIZED,l.onDashStreamInitialized,l),l.dashPlayer.off(m.MediaPlayer.events.STREAM_ACTIVATED,l.onDashStreamActivated,l),l.dashPlayer.off(m.MediaPlayer.events.STREAM_DEACTIVATED,l.onDashStreamDeactivated,l),l.dashPlayer.on(m.MediaPlayer.events.TEXT_TRACKS_ADDED,e.onDashTracksAdded,e),l.switchQualityLevel&&(l.dashPlayer.off(m.MediaPlayer.events.QUALITY_CHANGE_RENDERED,l.onDashQualityChanged,
403
404
  l),delete l.switchQualityLevel),l.dashPlayer.destroy(),delete l.dashPlayer,delete l.onDashMetadata,delete l.onDashStreamInitialized,delete l.onDashStreamActivated,delete l.onDashStreamDeactivated,delete l.onDashTracksAdded,delete l.switchSubtitleTrack)}});return!0},na=function(e){var n=e.videoEl;e.closecall=function(m){if(m.isPlayVideo){var c=m.videoEl;c.paused||c.pause();c.src="";delete m.isPlayVideo}};e.isPlayVideo=!0;n.src=e.murl;return!0},ha=function(e){var n=e.videoEl;e.closecall=function(m){if(m.isPlayAudio){var c=
404
- m.videoEl;c.paused||c.pause();c.src="";delete m.isPlayAudio}};e.isPlayAudio=!0;n.src=e.murl;return!0},ca=function(e){var n=e.murl;if("dvr"===(n.type||"")&&n.http)return e.murl=n.http,na(e);if(I.MediaSource&&I.MediaSource.isTypeSupported('video/mp4; codecs="avc1.42E01E,mp4a.40.2"')){var m=I.RTCPeerConnection||I.webkitRTCPeerConnection||I.mozRTCPeerConnection||I.RTCIceGatherer;if(n.rtc&&m)return e.murl=n.rtc,aa(e);if(n["httpflv-n"])return e.murl=n["httpflv-n"],ma(e);if(n.httpflv)return e.murl=n.httpflv,
405
+ m.videoEl;c.paused||c.pause();c.src="";delete m.isPlayAudio}};e.isPlayAudio=!0;n.src=e.murl;return!0},ca=function(e){var n=e.murl;if("dvr"===(n.type||"")&&n.http)return e.murl=n.http,na(e);if(J.MediaSource&&J.MediaSource.isTypeSupported('video/mp4; codecs="avc1.42E01E,mp4a.40.2"')){var m=J.RTCPeerConnection||J.webkitRTCPeerConnection||J.mozRTCPeerConnection||J.RTCIceGatherer;if(n.rtc&&m)return e.murl=n.rtc,aa(e);if(n["httpflv-n"])return e.murl=n["httpflv-n"],ma(e);if(n.httpflv)return e.murl=n.httpflv,
405
406
  ma(e);if(n["wsflv-n"])return e.murl=n["wsflv-n"],ma(e);if(n.wsflv)return e.murl=n.wsflv,ma(e);if(n.hls)return e.murl=n.hls,ka(e);if(n.dash)return e.murl=n.dash,ia(e);if(n.ts)return e.murl=n.ts,Y(e)}else if(e.murl.hls)return e.murl=e.murl.hls,ka(e);return!1},oa=function(e){var n=[];var m=String.fromCharCode(107)+"u"+String.fromCharCode(97)+"ishou";var c=String.fromCharCode(46)+"co"+String.fromCharCode(109)+"/",l=String.fromCharCode(100)+"ou"+String.fromCharCode(121)+"i"+String.fromCharCode(110);n.push("https://live."+
406
407
  m+c+"u/");n.push("https://live."+l+c);if("string"===typeof e&&23<e.length)for(c=0;c<n.length;c++)if(m=n[c],0===e.indexOf(m))return!0;return!1};ba.prototype={play:function(e,n,m){var c=this;if(e){c.murl&&c.stop();if("string"===typeof e&&(e.startsWith("wcdn://")||e.startsWith("wcdns://")))return!0;if("object"===typeof e){"object"===typeof e.thumbnails&&(c._config.thumbnails=JSON.parse(JSON.stringify(e.thumbnails)));if("object"===typeof e.murls){c.multiStreams=JSON.parse(JSON.stringify(e));var l=e.murls}else Array.isArray(e)?
407
- (c.multiStreams={},l=e):(c.multiStreams={},l=[e]),c.multiStreams.murls=l;var v=!0,A="",K=[],b;for(b in l){var O,z=l[b];if("object"===typeof z)if(Array.isArray(z)){var la="";var H=z[0];if(2<z.length){var ja=z[2];la=z[1]}else ja=1<z.length?z[1]:b;K.push({url:H,name:ja,mime:la});v&&(e=H,A=ja,v=!1)}else{if(H=!1,"default"in z&&z["default"]&&(H=z["default"]),v||H)"url"in z&&(e=z.url),"name"in z&&(O=z.name),A=O,v=!1}else"string"===typeof z&&v&&(O=b,e=z,A=O,v=!1)}0<K.length&&(c.multiStreams.murls=K);c.multiStreams.curStream=
408
- A;console.log(e)}c.murl=e}if(!c.murl)return!1;c.force_stopped=!1;c.isPlaying=!0;c.loadingOverlay&&(c.loadingOverlay.style.display="flex");"undefined"!=typeof n&&(n?c._config.isLive=n:delete c._config.isLive);"undefined"!=typeof m&&(m?c._config.useOldFlv=m:delete c._config.useOldFlv);e=!1;if("object"==typeof c.murl)e=ca(c);else if("string"==typeof c.murl){e=L(c.murl);e||(n=c.murl.indexOf("mime_type="),0<n&&(n+=10,l=c.murl.indexOf("&",n),0>l&&(l=c.murl.length),n=c.murl.substring(n,l),"video_mp4"===
408
+ (c.multiStreams={},l=e):(c.multiStreams={},l=[e]),c.multiStreams.murls=l;var v=!0,A="",M=[],b;for(b in l){var P,z=l[b];if("object"===typeof z)if(Array.isArray(z)){var la="";var H=z[0];if(2<z.length){var ja=z[2];la=z[1]}else ja=1<z.length?z[1]:b;M.push({url:H,name:ja,mime:la});v&&(e=H,A=ja,v=!1)}else{if(H=!1,"default"in z&&z["default"]&&(H=z["default"]),v||H)"url"in z&&(e=z.url),"name"in z&&(P=z.name),A=P,v=!1}else"string"===typeof z&&v&&(P=b,e=z,A=P,v=!1)}0<M.length&&(c.multiStreams.murls=M);c.multiStreams.curStream=
409
+ A;console.log(e)}c.murl=e}if(!c.murl)return!1;c.force_stopped=!1;c.isPlaying=!0;c.loadingOverlay&&(c.loadingOverlay.style.display="flex");"undefined"!=typeof n&&(n?c._config.isLive=n:delete c._config.isLive);"undefined"!=typeof m&&(m?c._config.useOldFlv=m:delete c._config.useOldFlv);e=!1;if("object"==typeof c.murl)e=ca(c);else if("string"==typeof c.murl){e=K(c.murl);e||(n=c.murl.indexOf("mime_type="),0<n&&(n+=10,l=c.murl.indexOf("&",n),0>l&&(l=c.murl.length),n=c.murl.substring(n,l),"video_mp4"===
409
410
  n?e=".mp4":"video_flv"===n?e=".flv":"video_hls"===n?e=".m3u8":"video_rtc"===n?e=".rtc":"video_dash"===n&&(e=".mpd")));if(!e&&("string"===typeof c._config.streamtype&&("httpflv"===c._config.streamtype?e=".flv":"hls"===c._config.streamtype?e=".m3u8":"dash"===c._config.streamtype?e=".mpd":"mpegts"===c._config.streamtype?e=".ts":"webrtc"===c._config.streamtype&&(e=".rtc")),!e&&oa(c.murl))){var d=function(){setTimeout(function(){c.loadingOverlay&&(c.loadingOverlay.style.display="none")},1E3)};if(!c._config.url_proxy)return c.toast("Sorry, the player cannot play this media address",
410
411
  5E3,!0),d(),!1;var h=h;w(c._config.url_proxy,JSON.stringify({roomUrl:c.murl,token:c._config.proxy_token||"12345678"}),function(q){if("object"===typeof q&&q.result){q={murls:q.flvStreams||q.hlsStreams,multistream:1};if(!q.murls)return c.toast("Sorry, missing valid address for this room.",5E3,!0),d(),!1;c.play(q,h,m)}else c.toast("Sorry, unable to obtain a valid address for this room.",5E3,!0),d()},function(q){c.toast("Sorry, failed to get address due to network!",5E3,!0);d()});return!1}e=0===c.murl.indexOf("rtsp")?
411
- fa(c):".rtc"===e||c.murl.startsWith("webrtc://")?aa(c):".flv"===e?c._config.useOldFlv?ma(c):Y(c):".m3u8"===e?ka(c):".mpd"===e?ia(c):".mp4"===e?na(c):".mp3"===e||".m4a"===e||".aac"===e||".mp4a"===e||".ogg"===e?ha(c):".ts"===e?Y(c):na(c)}e?(c.setupEventsHandler(),c.startHideControlbar(c),c.multiStreams&&I.setTimeout(function(){c.buildStreamSelector()},1E3)):(c.isPlaying=!1,c.loadingOverlay&&(c.loadingOverlay.style.display="none"),c.toast("Play media failed, unsupported media type",5E3,!0));return e},
412
- __switchStream:function(e){if("string"!==typeof e)this.toast("Switch stream methon does not support "+e);else{this.murl=e;e=L(this.murl);if(!e){var n=this.murl.indexOf("mime_type=");if(0<n){n+=10;var m=this.murl.indexOf("&",n);0>m&&(m=this.murl.length);n=this.murl.substring(n,m);"video_mp4"===n?e=".mp4":"video_flv"===n?e=".flv":"video_hls"===n?e=".m3u8":"video_rtc"===n?e=".rtc":"video_dash"===n&&(e=".mpd")}}e||"string"===typeof this._config.streamtype&&("httpflv"===this._config.streamtype?e=".flv":
412
+ fa(c):".rtc"===e||c.murl.startsWith("webrtc://")?aa(c):".flv"===e?c._config.useOldFlv?ma(c):Y(c):".m3u8"===e?ka(c):".mpd"===e?ia(c):".mp4"===e?na(c):".mp3"===e||".m4a"===e||".aac"===e||".mp4a"===e||".ogg"===e?ha(c):".ts"===e?Y(c):na(c)}e?(c.setupEventsHandler(),c.startHideControlbar(c),c.multiStreams&&J.setTimeout(function(){c.buildStreamSelector()},1E3)):(c.isPlaying=!1,c.loadingOverlay&&(c.loadingOverlay.style.display="none"),c.toast("Play media failed, unsupported media type",5E3,!0));return e},
413
+ __switchStream:function(e){if("string"!==typeof e)this.toast("Switch stream methon does not support "+e);else{this.murl=e;e=K(this.murl);if(!e){var n=this.murl.indexOf("mime_type=");if(0<n){n+=10;var m=this.murl.indexOf("&",n);0>m&&(m=this.murl.length);n=this.murl.substring(n,m);"video_mp4"===n?e=".mp4":"video_flv"===n?e=".flv":"video_hls"===n?e=".m3u8":"video_rtc"===n?e=".rtc":"video_dash"===n&&(e=".mpd")}}e||"string"===typeof this._config.streamtype&&("httpflv"===this._config.streamtype?e=".flv":
413
414
  "hls"===this._config.streamtype?e=".m3u8":"dash"===this._config.streamtype?e=".mpd":"mpegts"===this._config.streamtype?e=".ts":"webrtc"===this._config.streamtype&&(e=".rtc"));!this._config.isLive&&this.videoEl&&(this.postSeekTime=this.videoEl.currentTime);this.closecall&&(this.closecall(this),delete this.closecall);this.closecall2&&(this.closecall2(this),delete this.closecall2);this.videoEl&&(this.videoEl.removeAttribute("src"),this.videoEl.load());(0===this.murl.indexOf("rtsp")?fa(this):".rtc"===
414
415
  e||this.murl.startsWith("webrtc://")?aa(this):".flv"===e?this._config.useOldFlv?ma(this):Y(this):".m3u8"===e?ka(this):".mpd"===e?ia(this):".mp4"===e?na(this):".mp3"===e||".m4a"===e||".aac"===e||".mp4a"===e||".ogg"===e?ha(this):".ts"===e?Y(this):na(this))||this.toast("Switch stream failed, unsupported media type")}},stop:function(){this.closecall&&(this.closecall(this),this.removeVideoEventHandlers(),delete this.closecall);this.closecall2&&(this.closecall2(this),delete this.closecall2);this.videoEl&&
415
416
  (this.videoEl.removeAttribute("src"),this.videoEl.load());this.isPlaying=!1;this.setplaystate(!1);this.bigPlayOverlay&&(this.bigPlayOverlay.style.display="none");this.updateProgress(0);this.timeSpan&&(this.timeSpan.innerHTML="");this.controlbar&&(this.controlbar.querySelector(".zwp__duration-container").style.display="none");this.progressBar&&this.progressBar.streamtype&&(this.progressBar.streamtype.style.display="none");this.progressBar&&this.progressBar.chapters&&(this.progressBar.chapters.innerHTML=
416
- "");this.subtitles&&delete this.subtitles;this.subtitleShow&&(this.subtitleShow.style.display="none");this.toastTimerId&&(clearTimeout(this.toastTimerId),delete this.toastTimerId);this.mutedTipBox&&(this.popup_layers.removeChild(player.mutedTipBox),delete this.mutedTipBox);this.overlayLayerClickTimer&&(I.clearTimeout(this.overlayLayerClickTimer),delete this.overlayLayerClickTimer);delete this.multiStreams;this.resetSpeedMenu();this.resetQualitiesMenu();this.removeChapters();this.resetSubtitleMenu()},
417
+ "");this.subtitles&&delete this.subtitles;this.subtitleShow&&(this.subtitleShow.style.display="none");this.toastTimerId&&(clearTimeout(this.toastTimerId),delete this.toastTimerId);this.mutedTipBox&&(this.popup_layers.removeChild(player.mutedTipBox),delete this.mutedTipBox);this.overlayLayerClickTimer&&(J.clearTimeout(this.overlayLayerClickTimer),delete this.overlayLayerClickTimer);delete this.multiStreams;this.resetSpeedMenu();this.resetQualitiesMenu();this.removeChapters();this.resetSubtitleMenu()},
417
418
  pause:function(){this.isPlaying&&this.videoEl&&!this.videoEl.paused&&!this.videoEl.ended&&(this.videoEl.pause(),this.setplaystate(!1))},resume:function(){this.isPlaying?this.videoEl&&(this.videoEl.paused||this.videoEl.ended)&&(this.videoEl.play(),this.setplaystate(!0)):this._config.url&&this.play(this._config.url)},seekTime:function(e){if(this.isPlaying&&this.videoEl&&!(0>e)){var n=this.videoEl.duration;isNaN(n)||Infinity===n||(e>n&&(e=n),this.videoEl.currentTime=e)}},getDuration:function(){if(this.isPlaying&&
418
419
  this.videoEl)return this.videoEl.duration},destroy:function(){this.closecall&&(this.closecall(this),this.removeVideoEventHandlers(),delete this.closecall);this.closecall2&&(this.closecall2(this),delete this.closecall2);this.videoRemoveWhenClose&&(this.videoEl&&this.videoWrapper&&(this.videoWrapper.removeChild(this.videoEl),this.playerContainer.removeChild(this.videoWrapper),delete this.videoWrapper),delete this.videoRemoveWhenClose);this.videoEl&&(this.videoEl.removeAttribute("src"),this.videoEl.load(),
419
- this.videoEl=null,delete this.videoEl);this.snapCanvas&&delete this.snapCanvas;this.controlbar&&(this.progressBar&&this.progressBar.chapters&&(this.progressBar.chapters.innerHTML=""),this.playerContainer.removeChild(this.controlbar),delete this.controlbar);this.danmuToolbar&&(this.danmuToolbar.remove(),delete this.danmuToolbar);this.subtitles&&delete this.subtitles;this.toastTimerId&&(clearTimeout(this.toastTimerId),delete this.toastTimerId);this.overlayLayerClickTimer&&(I.clearTimeout(this.overlayLayerClickTimer),
420
+ this.videoEl=null,delete this.videoEl);this.snapCanvas&&delete this.snapCanvas;this.controlbar&&(this.progressBar&&this.progressBar.chapters&&(this.progressBar.chapters.innerHTML=""),this.playerContainer.removeChild(this.controlbar),delete this.controlbar);this.danmuToolbar&&(this.danmuToolbar.remove(),delete this.danmuToolbar);this.subtitles&&delete this.subtitles;this.toastTimerId&&(clearTimeout(this.toastTimerId),delete this.toastTimerId);this.overlayLayerClickTimer&&(J.clearTimeout(this.overlayLayerClickTimer),
420
421
  delete this.overlayLayerClickTimer);this.overlay_layers&&(this.subtitle1&&delete this.subtitle1,this.subtitle2&&delete this.subtitle2,this.subtitleShow&&(Ba.removeElement(this.subtitleShow),delete this.subtitleShow),this.danmuPlayer&&(this.danmuPlayer.destroy(),delete this.danmuPlayer),this.playerContainer.removeChild(this.overlay_layers),delete this.overlay_layers);this.popup_layers&&(this.playerContainer.removeChild(this.popup_layers),delete this.popup_layers);this.playerElm&&(delete this.playerContainer.zwpDragable,
421
- this.playerElm.removeChild(this.playerContainer),delete this.playerContainer,this.doDeletePlayerElm?(document.removeChild(this.playerElm),delete this.playerElm):this.doRemovePlayerClass&&(Q(this.playerElm,"zwp-wrap"),this.playerElm.setAttribute("class",this.playerElmOldClass)));this.windowScrollHandler&&(I.removeEventListener("scroll",this.windowScrollHandler),delete this.windowScrollHandler)},setplaystate:function(e){this.controlbar&&(this.playbtn||(this.playbtn=this.controlbar.querySelector(".zwp-playbtn")),
422
- this.playbtn&&(e?(this.playbtn.setAttribute("data-action","pause"),this.bigPlayOverlay&&(this.bigPlayOverlay.style.display="none")):(this.playbtn.setAttribute("data-action","play"),this.bigPlayOverlay&&(this.bigPlayOverlay.style.display="flex"))),this.playerElm&&(e?(Q(this.playerElm,"zwp-pause"),P(this.playerElm,"zwp-playing")):(Q(this.playerElm,"zwp-playing"),P(this.playerElm,"zwp-pause"))),this.loadingOverlay&&(this.loadingOverlay.style.display="none"))},setEnableDanmu:function(e){e?this.overlay_layers&&
422
+ this.playerElm.removeChild(this.playerContainer),delete this.playerContainer,this.doDeletePlayerElm?(document.removeChild(this.playerElm),delete this.playerElm):this.doRemovePlayerClass&&(Q(this.playerElm,"zwp-wrap"),this.playerElm.setAttribute("class",this.playerElmOldClass)));this.windowScrollHandler&&(J.removeEventListener("scroll",this.windowScrollHandler),delete this.windowScrollHandler)},setplaystate:function(e){this.controlbar&&(this.playbtn||(this.playbtn=this.controlbar.querySelector(".zwp-playbtn")),
423
+ this.playbtn&&(e?(this.playbtn.setAttribute("data-action","pause"),this.bigPlayOverlay&&(this.bigPlayOverlay.style.display="none")):(this.playbtn.setAttribute("data-action","play"),this.bigPlayOverlay&&(this.bigPlayOverlay.style.display="flex"))),this.playerElm&&(e?(Q(this.playerElm,"zwp-pause"),O(this.playerElm,"zwp-playing")):(Q(this.playerElm,"zwp-playing"),O(this.playerElm,"zwp-pause"))),this.loadingOverlay&&(this.loadingOverlay.style.display="none"))},setEnableDanmu:function(e){e?this.overlay_layers&&
423
424
  !this.danmuPlayer&&(this.danmuPlayer=HUAYI.Danmu.create({playerId:this.overlay_layers})):this.danmuPlayer&&(this.danmuPlayer.destroy(),delete this.danmuPlayer)},appendDanmu:function(e,n){this.danmuPlayer&&(n||(n=this.danmuSetting),this.danmuPlayer.addDanmu(e,n))},setChapters:function(e){null===e?this.removeChapters():(this.chapters=e,this.videoEl&&setTimeout(function(){this.loadChapters()}.bind(this),1E3))},addSubtitle:function(e,n,m){this.loadSubtitle(e,n,m)},removeSubtitle:function(){this.showSubtitle(!1)},
424
425
  buildDanmuControlbar:function(e,n){this.buildDanmuToolbar(e,n)},notifyResize:function(e,n){this.playerElm&&("undefined"!==typeof e&&("number"===typeof e&&(e+="px"),this.playerElm.style.width=e),"undefined"!==typeof n&&("number"===typeof n&&(n+="px"),this.playerElm.style.height=n))}};return ba})})(window);