diff --git a/SrcJyMenu.js b/SrcJyMenu.js
index 29d38a8f..2339510b 100644
--- a/SrcJyMenu.js
+++ b/SrcJyMenu.js
@@ -49,10 +49,7 @@ function erjimenu(desc) {
},
{
title: "切换站源",
- url: !fileExist('hiker://files/rules/Src/Juying/jiekou.json') ? "toast://分享页面或没有接口,无法扩展更多片源" : getMyVar('SrcJy$back') == '1' ? `#noLoading#@lazyRule=.js:back(false);'hiker://empty'` : $('hiker://empty#noRecordHistory##noHistory#').rule((name) => {
- require(config.依赖.match(/http(s)?:\/\/.*\//)[0] + 'SrcJyXunmi.js');
- xunmi(name);
- }, MY_PARAMS.name),
+ url: !fileExist(jxfile) ? "toast://分享页面或没有接口,无法扩展更多片源" : "toast://暂未上线",
pic_url: 'https://hikerfans.com/tubiao/messy/20.svg',
col_type: 'icon_small_3'
}
@@ -61,115 +58,47 @@ function erjimenu(desc) {
function lookset() {
- function getide(is) {
- if (is == 1) {
- return '‘‘’’◉ ';
- } else {
- return '‘‘’’◉ ';
- }
- }
- function setupPages(type) {
- switch (type) {
- case "设置":
- return $("hiker://empty#noRecordHistory#").rule(() => {
- setPageTitle("断插配置");
- this.d = [];
- d.push({
- desc: 'auto',
- url: 'file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/cache/Parse_Dn.html',
- col_type: 'x5_webview_single'
- });
- setResult(d);
- })
- break;
- case "编辑":
- return $("hiker://empty#noRecordHistory#").rule(() => {
- setPageTitle("解析管理");
- this.d = [];
- require('https://hikerfans.com/js/jxItem.js');
- jxList();
- setResult(d);
- })
- break;
- default:
- return 'toast://需要传入正确参数'
- break;
- }
- }
setPageTitle("♥观影设置");
- var d = [];
- var cfgfile = "hiker://files/rules/Src/Juying/config.json";
- var Juyingcfg = fetch(cfgfile);
- if (Juyingcfg != "") {
- eval("var JYconfig=" + Juyingcfg + ";");
- } else {
- var JYconfig = {};
+ let recordfile = "hiker://files/rules/Src/Juying2/parse.json";//解析相关记录文件
+ let parseRecord = {};
+ if(fetch(recordfile)){
+ try{
+ eval("parseRecord =" + fetch(recordfile) + ";");
+ }catch(e){}
}
- putMyVar('superwebM3U8', JYconfig.cachem3u8 != 0 && JYconfig.superweb == 1 ? '1' : '0');
+
+ let d = [];
+
d.push({
title: '功能开关',
col_type: "rich_text"
});
d.push({
- title: (JYconfig['printlog'] == 1 ? getide(1) : getide(0)) + '打印日志',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- if (JYconfig['printlog'] != 1) {
- JYconfig['printlog'] = 1;
+ title: (parseRecord['printlog'] == 1 ? getide(1) : getide(0)) + '解析日志',
+ url: $('#noLoading#').lazyRule((parseRecord, recordfile) => {
+ if (parseRecord['printlog'] != 1) {
+ parseRecord['printlog'] = 1;
} else {
- JYconfig['printlog'] = 0;
+ parseRecord['printlog'] = 0;
}
- writeFile(cfgfile, JSON.stringify(JYconfig));
+ writeFile(recordfile, JSON.stringify(parseRecord));
refreshPage(false);
return 'toast://切换成功';
- }, JYconfig, cfgfile),
+ }, parseRecord, recordfile),
col_type: "text_2"
});
d.push({
- title: (JYconfig['cachem3u8'] != 0 ? getide(1) : getide(0)) + 'm3u8缓存',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- if (JYconfig['cachem3u8'] == 0) {
- JYconfig['cachem3u8'] = 1;
- putMyVar('SrcM3U8', '1');
+ title: (parseRecord['cachem3u8'] != 0 ? getide(1) : getide(0)) + 'm3u8缓存',
+ url: $('#noLoading#').lazyRule((parseRecord, recordfile) => {
+ if (parseRecord['cachem3u8'] == 0) {
+ parseRecord['cachem3u8'] = 1;
} else {
- JYconfig['cachem3u8'] = 0;
- putMyVar('SrcM3U8', '0');
+ parseRecord['cachem3u8'] = 0;
}
- writeFile(cfgfile, JSON.stringify(JYconfig));
+ writeFile(recordfile, JSON.stringify(parseRecord));
refreshPage(false);
return 'toast://切换成功';
- }, JYconfig, cfgfile),
- col_type: "text_2"
- });
- d.push({
- title: (JYconfig['yundiskLine'] == 1 ? getide(1) : getide(0)) + '云盘搜索',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- if (JYconfig['yundiskLine'] != 1) {
- JYconfig['yundiskLine'] = 1;
- putMyVar('yundiskLine', '1');
- } else {
- JYconfig['yundiskLine'] = 0;
- putMyVar('yundiskLine', '0');
- }
- writeFile(cfgfile, JSON.stringify(JYconfig));
- refreshPage(false);
- return 'toast://' + (JYconfig['alistLine'] ? '已开启云盘搜索线路' : '已关闭云盘搜索线路');
- }, JYconfig, cfgfile),
- col_type: "text_2"
- });
- d.push({
- title: (JYconfig['alistLine'] == 1 ? getide(1) : getide(0)) + 'Alist搜索',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- if (JYconfig['alistLine'] != 1) {
- JYconfig['alistLine'] = 1;
- putMyVar('alistLine', '1');
- } else {
- JYconfig['alistLine'] = 0;
- putMyVar('alistLine', '0');
- }
- writeFile(cfgfile, JSON.stringify(JYconfig));
- refreshPage(false);
- return 'toast://' + (JYconfig['alistLine'] ? '已开启Alist搜索线路' : '已关闭Alist搜索线路');
- }, JYconfig, cfgfile),
+ }, parseRecord, recordfile),
col_type: "text_2"
});
d.push({
@@ -179,47 +108,35 @@ function lookset() {
title: '屏蔽操作',
col_type: "rich_text"
});
+
+
d.push({
title: '无效播放地址',
- url: $("", "屏蔽无法播放的地址").input(() => {
- var recordfile = "hiker://files/rules/Src/Juying/parse.json";
- var recordparse = fetch(recordfile);
- if (recordparse != "") {
- eval("var recordlist=" + recordparse + ";");
- } else {
- var recordlist = {};
- }
- recordlist['excludeurl'] = recordlist['excludeurl'] || [];
+ url: $("", "屏蔽无法播放的地址").input((parseRecord, recordfile) => {
+ parseRecord['excludeurl'] = parseRecord['excludeurl'] || [];
let url = input.split(';{')[0].replace('file:///storage/emulated/0/Android/data/com.example.hikerview/files/Documents/cache/video.m3u8##', '').replace('#isVideo=true#', '');
- if (recordlist['excludeurl'].indexOf(url) == -1) {
- recordlist['excludeurl'].push(url);
+ if (parseRecord['excludeurl'].indexOf(url) == -1) {
+ parseRecord['excludeurl'].push(url);
}
- writeFile(recordfile, JSON.stringify(recordlist));
+ writeFile(recordfile, JSON.stringify(parseRecord));
return 'toast://屏蔽无效播放地址成功';
- }),
+ }, parseRecord, recordfile),
col_type: "text_2"
});
d.push({
- title: '清除播放拦载记录',
- url: $("清除拦截无法播放地址记录?").confirm(() => {
- var recordfile = "hiker://files/rules/Src/Juying/parse.json";
- var recordparse = fetch(recordfile);
- if (recordparse != "") {
- eval("var recordlist=" + recordparse + ";");
- recordlist['excludeurl'] = [];
- writeFile(recordfile, JSON.stringify(recordlist));
- return 'toast://已清除跳舞小姐姐视频拦截记录';
- } else {
- return 'toast://无记录';
- }
- }),
+ title: '清空播放拦载记录',
+ url: $("清空拦截无法播放地址记录?").confirm((parseRecord, recordfile) => {
+ delete parseRecord['excludeurl'];
+ writeFile(recordfile, JSON.stringify(parseRecord));
+ return 'toast://无清空';
+ }, parseRecord, recordfile),
col_type: "text_2"
});
d.push({
col_type: "line"
});
- var parsefrom = [];
- var recordfile = "hiker://files/rules/Src/Juying/parse.json";
+ /*
+ let parsefrom = [];
var recordparse = fetch(recordfile);
if (recordparse != "") {
eval("var recordlist=" + recordparse + ";");
@@ -320,169 +237,89 @@ function lookset() {
d.push({
col_type: "line_blank"
});
+ */
d.push({
title: '解析设置',
col_type: "rich_text"
});
- let parsemode = JYconfig.parsemode || 1;
- if (fileExist('hiker://files/rules/DuanNian/MyParse.json') || JYconfig.dnfile) {
- var haveDN = 1
- var isdn = JYconfig.isdn == 0 ? 0 : 1;
- } else {
- var haveDN = 0
- var isdn = 0;
- };
+
+ parseRecord, recordfile
+ let parsemode = parseRecord.parsemode || 1;
d.push({
- title: '当前解析模式:' + (parsemode == 1 ? '聚影智能' : parsemode == 2 ? '强制断插' : parsemode == 3 ? '强制嗅探' : '手动模式'),
- desc: parsemode == 1 ? '上次优先>接口自带+私有解析' + (haveDN && isdn ? '+断插解析' : '') : parsemode == 2 ? '走断插(含魔断)或帅助手设置的解析逻辑' : parsemode == 3 ? '接口自带和私有解析中的直链进行聚合嗅探' : '先进播放器,再通过线路选择解析,无法在选集页下载,无法预加载',
+ title: '当前解析模式:' + (parsemode == 1 ? '聚影智能' : parsemode == 2 ? '强制嗅探' : parsemode == 3 ? '手动模式' : '异常'),
+ desc: parsemode == 1 ? '上次优先>接口自带+私有解析' : parsemode == 2 ? 'web解析使用video进行嗅探' : parsemode == 3 ? '使用代理播放模式,在播放页手动选择解析' : '',
url: 'hiker://empty',
col_type: "text_center_1"
});
d.push({
title: (parsemode == 1 ? getide(1) : getide(0)) + '聚影智能',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- JYconfig['parsemode'] = 1;
- writeFile(cfgfile, JSON.stringify(JYconfig));
+ url: $('#noLoading#').lazyRule((parseRecord, recordfile) => {
+ parseRecord['parsemode'] = 1;
+ writeFile(recordfile, JSON.stringify(parseRecord));
refreshPage(false);
return 'toast://解析模式:聚影智能';
- }, JYconfig, cfgfile),
+ }, parseRecord, recordfile),
col_type: "text_3"
});
d.push({
- title: (haveDN && isdn && parsemode == 1 ? getide(1) : getide(0)) + '断插辅助',
- url: haveDN == 0 ? 'toast://没有断插?无法开启!' : $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- if (JYconfig['isdn'] == 0) {
- JYconfig['isdn'] = 1;
- var sm = "开启断插同步并发解析";
- } else {
- JYconfig['isdn'] = 0;
- var sm = "断插辅助解析已关闭";
- }
- writeFile(cfgfile, JSON.stringify(JYconfig));
+ title: (parsemode == 2 ? getide(1) : getide(0)) + '强制嗅探',
+ url: $('#noLoading#').lazyRule((parseRecord, recordfile) => {
+ parseRecord['parsemode'] = 2;
+ writeFile(recordfile, JSON.stringify(parseRecord));
refreshPage(false);
- return 'toast://切换成功:' + sm;
- }, JYconfig, cfgfile),
+ return 'toast://解析模式:强制嗅探';
+ }, parseRecord, recordfile),
col_type: "text_3"
});
d.push({
- title: '📝解析文件',
- url: $(JYconfig.dnfile ? JYconfig.dnfile : "", "指定断插解析文件路径\n默认可以留空").input((JYconfig, cfgfile) => {
- JYconfig['dnfile'] = input;
- writeFile(cfgfile, JSON.stringify(JYconfig));
+ title: (parsemode == 3 ? getide(1) : getide(0)) + '手动切换',
+ url: $('#noLoading#').lazyRule((parseRecord, recordfile) => {
+ parseRecord['parsemode'] = 3;
+ writeFile(recordfile, JSON.stringify(parseRecord));
refreshPage(false);
- return 'toast://解析文件设置成功';
- }, JYconfig, cfgfile),
+ return 'toast://解析模式:手动切换';
+ }, parseRecord, recordfile),
col_type: "text_3"
});
d.push({
col_type: "line"
});
- d.push({
- title: (parsemode == 2 ? getide(1) : getide(0)) + '强制断插',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- JYconfig['parsemode'] = 2;
- writeFile(cfgfile, JSON.stringify(JYconfig));
+
+ d.push({
+ title: '嗅探内核:'+(parseRecord['xiutannh']||"web"),
+ url: $('#noLoading#').lazyRule((parseRecord, recordfile) => {
+ let sm;
+ if(parseRecord['xiutannh'] == 'x5'){
+ parseRecord['xiutannh'] = 'web';
+ sm = 'web';
+ }else{
+ parseRecord['xiutannh'] = 'x5';
+ sm = 'x5';
+ }
+ writeFile(recordfile, JSON.stringify(parseRecord));
refreshPage(false);
- return 'toast://解析模式:强制断插';
- }, JYconfig, cfgfile),
- col_type: "text_3"
- });
- d.push({
- title: '🍧断插配置',
- url: fetch('hiker://files/cache/Parse_Dn.js').indexOf('updateDate') == -1 ? setupPages("设置") : "hiker://page/Route?rule=MyFieldᴰⁿ&type=设置#noHistory#",
- col_type: "text_3"
- });
- d.push({
- title: '🍦解析管理',
- url: fetch('hiker://files/cache/Parse_Dn.js').indexOf('updateDate') == -1 ? setupPages("编辑") : "hiker://page/Route?rule=MyFieldᴰⁿ&type=编辑#noRecordHistory#",
+ return 'toast://嗅探内核切换为:'+sm;
+ }, parseRecord, recordfile),
col_type: "text_3"
});
+
d.push({
col_type: "line"
});
d.push({
- title: (parsemode == 3 ? getide(1) : getide(0)) + '强制嗅探',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- JYconfig['parsemode'] = 3;
- writeFile(cfgfile, JSON.stringify(JYconfig));
- refreshPage(false);
- return 'toast://解析模式:强制嗅探';
- }, JYconfig, cfgfile),
- col_type: "text_3"
- });
- d.push({
- title: (parsemode != 2 && JYconfig.xiutannh != 'x5' ? getide(1) : getide(0)) + 'web内核',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- JYconfig['xiutannh'] = 'web';
- writeFile(cfgfile, JSON.stringify(JYconfig));
- refreshPage(false);
- return 'toast://嗅探内核:web';
- }, JYconfig, cfgfile),
- col_type: "text_3"
- });
- d.push({
- title: (parsemode != 2 && JYconfig.xiutannh == 'x5' ? getide(1) : getide(0)) + 'x5内核',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- JYconfig['xiutannh'] = 'x5';
- writeFile(cfgfile, JSON.stringify(JYconfig));
+ title: (getItem('dmRoute', '0') == "1" ? getide(1) : getide(0)) + 'dm盒子弹幕:' + (getItem('dmRoute', '0') == "1" ? '开启' : '关闭'),
+ desc: '1.仅对官链有效,2.拥有dm盒子小程序-版本29+',
+ url: $('#noLoading#').lazyRule(() => {
+ if (getItem('dmRoute', '0') == "1") {
+ setItem('dmRoute', '0');
+ } else {
+ setItem('dmRoute', '1');
+ }
refreshPage(false);
- return 'toast://嗅探内核:x5';
- }, JYconfig, cfgfile),
- col_type: "text_3"
+ return 'toast://切换成功';
+ }),
+ col_type: "text_center_1"
});
- if ((MY_NAME == "海阔视界" && getAppVersion() >= 4094) || (MY_NAME == "嗅觉浏览器" && getAppVersion() >= 1359)) {
- d.push({
- title: (parsemode == 4 ? getide(1) : getide(0)) + '手动切换',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- JYconfig['parsemode'] = 4;
- writeFile(cfgfile, JSON.stringify(JYconfig));
- refreshPage(false);
- return 'toast://解析模式:手动切换';
- }, JYconfig, cfgfile),
- col_type: "text_3"
- });
- }
- if (parsemode != 4) {
- if ((MY_NAME == "海阔视界" && getAppVersion() >= 3369) || (MY_NAME == "嗅觉浏览器" && getAppVersion() >= 798)) {
- JYconfig['superweb'] = JYconfig.superweb == 0 ? 0 : 1;
- d.push({
- col_type: "line"
- });
- d.push({
- title: (JYconfig.superweb == 1 ? getide(1) : getide(0)) + '播放器超级嗅探:' + (JYconfig.superweb == 1 ? '开启' : '关闭'),
- desc: JYconfig.superweb == 1 ? '无法在选集页下载,无法预加载,但是可以多线路' : '普通模式先嗅探到播放地址再进播放器',
- url: $('#noLoading#').lazyRule((JYconfig, cfgfile) => {
- if (JYconfig['superweb'] == 1) {
- JYconfig['superweb'] = 0;
- } else {
- JYconfig['superweb'] = 1;
- }
- putMyVar('superweb', JYconfig['superweb']);
- writeFile(cfgfile, JSON.stringify(JYconfig));
- refreshPage(false);
- return 'toast://切换成功';
- }, JYconfig, cfgfile),
- col_type: "text_center_1"
- });
- }
- d.push({
- col_type: "line"
- });
- d.push({
- title: (getItem('dmRoute', '0') == "1" ? getide(1) : getide(0)) + 'dm盒子弹幕:' + (getItem('dmRoute', '0') == "1" ? '开启' : '关闭'),
- desc: '1.仅对官链有效,2.拥有dm盒子小程序-版本29+',
- url: $('#noLoading#').lazyRule(() => {
- if (getItem('dmRoute', '0') == "1") {
- setItem('dmRoute', '0');
- } else {
- setItem('dmRoute', '1');
- }
- refreshPage(false);
- return 'toast://切换成功';
- }),
- col_type: "text_center_1"
- });
- }
d.push({
col_type: "line_blank"
});