From b136a797712eb5ffb8881eb7c761110e99bbf903 Mon Sep 17 00:00:00 2001 From: julmis Date: Sat, 22 May 2004 17:58:14 +0000 Subject: [PATCH] Fixing [Bug 1427] (Better than just uncommenting :-) ) --- lib/editor/popups/fullscreen.php | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/lib/editor/popups/fullscreen.php b/lib/editor/popups/fullscreen.php index 7755d9401b..c4180ca4e7 100644 --- a/lib/editor/popups/fullscreen.php +++ b/lib/editor/popups/fullscreen.php @@ -44,15 +44,17 @@ var editor = null; // to be initialized later [ function init() ] \* ---------------------------------------------------------------------- */ function _CloseOnEsc(ev) { - if (document.all) { - // IE - ev = window.event; - } - if (ev.keyCode == 27) { - // update_parent(); - window.close(); - return; - } + try { + if (document.all) { + // IE + ev || (ev = editor._iframe.contentWindow.event); + } + if (ev.keyCode == 27) { + // update_parent(); + window.close(); + return; + } + } catch(e) {} } /* ---------------------------------------------------------------------- *\ -- 2.39.5