ChatBuffer-KeyUp: Suppress browser's default behavior; leave cursor at the end of...
authorNoxx <noxx@penya.de>
Tue, 14 May 2013 20:07:02 +0000 (22:07 +0200)
committerNoxx <noxx@penya.de>
Tue, 14 May 2013 20:07:02 +0000 (22:07 +0200)
client/assets/dev/view.js

index b563604f3039341d8cb1324c826e97e0e345121d..8fb70b241bf46184818e40d0abb23483e532a466 100644 (file)
@@ -1016,7 +1016,8 @@ _kiwi.view.ControlBox = Backbone.View.extend({
                 this.buffer_pos--;\r
                 inp.val(this.buffer[this.buffer_pos]);\r
             }\r
-            break;\r
+            //suppress browsers default behavior as it would set the coursor at the beginning)\r
+            return false;\r
 \r
         case (ev.keyCode === 40):              // down\r
             if (this.buffer_pos < this.buffer.length) {\r