|
6 | 6 | // @description Powerful picture viewing tool online, which can popup/scale/rotate/batch save pictures or find the HD original picture automatically |
7 | 7 | // @description:zh-CN NLF 的围观图修改版,增加高清原图查找显示(在线看图工具,支持图片翻转、旋转、缩放、弹出大图、批量保存、查找原图) |
8 | 8 | // @description:zh-TW NLF 的圍觀圖修改版,增加高清原圖查詢顯示(線上看圖工具,支援圖片翻轉、旋轉、縮放、彈出大圖、批量儲存、查詢原圖) |
9 | | -// @version 2017.4.2.3 |
| 9 | +// @version 2017.4.8.1 |
10 | 10 | // @created 2011-6-15 |
11 | 11 | // @namespace http://userscripts.org/users/NLF |
12 | 12 | // @homepage http://hoothin.com |
@@ -7137,10 +7137,10 @@ background-image:url("'+ prefs.icons.magnifier +'");\ |
7137 | 7137 |
|
7138 | 7138 | if (this.data.img.nodeName != 'IMG') { |
7139 | 7139 | this.buttons['gallery'].style.display = 'none'; |
7140 | | - this.buttons['current'].style.display = 'none'; |
| 7140 | + //this.buttons['current'].style.display = 'none'; |
7141 | 7141 | } else { |
7142 | 7142 | this.buttons['gallery'].style.removeProperty('display'); |
7143 | | - this.buttons['current'].style.removeProperty('display'); |
| 7143 | + //this.buttons['current'].style.removeProperty('display'); |
7144 | 7144 | } |
7145 | 7145 | }, |
7146 | 7146 | setPosition:function(){ |
@@ -7981,8 +7981,18 @@ background-image:url("'+ prefs.icons.magnifier +'");\ |
7981 | 7981 | // } |
7982 | 7982 | // } |
7983 | 7983 | // } |
7984 | | - if (target.nodeName != 'IMG'){ |
7985 | | - if(target.children.length==1 && target.children[0].tagName=="IMG"){ |
| 7984 | + if (target.nodeName != 'IMG' && target.className.indexOf("pv-float-bar")==-1){ |
| 7985 | + var targetStyle=getComputedStyle(target); |
| 7986 | + if(targetStyle.backgroundImage && targetStyle.backgroundImage!="none" && targetStyle.backgroundImage!="inherit" && targetStyle.width.replace("px","")>prefs.floatBar.minSizeLimit.w && targetStyle.height.replace("px","")>prefs.floatBar.minSizeLimit.h){ |
| 7987 | + var src=targetStyle.backgroundImage.replace(/url\(["'](.*)["']\)/,"$1"); |
| 7988 | + result = { |
| 7989 | + src: src, |
| 7990 | + type: "scale", |
| 7991 | + imgSrc: src, |
| 7992 | + noActual:true, |
| 7993 | + img: target |
| 7994 | + }; |
| 7995 | + }else if(target.children.length==1 && target.children[0].tagName=="IMG"){ |
7986 | 7996 | target=target.children[0]; |
7987 | 7997 | }else if(target.parentNode){ |
7988 | 7998 | if(target.parentNode.nodeName=='IMG'){ |
|
0 commit comments