From 4e4c2511bc00cfc0214acab63b097efe142187a7 Mon Sep 17 00:00:00 2001
From: Thomas B. <thomas@roundcube.net>
Date: Thu, 24 Oct 2013 16:52:39 -0400
Subject: [PATCH] Merge pull request #143 from cmcnulty/#1489392---fix-control+arrow-behavior

---
 program/js/list.js |   11 +++++------
 1 files changed, 5 insertions(+), 6 deletions(-)

diff --git a/program/js/list.js b/program/js/list.js
index cb69bc4..33f88ab 100644
--- a/program/js/list.js
+++ b/program/js/list.js
@@ -456,12 +456,11 @@
 
   var dblclicked = now - this.rows[id].clicked < this.dblclick_time;
 
-  // unselects currently selected row
-  if (!this.drag_active && this.in_selection_before == id && !dblclicked)
-    this.select_row(id, mod_key, false);
-
+  // selects/unselects currently selected row
+  if (!this.drag_active && !dblclicked)
+    this.select_row(id, mod_key, true);
+    
   this.drag_start = false;
-  this.in_selection_before = false;
 
   // row was double clicked
   if (this.rowcount && dblclicked && this.in_selection(id)) {
@@ -787,7 +786,7 @@
         break;
 
       case CONTROL_KEY:
-        if (!with_mouse)
+        if (with_mouse)
           this.highlight_row(id, true);
         break;
 

--
Gitblit v1.9.1