summaryrefslogtreecommitdiff
path: root/skins/larry/ui.js
diff options
context:
space:
mode:
authorAleksander Machniak <alec@alec.pl>2013-03-08 08:49:57 +0100
committerAleksander Machniak <alec@alec.pl>2013-03-08 08:51:03 +0100
commit527e7d45092a1efb9f72664210a591be0a6b2c2d (patch)
treeeb49897cb3a85c83bff10d83b9bbd73d24227009 /skins/larry/ui.js
parent91deac7c91e18bfa0e94715cd2966699588fad35 (diff)
Fix javascript errors when working in a page opened with taget="_blank"
Diffstat (limited to 'skins/larry/ui.js')
-rw-r--r--skins/larry/ui.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/skins/larry/ui.js b/skins/larry/ui.js
index d2638bbca..76485c11e 100644
--- a/skins/larry/ui.js
+++ b/skins/larry/ui.js
@@ -117,7 +117,8 @@ function rcube_mail_ui()
}).css('cursor', 'pointer');
// toggle compose options if opened in new window and they were visible before
- if (window.opener && opener.rcmail && opener.rcmail.env.action == 'compose' && $('#composeoptionstoggle', opener.document).hasClass('remove'))
+ var opener_rc = rcmail.opener();
+ if (opener_rc && opener_rc.env.action == 'compose' && $('#composeoptionstoggle', opener.document).hasClass('remove'))
$('#composeoptionstoggle').click();
new rcube_splitter({ id:'composesplitterv', p1:'#composeview-left', p2:'#composeview-right',