summaryrefslogtreecommitdiff
path: root/program/js
diff options
context:
space:
mode:
authorthomascube <thomas@roundcube.net>2007-05-17 18:41:24 +0000
committerthomascube <thomas@roundcube.net>2007-05-17 18:41:24 +0000
commit41bece1a1adffb524daa2203dfb91211f63989d8 (patch)
tree7c1846c510c0b66bfe750f0bc87aca0fc48e1601 /program/js
parent5870871ae1f8a0f3b40436483a43cf3aafa35b2d (diff)
Add link to message subjects (#1484257); don't make selected list items bold; remove duplicate function
Diffstat (limited to 'program/js')
-rw-r--r--program/js/list.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/program/js/list.js b/program/js/list.js
index 719585893..23a9c349c 100644
--- a/program/js/list.js
+++ b/program/js/list.js
@@ -584,7 +584,7 @@ drag_mouse_move: function(e)
// get subjects of selectedd messages
var names = '';
- var c, subject, obj;
+ var c, node, subject, obj;
for(var n=0; n<this.selection.length; n++)
{
if (n>12) // only show 12 lines
@@ -599,10 +599,11 @@ drag_mouse_move: function(e)
subject = '';
for(c=0; c<obj.childNodes.length; c++)
- if (!subject && obj.childNodes[c].nodeName=='TD' && obj.childNodes[c].firstChild && obj.childNodes[c].firstChild.nodeType==3)
+ if (obj.childNodes[c].nodeName=='TD' && (node = obj.childNodes[c].firstChild) && (node.nodeType==3 || node.nodeName=='A'))
{
- subject = obj.childNodes[c].firstChild.data;
+ subject = node.nodeType==3 ? node.data : node.innerHTML;
names += (subject.length > 50 ? subject.substring(0, 50)+'...' : subject) + '<br />';
+ break;
}
}
}