From 8cfbc47e895becc0af66d736ce5cc2bd7946feed Mon Sep 17 00:00:00 2001
From: alecpl <alec@alec.pl>
Date: Tue, 05 Oct 2010 03:20:27 -0400
Subject: [PATCH] - Fix keyboard doesn't work with autocomplete list with Chrome (#1487029)

---
 program/js/app.js |    7 +++----
 1 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/program/js/app.js b/program/js/app.js
index 83a6df2..3a2cb08 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -2768,9 +2768,8 @@
 
   this.init_address_input_events = function(obj)
   {
-    var handler = function(e){ return ref.ksearch_keypress(e,this); };
-    obj.bind((bw.safari || bw.ie ? 'keydown' : 'keypress'), handler);
-    obj.attr('autocomplete', 'off');
+    obj.keydown(function(e){ return ref.ksearch_keydown(e, this); })
+      .attr('autocomplete', 'off');
   };
 
   // checks the input fields before sending a message
@@ -3278,7 +3277,7 @@
   /*********************************************************/
 
   // handler for keyboard events on address-fields
-  this.ksearch_keypress = function(e, obj)
+  this.ksearch_keydown = function(e, obj)
   {
     if (this.ksearch_timer)
       clearTimeout(this.ksearch_timer);

--
Gitblit v1.9.1