From fff77a2e8c4775b639bd7de89712a6e1678908f7 Mon Sep 17 00:00:00 2001
From: suVene
Date: Mon, 15 Dec 2008 11:53:31 +0000
Subject: clear cache. follow pluginManager
git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@26801 d0d07461-0603-4401-acd4-de1884942a52
---
nextlink.js | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
(limited to 'nextlink.js')
diff --git a/nextlink.js b/nextlink.js
index 82c5fc2..d2ed69e 100644
--- a/nextlink.js
+++ b/nextlink.js
@@ -5,24 +5,24 @@ var PLUGIN_INFO =
mapping "[[", "]]" by AutoPagerize XPath.
AutoPagerize 用の XPath より "[[", "]]" をマッピングします。
suVene
- 0.2.3
+ 0.2.4
1.2
2.0pre
||
+ let g:nextlink_followlink = "true"
+||<
と設定することにより、"[[", "]]" の動作は、カレントのタブに新しくページを読み込むようになります。
== Command ==
-:nextlink
- autocmd によって呼び出されます。
+:nextlink:
+ autocmd によって呼び出されます。
-== TODO ==
-- document cache clear.
]]>
;
//}}}
@@ -104,7 +104,6 @@ liberator.plugins.nextlink = (function() {
$U.bind(this, function(args) { this.handler(args); }), null, true
);
var loadEvent = autocommands['DOMLoad'] || 'PageLoad'; // for 1.2
-logger.log('event:' + loadEvent + (this.is2_0later ? 'DOMLoad' : 'PageLoad') );
liberator.execute(':autocmd! ' + (this.is2_0later ? 'DOMLoad' : 'PageLoad') + ' .* :nextlink onLoad');
liberator.execute(':autocmd! LocationChange .* :nextlink onLocationChange');
},
@@ -124,6 +123,8 @@ logger.log('event:' + loadEvent + (this.is2_0later ? 'DOMLoad' : 'PageLoad') );
for (let i = 0, len = this.siteinfo.length; i < len; i++) {
if (url.match(this.siteinfo[i].url) && this.siteinfo[i].url != '^https?://.') {
+ window.content.addEventListener('unload', $U.bind(this,
+ function() { this.cache[url] = null; }), false);
this.setCache(url,
['doc', 'xpath', 'siteinfo'],
[window.content.document, this.siteinfo[i].nextLink, this.siteinfo[i]]
--
cgit v1.2.3