From d6f0e829fb8f2bd1783f2cc4b64ece322b2e2620 Mon Sep 17 00:00:00 2001 From: suVene Date: Thu, 18 Dec 2008 13:34:41 +0000 Subject: * add subject_weather_yahoo.js. * observer_growl.js のオプション設定. * css微調整. * etc. git-svn-id: http://svn.coderepos.org/share/lang/javascript/vimperator-plugins/trunk@27023 d0d07461-0603-4401-acd4-de1884942a52 --- notifier.js | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'notifier.js') diff --git a/notifier.js b/notifier.js index 1ea68af..459189d 100644 --- a/notifier.js +++ b/notifier.js @@ -2,14 +2,14 @@ var PLUGIN_INFO = {NAME} - notice of change framework. + change notice framework. 変更通知フレームワーク。 suVene 0.1.2 2.0pre 2.0pre + ]]> ; //}}} (function() { @@ -259,14 +259,16 @@ function bootstrap() { var parsed, diff; if (typeof this.parse == 'function') parsed = this.parse(res); if (parsed && typeof this.diff == 'function') diff = this.diff(this.cache, parsed); - if (diff && (typeof diff.length != 'undefined' && diff.length > 0)) { + if (diff && + (typeof diff.length == 'undefined' || + (typeof diff.length != 'undefined' && diff.length > 0))) { this.cache = parsed; if (typeof this.buildMessages == 'function') { let messages = this.buildMessages(diff); - [].concat(messages).forEach($U.bind(this, function(m) { + [].concat(messages).forEach(function(m) { this.notify(m); liberator.sleep(1500); - })); + }, this); } } })); -- cgit v1.2.3