summaryrefslogtreecommitdiff
path: root/program
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2015-01-10 14:20:12 +0100
committerAleksander Machniak <alec@alec.pl>2015-01-10 14:20:12 +0100
commitb6b2858b0172e54c1b497fae5019a868f8be5934 (patch)
treececa776390c991b90a51d3acbacf654c2b99c651 /program
parent1187f60d12db504b13dd3f0156926c5df40cba1e (diff)
Fix checks based on window.ActiveXObject in IE > 10
Diffstat (limited to 'program')
-rw-r--r--program/js/app.js4
-rw-r--r--program/js/common.js2
2 files changed, 3 insertions, 3 deletions
diff --git a/program/js/app.js b/program/js/app.js
index ece521861..826c2ef48 100644
--- a/program/js/app.js
+++ b/program/js/app.js
@@ -8066,7 +8066,7 @@ function rcube_webmail()
if (plugin && plugin.enabledPlugin)
return 1;
- if (window.ActiveXObject) {
+ if ('ActiveXObject' in window) {
try {
if (plugin = new ActiveXObject("AcroPDF.PDF"))
return 1;
@@ -8099,7 +8099,7 @@ function rcube_webmail()
if (plugin && plugin.enabledPlugin)
return 1;
- if (window.ActiveXObject) {
+ if ('ActiveXObject' in window) {
try {
if (plugin = new ActiveXObject("ShockwaveFlash.ShockwaveFlash"))
return 1;
diff --git a/program/js/common.js b/program/js/common.js
index 76643068d..2b96a8a30 100644
--- a/program/js/common.js
+++ b/program/js/common.js
@@ -103,7 +103,7 @@ function roundcube_browser()
this.xmlhttp_test = function()
{
var activeX_test = new Function("try{var o=new ActiveXObject('Microsoft.XMLHTTP');return true;}catch(err){return false;}");
- this.xmlhttp = (window.XMLHttpRequest || (window.ActiveXObject && activeX_test()));
+ this.xmlhttp = window.XMLHttpRequest || (('ActiveXObject' in window) && activeX_test());
return this.xmlhttp;
};