From ee197271dfe2709684e910cc67ddeed3b3975464 Mon Sep 17 00:00:00 2001 From: anekos Date: Wed, 30 Jul 2008 11:32:00 +0000 Subject: 使っていない関数を削除 getElements?ByXPath git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@16885 d0d07461-0603-4401-acd4-de1884942a52 --- auto_detect_link.js | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) (limited to 'auto_detect_link.js') diff --git a/auto_detect_link.js b/auto_detect_link.js index c6156a0..e5b3e30 100644 --- a/auto_detect_link.js +++ b/auto_detect_link.js @@ -2,7 +2,7 @@ // @name Auto Detect Link // @description-ja (次|前)っぽいページへのリンクを探してジャンプ // @license Creative Commons 2.1 (Attribution + Share Alike) -// @version 1.0.1 +// @version 1.0.2 // ==/VimperatorPlugin== // // Usage: @@ -238,23 +238,6 @@ } - // XPath - function getElementByXPath (xpath, root) { - let res = content.document.evaluate(xpath, root, null, XPathResult.FIRST_ORDERED_NODE_TYPE, null); - if (res) - return res.singleNodeValue; - } - - - // XPath - function getElementsByXPath (xpath, root) { - let result = [], res = content.document.evaluate(xpath, root, null, 7, null); - for (let i = 0; i < res.snapshotLength; i++) - result.push(res.snapshotItem(i)); - return result; - } - - // リンクのフィルタ function linkFilter (link) { return link.href && !link.href.match(/@/) && link.href.match(/^((https?|file|ftp):\/\/|javascript:)/) && link.textContent; -- cgit v1.2.3