summaryrefslogtreecommitdiff
path: root/skins/classic/functions.js
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2013-04-29 10:43:13 +0200
committerAleksander Machniak <alec@alec.pl>2013-04-29 10:43:13 +0200
commitc958452d098be0cedf39e96a1ea29b1b5f265067 (patch)
tree68e423dafbf6213c8f9eec4a3c8465283aba265e /skins/classic/functions.js
parent7dcf242dd936838f0f1e6c7b46f1cc391e9e34df (diff)
Catch possible "Permission denied" error on iframe elements in IE
Diffstat (limited to 'skins/classic/functions.js')
-rw-r--r--skins/classic/functions.js9
1 files changed, 7 insertions, 2 deletions
diff --git a/skins/classic/functions.js b/skins/classic/functions.js
index 499783b3f..0d2f2231a 100644
--- a/skins/classic/functions.js
+++ b/skins/classic/functions.js
@@ -664,8 +664,13 @@ function rcmail_scroller(list, top, bottom)
function iframe_events()
{
// this==iframe
- var doc = this.contentDocument ? this.contentDocument : this.contentWindow ? this.contentWindow.document : null;
- rcube_event.add_listener({ element: doc, object:rcmail_ui, method:'body_mouseup', event:'mouseup' });
+ try {
+ var doc = this.contentDocument ? this.contentDocument : this.contentWindow ? this.contentWindow.document : null;
+ rcube_event.add_listener({ element: doc, object:rcmail_ui, method:'body_mouseup', event:'mouseup' });
+ }
+ catch (e) {
+ // catch possible "Permission denied" error in IE
+ };
};
// Abbreviate mailbox names to fit width of the container