Sorry about that. I just retried it and got the same problems. Try this one. I created the one I sent earlier with cvs diff. This one was created with Tortoise with whatever default options it throws into the bag. This one works fine with the latest CVS (1.27 of app.js, I believe.) Good luck.
-Charles
Daniel Paquet wrote:
Is the patch work with a freshly cvs'ed source?
The patch is failing for me. With error
patching file app.js Hunk #3 FAILED at 1006. Hunk #5 FAILED at 1043. Hunk #6 FAILED at 1052. Hunk #7 succeeded at 1048 (offset -25 lines). Hunk #8 FAILED at 1053. Hunk #9 succeeded at 1064 (offset -111 lines). Hunk #10 succeeded at 1081 (offset -111 lines). Hunk #11 succeeded at 2762 (offset -111 lines). 4 out of 11 hunks FAILED -- saving rejects to file app.js.rej
RCS file: /cvsroot/roundcubemail/roundcubemail/program/js/app.js,v retrieving revision 1.27 diff -u -r1.27 app.js --- program/js/app.js 13 Jan 2006 17:14:38 -0000 1.27 +++ program/js/app.js 19 Jan 2006 05:23:23 -0000 @@ -13,6 +13,10 @@ $Id: app.js,v 1.27 2006/01/13 17:14:38 roundcube Exp $ */
+// Constants +var CONTROL_KEY = 1; +var SHIFT_KEY = 2; +var CONTROL_SHIFT_KEY = 3;
var rcube_webmail_client;
@@ -997,11 +1001,30 @@ if (this.dont_select) return false;
{
var ctrl = this.check_ctrlkey(e);
this.select(id, ctrl);
{
var mod_key = this.get_modifier(e);
if (!mod_key) {
this.select(id, false);
this.last_selected = id;
} else {
switch (mod_key) {
case SHIFT_KEY: { this.shift_select(id,false); break; }
case CONTROL_KEY: {
this.select(id, true);
this.last_selected = id;
break;
}
case CONTROL_SHIFT_KEY: { this.shift_select(id,true); break;}
default: {
this.select(id, false);
this.last_selected = id;
break;
}
}
}
}
if (this.selection.length) {
@@ -1017,7 +1040,7 @@ // onmouseup-handler of message list row this.click_row = function(e, id) {
var mod_key = this.get_modifier(e);
// don't do anything (another action processed before) if (this.dont_select)
@@ -1026,16 +1049,33 @@ return false; }
{
this.select(id, (shift && this.task!='settings'));
if (!mod_key) {
this.last_selected = id;
this.select(id, false);
} else {
switch (mod_key) {
case SHIFT_KEY: { this.shift_select(id,false); break; }
case CONTROL_KEY: {
this.last_selected = id;
this.select(id, (this.task!='settings'));
break;
}
case CONTROL_SHIFT_KEY: {this.shift_select(id,true);break;}
default: {
this.select(id, false);
this.last_selected = id;
break;
}
}
}
} this.drag_start = false; this.in_selection_before = false;
// row was double clicked
@@ -1132,7 +1172,6 @@ this.selection = a_pre.concat(a_post); this.set_classname(this.list_rows[id].obj, 'selected', false); }
selected = (this.selection.length==1);
}
@@ -1150,6 +1189,28 @@ };
+// select all rows from the last selected row to the current one, while deselecting all other rows
if ((this.list_rows[n].obj.rowIndex >= i) && (this.list_rows[n].obj.rowIndex <= j)) {
if (!this.in_selection(n))
this.select(n, true);
} else {
if (this.in_selection(n) && !control)
this.select(n, true);
}
@@ -2809,6 +2870,26 @@ return false; }
+// returns modifier key (constants defined at top of file)
opcode += (e.ctrlKey && CONTROL_KEY) + (e.shiftKey && SHIFT_KEY);
return opcode;
e.cancelBubble = true;
e.returnValue = false;
e.preventDefault();