summaryrefslogtreecommitdiff
path: root/program
diff options
context:
space:
mode:
Diffstat (limited to 'program')
-rw-r--r--program/js/app.js5
-rw-r--r--program/js/common.js7
-rw-r--r--program/js/list.js1
3 files changed, 5 insertions, 8 deletions
diff --git a/program/js/app.js b/program/js/app.js
index c19ff62b2..5d7e28640 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -178,11 +178,6 @@ function rcube_webmail()
parent.rcmail.env.frame_lock = null;
}
- // Makes that reference to document.activeElement do not throw
- // "unspecified error" in IE9 (#1489008)
- if (this.env.framed && bw.ie)
- document.documentElement.focus();
-
// enable general commands
this.enable_command('close', 'logout', 'mail', 'addressbook', 'settings', 'save-pref',
'compose', 'undo', 'about', 'switch-task', 'menu-open', 'menu-save', true);
diff --git a/program/js/common.js b/program/js/common.js
index 1075225b4..f7c0a7536 100644
--- a/program/js/common.js
+++ b/program/js/common.js
@@ -717,7 +717,7 @@ if (bw.ie) {
// jQuery plugin to emulate HTML5 placeholder attributes on input elements
jQuery.fn.placeholder = function(text) {
return this.each(function() {
- var elem = $(this);
+ var active = false, elem = $(this);
this.title = text;
// Try HTML5 placeholder attribute first
@@ -742,8 +742,9 @@ jQuery.fn.placeholder = function(text) {
elem[(active ? 'addClass' : 'removeClass')]('placeholder').attr('spellcheck', active);
});
- // Do not blur currently focused element
- if (this != document.activeElement)
+ // Do not blur currently focused element (catch exception: #1489008)
+ try { active = this == document.activeElement; } catch(e) {}
+ if (!active)
elem.blur();
}
});
diff --git a/program/js/list.js b/program/js/list.js
index 9a531eaea..b677efeaa 100644
--- a/program/js/list.js
+++ b/program/js/list.js
@@ -692,6 +692,7 @@ select_row: function(id, mod_key, with_mouse)
this.shift_start = null;
this.last_selected = id;
+ this.list.focus();
},