[]
https://static.yximgs.com/udata/pkg/acfun-player/h5player.7182a2.js10&&(this.max=this.max-10,this.setItem(e,t,i)),console.log(n)}},t.removeItem=function(e){var t=this,i=this.cacheKey,n=this.memoryCache,a=JSON.parse(localStorage.getItem(i)||”[]”);a.some((function(t,n){return t.key===e&&(localStorage.setItem(i,JSON.stringify(a.splice(n,n))),!0)})),n.some((function(i,n){return i.key===e&&(t.memoryCache.splice(n,1),!0)}))},t.getItem=function(e){var t=this,i=null,n=this.cacheKey,a=this.memoryCache;try{if(a.some((function(n,a){return n.key===e&&(1*n.expirationTime>(new Date).getTime()?i=n.val:t.removeItem(e),!0)})),!i)JSON.parse(localStorage.getItem(n)||”[]”).some((function(n,a){return n.key===e&&(1*n.expirationTime>(new Date).getTime()?i=n.val:t.removeItem(e),!0)}))}catch(e){console.log(e)}return i},e}(),ls=new LS,instant=window.instant,utils={isArray:function(e){return Array.isArray?Array.isArray(e):”[object Array]”===toString.call(e)},parseCookieString:function(e,t,i){void 0===i&&(i={});var n={};if(e.length>0)for(var a=!1===t?function(e){return e}:decodeURIComponent,o=e.split(/;s/g),r=null,l=null,s=null,d=0,c=o.length;d=1e8?(t/1e7|0)/10+”亿”:(t=0|(e||0))>=1e4?(.001*t|0)/10+”万”:t.toString().replace(/(d)(?=(d{3})+(?!d))/g,”$1,”)},showNotSupport:function(){var e=document.createElement(“div”);e.classList.add(“is-ie”),e.innerHTML=”

尊敬的Acer,猴子温馨提示:

AcFun已全面升级至H5播放器,请使用Chrome内核的浏览器

或者Windows 8.1以上系统的IE11或Edge浏览器获得更好的播放体验。”;var t=document.getElementsByClassName(“player”)[0];t.style.backgroundColor=”black”,t.appendChild(e)},showError:function(e){var t=’]]]]]]>]]]]>]]>

‘+e+”

“,i=document.createElement(“div”);i.classList.add(“error-container”),i.innerHTML=t,setTimeout((function(){var e=document.getElementById(“player”);e.classList.add(“show-error”),e.appendChild(i)}))},hideError:function(){var e=document.getElementById(“player”);if(e){e.classList.remove(“show-error”);var t=e.querySelector(“.error-container”);t&&e.removeChild(t)}},analysisUrl:function(e){var t=null;try{t=(t=e.ksPlayJson&&JSON.parse(e.ksPlayJson))||e.playInfos[0].playUrls[0]}catch(e){t=null;var i={action:”error”,name:”parseKsPlayJsonError”,error_message:e,error_src:location.href};window.instant?window.instant.send(i):window.instantData&&window.instantData.payload.push(i)}return t},webLog:function(e,t,i,n,a,o){try{window.player.emit(“summaryReport”,o);var r=(new Date).getTime(),l={req_id:weblog.impr.getCurrentReqID(),group_id:weblog.impr.getCurrentGroupID(),atom_id:String(e||0),ac_id:”0″,album_id:String(t)};A.emit(“COMMENT_SHOW”,_extends({impr_comment_cnt:weblog.commCount},l),”SHOW_EVENT”,!1),A.emit(“STAY_DURATION”,_extends({stay_duration:r-weblog.base.log_time},l),”CLICK_EVENT”,!1),window.weblog.flush(),window.weblog.destroy();var s=document.referrer;!t&&!n&&e&&i&&(s=location.origin+”/v/ac”+e);var d=window.Weblog&&new Weblog({useBeacon:!0},{base:{safety_id:window.globalConfig.safetyId}});if(window.weblog=d,window.Weblog&&d){var c=new Event(“weblog:updateBase”);c.url=location.href,c.refer_url=s,window.dispatchEvent(c)}d.plug(Weblog.builtIns.impr),d.plug(Weblog.builtIns.video);var u=weblog.impr.generateReqID(a),p={req_id:u,group_id:u+”_1″,atom_id:String(i||0),ac_id:”0″,album_id:String(n)};A.emit(“READ”,p,”CLICK_EVENT”),A.emit(“CLIENT_IMPR”,{req_id:u,group_list:[{group_id:u+”_1″,atom_id:String(i),ac_id:”0″,album_id:String(n)}]},”SHOW_EVENT”)}catch(e){console.error(e)}},logSwitch2Play:function(e){try{e&&instant&&instant.send({name:”click_to_video_start_load”,duration:e,action:”performance”})}catch(e){console.log(e)}},logCached:function(e){try{instant?instant.send({name:”use_cached_play_url”,value:e?1:0,action:”report”}):(window.preInstant||(window.preInstant=[]),window.preInstant.push({name:”use_cached_play_url”,value:2,action:”report”}))}catch(e){console.log(e)}}},H5Player=window.H5Player,CATEGORY_INFO_MAP={v:{key:”v”,globalDataKey:”videoInfo”,resourceId:”dougaId”,type:”douga”,resourceType:”video”,danmakuSelector:”.danmu .sp2″,bangumiId:”albumId”,resourceTypeCode:2},bangumi:{key:”bangumi”,globalDataKey:”bangumiData”,resourceId:”bangumiId”,type:”bangumi”,resourceType:”bangumi”,bangumiId:”bangumiId”,danmakuSelector:”.danmu .sp2″,resourceTypeCode:1}},lastVid=null,lastSourceId=null,actionArea=document.querySelector(“.action-area”),leftArea=document.querySelector(“.action-area .left-area”),rightArea=document.querySelector(“.action-area .right-area”),orideclare=document.querySelector(“.action-area .originalDeclare”),mobile=document.querySelector(“.action-area .mobile”),AcFunPlayer=function(){function e(){var e=this;_defineProperty(this,”hasInitedAsyncPlugin”,!1),_defineProperty(this,”hasAsyncPluginsLoaded”,!1),_defineProperty(this,”firstLog”,!0),_defineProperty(this,”player”,null),_defineProperty(this,”preloadQueue”,[]),_defineProperty(this,”preloadRecommendTimer”,null),_defineProperty(this,”loadAsyncPluginsTimer”,null),_defineProperty(this,”danmakuOptions”,null),_defineProperty(this,”isDanmakuGInited”,!1),this.pageType=location.pathname.split(“/”)[1],this.categoryInfo=CATEGORY_INFO_MAP[this.pageType],this.switchVideoSTime=null,this.switchVideoETime=null,this.initState(),this.initStyle(),this.loadVideo(),this.firstLog=!1,setTimeout((function(){e.preloadVideos()}),3e3);var t=document.body;t.addEventListener(“click”,(function(i){for(var n=!0,a=!0,o=i.target,r=!1,l=document.querySelector(“.part”),s=document.querySelector(“.list-area”),d=document.querySelector(“.highlights”),c=document.querySelector(“.recommend-bangumis”),u=document.getElementById(“pagelet_newrecommend”);o!==t;){var p=null,m=!1,y=”a”===o.tagName.toLowerCase(),h=y?”href”:”data-href”,g=o.getAttribute(h);if(g&&(/^/v/ac/.test(g)?p=”v”:/^/bangumi/a/.test(g)&&(p=”bangumi”)),y&&!p)return!0;var f=!1;if(d&&d.contains(o)){var w=o;w.classList.contains(“active”)?(r=!0,f=!0):”v”==w.dataset.type&&(d.querySelector(“.active”)&&d.querySelector(“.active”).classList.remove(“active”),w.classList.add(“active”),l&&l.querySelector(“.single-p.active”)&&l.querySelector(“.single-p.active”).classList.remove(“active”),m=!0,a=!1,f=!0)}if(p===e.pageType)if(“bangumi”===p){if(s&&s.contains(o)){var v=o;if(!v.classList.contains(“play”)){s.querySelector(“.videoes .play”)&&s.querySelector(“.videoes .play”).classList.remove(“play”),s.querySelector(“.digitized .play”)&&s.querySelector(“.digitized .play”).classList.remove(“play”);var I=1*v.dataset.index;s.querySelector(“.videoes li:nth-child(“+(I+1)+”)”).classList.add(“play”),s.querySelector(“.digitized li:nth-child(“+(I+1)+”)”).classList.add(“play”),n=!0,a=!1,f=!0}}if(c&&c.contains(o))n=!0,a=o.getAttribute(“data-id”)!=e.resourceInfo.bangumiId,f=!0;if(l&&l.contains(o))a=o.getAttribute(“data-id”)!=e.resourceInfo.bangumiId,n=!1,f=!0;u&&u.contains(o)&&(n=!1,f=!0,a=!0)}else l&&l.contains(o)&&(n=!1),f=!0;if(f){i.preventDefault(),!r&&e.switchPage({pathName:g,forceAutoPlay:!1,needFreshPart:a,goTop:n,pageType:p,ishighLights:m});break}o=o.parentNode}}),!0),window.onpopstate=function(t){var i=null;document.location.pathname&&(/^/v/ac/.test(document.location.pathname)?i=”v”:/^/bangumi/a/.test(document.location.pathname)&&(i=”bangumi”)),i!==e.pageType?location.reload():e.switchVideo({pathName:document.location.pathname,needFreshPart:!0,goTop:!0,pageType:i})},this.preLoadLoop()}var t=e.prototype;return t.initState=function(){var e=this;try{this.lastVid=this.vid,this.lastBangumiId=this.bangumiId;var t=window[this.categoryInfo.globalDataKey];this.resourceInfo=t,this.mkey=t.mkey,this.channel=t.channel||{},this.videoInfo=t.currentVideoInfo,this.errorCode=t.playErrorCode,this.bangumiPaymentType=t.bangumiPaymentType,this.errorMessage=t.playErrorMessage,this.vid=this.videoInfo&&this.videoInfo.id,this.resourceId=t[this.categoryInfo.resourceId],this.resourceType=this.categoryInfo.resourceType,this.bangumiId=t[this.categoryInfo.bangumiId],this.commentParted=t.commentParted,this.lastWindowHeight=window.innerHeight,this.lastWindowWidth=window.innerWidth,this.nextInfo=null;var i=””;if(“bangumi”===this.pageType){this.bangumiItemId=t.itemId;var n=t.episodeName?”:”+t.episodeName:””;i=t.bangumiTitle+” “+n+” “+(t.title||””)+” – AcFun弹幕视频网 – 认真你就输啦 (?ω?)ノ- ( ゜- ゜)つロ”,(t.showHighlights||utils.getQueryString(“ac”)||t.hlVideoInfo)&&(window.videoInfo?(this.videoInfo=window.videoInfo.currentVideoInfo,this.channel=window.videoInfo.channel||{},this.vid=window.videoInfo.currentVideoInfo&&window.videoInfo.currentVideoInfo.id,this.resourceId=window.videoInfo.dougaId):(this.videoInfo=t.hlVideoInfo,this.channel=t.channel||{},this.vid=this.videoInfo.id,this.resourceId=t.hlId))}else this.bangumiItemId=null;var a=null;if(“v”===this.pageType)t.videoList&&t.videoList.length>1?(document.querySelector(“#main”)&&document.querySelector(“#main”).classList.remove(“single-part”),t.videoList[t.videoList.length-1].priority!==this.videoInfo.priority&&t.videoList.some((function(i,n){var o=t.videoList[n+1];return i.priority===e.videoInfo.priority&&o&&(a={title:”下一集”,subTitle:o.title,img:t.coverUrl}),!!a}))):document.querySelector(“#main”)&&document.querySelector(“#main”).classList.add(“single-part”);else if(“bangumi”===this.pageType)if(t.showHighlights&&t.sidelights&&t.sidelights.length){this.resourceType=”video”;for(var o=utils.getQueryString(“ac”)||0;o-10?(mobile&&t&&(mobile.style.display=”none”),(!mobile||t300?(orideclare.style.display=”inline-block”,mobile.style.display=”inline-block”):orideclare&&!i&&e>199?orideclare.style.display=”inline-block”:i&&mobile&&e>101&&(mobile.style.display=”inline-block”))}},t.handleResize=function(e){var t=this.lastWindowWidth,i=this.lastWindowHeight,n=window.innerHeight,a=window.innerWidth,o=!(a===t),r=!(n===i);this.lastWindowWidth=a,this.lastWindowHeight=n;var l=document.getElementById(“main-content”),s=document.querySelector(“.left-column”);if(o&&!e&&!r)return a>1050&&a1150){var c=a-370-100;if((d=d9*(c=c>1340?1340:c)/16)return l.style.width=””,l.style.margin=””,l.style.maxWidth=c+370+”px”,s.style.width=””,void this.handleTitleDescSize();var u=Math.floor(16*d/9);l.style.width=u+370+”px”,l.style.maxWidth=””,l.style.margin=”0 auto”,s.style.maxWidth=””,s.style.width=u+”px”}else l.style.width=””,l.style.maxWidth=””,l.style.margin=””,s.style.width=””,s.style.maxWidth=””}this.handleTitleDescSize()},t.loadVideo=function(e,t,i,n){var a=this;void 0===t&&(t=!0),this.loadAsyncPluginsCb=null,t&&!i&&(document.documentElement.scrollTop=0);var o=this.firstLog,r=(this.nextInfo,this.isAcfunOnly,this.resourceInfo),l=this.vid,s=this.bangumiId,d=this.videoInfo,c=this.errorCode,u=this.errorMessage,p=this.pageType,m=this.resourceId,y=this.resourceType,h=this.channel;if(!H5Player||!H5Player.prototype.isSupport())return utils.showNotSupport(),!1;if(utils.hideError(),this.player&&(this.player.emit(“toggleVipPop”,!1),this.player.emit(“hidePayBangumi”)),101105===c)this.player||(this.player=window.player=new H5Player({wrapper:”#ACPlayer”,extendWrapper:”.player-extend-wrap”,startBitrateNoLimit:abtestConfig&&abtestConfig.abConfig&&abtestConfig.abConfig.startBitrateNoLimit})),window.qualityConfig&&(window.player.qualityConfig=window.qualityConfig),this.danmakuOptions=this.getDanmakuOptions({channel:h,vid:l,resourceId:m,type:n?”douga”:void 0}),this.loadAsyncPlugins(),this.player.emit(“toggleVipPop”,!0),document.getElementById(“danmaku”)&&(document.getElementById(“danmaku”).style.display=”none”),this.player.$wrapper.classList.add(“no-mini”);else if(d){o&&instantRecord(“initialize_player”),this.player||(this.player=window.player=new H5Player({wrapper:”#ACPlayer”,extendWrapper:”.player-extend-wrap”,startBitrateNoLimit:abtestConfig&&abtestConfig.abConfig&&abtestConfig.abConfig.startBitrateNoLimit}),window.qualityConfig&&(window.player.qualityConfig=window.qualityConfig),o&&instantRecord(“tti”),this.bindEvents()),this.player.$wrapper.classList.remove(“no-mini”);var g=utils.analysisUrl(d),f=0,w=d.userPlayedSeconds,v=d.durationMillis&&d.durationMillis/1e3;if(v&&w>5&&w+50&&I480?e:480,a.style.height=e+”px”,document.getElementById(“movie-player”).appendChild(a),o.style.paddingBottom=”0″,r&&setTimeout((function(){t.play()}),0),n=!0}),100)):(document.getElementById(“header”).classList.remove(“dark-style”),document.getElementById(“main”).classList.remove(“dark-style”),document.getElementById(“toolbar”).classList.remove(“dark-style”),document.querySelector(“.right-column”).classList.remove(“dark-style”),a.style.height=””,o.appendChild(a),o.style.paddingBottom=”calc(56.25% + 40px)”,setTimeout((function(){r&&t.play()}),0),n=!1,e.handleResize(!0))})),t.on(“fullScreenChange”,(function(t){if(!1===t){if(n){var i=document.getElementById(“ACPlayer”);return void document.getElementById(“movie-player”).appendChild(i)}setTimeout((function(){e.handleResize(!0)}),0)}})),t.on(“danmakuRightListDomReady”,(function(e){document.querySelector(“.danmaku-container”).innerHTML=””,document.querySelector(“.danmaku-container”).appendChild(e)})),t.on(“pause”,(function(){e.sendHistory(i)})),t.on(“ended”,(function(){!t.loop&&t.playContinue&&e.playNext(),e.sendHistory(i)})),t.on(“playNextBtnClick”,(function(){e.playNext()}));var a=!1;t.on(“canplay”,(function(){a=!0,e.loadAsyncPlugins()})),setTimeout((function(){a||e.loadAsyncPlugins()}),3e3)},t.playNext=function(){var e,t=this.pageType,i=(this.resourceInfo,null),n=!0,a=!1;if(“v”===t?i=(e=document.querySelector(“.single-p.active”))&&e.nextSibling:”bangumi”===t&&((e=document.querySelector(“.single-p.active”))||(e=document.querySelector(“.highlight-item.active”),a=!0),i=e&&e.nextSibling,n=!1),i){if(“bangumi”===t&&(window.curItemId=i.dataset.id,utils.getQueryString(“ac”)&&document.querySelector(“.highlights .active”))){for(a=!0,e.classList.remove(“active”);!i.classList.contains(“highlight-item”);)i=i.nextSibling;i.classList.add(“active”),t=”v”}this.switchPage({pathName:i.getAttribute(“data-href”),forceAutoPlay:!0,needFreshPart:n,goTop:!1,pageType:t,ishighLights:a})}else if(“v”===t)window.A&&window.A.emit(“global::info”,”已经播放到最后一p啦~”,3e3);else{if(a)return void(window.A&&window.A.emit(“global::info”,”已经播放到最后一集花絮啦~”,3e3));window.A&&window.A.emit(“global::info”,”已经播放到最后一话啦~”,3e3)}},t.switchPage=function(e){var t=e.pathName,i=e.forceAutoPlay,n=e.needFreshPart,a=e.goTop,o=e.pageType,r=e.ishighLights,l=this.resourceInfo;if(r||o===this.pageType)if(window.bigPipe&&history.pushState){var s=location.search,d=location.hash;if(r){var c=+document.querySelector(“.highlight-item.active”).getAttribute(“data-index”)+1;l.showHighlights=!0,l.highlightId=c-1,history.pushState({},””,location.origin+location.pathname+”?ac=”+c)}else”?”==(s=s.replace(/ac=[d]*(&)?/gi,””))&&(s=””),history.pushState({},””,location.origin+t+s+d);this.switchVideo({pathName:t,forceAutoPlay:i,needFreshPart:n,goTop:a,pageType:o,ishighLights:r})}else location.href=t;else window.open(t)},t.switchVideo=function(e){var t=this,i=e.pathName,n=e.forceAutoPlay,a=e.needFreshPart,o=e.goTop,r=e.pageType,l=e.ishighLights;this.switchVideoSTime=(new Date).getTime(),this.player&&this.player.danmaku&&this.player.danmaku.list&&(this.player.danmaku.list=[]),this.player&&this.player.emit(“nextInfoChange”,null);var s=ls.getItem(i),d=!1;if(s){var c=s.playUrl,u=s.playedSeconds,p=s.mkey,m=s.channel,y=s.vid,h=s.resourceId,g=s.bangumiId;if(this.player){if(this.player.mkey=p,n&&(window.player.autoplay=!0),this.player.vid=y,this.resourceId=h,this.switchVideoETime=(new Date).getTime(),this.player.emit(“initLogParams”,this.resourceId,this.bangumiId,this.resourceType,y),this.switchLog({lastVid:this.vid,lastBangumiId:this.bangumiId,vid:y,bangumiId:g}),this.danmakuOptions=this.getDanmakuOptions({channel:m,vid:y,resourceId:h,type:l?”douga”:void 0}),this.player.load(c,u),this.player&&!(this.player instanceof HTMLElement)&&this.player.plug(“pause-display”)){var f=window.videoResource;f&&f.imgUrl&&f.link?this.player.plug(“pause-display”).setDisplayItem(f.imgUrl,f.link):this.player.plug(“pause-display”).clearDisplayItem()}this.player.autoplay&&this.player.play(),d=!0,o&&(document.documentElement.scrollTop=0)}}if(“v”===r){if(l)return void this.pipe({id:”videoInfo_new”,loaded:d,pathName:i,container:function(e){var a=document.createElement(“div”);a.innerHTML=e.html,t.preloadNextVideo();var r=document.createElement(“script”);r.innerHTML=a.querySelector(“script.videoInfo”).innerHTML,document.body.appendChild(r),setTimeout((function(){var e=i.split(“/v/ac”)[1];t.switchComment(“v”,e,3)})),window.videoInfo&&(window.player.videoInfo=window.videoInfo);var s=a.querySelector(“script.videoResource”).innerHTML,c=s.slice(s.indexOf(“{“));try{window.videoResource=c=JSON.parse(c),!t.player||t.player instanceof HTMLElement||!t.player.plug(“pause-display”)||(c&&c.imgUrl&&c.link?t.player.plug(“pause-display”).setDisplayItem(c.imgUrl,c.link):t.player.plug(“pause-display”).clearDisplayItem())}catch(e){t.player&&!(t.player instanceof HTMLElement)&&t.player.plug(“pause-display”)&&t.player.plug(“pause-display”).clearDisplayItem()}t.initState(),t.loadVideo(n,o,d,l)}});this.pipe({id:”videoInfo_new”,loaded:d,container:function(e){var i=document.createElement(“div”);i.innerHTML=e.html,a?t.updateComponent([“.video-description”,”.introduction”,”.part”],i):t.updateComponent([“.video-description”,”.introduction”],i),t.preloadNextVideo();var r=document.createElement(“script”);r.innerHTML=i.querySelector(“script.videoInfo”).innerHTML,document.body.appendChild(r),setTimeout((function(){t.switchComment()})),window.videoInfo&&(window.player.videoInfo=window.videoInfo);var l=i.querySelector(“script.videoResource”).innerHTML,s=l.slice(l.indexOf(“{“));try{window.videoResource=s=JSON.parse(s),!t.player||t.player instanceof HTMLElement||!t.player.plug(“pause-display”)||(s&&s.imgUrl&&s.link?t.player.plug(“pause-display”).setDisplayItem(s.imgUrl,s.link):t.player.plug(“pause-display”).clearDisplayItem())}catch(e){t.player&&!(t.player instanceof HTMLElement)&&t.player.plug(“pause-display”)&&t.player.plug(“pause-display”).clearDisplayItem()}t.initState(),t.loadVideo(n,o,d)}}),setTimeout((function(){t.pipe({id:”pagelet_newrecommend”,container:”pagelet_newrecommend”})}))}else”bangumi”===r&&(this.pipe({id:”videoInfo_new”,loaded:d,container:function(e){var i=document.createElement(“div”);i.innerHTML=e.html,a?t.updateComponent([“.video-description”,”.introduction”,”.highlights”,”.recommend-bangumis”,”.bangumi-list”,”.basic-info”],i):t.updateComponent([“.video-description”,”.introduction”,”.highlights”,”.recommend-bangumis”],i),t.preloadNextVideo();var r=document.createElement(“script”);r.innerHTML=i.querySelector(“script.videoInfo”).innerHTML,document.body.appendChild(r),setTimeout((function(){t.switchComment()})),window.bangumiData&&window.bangumiData.currentVideoInfo&&(window.player.videoInfo=window.bangumiData.currentVideoInfo);var l=i.querySelector(“script.videoResource”).innerHTML,s=l.slice(l.indexOf(“{“));try{window.videoResource=s=JSON.parse(s),!t.player||t.player instanceof HTMLElement||!t.player.plug(“pause-display”)||(s&&s.imgUrl&&s.link?t.player.plug(“pause-display”).setDisplayItem(s.imgUrl,s.link):t.player.plug(“pause-display”).clearDisplayItem())}catch(e){t.player&&!(t.player instanceof HTMLElement)&&t.player.plug(“pause-display”)&&t.player.plug(“pause-display”).clearDisplayItem()}var c=document.querySelector(“._web-share-wechat-qrcode”);c&&c.parentNode&&c.parentNode.removeChild(c),t.initState(),a?t.pipe({id:”pagelet_partlist”,container:”pagelet_partlist”,pipeCb:function(){t.loadVideo(n,o,d)}}):(t.pipe({id:”pagelet_partlist”,container:”pagelet_partlist”}),t.loadVideo(n,o,d))}}),setTimeout((function(){t.pipe({id:”pagelet_newrecommend”,container:”pagelet_newrecommend”})})))},t.switchComment=function(e,t,i){var n=this.vid,a=this.resourceId,o=this.pageType,r=this.commentParted,l=this.resourceInfo;o=e||o,a=t||a;localStorage.getItem(“ac_usp_commMode”);var s=a;”bangumi”===o&&(r?(n||(n=l.videoId),s=a+”_”+n):i||(i=2)),i||(i=”bangumi”==o?6:3);try{A.emit(“loadpage”,{p:1,sourceId:s,sourceType:i})}catch(e){console.log(e)}},t.updateComponent=function(e,t){var i=this;e.forEach((function(e){var n=t.querySelector(e),a=document.querySelector(e);if(n){if(a){try{a.style.visibility=”hidden”,a.replaceWith(n)}catch(e){console.log(e),a.outerHTML=n.outerHTML}document.querySelector(e).style.visibility=””}else if(n&&!a){if(“.part”===e){var o=document.querySelector(“#pagelet_rightrecommend”);return void(o&&o.parentNode.insertBefore(n,o))}if(“.highlights”===e){var r=document.querySelector(“#pagelet_newrecommend”);return void(r&&r.parentNode.insertBefore(n,r))}if(“.recommend-bangumis”===e){var l=document.querySelector(“#pagelet_newcomment”);return void(l&&l.parentNode.insertBefore(n,l))}if(“.bangumi-list”===e){var s=document.querySelector(“#pagelet_partlist”);return void(s&&s.parentNode.insertBefore(n,s))}}}else a&&a.parentNode.removeChild(a);”.video-description”===e&&i.player&&i.player.danmaku&&i.player.danmaku.list&&(document.querySelector(i.categoryInfo.danmakuSelector).innerHTML=utils.parsePts(i.player.danmaku.list.length))}))},t.pipe=function(e){var t=this,i=e.id,n=e.container,a=e.preLoad,o=e.pathName,r=e.loaded,l=e.pipeCb;if(o=o||location.pathname,a){var s=ls.getItem(o);if(s){var d=s.playUrl,c=s.playedSeconds;return void(this.player&&(this.player.preload(d,c),console.log(“preload video”,o)))}}var u=function(e){if(!/videoInfo/.test(i))return!0;var n=t.player;try{var l=document.createElement(“div”);l.innerHTML=e.html;var s=l.querySelector(“script.videoInfo”).innerHTML,d=s.slice(s.indexOf(“{“));if((d=JSON.parse(d))&&!d.playErrorCode){var c=d.currentVideoInfo;if(!c)return;var u=utils.analysisUrl(d.currentVideoInfo),p=0,m=c.userPlayedSeconds,y=c.durationMillis&&c.durationMillis/1e3;y&&m>5&&m+53&&(d.scrollTop=44*(p-2))}}l&&l()}},”quickView”)}},t.preloadVideos=function(){“v”===this.pageType&&this.preloadRecommend(),this.preloadNextVideo()},t.preloadNextVideo=function(){var e=this.pageType,t=null;if(“v”===e){var i=document.querySelector(“.single-p.active”);t=i&&i.nextSibling}else if(“bangumi”===e){var n=document.querySelector(“.container ul.active li.play”);t=n&&n.nextSibling}if(t){var a=t.getAttribute(“data-href”);this.preLoad(a)}},t.preloadRecommend=function(){var e=this;this.preloadRecommendTimer&&clearTimeout(this.preloadRecommendTimer),this.preloadRecommendTimer=setTimeout((function(){for(var t=document.querySelectorAll(“.recommendation figure”),i=0;i0?location.hash.match(/album=(d+)+/)[1]:0),p={req_id:weblog.impr.getCurrentReqID(),group_id:weblog.impr.getCurrentGroupID(),atom_id:String(l),ac_id:String(s),album_id:String(u),resourceTypeCode:e.resourceTypeCode,playedSeconds:r,videoId:+(l||0),reportIdName:+c,resourceType:o,bangumiItemId:this.bangumiItemId};p[d]=+c,window.weblog&&weblog.sendImmediately(“CLIENT_BROWSE_HISTORY”,p)}},t.switchLog=function(e){var t=e||this,i=t.lastVid,n=t.lastBangumiId,a=t.vid,o=t.bangumiId,r=”v”===this.pageType?”resourceDetail”:”bangumiDetail”,l=this.switchVideoSTime,s=this.switchVideoETime;if(l&&s){var d=s-l;d>=0&&d

1

0

5

喂红烧牛肉面食 0 香蕉

分享

分享本视频给朋友吧

扫一扫

分享到微信/朋友圈

手机看

手机扫码观看视频

扫一扫手机继续观看

展开



Source

Leave a Reply