I tried sending this message with RoundCube, but I don't think the attachment was working. Anyway, this patch changes the control-select and shift-select behavior for lists to emulate that of standard windows applications (or at least Outlook and Thunderbird which is what I tested it against). Please give it a try and let me know how it turns out. Also let me know if any further steps need to be taken to have this patch considered for merge into the main code.
-Charles
2006/1/16, popquizh@popquizhotshot.com popquizh@popquizhotshot.com:
I tried sending this message with RoundCube, but I don't think the attachment was working. Anyway, this patch changes the control-select and shift-select behavior for lists to emulate that of standard windows applications (or at least Outlook and Thunderbird which is what I tested it against). Please give it a try and let me know how it turns out. Also let me know if any further steps need to be taken to have this patch considered for merge into the main code.
have tested this patch, works perfect with firefox
-Charles
-- Begzudin Omerovic
www.oglasi.com - najveci izbor nekretnina na Balkanu !!!!
Glad to hear it, I've made one further change to allow the seldom-used control-shift-click behavior which works like shift select but which doesn't unselect anything (try it in outlook or thunderbird). I'll post that patch tonight.
-Charles
On Tue, 17 Jan 2006 12:58:33 +0100, Begzudin Omerovic begzudin.omerovic@gmail.com wrote:
2006/1/16, popquizh@popquizhotshot.com popquizh@popquizhotshot.com:
I tried sending this message with RoundCube, but I don't think the attachment was working. Anyway, this patch changes the control-select and shift-select behavior for lists to emulate that of standard windows applications (or at least Outlook and Thunderbird which is what I tested it against). Please give it a try and let me know how it turns out. Also let me know if any further steps need to be taken to have this patch considered for merge into the main code.
have tested this patch, works perfect with firefox
-Charles
-- Begzudin Omerovic
www.oglasi.com - najveci izbor nekretnina na Balkanu !!!!
Here is the promised patch for control-shift-click on lists (in addition to the other changes with shift-click and control-click). I'd never even heard of control-shift-click behavior until I started playing around with this, but it's only a change to a couple of lines of code over the previous patch, so I figured might as well.
-Charles
Charles McNulty wrote:
Glad to hear it, I've made one further change to allow the seldom-used control-shift-click behavior which works like shift select but which doesn't unselect anything (try it in outlook or thunderbird). I'll post that patch tonight.
-Charles
On Tue, 17 Jan 2006 12:58:33 +0100, Begzudin Omerovic begzudin.omerovic@gmail.com wrote:
2006/1/16, popquizh@popquizhotshot.com popquizh@popquizhotshot.com:
I tried sending this message with RoundCube, but I don't think the attachment was working. Anyway, this patch changes the control-select and shift-select behavior for lists to emulate that of standard windows applications (or at least Outlook and Thunderbird which is what I tested it against). Please give it a try and let me know how it turns out. Also let me know if any further steps need to be taken to have this patch considered for merge into the main code.
have tested this patch, works perfect with firefox
-Charles
-- Begzudin Omerovic
www.oglasi.com - najveci izbor nekretnina na Balkanu !!!!
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 17 Jan 2006 02:10:41 -0000 @@ -13,6 +13,9 @@ $Id: app.js,v 1.27 2006/01/13 17:14:38 roundcube Exp $ */
+const CONTROL_KEY = 1; +const SHIFT_KEY = 2; +const CONTROL_SHIFT_KEY = 3;
var rcube_webmail_client;
@@ -997,11 +1000,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 +1039,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 +1048,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 +1171,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 +1188,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 +2869,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();
Great !! Nice work !! Thanks ..
Nicolas
-----Message d'origine----- De : Charles McNulty [mailto:charles@charlesmcnulty.com] Envoyé : mercredi 18 janvier 2006 03:18 À : dev@lists.roundcube.net Objet : Re: shift-select and control-select patch
Here is the promised patch for control-shift-click on lists (in addition to the other changes with shift-click and control-click). I'd never even heard of control-shift-click behavior until I started playing around with this, but it's only a change to a couple of lines of code over the previous patch, so I figured might as well.
-Charles
Charles McNulty wrote:
Glad to hear it, I've made one further change to allow the seldom-used control-shift-click behavior which works like shift select but which doesn't unselect anything (try it in outlook or thunderbird). I'll post that patch tonight.
-Charles
On Tue, 17 Jan 2006 12:58:33 +0100, Begzudin Omerovic
begzudin.omerovic@gmail.com wrote:
2006/1/16, popquizh@popquizhotshot.com popquizh@popquizhotshot.com:
I tried sending this message with RoundCube, but I don't think the attachment was working. Anyway, this patch changes the control-select and shift-select behavior for lists to emulate that of standard windows applications (or at least Outlook and Thunderbird which is what I tested it against). Please give it a try and let me know
how it turns out.
Also let me know if any further steps need to be taken to have this patch considered for merge into the main code.
have tested this patch, works perfect with firefox
-Charles
-- Begzudin Omerovic
www.oglasi.com - najveci izbor nekretnina na Balkanu !!!!
Fixed bug with Internet Explorer. Firefox doesn't mind const, but IE chokes on it. My bad. Who uses IE anyway :)
-Charles
PS. This is the code that allows you to use shift-click, control-click or shift-control-click on message lists, and makes it behave the exact same way as Outlook and Thunderbird.
PPS. In answer to the person that asked how you apply patches, you simply put the patch file in the same directory as the file you want to patch and then type:
patch app.js app.js.patch
from a command line.
-----Message d'origine----- De : Charles McNulty [mailto:charles@charlesmcnulty.com] Envoyé : mercredi 18 janvier 2006 03:18 À : dev@lists.roundcube.net Objet : Re: shift-select and control-select patch
Here is the promised patch for control-shift-click on lists (in addition to the other changes with shift-click and control-click). I'd never even heard of control-shift-click behavior until I started playing around with this, but it's only a change to a couple of lines of code over the previous patch, so I figured might as well.
-Charles
Charles McNulty wrote:
Glad to hear it, I've made one further change to allow the seldom-used control-shift-click behavior which works like shift select but which doesn't unselect anything (try it in outlook or thunderbird). I'll post that patch tonight.
-Charles
On Tue, 17 Jan 2006 12:58:33 +0100, Begzudin Omerovic
begzudin.omerovic@gmail.com wrote:
2006/1/16, popquizh@popquizhotshot.com popquizh@popquizhotshot.com:
I tried sending this message with RoundCube, but I don't think the attachment was working. Anyway, this patch changes the control-select and shift-select behavior for lists to emulate that of standard windows applications (or at least Outlook and Thunderbird which is what I tested it against). Please give it a try and let me
know how it turns out.
Also let me know if any further steps need to be taken to have this patch considered for merge into the main code.
have tested this patch, works perfect with firefox
-Charles
-- Begzudin Omerovic
www.oglasi.com - najveci izbor nekretnina na Balkanu !!!!