summaryrefslogtreecommitdiff
path: root/program
diff options
context:
space:
mode:
Diffstat (limited to 'program')
-rw-r--r--program/js/app.js19
-rw-r--r--program/localization/en_US/labels.inc1
2 files changed, 11 insertions, 9 deletions
diff --git a/program/js/app.js b/program/js/app.js
index 658f3c569..41f9a3859 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -4522,11 +4522,11 @@ function rcube_webmail()
this.ksearch_select = function(node)
{
if (this.ksearch_pane && node) {
- this.ksearch_pane.find('li.selected').removeClass('selected');
+ this.ksearch_pane.find('li.selected').removeClass('selected').removeAttr('aria-selected');
}
if (node) {
- $(node).addClass('selected');
+ $(node).addClass('selected').removeAttr('aria-selected', 'true');
this.ksearch_selected = node._rcm_id;
$(this.ksearch_input).attr('aria-activedecendant', 'rcmkSearchItem' + this.ksearch_selected);
}
@@ -4659,7 +4659,7 @@ function rcube_webmail()
return;
// display search results
- var i, len, ul, li, text, type, init,
+ var i, id, len, ul, text, type, init,
value = this.ksearch_value,
maxlen = this.env.autocomplete_max ? this.env.autocomplete_max : 15;
@@ -4697,12 +4697,13 @@ function rcube_webmail()
for (i=0; i < len && maxlen > 0; i++) {
text = typeof results[i] === 'object' ? results[i].name : results[i];
type = typeof results[i] === 'object' ? results[i].type : '';
- li = document.createElement('LI');
- li._rcm_id = i + this.env.contacts.length;
- li.id = 'rcmkSearchItem' + li._rcm_id;
- li.innerHTML = this.quote_html(text.replace(new RegExp('('+RegExp.escape(value)+')', 'ig'), '##$1%%')).replace(/##([^%]+)%%/g, '<b>$1</b>');
- if (type) li.className = type;
- ul.appendChild(li);
+ id = i + this.env.contacts.length;
+ $('<li>').attr('id', 'rcmkSearchItem' + id)
+ .attr('role', 'option')
+ .html(this.quote_html(text.replace(new RegExp('('+RegExp.escape(value)+')', 'ig'), '##$1%%')).replace(/##([^%]+)%%/g, '<b>$1</b>'))
+ .addClass(type || '')
+ .appendTo(ul)
+ .get(0)._rcm_id = id;
maxlen -= 1;
}
}
diff --git a/program/localization/en_US/labels.inc b/program/localization/en_US/labels.inc
index 3ac7f03aa..23f22a969 100644
--- a/program/localization/en_US/labels.inc
+++ b/program/localization/en_US/labels.inc
@@ -259,6 +259,7 @@ $labels['upload'] = 'Upload';
$labels['uploadprogress'] = '$percent ($current from $total)';
$labels['close'] = 'Close';
$labels['messageoptions'] = 'Message options...';
+$labels['togglecomposeoptions'] = 'Toggle composition options';
$labels['low'] = 'Low';
$labels['lowest'] = 'Lowest';