From e6b21256de611a42ed4aaaa07d36286a13997b00 Mon Sep 17 00:00:00 2001 From: Vladimir Prieto Date: Tue, 25 Feb 2014 17:21:39 -0300 Subject: [PATCH] add autoHide dealy option by default no autoHide --- Source/FloatingTips.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Source/FloatingTips.js b/Source/FloatingTips.js index e3c56e8..31cfcbf 100644 --- a/Source/FloatingTips.js +++ b/Source/FloatingTips.js @@ -41,7 +41,8 @@ var FloatingTips = new Class({ className: 'floating-tip', identifier: '', offset: { x: 0, y: 0 }, - fx: { 'duration': 'short' } + fx: { 'duration': 'short' }, + autoHide: 0 }, /** @@ -104,6 +105,8 @@ var FloatingTips = new Class({ this._animate(tip, 'in'); element.store('floatingtip_visible', true); this.fireEvent('show', [tip, element]); + if (this.options.autoHide > 0) + this.hide.delay(this.options.autoHide,this,element); return this; },