From abec0de2782d6198d168d27851e95f542f9c5a9b Mon Sep 17 00:00:00 2001 From: xiu2 <54703944+XIU2@users.noreply.github.com> Date: Sun, 10 Apr 2022 18:12:53 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=20[=E7=82=B9=E5=87=BB?= =?UTF-8?q?=E7=9B=B4=E6=8E=A5=E4=B8=8B=E8=BD=BD=E6=96=87=E4=BB=B6]=20?= =?UTF-8?q?=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Lanzou-Enhanced.user.js | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Lanzou-Enhanced.user.js b/Lanzou-Enhanced.user.js index a1fc179..9363e93 100644 --- a/Lanzou-Enhanced.user.js +++ b/Lanzou-Enhanced.user.js @@ -1,6 +1,6 @@ // ==UserScript== // @name 蓝奏云网盘增强 -// @version 1.4.0 +// @version 1.4.1 // @author X.I.U // @description 刷新不回根目录、后退返回上一级、右键文件显示菜单、点击直接下载文件、点击空白进入目录、自动显示更多文件、一键复制所有分享链接、自定义分享链接域名、自动打开/复制分享链接、带密码的分享链接自动输密码、拖入文件自动显示上传框、输入密码后回车确认、调整描述(话说)编辑框初始大小 // @include /^https:\/\/.+\.lanzou[a-z]\.com\/.*$/ @@ -284,9 +284,11 @@ iframe = iframe.contentWindow; let timer = setInterval(function(){ if (iframe.document.querySelector('#go a[href]')) { - GM_openInTab(iframe.document.querySelector('#go a[href]').href, {active: false, insert: true, setParent: false}); // 后台打开 - window.top.close(); // 关闭该后台标签页 + iframe.document.querySelector('#go a[href]').target = '_top' + iframe.document.querySelector('#go a[href]').click(); + //GM_openInTab(iframe.document.querySelector('#go a[href]').href, {active: false, insert: true, setParent: false}); // 后台打开 clearInterval(timer); + setTimeout(function(){window.top.close();},200)// 关闭该后台标签页 } }, 10); }