From bcfa69c3246ad421ea5c02a07baf2a2b8a48e7a0 Mon Sep 17 00:00:00 2001 From: isisadmin Date: Fri, 4 Dec 2015 01:06:13 +0100 Subject: [PATCH] search panel controllet bug fix --- controllets/search-panel-controllet/search-panel-controllet.html | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/controllets/search-panel-controllet/search-panel-controllet.html b/controllets/search-panel-controllet/search-panel-controllet.html index 9cf7210..f7b4519 100755 --- a/controllets/search-panel-controllet/search-panel-controllet.html +++ b/controllets/search-panel-controllet/search-panel-controllet.html @@ -169,12 +169,9 @@ Example: * @param {Event} e */ _valueChanged : function(oldvalue, newValue){ - if(newValue != undefined) - { - clearTimeout(this.timer); - this.timer = setTimeout(this.fire('search-panel-controllet_content-changed', {searchKey: this.searchKey, id : this.id}), 500); - //this.fire('search-panel-controllet_content-changed', {searchKey: this.searchKey, id: this.id}); - } + var t = this; + clearTimeout(this.timer); + this.timer = setTimeout(function(){t.fire('search-panel-controllet_content-changed', {searchKey: t.searchKey, id : t.id})}, 500); }, /** * It returns the value in text area -- libgit2 0.21.4