#1485403: fix "bolding" of folder with subfolders with more than two levels

release-0.6
alecpl 16 years ago
parent 94a99c11f4
commit 07d36706e5

@ -3555,7 +3555,7 @@ function rcube_webmail()
var reg, text_obj, item, mycount, childcount, div; var reg, text_obj, item, mycount, childcount, div;
if (item = this.get_folder_li(mbox)) if (item = this.get_folder_li(mbox))
{ {
mycount = this.env.unread_counts[mbox]; mycount = this.env.unread_counts[mbox] ? this.env.unread_counts[mbox] : 0;
text_obj = item.getElementsByTagName('a')[0]; text_obj = item.getElementsByTagName('a')[0];
reg = /\s+\([0-9]+\)$/i; reg = /\s+\([0-9]+\)$/i;
@ -3578,7 +3578,7 @@ function rcube_webmail()
text_obj.innerHTML = text_obj.innerHTML.replace(reg, ''); text_obj.innerHTML = text_obj.innerHTML.replace(reg, '');
// set parent's display // set parent's display
reg = new RegExp(RegExp.escape(this.env.delimiter) + '[^' + RegExp.escape(this.env.delimiter) + ']+'); reg = new RegExp(RegExp.escape(this.env.delimiter) + '[^' + RegExp.escape(this.env.delimiter) + ']+$');
if (mbox.match(reg)) if (mbox.match(reg))
this.set_unread_count_display(mbox.replace(reg, ''), false); this.set_unread_count_display(mbox.replace(reg, ''), false);

Loading…
Cancel
Save