Skip to content

Commit 83a0507

Browse files
committed
fix
1 parent b2dcfa1 commit 83a0507

1 file changed

Lines changed: 10 additions & 4 deletions

File tree

VIP Video Cracker/VIP Video Cracker.user.js

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
var cracks=[
4343
{name:"47影视云",url:"http://api.47ks.com/webcloud/?v=%s"},
4444
{name:"疯狂解析",url:"http://vip.ifkdy.com/?url=%s"},
45+
{name:"小海解析",url:"https://ckplaer.duapp.com/hai.php?url=%s"},
4546
{name:"无名小站1",url:"http://www.wmxz.wang/video.php?url=%s"},
4647
{name:"无名小站2",url:"http://www.sfsft.com/admin.php?url=%s"},
4748
{name:"71ki解析",url:"http://jx.71ki.com/tong.php?url=%s"},
@@ -91,7 +92,7 @@
9192
select.onchange=function(){
9293
var value=select.options[select.options.selectedIndex].value;
9394
if(value){
94-
window.open(value.replace("%s",location.href));
95+
window.open(value.replace("%s",(iqiyi?decodeURIComponent(document.querySelector(".sns-icon>li>a").href.replace(/.*url=(.*)%3Fsrc.*/,"$1")):location.href.replace(/#.*/,""))));
9596
if(value=="https://greasyfork.org/scripts/23316/code/hacg.user.js"){
9697
GM_setValue("hacgGodTurnVisited",true);
9798
select.options.remove(select.options.selectedIndex);
@@ -109,7 +110,6 @@
109110
quickAccess.innerHTML="<input type='checkbox'>立即跳转";
110111
var jumpCheck=quickAccess.querySelector("input");
111112
jumpCheck.onclick=function(){
112-
if(iqiyi)jumpCheck.checked=false;
113113
vipVideoCrackJump=jumpCheck.checked;
114114
GM_setValue("vipVideoCrackJump",vipVideoCrackJump);
115115
crackJump();
@@ -120,8 +120,9 @@
120120
crackArea.appendChild(quickAccess);
121121
function crackJump(){
122122
if(vipVideoCrackJump){
123+
console.log(value);
123124
var value=vipVideoCrackUrl?vipVideoCrackUrl:cracks[0].url;
124-
GM_openInTab(value.replace("%s",location.href),false);
125+
GM_openInTab(value.replace("%s",(iqiyi&&document.querySelector(".sns-icon>li>a")?decodeURIComponent(document.querySelector(".sns-icon>li>a").href.replace(/.*url=(.*)%3Fsrc.*/,"$1")):location.href.replace(/#.*/,""))),false);
125126
if(video.parentNode && !iqiyi)video.parentNode.replaceChild(placeholder,video);
126127
}
127128
}
@@ -139,7 +140,7 @@
139140
var videoParent=video.parentNode;
140141
videoParent.appendChild(crackArea);
141142
placeholder.style.lineHeight=getComputedStyle(videoParent).height;
142-
if(vipVideoCrackJump && !iqiyi){
143+
if(vipVideoCrackJump){
143144
jumpCheck.checked=true;
144145
}
145146
crackJump();
@@ -153,6 +154,11 @@
153154
setTimeout(function(){crackJump();},1);
154155
return replaceState.apply(history, arguments);
155156
};
157+
if(iqiyi){
158+
unsafeWindow.addEventListener("hashchange",function(){
159+
crackJump();
160+
});
161+
}
156162
}else{
157163
//console.log("no player!");
158164
}

0 commit comments

Comments
 (0)